Publish, unpublish or delete a menu item
Show a menu item to customers, hide it, or remove it.
POST
{BASE_URL}/menu/items/:externalId/publishPOST
{BASE_URL}/menu/items/:externalId/unpublishDELETE
{BASE_URL}/menu/items/:externalIdRequires the UPDATE scope.
- Publish shows the item on your menu; unpublish hides it. Both answer the item, in the shape
PUT /menu/itemsreturns. Calling either twice is harmless. - Delete removes the item. Orders that included it keep their own copy of what was ordered.
A sandbox key changes nothing and answers "dryRun": true.
An item that does not exist, or that another integration manages, answers 404 resource_not_found.
Status codes#
| Status | Code | When |
|---|---|---|
200 | — | Done, or "dryRun": true for a sandbox key. |
400 | externalId_invalid | The externalId is not 1–128 letters, digits or . _ ~ : -. |
403 | provider_module_not_allowed | A Technology Provider without the Dining module. |
404 | resource_not_found | No listing with that externalId that you manage. |
cURL
curl -X POST "$LOCALOY_BASE_URL/menu/items/sku-4471/publish" \
-H "Authorization: Bearer $LOCALOY_API_KEY"Response · 200
{
"success": true,
"message": "Published",
"dryRun": false,
"data": { "externalId": "sku-4471", "published": true, "…": "…" }
}cURL
curl -X DELETE "$LOCALOY_BASE_URL/menu/items/sku-4471" \
-H "Authorization: Bearer $LOCALOY_API_KEY"Response · 200
{ "success": true, "message": "Menu item deleted", "dryRun": false }