End-to-end example
A complete walkthrough from a new app to a fulfilled test order, in one place.
This tutorial takes one order from a new app to fulfilled in test mode. Each step links the page that covers it in depth.
You need a developers.maple.inc account and a public HTTPS URL you control to receive webhooks. A tunnel to your laptop works. Every call below goes to https://api.maple.inc/v1.
export MAPLE_BASE="https://api.maple.inc/v1"export MAPLE_KEY="mpk_test_..."Create an app and a test key
In the console, create an organization and an app. On Home, choose Create test key and give it
locations:read,orders:readandorders:write. Copy the key intoMAPLE_KEY; it is shown once. See the Quickstart.Check the key:
curl "$MAPLE_BASE/me" -H "Authorization: Bearer $MAPLE_KEY"The answer is the
app, withlivemode: falseand the key’sscopes.Create a test restaurant
On Home, choose Create test restaurant. Leave Add a sample menu on. The console grants your app access to the restaurant and makes it the order receiver, so you need no grant from anyone and no
POST /v1/locations/{locationId}/connection. Read it back:curl "$MAPLE_BASE/locations" -H "Authorization: Bearer $MAPLE_KEY"Keep the location
id(str_…). For a real restaurant you are granted instead, then connect: see Get installed and Receive and decide orders.Register a webhook endpoint
Register your URL for the order events, either under Webhooks → Endpoints or with the API:
curl -X POST "$MAPLE_BASE/webhook_endpoints" \-H "Authorization: Bearer $MAPLE_KEY" \-H "Content-Type: application/json" \-d '{"url": "https://your-app.example.com/maple/webhooks","enabled_events": ["order.submitted", "order.rejected", "order.canceled"]}'The answer carries the
secret(mwhsec_…) once. Store it and verify the signature of every delivery. Maple sends an event only to endpoints that exist when it happens, so register the endpoint before the next step.Place a test order
In the console, open your app’s Restaurants page and choose Place test order on the restaurant. It is a real pay-in-store pickup order that runs through the normal workflow; no card is charged. Your endpoint receives an
order.submittedevent:{"object": "event","id": "evt_...","type": "order.submitted","api_version": "2026-11-27","created": 1765432100,"livemode": false,"data": { "object": { "object": "order", "id": "ord_...", "status": "submitted", "...": "the order" } }}data.objectis the order thatGET /v1/orders/{orderId}returns. Set itsidasORDER_ID:export ORDER_ID="ord_..."Accept it
curl -X POST "$MAPLE_BASE/orders/$ORDER_ID/accept" -H "Authorization: Bearer $MAPLE_KEY"To refuse an order instead, call
rejectwith an optional{ "reason": "…" }. Add anIdempotency-Keyheader to any call you may retry; see Idempotency.Mark it ready, then fulfill it
curl -X POST "$MAPLE_BASE/orders/$ORDER_ID/ready" -H "Authorization: Bearer $MAPLE_KEY"curl -X POST "$MAPLE_BASE/orders/$ORDER_ID/fulfill" -H "Authorization: Bearer $MAPLE_KEY"Read the order after each call:
curl "$MAPLE_BASE/orders/$ORDER_ID" -H "Authorization: Bearer $MAPLE_KEY"Its
statusmovessubmitted → accepted → ready → fulfilled.fulfilledis terminal. An accepted order can also be canceled withcancel, any time before it is fulfilled. See the Order lifecycle.Look at what happened
In the console, Requests shows each call by its
x-request-idand Webhooks → Deliveries shows what Maple sent to your endpoint. To read the events through the API, callGET /v1/events. See Webhooks.
Next
Publish your restaurant’s menu with Publish your catalog, then follow Going live.