For developers and AI
API and MCP for your restaurant
Let your website, your own programs and AI tools like Claude Code or Cursor work with your Plattr menu, bookings and loyalty. One key, only the rights you choose, and every change is in your journal, where you can undo it.
- Only the sections you choose
- Read only or read and change
- Every change logged and undoable
- No guest contacts
Start
Start in three steps
Open API & MCP
In Plattr: Restaurant settings → API & MCP. Keys come with the Mini plan.
Create a key
Choose what it may open (menu, bookings, loyalty) and whether it may only read or also change. The key is shown once.
Paste it
Into your AI tool with the lines below, or into your server as the Authorization header.
MCP
Connect an AI tool
MCP lets AI tools work with Plattr directly. Any tool that can send a header works, for example Claude Code and Cursor. The AI sees only the tools its key allows.
MCP address
https://www.plattr.me/api/mcpClaude Code: run in the terminal
claude mcp add --transport http plattr https://www.plattr.me/api/mcp --header "Authorization: Bearer pk_live_YOUR_KEY"Cursor and other tools: add to mcp.json
{
"mcpServers": {
"plattr": {
"url": "https://www.plattr.me/api/mcp",
"headers": {
"Authorization": "Bearer pk_live_YOUR_KEY"
}
}
}
}Replace pk_live_YOUR_KEY with your key.
The tools an AI can get
| Tool | What it does | Access | Needs |
|---|---|---|---|
get_menu | Read the dishes | read | Menu |
get_menu_categories | Read the menu categories | read | Menu |
get_dish | Read one dish | read | Menu |
update_dish | Change name, description, price, calories or availability | change | Menu |
list_bookings | List bookings | read | Bookings · Standard plan |
check_availability | Find free times on a day | read | Bookings · Standard plan |
get_booking | Read one booking | read | Bookings · Standard plan |
create_booking | Create a booking | change | Bookings · Standard plan |
update_booking | Change day, time, party size, status or table | change | Bookings · Standard plan |
cancel_booking | Cancel a booking | change | Bookings · Standard plan |
get_loyalty_programs | Read the loyalty programs | read | Loyalty |
get_loyalty_summary | Read loyalty totals | read | Loyalty |
API
Call the API from your server
JSON over HTTPS. Put the key in the Authorization header. Keys work only from a server: a request from a web page is refused, so a key never ends up in a browser.
Example: read the menu
curl https://www.plattr.me/api/v1/menu \
-H "Authorization: Bearer pk_live_YOUR_KEY"Menu
| GET | /menu | Dishes with price, photo, allergens, ingredients and calories. ?category_id= for one category. |
| GET | /menu?resource=categories | The menu categories. |
| GET | /menu/items/:id | One dish. |
| PATCH | /menu/items/:id | Change name, description, price, calories or is_active. |
Bookings
| GET | /bookings | Bookings (date_from, date_to, status), without guest contacts. |
| POST | /bookings | Create a booking. |
| GET | /bookings/availability?date=YYYY-MM-DD | Free times on a day (party_size optional). |
| GET | /bookings/:id | One booking. |
| PUT | /bookings/:id | Change day, time, party size, status or table. |
| DELETE | /bookings/:id | Cancel a booking. |
Loyalty
| GET | /loyalty?resource=programs | The loyalty programs. |
| GET | /loyalty?resource=summary | Loyalty totals, no single guest named. |
Answers
What comes back
Every answer is JSON with one key: items, categories, item or bookings. The whole menu comes in one answer, there are no pages.
GET /menu
{
"items": [
{
"id": "3f6c2a1e-8b4d-4c2a-9a51-0d6e7f1b2c3d",
"name": "Margherita",
"description": "Tomato, mozzarella, basil",
"price": 12.5,
"image_url": "https://cdn.plattr.me/restaurants/…/margherita.webp",
"category_id": "9a1b7c3d-2e4f-4a5b-8c6d-7e8f9a0b1c2d",
"is_active": true,
"allergens": [
"gluten",
"milk",
"vegetarian"
],
"calories": 820,
"ingredients": [
"tomato",
"mozzarella",
"basil"
],
"display_order": 1
}
]
}GET /menu?resource=categories
{
"categories": [
{
"id": "9a1b7c3d-2e4f-4a5b-8c6d-7e8f9a0b1c2d",
"name": "Pizza",
"description": null,
"display_order": 2,
"is_active": true
}
]
}The fields of a dish
| Field | What it is |
|---|---|
id | The dish id, for /menu/items/:id. |
name | As the owner wrote it, in the menu's language. |
description | Text or null. |
price | A number in the restaurant's currency, not cents: 12.5 is 12.50. The API does not send the currency. |
image_url | The photo, or null. |
category_id | The category's id (from ?resource=categories), or null. |
is_active | false = not on sale right now. Such dishes are in the list too: hide them yourself. |
allergens | Codes: the 14 EU allergens and diet labels (lists below). Older menus may also hold words the owner typed. |
calories | A whole number, or null. |
ingredients | A list of words, or of { name, quantity }, or null. |
display_order | The owner's order: sort by it, lowest first. |
Allergen codes (EU)
- gluten
- crustaceans
- eggs
- fish
- peanuts
- soy
- milk
- nuts
- celery
- mustard
- sesame
- sulphites
- lupin
- molluscs
Diet labels
- vegan
- vegetarian
- halal
- kosher
- gluten-free
- lactose-free
- sugar-free
- spicy
- The API gives the menu, not the restaurant's name or address: put those on your site yourself.
- A single dish (GET /menu/items/:id) comes as { "item": … } with its category's id and name.
Safety
What a key can and cannot do
- Only what you tick: menu, bookings, loyalty. Anything else is refused.
- Read only, or read and change. A read-only key cannot change anything.
- Every request is written to your journal first: which key, what, the old and the new value. No journal line, no data. Reads are written once per key and kind of read every 10 minutes, changes every time.
- Each line in the journal says AI (MCP) or API, and a change to a dish or a booking can be undone.
- Allergens and ingredients are changed only by you, in Plattr.
- Guest names, e-mails and phone numbers are not available through a key.
- Revoke a key at any time: it stops working at once.
Refusals
When something is refused
A refusal is JSON with error (text) and, where there is one, code: { "error": "This API key may only read", "code": "scope_forbidden" }. A plan refusal says it in error: { "error": "upgrade_required", "requiredPlan": "standard" }.
- 401
- No key, a wrong key, or an expired or revoked key.
- 403 server_only
- The request came from a web page: it carried a browser's Origin or Sec-Fetch-Site header. curl, Node's fetch and other server code do not send them.
- 403 section_forbidden
- The key does not have this section.
- 403 scope_forbidden
- The key may only read.
- 403 allergens_owner_only
- Allergens and ingredients are changed only in Plattr.
- 403 upgrade_required
- The plan does not include it: API from Mini, bookings from Standard.
- 429 rate_limited
- Too many requests. Wait a minute.
- 503 log_unavailable
- The journal could not be written, so nothing was read or changed. Try again.