{"openapi":"3.1.0","info":{"title":"Webkio API","version":"1.0.0","description":"Read a Webkio account's sites, orders and contacts; add contacts, email subscribers and blog post drafts; and subscribe URLs to its events.\n\n**Blank fields**: in a request body, a field you leave out or send empty changes nothing.\n\n**Authentication**: an API key (Settings > API & webhooks, or the developer console) as `Authorization: Bearer wk_...`.\n\n**Times**: every timestamp is ISO 8601 in UTC. The account and each site carry a `timezone` (IANA) for display; booking and reservation dates and times are the site's local ones.\n\n**Lists** are cursor-paginated: `limit` (1-100, default 25) and `cursor` (the previous page's `meta.next_cursor`) until `meta.has_more` is false.\n\n**Errors** are `{\"success\": false, \"error\": {\"code\": \"...\", \"message\": \"...\"}}`. Branch on the code:\n- `missing_api_key`: No key was sent.\n- `invalid_api_key`: The key is unknown or revoked.\n- `console_token_expired`: The developer site's temporary token has expired; reload the explorer.\n- `account_unavailable`: The account is deleted, suspended or banned.\n- `plan_required`: The account's plan does not include integrations, or the feature the endpoint uses (the CRM, the blog).\n- `plan_limit_reached`: A limit of the plan is reached: new subscribers this month, or blog posts on a site.\n- `read_only_demo`: The demo account cannot change anything.\n- `rate_limited`: Over 200 requests a minute. Retry-After says when to come back.\n- `not_found`: No such endpoint.\n- `resource_not_found`: No such record on this account.\n- `unknown_event`: The event type is not one GET /v1/event-types lists.\n- `invalid_target_url`: The webhook URL is not https, not public, or too long.\n- `invalid_project`: project_id is not one of this account's sites.\n- `invalid_list`: list_id is not one of the site's email lists.\n- `email_rejected`: Webkio does not send email to that address: it bounced or complained before, or it is a throwaway address.\n- `webhook_limit_reached`: The account already has 50 webhooks.\n- `invalid_cursor`: The cursor was not one this API gave out.\n- `validation_failed`: The request was understood but not accepted; the message says why.\n- `server_error`: Something failed on our side.\n\n200 requests a minute per account. Guide: https://webkio.com/docs/api-and-webhooks","contact":{"name":"Webkio support","url":"https://webkio.com/docs/api-and-webhooks","email":"contact@webkio.com"},"termsOfService":"https://webkio.com/terms"},"servers":[{"url":"https://api.webkio.com/v1"}],"security":[{"bearerAuth":[]}],"tags":[{"name":"Account","description":"Who the key belongs to, and their sites."},{"name":"Webhooks","description":"Event types, sample data, and subscriptions."},{"name":"Contacts","description":"The CRM's people, matched on email within a site. Plans with the CRM."},{"name":"Email","description":"Email subscribers and lists."},{"name":"Blog","description":"Blog post drafts, to publish from the dashboard."},{"name":"Orders","description":"Orders, read only."}],"paths":{"/me":{"get":{"tags":["Account"],"operationId":"getMe","summary":"The account the key belongs to","description":"Integrations call this to test a connection.","responses":{"200":{"description":"The account.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Account"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/projects":{"get":{"tags":["Account"],"operationId":"listProjects","summary":"The account's sites","parameters":[{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"Sites, oldest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/Project"}},"meta":{"$ref":"#/components/schemas/ListMeta"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/event-types":{"get":{"tags":["Webhooks"],"operationId":"listEventTypes","summary":"The events a webhook can subscribe to","description":"The whole list; it is short and not paginated.","responses":{"200":{"description":"Every event type.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/EventType"}}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/event-types/{type}/samples":{"get":{"tags":["Webhooks"],"operationId":"listEventSamples","summary":"Newest records for an event type","description":"Your own newest records, in exactly the shape a webhook delivers them.","parameters":[{"name":"type","in":"path","required":true,"schema":{"type":"string","enum":["order.created","order.paid","booking.created","rental.reserved","subscriber.created","property_enquiry.created","review.submitted"]}},{"name":"project_id","in":"query","required":false,"schema":{"type":"string"},"description":"Only this site."},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":10,"default":3}}],"responses":{"200":{"description":"Newest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/EventEnvelope"}}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/webhooks":{"get":{"tags":["Webhooks"],"operationId":"listWebhooks","summary":"The account's webhooks","parameters":[{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"Newest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/Webhook"}},"meta":{"$ref":"#/components/schemas/ListMeta"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["Webhooks"],"operationId":"createWebhook","summary":"Subscribe a URL to an event","description":"The URL must be https and public. Subscribing the same URL to the same event again returns the existing webhook. The signing secret is returned only here.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["event","target_url"],"properties":{"event":{"type":"string","enum":["order.created","order.paid","booking.created","rental.reserved","subscriber.created","property_enquiry.created","review.submitted"]},"target_url":{"type":"string","format":"uri","examples":["https://example.com/webkio"]},"project_id":{"type":"string","description":"Only this site. Leave out for every site."}}}}}},"responses":{"201":{"description":"The webhook, with its secret.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/WebhookCreated"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/webhooks/{id}":{"get":{"tags":["Webhooks"],"operationId":"getWebhook","summary":"One webhook","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The webhook (without its secret).","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Webhook"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["Webhooks"],"operationId":"deleteWebhook","summary":"Remove a webhook","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Removed.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"object","properties":{"deleted":{"type":"boolean"}}}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/contacts":{"get":{"tags":["Contacts"],"operationId":"listContacts","summary":"Find contacts","description":"Newest first. Pass `email` to find one person.","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"},"description":"Only this site."},{"name":"email","in":"query","required":false,"schema":{"type":"string","format":"email"},"description":"Only the contact with this email. Not case-sensitive."},{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"Contacts, newest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/Contact"}},"meta":{"$ref":"#/components/schemas/ListMeta"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["Contacts"],"operationId":"upsertContact","summary":"Create or update a contact","description":"Matched on `email` within the site: an email the site does not know creates a contact (201), a known one updates it (200). `name`, `phone` and `notes` replace what is stored; `tags` are added to the contact's own.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactInput"}}}},"responses":{"200":{"description":"The updated contact.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Contact"}}}}}},"201":{"description":"The new contact.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Contact"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/contacts/{id}":{"get":{"tags":["Contacts"],"operationId":"getContact","summary":"One contact","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The contact.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Contact"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/subscribers":{"post":{"tags":["Email"],"operationId":"addSubscriber","summary":"Add an email subscriber","description":"Adds the address to the site's subscribers, active at once, and to `list_id` when sent. Only send people who agreed to hear from the site. Someone already subscribed is not added twice (200): they join the list, gain the tags and keep their status, so an address that unsubscribed stays unsubscribed. A new subscriber (201) counts toward the plan's monthly limit and starts the site's welcome automation.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriberInput"}}}},"responses":{"200":{"description":"Already subscribed.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Subscriber"}}}}}},"201":{"description":"The new subscriber.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Subscriber"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/email-lists":{"get":{"tags":["Email"],"operationId":"listEmailLists","summary":"Email lists","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"},"description":"Only this site."},{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"Lists, oldest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/EmailList"}},"meta":{"$ref":"#/components/schemas/ListMeta"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/blog-posts":{"post":{"tags":["Blog"],"operationId":"createBlogPost","summary":"Create a blog post draft","description":"Always a draft: it is published from the dashboard, where it is checked before it goes live. The slug is made from the title unless you send one, and kept unique on the site. `content` is HTML; scripts and unsafe markup are removed.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlogPostInput"}}}},"responses":{"201":{"description":"The draft.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/BlogPost"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/products":{"get":{"tags":["Products"],"operationId":"listProducts","summary":"Find products","description":"Newest first. Includes products that have been switched off, so a catalogue sync can withdraw them too - filter with `active` if you only want the ones on sale. Stock lives on the variant for anything sold by size or colour, so read `variants[].stock` when `variants` is not empty.","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"},"description":"Only this site."},{"name":"sku","in":"query","required":false,"schema":{"type":"string"},"description":"The SKU, exactly. How you find the product behind an order line."},{"name":"type","in":"query","required":false,"schema":{"type":"string","enum":["physical","digital","service","bundle"]}},{"name":"category_id","in":"query","required":false,"schema":{"type":"string"}},{"name":"active","in":"query","required":false,"schema":{"type":"boolean"},"description":"Omit for both."},{"name":"search","in":"query","required":false,"schema":{"type":"string"},"description":"Matches name or SKU."},{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"Products, newest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"meta":{"$ref":"#/components/schemas/ListMeta"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/products/{id}":{"get":{"tags":["Products"],"operationId":"getProduct","summary":"One product","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The product.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Product"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/products/{id}/stock":{"put":{"tags":["Products"],"operationId":"setProductStock","summary":"Set what is in stock","description":"States the real count rather than adjusting by a difference, because every caller retries: a repeated `-3` destroys the figure, a repeated `= 42` is simply true again. Pass `variant_id` for anything sold by size or colour. The owner is warned when a product drops INTO its low-stock window, and not again while it stays there, so a nightly sync does not email them nightly. Refused on a product that does not track stock.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["quantity"],"properties":{"quantity":{"type":"integer","minimum":0,"description":"Whole number, zero or more."},"variant_id":{"type":"string","description":"Required for a product with variants, since stock lives there."}}}}}},"responses":{"200":{"description":"The updated product.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Product"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/orders":{"get":{"tags":["Orders"],"operationId":"listOrders","summary":"Find orders","description":"Newest first. Each order reads as the order webhooks send it.","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"},"description":"Only this site."},{"name":"number","in":"query","required":false,"schema":{"type":"string"},"description":"The order number, exactly."},{"name":"email","in":"query","required":false,"schema":{"type":"string","format":"email"},"description":"The customer's email. Not case-sensitive."},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["pending","paid","processing","shipped","delivered","refunded","cancelled"]}},{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"Orders, newest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/Order"}},"meta":{"$ref":"#/components/schemas/ListMeta"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/orders/{id}":{"get":{"tags":["Orders"],"operationId":"getOrder","summary":"One order","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The order.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Order"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["Orders"],"operationId":"updateOrder","summary":"Move an order's status on","description":"Moves the order and does what goes with it: tracking details are saved, shipping is timestamped, a cancellation puts the stock back, and the customer is emailed - the same as a change made in the dashboard. An order is marked **paid** by the payment flow and **refunded** by the refund action, so neither is settable here.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["status"],"properties":{"status":{"type":"string","enum":["processing","shipped","delivered","cancelled"]},"tracking_number":{"type":"string","description":"Saved against the order; usually sent with `shipped`."},"tracking_url":{"type":"string","format":"uri"}}}}}},"responses":{"200":{"description":"The updated order.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Order"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/bookings":{"get":{"tags":["Bookings"],"operationId":"listBookings","summary":"Find bookings","description":"Newest first. Each booking reads as the booking.created webhook sends it. from/to filter the APPOINTMENT date, not when it was made.","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"},"description":"Only this site."},{"name":"email","in":"query","required":false,"schema":{"type":"string","format":"email"},"description":"The customer's email. Not case-sensitive."},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["pending","confirmed","cancelled","completed","no-show"]}},{"name":"from","in":"query","required":false,"schema":{"type":"string","format":"date"},"description":"Appointments on or after this date (YYYY-MM-DD)."},{"name":"to","in":"query","required":false,"schema":{"type":"string","format":"date"},"description":"Appointments on or before this date (YYYY-MM-DD)."},{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"Bookings, newest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/Booking"}},"meta":{"$ref":"#/components/schemas/ListMeta"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/bookings/{id}":{"get":{"tags":["Bookings"],"operationId":"getBooking","summary":"One booking","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The booking.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Booking"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["Bookings"],"operationId":"updateBooking","summary":"Change a booking's status","description":"Moves the booking and does everything that goes with it: a cancellation refunds a card payment where the policy allows, and the customer is emailed - the same as a change made in the dashboard.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["status"],"properties":{"status":{"type":"string","enum":["pending","confirmed","cancelled","completed","no-show"]}}}}}},"responses":{"200":{"description":"The updated booking.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Booking"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/reservations":{"get":{"tags":["Reservations"],"operationId":"listReservations","summary":"Find rental reservations","description":"Newest first. Each reservation reads as the rental.reserved webhook sends it. from/to filter the PICKUP date, not when the reservation was taken.","parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"},"description":"Only this site."},{"name":"reference","in":"query","required":false,"schema":{"type":"string"},"description":"The reservation reference, exactly."},{"name":"email","in":"query","required":false,"schema":{"type":"string","format":"email"},"description":"The customer's email. Not case-sensitive."},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["pending","confirmed","cancelled","completed"]}},{"name":"from","in":"query","required":false,"schema":{"type":"string","format":"date"},"description":"Pick-ups on or after this date (YYYY-MM-DD)."},{"name":"to","in":"query","required":false,"schema":{"type":"string","format":"date"},"description":"Pick-ups on or before this date (YYYY-MM-DD)."},{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"Reservations, newest first.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"type":"array","items":{"$ref":"#/components/schemas/Reservation"}},"meta":{"$ref":"#/components/schemas/ListMeta"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/reservations/{id}":{"get":{"tags":["Reservations"],"operationId":"getReservation","summary":"One reservation","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"The reservation.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Reservation"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["Reservations"],"operationId":"updateReservation","summary":"Change a reservation's status","description":"Moves the reservation and does everything that goes with it: a cancellation refunds a card payment where the policy allows, releases the deposit hold, and emails the customer - the same as a change made in the dashboard.","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["status"],"properties":{"status":{"type":"string","enum":["pending","confirmed","cancelled","completed"]}}}}}},"responses":{"200":{"description":"The updated reservation.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","const":true},"data":{"$ref":"#/components/schemas/Reservation"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"422":{"$ref":"#/components/responses/ValidationError"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/openapi.json":{"get":{"tags":["Account"],"operationId":"getOpenApi","summary":"This description","security":[],"responses":{"200":{"description":"The OpenAPI document.","content":{"application/json":{"schema":{"type":"object"}}}}}}}},"webhooks":{"order.created":{"post":{"operationId":"onOrderCreated","summary":"New order","description":"An order is placed in your shop. Card payments may still be pending. Sent to every URL subscribed to `order.created`, signed with that subscription's secret.","parameters":[{"name":"X-Webkio-Event","in":"header","required":true,"schema":{"type":"string","const":"order.created"}},{"name":"X-Webkio-Delivery","in":"header","required":true,"schema":{"type":"string"}},{"name":"X-Webkio-Timestamp","in":"header","required":true,"schema":{"type":"integer"},"description":"Unix seconds when it was sent."},{"name":"X-Webkio-Signature","in":"header","required":true,"schema":{"type":"string"},"description":"\"v1=\" + hex HMAC-SHA256 of \"{timestamp}.{raw body}\" keyed with the subscription secret."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventEnvelope"},"example":{"id":"order.created_Ab12Cd","event":"order.created","project":{"id":"xYz12AbC","name":"Your Shop","timezone":"America/New_York"},"data":{"id":"Ab12Cd","number":"ORD-260914-0001","status":"pending","type":"shipping","customer":{"name":"Sofia Almeida","email":"sofia@example.com","phone":"+1 212 555 0198"},"currency":"USD","subtotal":42.5,"shipping":4.95,"tip":null,"discount":null,"tax":0,"total":47.45,"payment_method":"card","shipping_method":"Standard","shipping_address":{"line1":"1 Main Street","city":"Austin","postcode":"78701","country":"US"},"coupon_code":null,"note":null,"scheduled_for":null,"items":[{"name":"Linen apron","sku":"APR-01","quantity":2,"price":21.25,"total":42.5}],"created_at":"2026-09-14T09:30:00Z"}}}}},"responses":{"2XX":{"description":"Received. Answer within 10 seconds."},"410":{"description":"Unsubscribe: the webhook is removed."}}}},"order.paid":{"post":{"operationId":"onOrderPaid","summary":"Order paid","description":"Payment for an order is confirmed. Sent to every URL subscribed to `order.paid`, signed with that subscription's secret.","parameters":[{"name":"X-Webkio-Event","in":"header","required":true,"schema":{"type":"string","const":"order.paid"}},{"name":"X-Webkio-Delivery","in":"header","required":true,"schema":{"type":"string"}},{"name":"X-Webkio-Timestamp","in":"header","required":true,"schema":{"type":"integer"},"description":"Unix seconds when it was sent."},{"name":"X-Webkio-Signature","in":"header","required":true,"schema":{"type":"string"},"description":"\"v1=\" + hex HMAC-SHA256 of \"{timestamp}.{raw body}\" keyed with the subscription secret."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventEnvelope"},"example":{"id":"order.paid_Ab12Cd","event":"order.paid","project":{"id":"xYz12AbC","name":"Your Shop","timezone":"America/New_York"},"data":{"status":"paid","id":"Ab12Cd","number":"ORD-260914-0001","type":"shipping","customer":{"name":"Sofia Almeida","email":"sofia@example.com","phone":"+1 212 555 0198"},"currency":"USD","subtotal":42.5,"shipping":4.95,"tip":null,"discount":null,"tax":0,"total":47.45,"payment_method":"card","shipping_method":"Standard","shipping_address":{"line1":"1 Main Street","city":"Austin","postcode":"78701","country":"US"},"coupon_code":null,"note":null,"scheduled_for":null,"items":[{"name":"Linen apron","sku":"APR-01","quantity":2,"price":21.25,"total":42.5}],"created_at":"2026-09-14T09:30:00Z"}}}}},"responses":{"2XX":{"description":"Received. Answer within 10 seconds."},"410":{"description":"Unsubscribe: the webhook is removed."}}}},"booking.created":{"post":{"operationId":"onBookingCreated","summary":"New booking","description":"A customer books an appointment. Sent to every URL subscribed to `booking.created`, signed with that subscription's secret.","parameters":[{"name":"X-Webkio-Event","in":"header","required":true,"schema":{"type":"string","const":"booking.created"}},{"name":"X-Webkio-Delivery","in":"header","required":true,"schema":{"type":"string"}},{"name":"X-Webkio-Timestamp","in":"header","required":true,"schema":{"type":"integer"},"description":"Unix seconds when it was sent."},{"name":"X-Webkio-Signature","in":"header","required":true,"schema":{"type":"string"},"description":"\"v1=\" + hex HMAC-SHA256 of \"{timestamp}.{raw body}\" keyed with the subscription secret."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventEnvelope"},"example":{"id":"booking.created_Bk34Ef","event":"booking.created","project":{"id":"xYz12AbC","name":"Your Shop","timezone":"America/New_York"},"data":{"id":"Bk34Ef","service":"Haircut and finish","date":"2026-09-20","time":"14:30","status":"confirmed","customer":{"name":"Sofia Almeida","email":"sofia@example.com","phone":"+1 212 555 0198"},"amount_due":45,"currency":"USD","payment_status":"unpaid","address":null,"notes":"First visit","created_at":"2026-09-14T09:30:00Z"}}}}},"responses":{"2XX":{"description":"Received. Answer within 10 seconds."},"410":{"description":"Unsubscribe: the webhook is removed."}}}},"rental.reserved":{"post":{"operationId":"onRentalReserved","summary":"New rental reservation","description":"A customer reserves a rental item. Sent to every URL subscribed to `rental.reserved`, signed with that subscription's secret.","parameters":[{"name":"X-Webkio-Event","in":"header","required":true,"schema":{"type":"string","const":"rental.reserved"}},{"name":"X-Webkio-Delivery","in":"header","required":true,"schema":{"type":"string"}},{"name":"X-Webkio-Timestamp","in":"header","required":true,"schema":{"type":"integer"},"description":"Unix seconds when it was sent."},{"name":"X-Webkio-Signature","in":"header","required":true,"schema":{"type":"string"},"description":"\"v1=\" + hex HMAC-SHA256 of \"{timestamp}.{raw body}\" keyed with the subscription secret."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventEnvelope"},"example":{"id":"rental.reserved_Rv56Gh","event":"rental.reserved","project":{"id":"xYz12AbC","name":"Your Shop","timezone":"America/New_York"},"data":{"id":"Rv56Gh","reference":"RSV-1042","item":"Volkswagen Golf","status":"pending","customer":{"name":"Sofia Almeida","email":"sofia@example.com","phone":"+1 212 555 0198"},"pickup":{"date":"2026-09-21","time":"10:00","location":"Airport desk"},"return":{"date":"2026-09-24","time":"10:00","location":"Airport desk"},"days":3,"total":180,"deposit":200,"currency":"USD","payment_status":"unpaid","notes":null,"created_at":"2026-09-14T09:30:00Z"}}}}},"responses":{"2XX":{"description":"Received. Answer within 10 seconds."},"410":{"description":"Unsubscribe: the webhook is removed."}}}},"subscriber.created":{"post":{"operationId":"onSubscriberCreated","summary":"New subscriber","description":"Someone joins your email list. Sent to every URL subscribed to `subscriber.created`, signed with that subscription's secret.","parameters":[{"name":"X-Webkio-Event","in":"header","required":true,"schema":{"type":"string","const":"subscriber.created"}},{"name":"X-Webkio-Delivery","in":"header","required":true,"schema":{"type":"string"}},{"name":"X-Webkio-Timestamp","in":"header","required":true,"schema":{"type":"integer"},"description":"Unix seconds when it was sent."},{"name":"X-Webkio-Signature","in":"header","required":true,"schema":{"type":"string"},"description":"\"v1=\" + hex HMAC-SHA256 of \"{timestamp}.{raw body}\" keyed with the subscription secret."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventEnvelope"},"example":{"id":"subscriber.created_Sb78Ij","event":"subscriber.created","project":{"id":"xYz12AbC","name":"Your Shop","timezone":"America/New_York"},"data":{"id":"Sb78Ij","email":"sofia@example.com","name":"Sofia Almeida","status":"active","tags":["newsletter"],"created_at":"2026-09-14T09:30:00Z"}}}}},"responses":{"2XX":{"description":"Received. Answer within 10 seconds."},"410":{"description":"Unsubscribe: the webhook is removed."}}}},"property_enquiry.created":{"post":{"operationId":"onPropertyEnquiryCreated","summary":"New property inquiry","description":"A visitor inquires about a property listing. Sent to every URL subscribed to `property_enquiry.created`, signed with that subscription's secret.","parameters":[{"name":"X-Webkio-Event","in":"header","required":true,"schema":{"type":"string","const":"property_enquiry.created"}},{"name":"X-Webkio-Delivery","in":"header","required":true,"schema":{"type":"string"}},{"name":"X-Webkio-Timestamp","in":"header","required":true,"schema":{"type":"integer"},"description":"Unix seconds when it was sent."},{"name":"X-Webkio-Signature","in":"header","required":true,"schema":{"type":"string"},"description":"\"v1=\" + hex HMAC-SHA256 of \"{timestamp}.{raw body}\" keyed with the subscription secret."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventEnvelope"},"example":{"id":"property_enquiry.created_Pe90Kl","event":"property_enquiry.created","project":{"id":"xYz12AbC","name":"Your Shop","timezone":"America/New_York"},"data":{"id":"Pe90Kl","type":"viewing","status":"new","customer":{"name":"Sofia Almeida","email":"sofia@example.com","phone":"+1 212 555 0198"},"message":"Could I view it on Saturday morning?","listing":{"id":"Ls11Mn","title":"3 bed terrace, Southville"},"created_at":"2026-09-14T09:30:00Z"}}}}},"responses":{"2XX":{"description":"Received. Answer within 10 seconds."},"410":{"description":"Unsubscribe: the webhook is removed."}}}},"review.submitted":{"post":{"operationId":"onReviewSubmitted","summary":"New product review","description":"A customer reviews a product. Sent to every URL subscribed to `review.submitted`, signed with that subscription's secret.","parameters":[{"name":"X-Webkio-Event","in":"header","required":true,"schema":{"type":"string","const":"review.submitted"}},{"name":"X-Webkio-Delivery","in":"header","required":true,"schema":{"type":"string"}},{"name":"X-Webkio-Timestamp","in":"header","required":true,"schema":{"type":"integer"},"description":"Unix seconds when it was sent."},{"name":"X-Webkio-Signature","in":"header","required":true,"schema":{"type":"string"},"description":"\"v1=\" + hex HMAC-SHA256 of \"{timestamp}.{raw body}\" keyed with the subscription secret."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventEnvelope"},"example":{"id":"review.submitted_Rw22Op","event":"review.submitted","project":{"id":"xYz12AbC","name":"Your Shop","timezone":"America/New_York"},"data":{"id":"Rw22Op","rating":5,"title":"Lovely quality","content":"Washed well and still looks new.","status":"pending","verified_purchase":true,"customer":{"name":"Sofia Almeida","email":"sofia@example.com"},"product":{"id":"Pr33Qr","name":"Linen apron"},"created_at":"2026-09-14T09:30:00Z"}}}}},"responses":{"2XX":{"description":"Received. Answer within 10 seconds."},"410":{"description":"Unsubscribe: the webhook is removed."}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"An API key (wk_...). In the developer site's explorer you are signed in with a temporary token instead.\n\n**A key can be made read-only.** It then answers every GET as usual and refuses anything that would change something with `403 read_only_key`. Worth using for a reporting script, a dashboard or anyone outside your team, and worth starting with while you find your way around: the write endpoints here cancel appointments, refund card payments and set stock levels on a real shop. Tick the box when you create the key in the console."}},"parameters":{"Limit":{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},"Cursor":{"name":"cursor","in":"query","required":false,"schema":{"type":"string"},"description":"The previous page's meta.next_cursor."}},"schemas":{"Error":{"type":"object","properties":{"success":{"type":"boolean","const":false},"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["missing_api_key","invalid_api_key","console_token_expired","account_unavailable","plan_required","plan_limit_reached","read_only_demo","rate_limited","not_found","resource_not_found","unknown_event","invalid_target_url","invalid_project","invalid_list","email_rejected","webhook_limit_reached","invalid_cursor","validation_failed","server_error"],"description":"Stable - branch on this."},"message":{"type":"string","description":"For people; may be reworded."}}}}},"ListMeta":{"type":"object","properties":{"has_more":{"type":"boolean"},"next_cursor":{"type":["string","null"],"description":"Pass as `cursor` for the next page; null on the last."}}},"Account":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"timezone":{"type":"string","description":"IANA timezone.","examples":["America/New_York"]}}},"Project":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"status":{"type":"string"},"timezone":{"type":"string","description":"IANA timezone.","examples":["America/New_York"]},"created_at":{"type":"string","format":"date-time","examples":["2026-09-14T09:30:00Z"]}}},"EventType":{"type":"object","properties":{"key":{"type":"string","enum":["order.created","order.paid","booking.created","rental.reserved","subscriber.created","property_enquiry.created","review.submitted"]},"label":{"type":"string"},"description":{"type":"string"}}},"Webhook":{"type":"object","properties":{"id":{"type":"string"},"event":{"type":"string","enum":["order.created","order.paid","booking.created","rental.reserved","subscriber.created","property_enquiry.created","review.submitted"]},"target_url":{"type":"string"},"project_id":{"type":["string","null"]},"active":{"type":"boolean"},"created_via":{"type":"string","enum":["api","dashboard"]},"failure_count":{"type":"integer"},"last_status":{"type":["integer","null"]},"last_delivery_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time","examples":["2026-09-14T09:30:00Z"]}}},"WebhookCreated":{"allOf":[{"$ref":"#/components/schemas/Webhook"},{"type":"object","properties":{"secret":{"type":"string","description":"Signs every delivery. Shown only now."}}}]},"Contact":{"type":"object","properties":{"id":{"type":"string"},"project_id":{"type":"string"},"name":{"type":["string","null"]},"email":{"type":["string","null"]},"phone":{"type":["string","null"]},"tags":{"type":"array","items":{"type":"string"}},"notes":{"type":["string","null"]},"source":{"type":["string","null"],"description":"Where the contact came from first, such as order, booking, subscriber or api."},"orders_count":{"type":"integer"},"total_spent":{"type":"number"},"currency":{"type":"string","examples":["USD"]},"first_seen_at":{"type":["string","null"],"format":"date-time"},"last_seen_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":["string","null"],"format":"date-time"},"updated_at":{"type":["string","null"],"format":"date-time"}}},"ContactInput":{"type":"object","required":["project_id","email"],"properties":{"project_id":{"type":"string","description":"The site, from GET /v1/projects."},"email":{"type":"string","format":"email","maxLength":255,"description":"What the contact is matched on."},"name":{"type":"string","maxLength":255},"phone":{"type":"string","maxLength":50},"notes":{"type":"string","maxLength":5000,"description":"Replaces the contact's notes."},"tags":{"oneOf":[{"type":"array","items":{"type":"string","maxLength":50},"maxItems":30},{"type":"string","examples":["vip, wholesale"]}],"description":"A list, or one text with commas between the tags."}}},"Subscriber":{"type":"object","properties":{"id":{"type":"string"},"project_id":{"type":"string"},"email":{"type":"string"},"name":{"type":["string","null"]},"status":{"type":"string","enum":["active","unengaged","pending","unsubscribed","bounced","complained"]},"tags":{"type":"array","items":{"type":"string"}},"created_at":{"type":["string","null"],"format":"date-time"}}},"SubscriberInput":{"type":"object","required":["project_id","email"],"properties":{"project_id":{"type":"string","description":"The site, from GET /v1/projects."},"email":{"type":"string","format":"email","maxLength":255},"name":{"type":"string","maxLength":255},"tags":{"oneOf":[{"type":"array","items":{"type":"string","maxLength":50},"maxItems":30},{"type":"string","examples":["vip, wholesale"]}],"description":"A list, or one text with commas between the tags."},"list_id":{"type":"string","description":"Also add them to this list, from GET /v1/email-lists."}}},"EmailList":{"type":"object","properties":{"id":{"type":"string"},"project_id":{"type":"string"},"name":{"type":"string"},"description":{"type":["string","null"]},"created_at":{"type":["string","null"],"format":"date-time"}}},"BlogPost":{"type":"object","properties":{"id":{"type":"string"},"project_id":{"type":"string"},"title":{"type":"string"},"slug":{"type":"string"},"status":{"type":"string","examples":["draft"]},"excerpt":{"type":["string","null"]},"content":{"type":["string","null"],"description":"HTML."},"tags":{"type":"array","items":{"type":"string"}},"meta_title":{"type":["string","null"]},"meta_description":{"type":["string","null"]},"featured_image":{"type":["string","null"]},"created_at":{"type":["string","null"],"format":"date-time"},"updated_at":{"type":["string","null"],"format":"date-time"}}},"BlogPostInput":{"type":"object","required":["project_id","title"],"properties":{"project_id":{"type":"string","description":"The site, from GET /v1/projects."},"title":{"type":"string","maxLength":255},"content":{"type":"string","description":"HTML. Scripts and unsafe markup are removed."},"excerpt":{"type":"string","maxLength":1000},"slug":{"type":"string","maxLength":200,"pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$","description":"Made from the title when left out."},"tags":{"oneOf":[{"type":"array","items":{"type":"string","maxLength":50},"maxItems":30},{"type":"string","examples":["vip, wholesale"]}],"description":"A list, or one text with commas between the tags."},"meta_title":{"type":"string","maxLength":255},"meta_description":{"type":"string","maxLength":500},"featured_image":{"type":"string","format":"uri","maxLength":500}}},"Reservation":{"type":"object","properties":{"id":{"type":"string"},"project_id":{"type":"string"},"reference":{"type":["string","null"]},"item":{"type":["string","null"],"description":"The thing hired out."},"status":{"type":"string","enum":["pending","confirmed","cancelled","completed"]},"customer":{"type":"object","properties":{"name":{"type":["string","null"]},"email":{"type":["string","null"]},"phone":{"type":["string","null"]}}},"pickup":{"type":"object","properties":{"date":{"type":["string","null"]},"time":{"type":["string","null"]},"location":{"type":["string","null"]}}},"return":{"type":"object","properties":{"date":{"type":["string","null"]},"time":{"type":["string","null"]},"location":{"type":["string","null"]}}},"days":{"type":["integer","null"]},"total":{"type":["number","null"]},"deposit":{"type":["number","null"]},"currency":{"type":["string","null"]},"payment_status":{"type":["string","null"]},"notes":{"type":["string","null"],"description":"The customer's note."},"created_at":{"type":["string","null"],"format":"date-time"}}},"Booking":{"type":"object","properties":{"id":{"type":"string"},"project_id":{"type":"string"},"service":{"type":["string","null"]},"date":{"type":["string","null"],"description":"The appointment date, in the site's own timezone."},"time":{"type":["string","null"],"description":"HH:MM, in the site's own timezone."},"status":{"type":"string","enum":["pending","confirmed","cancelled","completed","no-show"]},"customer":{"type":"object","properties":{"name":{"type":["string","null"]},"email":{"type":["string","null"]},"phone":{"type":["string","null"]}}},"amount_due":{"type":["number","null"]},"currency":{"type":["string","null"]},"payment_status":{"type":["string","null"]},"address":{"type":["string","null"]},"notes":{"type":["string","null"],"description":"The customer's note."},"created_at":{"type":["string","null"],"format":"date-time"}}},"Product":{"type":"object","properties":{"id":{"type":"string"},"project_id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"sku":{"type":["string","null"]},"type":{"type":"string","enum":["physical","digital","service","bundle"]},"active":{"type":"boolean"},"featured":{"type":"boolean"},"price":{"type":"object","properties":{"amount":{"type":"number"},"compare_at":{"type":["number","null"]},"currency":{"type":["string","null"],"description":"From the shop's settings."}}},"stock":{"type":"object","properties":{"tracked":{"type":"boolean"},"quantity":{"type":["integer","null"],"description":"Null when the shop does not count this product - which is not the same as zero."},"low_at":{"type":["integer","null"]},"backorder":{"type":"boolean"}}},"category":{"type":["object","null"],"properties":{"id":{"type":"string"},"name":{"type":"string"}}},"description":{"type":["string","null"]},"images":{"type":"array","items":{"type":"string"}},"variants":{"type":"array","description":"Stock lives here when it is not empty.","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"sku":{"type":["string","null"]},"price":{"type":["number","null"]},"stock":{"type":["integer","null"]},"active":{"type":"boolean"}}}},"created_at":{"type":"string"}}},"Order":{"type":"object","properties":{"id":{"type":"string"},"project_id":{"type":"string"},"number":{"type":"string"},"status":{"type":"string","enum":["pending","paid","processing","shipped","delivered","refunded","cancelled"]},"type":{"type":["string","null"]},"customer":{"type":"object","properties":{"name":{"type":["string","null"]},"email":{"type":["string","null"]},"phone":{"type":["string","null"]}}},"currency":{"type":["string","null"]},"subtotal":{"type":["number","null"]},"shipping":{"type":["number","null"]},"tip":{"type":["number","null"]},"discount":{"type":["number","null"]},"tax":{"type":["number","null"]},"total":{"type":["number","null"]},"payment_method":{"type":["string","null"]},"shipping_method":{"type":["string","null"]},"shipping_address":{"description":"An address object; text on some older orders."},"coupon_code":{"type":["string","null"]},"note":{"type":["string","null"],"description":"The customer's note."},"scheduled_for":{"type":["string","null"],"format":"date-time"},"items":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"sku":{"type":["string","null"]},"quantity":{"type":"integer"},"price":{"type":["number","null"]},"total":{"type":["number","null"]}}}},"created_at":{"type":["string","null"],"format":"date-time"}}},"EventEnvelope":{"type":"object","properties":{"id":{"type":"string","description":"The same every time the same record is sent."},"event":{"type":"string","enum":["order.created","order.paid","booking.created","rental.reserved","subscriber.created","property_enquiry.created","review.submitted"]},"project":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"timezone":{"type":"string","description":"IANA timezone.","examples":["America/New_York"]}}},"data":{"type":"object","description":"The record. Its fields depend on the event; timestamps are UTC, and the samples endpoint shows every field with your own data."}}}},"responses":{"Unauthorized":{"description":"missing_api_key, invalid_api_key or console_token_expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"Forbidden":{"description":"account_unavailable, plan_required, plan_limit_reached or read_only_demo.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"NotFound":{"description":"resource_not_found, unknown_event or not_found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"ValidationError":{"description":"unknown_event, invalid_target_url, invalid_project, invalid_list, email_rejected, webhook_limit_reached, invalid_cursor or validation_failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"RateLimited":{"description":"rate_limited: over 200 requests a minute. Retry-After says when to come back.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}