Keys and scopes
Two kinds of key
| Secret key | Website key | |
|---|---|---|
| Looks like | rf_sk_… | rf_pk_… |
| Use it in | Your server, app backend, AI assistant settings | Web pages (JavaScript in the browser) |
| Can | Any scope you give it | Only public scopes (menu, availability, booking) |
| Limits | Branches, expiry date | Branches, expiry date, and the websites allowed to use it |
Send either as Authorization: Bearer … (or X-API-Key). Keys are shown once when created; RestoFleet keeps only a SHA-256 fingerprint. Revoke a key at any time in Setup → API keys; it stops working immediately.
From a web page with a website key
fetch('https://api.restofleet.com/api/v1/open/restaurant', {
headers: { Authorization: 'Bearer rf_pk_...' },
}).then((r) => r.json());Scopes
| Scope | Allows | Website keys |
|---|---|---|
brand:read | Restaurant & branches. Name, branches, address, phone and opening hours. | Yes |
menu:read | Menu. Categories, dishes, prices and what is available now. | Yes |
availability:read | Table availability. Free booking times for a date and party size. | Yes |
reservations:write | Book tables. Create bookings (and cancel them with a secret key). | Yes |
reservations:read | Read bookings. Look up a booking by its id. | No |
guests:read | Guest loyalty. Find a guest by phone: name, visits and points. | No |