@zimmerstack/connect 0.9.0 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +41 -15
- package/README.md +145 -55
- package/dist/cjs/client.d.ts +33 -8
- package/dist/cjs/client.js +42 -8
- package/dist/cjs/doctor.js +1 -1
- package/dist/cjs/generated.d.ts +54 -10
- package/dist/cjs/generated.js +3 -1
- package/dist/esm/client.d.ts +33 -8
- package/dist/esm/client.js +42 -8
- package/dist/esm/doctor.js +1 -1
- package/dist/esm/generated.d.ts +54 -10
- package/dist/esm/generated.js +3 -1
- package/dist/esm/mcp/cli.js +7 -2
- package/dist/esm/mcp/reference.generated.js +1557 -312
- package/package.json +2 -2
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Do not edit: change the contract, then run `pnpm --dir apps/connect-sdk run generate`.
|
|
3
3
|
// What the package's MCP server (src/mcp) answers lookups from. It is not part of the client's own exports.
|
|
4
4
|
/** The rules file this package ships (AGENTS.md), for the zimmerstack_rules tool. */
|
|
5
|
-
export const RULES = "# Building on @zimmerstack/connect: rules for coding agents\n\nYou are writing code that calls the ZimmerStack Connect API through its official package. A write\nthrough it changes a real hotel's prices and rooms on every booking site it sells on. The package\nenforces most of the API's rules for you; this file is the rest. Keep it in the repository (as\nAGENTS.md or CLAUDE.md) and follow it. The whole API reference, in one file an agent can read:\nhttps://docs.zimmerstack.com/llms-full.txt\n\n## The key\n\n- It lives in the environment variable `ZIMMERSTACK_CONNECT_KEY` on a server. Never write it into a\n file that is committed, a log line, an error message, a URL, a test fixture or anything a browser\n or a mobile app receives. Never print it. `new ZimmerStack()` reads it by itself.\n- The package refuses to start in a browser or in React Native. Do not work around that: the\n person's own frontend calls their own server, and the server calls ZimmerStack. Never put the key in\n a variable a bundler sends to the browser (`VITE_`, `NEXT_PUBLIC_`, `REACT_APP_`, `EXPO_PUBLIC_`).\n An app with no server gets the smallest one: https://docs.zimmerstack.com/sdk#no-server. A plain\n `fetch` from a browser is refused too (\"Failed to fetch\"), on purpose.\n- `zsk_test_…` is a sandbox: nothing reaches a channel. Build and test with it. `zsk_live_…` is a real\n hotel. The package refuses to WRITE with a live key under a test runner; never switch that off to\n make a test pass.\n- A software vendor's company key acts on one hotel at a time: `zs.forProperty(propertyId)`\n (`zs.properties.list()` names them), or `ZIMMERSTACK_PROPERTY_ID` in the environment for an app that\n serves one hotel. A test company key that reaches one sandbox finds it by itself; with several,\n name one; a live key never guesses.\n- No key yet: a software company signs up, free, at https://www.zimmerstack.com/partners/pms-companies#join\n and makes test keys in the partner portal (Developers); a hotel's owner makes one in Admin →\n Developers → API keys.\n- A key is zsk_live_ (or zsk_test_ on a sandbox) + 40 letters and digits + a 6-character checksum (the CRC32 of everything before it, in base 62), so a key can be told from a look-alike without asking us. Where a person pastes a key (a settings screen, a\n deploy script), check it with `checkKey(value)` first: it tells a mistyped or cut-short key from a real\n one without sending it anywhere, and its `message` never contains the key.\n- The key your code runs on is replaced by a person, never by code: no route makes, rotates or revokes\n a hotel's own key or a company key. Every key can be rotated, company keys included: the new key is shown once and the old one keeps answering for 24 hours, then answers 401 API_KEY_REVOKED. A key reported as found in a public place (for example by GitHub secret scanning in a public repository) is revoked at once and its holder is emailed: requests on it answer 401 API_KEY_REVOKED.\n So when calls suddenly answer `API_KEY_REVOKED`, do not retry: tell the person to make a new key.\n (The one thing that is by API: the keys a software partner made on a hotel, below.)\n- When something is wrong, run `npx @zimmerstack/connect doctor` before changing code: it checks the\n key, the hotels and scopes it reaches, every budget, the last day's refused requests, the webhook\n endpoints and the sync state, and says what to do about each. It only reads and never prints the key.\n\n## Let the package pace; never work around it\n\n- It reads every budget in the `RateLimit` headers and slows down before one runs out, and sends one\n hotel's writes one at a time, in order. It sends a request again only when that is safe: a 429\n always, after its `Retry-After`; a 5xx or a network failure only for a read, or for a write that\n carries an idempotency key (a delete carries none, and is never sent twice). Anything else is a\n `ZimmerStackError` at once. Do not wrap its calls in your own retry loop, and never resend a 4xx\n other than 429: it is a verdict on the request. Fix the request.\n- Per minute: 120 requests and 30 writes per key; 300 and 60 for all of a hotel's keys together.\n A write is every call that is not a read. A hotel also has budgets per hour and per day that count\n CHANGED cells (at least 10,000 an hour, 30,000\n a day). Hitting one is `error.code === \"RATE_LIMITED\"` with `error.retryAfterSeconds` and\n `error.freesAt`: tell the person when to try again; do not sleep through an hour. A job that may wait\n passes `{ maxWaitSeconds: 3600 }` on the call: the package then holds it and tells `onEvent` when it\n lands. `zs.limits.get()` answers every budget with what is left of it.\n- One instance per process (`new ZimmerStack()` once, in a module). Two instances do not share a pace.\n Under a company key each hotel (`zs.forProperty(id)`) has its own queue and its own pace: one hotel's\n budget never holds up another's calls.\n- Never write on a timer, in a loop over all nights, or \"to be safe\". Send what a person changed,\n when they changed it: `zs.grid.save(edits)` folds nights into ranges and splits a large save.\n- Do not poll faster than every 15 seconds (`zs.batches.wait` already does it right), and stop.\n\n## Every limit, from the API's own table\n\nThe package keeps inside these by itself; they are here so you can size a job. `zs.limits.get()` answers\nthe same rows for your key with what is left of each. \"At least\" is what the smallest hotel gets: a larger\nhotel gets more, and `zs.limits.get()` says exactly.\n\n- `api-address`: 1,200 requests, 60 s fixed, per address, on each API machine.\n- `ip`: 240 requests, 60 s sliding, per address.\n- `ip-auth`: 20 failed authentications, 60 s sliding, per address.\n- `key-auth`: 5 failed authentications, 60 s sliding, per address and key.\n- `global-unauthenticated`: 1,200 requests, 60 s sliding, per everyone without a verified key.\n- `requests`: 120 requests, 60 s sliding, per key.\n- `writes`: 30 writes, 60 s sliding, per key.\n- `property`: 300 requests, 60 s sliding, per property (all its keys).\n- `property-writes`: 60 writes, 60 s sliding, per property (all its keys).\n- `cells`: 20,000 cells, 60 s sliding, per property (all its keys).\n- `company`: 1,200 requests, 60 s sliding, per company key (all its hotels).\n- `global`: 3,000 requests, 60 s sliding, per everyone.\n- `bookings`: 20 bookings, 60 s sliding, per key.\n- `property-bookings`: 40 bookings, 60 s sliding, per property (all its keys).\n- `property-bookings-day`: 500 bookings, rolling 24 hours, per property (all its keys).\n- `direct-cancels`: 10 cancels, 60 s sliding, per key.\n- `property-direct-cancels-day`: 50 cancels, rolling 24 hours, per property (all its keys).\n- `cells-hour`: at least 10,000 changed cells, one clock hour (UTC), per property (all its keys).\n- `cells-day`: at least 30,000 changed cells, rolling 24 hours, per property (all its keys).\n- `vendor-cells-day`: at least 150,000 changed cells, rolling 24 hours, per software vendor (all its hotels).\n- `shield-lane`: at least 500 closing cells, one clock hour (UTC), per property (all its keys).\n- `structure-creates`: 20 new room types and rate plans, 60 s sliding, per property.\n- `structure-creates-day`: 300 new room types and rate plans, rolling 24 hours, per property.\n- `structure-edits-day`: 300 changed room types and rate plans, rolling 24 hours, per property.\n- `structure-deletes-day`: 60 deleted room types and rate plans, rolling 24 hours, per property.\n- `vendor-structure-creates-day`: at least 500 new room types and rate plans, rolling 24 hours, per software vendor (all its hotels).\n- `vendor-remote-properties-day`: 10 hotels, rolling 24 hours, per software vendor.\n- `vendor-property-removals-day`: 10 hotels, rolling 24 hours, per software vendor.\n- `partner-new-properties-hour`: 20 hotels, one hour, per software partner.\n- `partner-new-sandboxes-hour`: 30 sandboxes, rolling hour, per software partner.\n- `connect-links-hour`: 10 connect links, rolling hour, per property.\n- `partner-connect-links-hour`: 120 connect links, rolling hour, per software partner.\n- `modifier-changes-day`: 6 changes, rolling 24 hours, per property.\n- `rate-resends-day`: 3 re-sends, rolling 24 hours, per property.\n- `partner-support-tickets-day`: 20 tickets, rolling 24 hours, per software partner.\n- `partner-support-messages-hour`: 60 messages, rolling hour, per software partner.\n- `maxUpdatesPerRequest`: 1,000 entries, per request.\n- `maxCellsPerRequest`: 5,000 cells, per request.\n- `maxBodyBytes`: 1,048,576 bytes, per request.\n- `horizonDays`: 500 nights, per request.\n- `maxNightsPerBooking`: 90 nights, per request.\n- `newEntitiesPerRequest`: 20 new room types and rate plans, per request.\n- `maxRoomTypes`: 18 room types, per property.\n- `maxRatePlans`: 180 rate plans, per property.\n- `maxActiveKeysPerProperty`: 5 keys, per property.\n- `maxActiveCompanyKeys`: 5 keys, per software partner.\n- `maxSandboxes`: 5 sandboxes, per software partner.\n- `maxAllowedCidrs`: 20 addresses or ranges, per key.\n- `idempotencyRetentionDays`: 7 days, per key.\n- `maxSupportMessageChars`: 5,000 characters, per request.\n- `maxSupportTicketProperties`: 200 hotels, per request.\n\n## Money and dates\n\n- A price is SENT and READ in major units of the hotel's own currency, with that currency's own decimals (ISO 4217: 2 for\n rupees, euros and dollars, 0 for yen; `decimals` on `GET /property`). Send a number or a decimal string (4500.50 or\n \"4500.50\"); read `rate` (\"4500.50\") beside `currency` and `decimals`. It is kept exactly: never round a price yourself.\n `zs.grid.load` gives major units; `zs.grid.save` takes them.\n- `rateMinor` and every other `…Minor` field is HUNDREDTHS of the major unit for every currency (450050 = 4500.50;\n 1500000 = 15000 yen), which is the ISO minor unit only where the currency has two decimals. Prefer `rate`.\n- A price with more decimals than the currency has, a number or a decimal string alike, is rounded and named in\n the answer's `rounded` list: show that list to the person, never hide it.\n- Never do money arithmetic on floats, and never divide by 100 yourself. The package's helpers work on the\n strings: `toAmount(value, decimals)`, `addAmounts`, `subtractAmounts`, `multiplyAmount(amount, factor, decimals)`,\n `compareAmounts`, `formatAmount(amount, { currency, decimals, locale })`. A ledger that stores whole minor\n units (cents, paise, yen) converts with `amountFromMinorUnits` and `amountToMinorUnits`; an API `…Minor`\n field becomes the string with `amountFromHundredths(rateMinor, decimals)`. `decimals` always comes from the\n API's answer, never from a table of your own.\n- A date is a plain `YYYY-MM-DD` calendar day in the hotel's timezone. Never build one with\n `new Date()` arithmetic in local time; use `eachDate(from, to)`.\n- `stopSell: true` closes ONE rate plan on that night: a switch. The room type's other rate plans keep\n selling, and so does a rate an OTA derives on its own side. A room count of 0 (`zs.availability.set`)\n is a COUNT: it closes the room type everywhere, and an OTA cancellation or your next count moves it. To\n close a room type and keep it closed, do both in one call: `zs.availability.close` (below). Say which\n of these a button does. Never a zero price.\n- Writes may reach 500 days ahead. A write is accepted (202) when it is in ZimmerStack's record; it\n reaches the channels in seconds to minutes. `zs.sync.get()` says how far along it is.\n\n## Sent is not held: read what comes back\n\n- A 202 says \"in ZimmerStack's record\", not \"on the booking sites\". Show \"saving\" until\n `zs.batches.wait(batchId)` reads `landed`. `failed` is not a network error to retry: the channel\n manager refused a value (`parkedCells`, `lastError`) or the write named a room type or rate plan that\n reaches no channel (`unreachable`). A refused value is held, not sent again: send a corrected value for\n those nights. Sending the same value again is refused with the same words.\n- Read every write's answer, not only its status: `rejected` (cells not written, with the reason),\n `rounded` (prices kept differently from what was sent), `priceWarnings` and `warnings`. Show them to the\n person who saved.\n- A value that ZimmerStack's record and the channel manager both already hold is dropped as unchanged\n (`noopCells`): it is not sent again. So sending the same grid twice does no harm, and it does not\n \"refresh\" the channels either: never resend on a timer to be safe.\n- Someone can change a price or a stay rule on the channel manager's side or in an OTA's extranet. A\n nightly read finds it: `channel.drift.detected` names the nights (`data.drift.cells`, your value and\n theirs), your value is sent again unless the hotel switched that repair off, and `channel.drift.healed`\n follows when a later read agrees. `zs.sync.get()` carries `rates.driftCells`. Show it; never answer it\n by pushing the whole calendar every night.\n- `channel.sync.alert` says a problem began (`data.sync.event`: a refused value, a disconnect, prices or\n room counts that stopped going out, a setting changed) and `channel.sync.recovered` that it ended. Show\n both to the hotel; neither is a reason to resend everything.\n- A night more than a year ahead that your software never wrote is closed on the booking sites. A room\n count you write for it is sent as written; otherwise it opens by itself when it comes inside the year.\n\n## See what a write will do, and read what it did not do\n\n- Every answer of `zs.availability.set`, `zs.rates.set` and `zs.restrictions.set` may carry `notices`: what\n the write did NOT do, one sentence each with a stable `code`, a `level` (warning or info) and an\n `action`. Read them after every save with `noticesOf(accepted)` and show the warnings to the person\n who saved (`message` and `action`). Branch on `code` (`NOTICES` lists all 19 with what each\n means); a code you do not know was added later, so show it too. A notice is never an error: the write\n was accepted.\n- The two that explain most surprises: `ROOM_STILL_ON_SALE` (you stop-sold one rate plan and the room\n still sells through `otherRatePlanIds`) and `COUNT_ZERO_IS_NOT_STOP_SELL` (a count of 0 is a count, which\n the next OTA cancellation or your next count moves).\n- `zs.availability.dryRun(updates)`, `zs.rates.dryRun(updates)` and `zs.restrictions.dryRun(updates)` answer\n what the same `set` WOULD do and write nothing: a `WritePreview` (`dryRun: true`, `verdict`, what would\n change, what is already held, the notices), never a `WriteAccepted`. Use one before a large or unusual\n write, or to show a person what a button will do. It spends the minute budgets like the write it\n previews (one request, one write, the same cells), so it is not a free read of the calendar: never\n dry-run on a timer or to \"check\" a night. `zs.rates.get` and its siblings are the reads.\n- `zs.availability.close({ roomTypeId, dateFrom, dateTo })` closes one room type on those nights everywhere:\n its count goes to 0 and stop-sell is switched on for every one of its rate plans. Read `notReached` in\n the answer: it names what the close could not reach (a rate an OTA links on its own side is closed only\n by the count). `zs.availability.reopen` undoes exactly that close; pass `available` when your software\n knows how many rooms are free now. `closeDryRun` and `reopenDryRun` show what each would do. Call\n close and reopen from a person's action or a rule a person set; never from a loop over all rooms.\n- When a person asks \"why is this night not selling as we sent it\", call\n `zs.explain.night({ roomTypeId, date })` and show its `summary`: what your software last sent, what\n ZimmerStack's record holds and who set it, what the channel manager was last seen holding, and any\n value it refused, in its own words. It reads the channel manager's copy as last seen, never a booking\n site's own screen; `seenAt: null` means \"never read back\", not \"wrong\". Never loop it over a calendar.\n\n## Bookings and events: the webhook is the nudge, the log is the truth\n\n- Every event of a hotel (an OTA booking arriving, changing, cancelled; a website booking; a channel\n problem and its end; drift) has a `sequence`, one higher than the hotel's last. The webhook carries it,\n and `GET /events` lists every event once, in that order, for 90 days.\n- Build the receiver so nothing depends on a delivery: verify it (`verifyWebhook`), answer 2xx at once,\n then read the log from the place you saved:\n `for await (const event of zs.events.all({ after: place })) { apply(event); place = event.sequence; }`\n and save `place` with what you applied, in one transaction. Run the same loop on a schedule (every few\n minutes is plenty) and after a restart: a missed, repeated or out-of-order delivery then changes nothing.\n- `event.data.booking.version` counts a booking's events (1, 2, 3 …). A copy you hold with a higher\n version is newer than the event in your hand: do not overwrite it.\n- `onGap` on `zs.events.all` fires when the log no longer holds what follows your place (a first run, or\n an outage longer than the log keeps): read `zs.channelBookings.all({ since })` and\n `zs.directBookings.all({ since })`, then carry on from the log.\n- Narrow an event with `isOtaBookingEvent`, `isWebsiteBookingEvent`, `isSyncEvent`, `isDriftEvent`,\n `isConnectEvent`. A type you do not know is skipped, never an error: new types are added without notice.\n- Two families are about your ACCOUNT, not one hotel: `platform.incident.*` (`isIncidentEvent`) and\n `support.ticket.*` (`isSupportTicketEvent`). They carry no `property` and no `sequence` and are not in\n the event log. Check for them BEFORE any code that reads `event.property`; `zs.status.get()` and\n `zs.supportTickets.get(id)` are the reads behind them.\n- A cancelled room stays in `rooms[]` with `status: \"CANCELLED\"`; `stay` and `occupancy` count the rooms\n still live. `finance.virtualCard: true` means the OTA pays the hotel with a card it issues: the guest\n owes the desk nothing for the room. No card number is ever sent.\n\n## Guest contact\n\n- A guest's phone and email are returned by the API until 30 days after checkout. After that guest.phone and guest.email are null and guest.contactWithheld says \"retention\", so you can tell withheld from a booking that never had one. The name, the stay and the money stay.\n Copy what you need into your own system when the booking arrives; do not plan to read it back later.\n- `guest.contactWithheld` says why `phone` and `email` are null: `\"retention\"` is final, `\"unavailable\"`\n means ask again. Never treat null as \"the guest gave none\" when it is set.\n- Every read that returned contact is logged (the key, the partner behind it, when, which bookings) and the hotel's owner sees the list. Read contact only where a person needs it.\n- An endpoint receives phone and email only while its owner has guest contact switched on; it can be switched at any time. A partner's company endpoint starts with it off.\n\n## Webhook endpoints by API (a software partner's company key)\n\n- With the scope `webhooks:manage` a company key creates, changes, pauses, resumes, tests and recovers\n its own company webhook endpoints: `zs.webhookEndpoints.*`. No hotel is named: an endpoint is the\n partner's. A test key manages test endpoints (your sandboxes' events), a live key live ones.\n- The signing secret is in the answer of `zs.webhookEndpoints.create` and `.rotateSecret`, once. Store it\n in the server's settings at that moment (never in code, a log or a chat); no call reads it back.\n- Before planned downtime call `zs.webhookEndpoints.pause`: events are held and `resume` sends them, oldest\n first. After an outage call `zs.webhookEndpoints.recover(id, since)`, or simply read the log.\n- `zs.webhookEndpoints.delete` is for good and takes the delivery log with it: only on a person's action.\n\n## Going live, connect links and a hotel's keys (a software partner's company key)\n\n- A hotel you add (`zs.properties.create`) is live from the start. A hotel that let you in by your vendor\n code is not: until it is, a call that names it answers `ARI_NOT_AUTHORITATIVE`.\n `zs.forProperty(id).readiness.get()` answers four checks, each with a sentence and what to do.\n- To send a year first, pass `{ beforeGoLive: true }` on each call: `zs.rates.set(prices, { beforeGoLive: true })`.\n Prices and stay rules sent this way are stored and wait (the answer says `heldUntilGoLive: true`).\n A price for every rate plan and night of the year ahead is what the readiness report asks for.\n- ROOM COUNTS ARE NOT SENT AHEAD. Until the hotel is live a room count may only LOWER what is on sale:\n one at or below what is on sale goes to the booking sites at once (a held count would oversell a\n room), and one that raises it is refused in the answer's `rejected` list (`NOTHING_ACCEPTED` when\n nothing else in the request landed), because the hotel's own people may still be running its counts.\n Do not loop on that refusal and do not try to work around it: send the room counts with\n `zs.availability.set` right after `goLive` answers.\n- `zs.readiness.goLive()` makes your software the hotel's source of truth. Call it when a person decided\n to, once `ready` is true. `NOT_READY` lists the checks that did not pass (`err.details`): fix them and\n call again; never retry it in a loop. Only ZimmerStack support switches a hotel back.\n- Connecting a booking site: `zs.connectLinks.create({ propertyId, channel })` (scope `channels:connect`,\n a LIVE key: a test key is refused) answers a one-time `url` for the hotel's own person, who signs in\n to the booking site and confirms every room and rate match on ZimmerStack's page. Never ask a hotel for\n a booking site's password, never store one, and never build a screen that takes one: no call accepts it.\n Listen for `channel.connect.completed` and `channel.connect.expired` (match on `data.connect.linkId`).\n- `zs.hotelKeys.list`, `.create`, `.rotate` and `.revoke` (scope `keys:manage`) manage the keys you made on\n a hotel you added; never a company key, never the hotel's own. A rotation makes a new key with the same name, scopes, addresses and expiry; the old one keeps answering for 24 hours (retireAt), then stops.\n- A VALUE SHOWN ONCE is in one answer and nowhere else: the `key` of `zs.hotelKeys.create` and `.rotate`,\n the `url` of `zs.connectLinks.create`, the `secret` of `zs.webhookEndpoints.create` and `.rotateSecret`.\n Take it with `shownOnce(answer)` and put it in the server's secret store in the same step. It is null\n on a retry of the same request: `shownOnce` then throws `ZimmerStackShownOnceError`, whose `nextStep`\n names the call that gets a new one. Never write code that stores `answer.key ?? \"\"`. Log\n `withoutShownOnce(answer)`, never the answer itself.\n\n## Billing, support and status (a software partner's company key)\n\n- `zs.billing.get()`, `.invoices()` and `.nextInvoice()` (scope `billing:read`) READ what the partner\n portal's Billing page shows. Nothing pays or changes anything by API. Amounts are decimal strings in\n major units beside `…Minor`: use the money helpers, and never add amounts of two currencies.\n- `atCost` on `zs.billing.get()` lists what the channel manager charged above its included room types and\n rate plans, passed on at cost. An item with `status: \"RECORDED\"` is on no invoice yet: show it as\n recorded, never as billed.\n- `zs.supportTickets.create({ severity, subject, message, propertyIds })` (scope `support:write`) opens a\n ticket; ZimmerStack attaches what its own records show. The level follows from the hotels you name: many_hotels needs two or more propertyIds or allProperties true; one_hotel needs exactly one; question takes any or none.\n Open one from a person's action or from one alert, never from a loop, and never put a key, a secret or\n a guest's details in the message.\n- Before blaming your own code for a failure across hotels, read `zs.status.get()`: the open incidents\n that touch your hotels. During one, keep what people changed and send it when it is resolved; do not\n resend everything.\n\n## Room types and rate plans\n\n- A hotel sells room types (\"Deluxe Room\") through rate plans (\"Bed and breakfast\"). Create or change\n one with `zs.roomTypes.save({ ref, name, roomCount, adults })` and\n `zs.ratePlans.save({ ref, roomTypeRef, name, mealPlan, defaultRate })`. `ref` is the person's own\n id for it: sending the same ref again changes that entity, it never makes a second one. Several in\n one request: `zs.catalog.upsertRoomTypes` and `zs.catalog.upsertRatePlans`. All need the scope\n `catalog:write`.\n- Every later write names ZimmerStack's numeric `id`, not the ref: room counts name a room type's\n id, prices and stay rules name a rate plan's id. `zs.roomTypes.list()` and `zs.ratePlans.list()`\n give them, and so does the answer of each `save`.\n- `zs.roomTypes.delete(idOrRef)` and `zs.ratePlans.delete(idOrRef)` delete for good, and a room\n type takes its rate plans with it. Call them only when a person chose to delete that one entity on\n a screen, after a confirmation that names it. Never from a loop, a sync job, a \"reset\" or a cleanup\n script, and never to repair a mismatch: send the entity again with `save` instead. A hotel may\n delete 60 entities a day.\n- `CATALOG_CONFLICT` or `CHANNEL_MANAGER_ERROR` on a delete means the hotel still uses it: a\n booking site still sells it, an upcoming stay holds one of its rooms, or rooms are still assigned\n to the room type. Nothing was deleted. Show the message and stop; do not try another way round.\n\n## Adding and removing a hotel (a software partner's company key)\n\n- Only a COMPANY key with the scope `properties:write` can do either; a hotel's own key cannot\n (`COMPANY_KEY_REQUIRED`). The person ticks \"Also add and remove hotels\" when making the key in the\n partner portal; only the account's owner or an Admin is offered that tick box. Neither call names a\n hotel with `forProperty`.\n- `zs.properties.create({ name, owner, address, roomTypes })` adds a hotel and answers with its `id`:\n act on it with `zs.forProperty(id)`. The owner gets the sign-in details by email, never the caller.\n It joins the partner's monthly invoice. With a `zsk_test_` key the same call makes a sandbox, which\n is never billed. A partner may add 20 hotels an hour.\n- After adding: the hotel is not on the channel manager yet. The first `zs.roomTypes.save` (or\n `zs.catalog.upsertRoomTypes`) with the same refs puts it there; then the rate plans, then room\n counts and prices.\n- `zs.properties.delete(propertyId, { confirm })` (also `zs.properties.remove`) removes a hotel the\n partner added, FOR GOOD: its booking sites are disconnected, its rate plans and then its room types\n are removed from the channel manager, the hotel is closed and it comes off the invoice from the next\n 1st. `confirm` is the hotel's exact name from `zs.properties.list()`. There is no undo, and a\n removed hotel cannot be added again by API.\n- Call `delete` only when a person chose to remove that one hotel on a screen, after typing or\n confirming its name. Never from a loop, a timer, a sync job, a \"reset\", a cleanup or a test against\n a live key, and never to fix a hotel that looks wrong. A partner may remove\n 10 hotels a day.\n- The answer's `channelManager.state` is `REMOVED`, or `RETRYING` when one step is still finishing:\n that is success, ZimmerStack retries it, do not call again in a loop. `PROPERTY_NOT_REMOVABLE` means\n this key may not remove that hotel (its owner let the partner in, or it uses more than the channel\n manager): show the message and stop.\n- Both calls take longer than the others (a removal disconnects the booking sites one after another),\n so the client waits up to 95 seconds for them whatever `timeoutMs` is. If `delete` ends in\n `TIMEOUT` or `NETWORK_ERROR`, the person may press Remove again: a hotel already gone answers\n `replay: true`, one still being removed answers `PROPERTY_BUSY`. Never retry it in a loop.\n\n## A channel's price modifier\n\n- `zs.channels.setModifier(channelId, steps)` moves EVERY price sent to that channel from then on.\n Call it only when a person saved that setting on a screen. Never from a loop, a timer, a seed\n script or a test against a live key. A hotel may change modifiers 6 times a day.\n- Saving a modifier makes the channel manager send that channel every date again, so prices already on the channel move to the new rule within minutes.\n Show that sentence where the person saves (`MODIFIER_TAKES_EFFECT`), and offer\n `zs.rates.resend()` as a separate, deliberate button (\"Apply to nights already on sale\"): 3 a day\n per hotel, never automatic.\n- Keep the grid on the price before any modifier; show a channel's price beside it with\n `channelPrice(rate, steps)`.\n\n## Website bookings: apply them before you push room counts\n\n- When the hotel also sells on its own website through ZimmerStack's booking engine, those bookings\n reach you as the webhooks `direct.booking.created`, `direct.booking.modified` and\n `direct.booking.cancelled` (the endpoint receives each only when it lists that type) and by\n `zs.directBookings.all({ since })` (scope `direct-bookings:read`). They are not OTA bookings:\n `isWebsiteBookingEvent(event)` tells them apart, `channel.otaName` is `\"Website\"` and `finance` is null.\n- `direct.booking.modified` is a no-show and its undo, nothing else yet: the hotel recorded that the guest\n did not arrive, or undid that. It is NOT a cancellation: `status` stays CONFIRMED and the payment is\n untouched, so never refund on it. Read `stayStatus` and each room's `status`: NOSHOW gives the nights\n back (they are on sale again on every channel), UPCOMING again holds them. `changes` names what moved\n (`\"stayStatus\"`, `\"rooms[0].status\"`); `previous` is the booking as it read before, `stayStatus`\n included. On a sandbox, `zs.sandbox.bookings.noShow(bookingId)` makes the real event for a booking\n simulated with `otaName: \"Website\"`, and `{ undo: true }` its undo.\n- A website booking takes one room off the count the channels hold, at once. A PMS that pushes absolute\n room counts must apply the booking to its own calendar BEFORE its next `zs.availability.set` or\n `zs.grid.save`, or that push puts the sold room back on sale. Read `zs.directBookings.all` before a\n full push. Nothing on our side stops the count from going up.\n- `zs.directBookings.cancel(bookingId, { refund, reason })` cancels a whole website booking that is\n still UPCOMING, and moves the guest's money (scope `direct-bookings:cancel`, granted on its own).\n `refund` is `\"policy\"` (the default: what the booking's own cancellation policy gives back, as if the\n guest cancelled), `\"full\"` (everything paid online: the hotel is at fault, an overbooking) or\n `\"none\"` (the hotel settles the money itself). Call it only from a person's own cancel button, with\n the refund they chose on the screen; never from a loop, a sync job or a test against a live key.\n Show `refund.amount` and `refund.status` from the answer. `BOOKING_NOT_CANCELLABLE` (checked in,\n checked out, a no-show) goes to the hotel's desk; do not retry it. `replay: true` means it was\n already cancelled and no money moved. Your own cancel comes back as `direct.booking.cancelled`\n (\"Cancelled by the hotel\"): match it on the booking id and treat it as already applied.\n\n## Errors\n\n```ts\nimport { ZimmerStack, ZimmerStackError } from \"@zimmerstack/connect\";\n\ntry {\n await zs.rates.set(updates);\n} catch (err) {\n if (err instanceof ZimmerStackError) {\n // err.code is stable (RATE_LIMITED, RATE_OUT_OF_BAND, SCOPE_MISSING, …); err.message is for people.\n // Show err.message to the person; branch on err.code; never retry unless err.retryable.\n }\n throw err;\n}\n```\n\n- `SCOPE_MISSING`: the key was not given that permission. Say which one is missing; the hotel's\n owner grants it (Admin → Developers → API keys). Do not look for another route.\n- `API_KEY_INVALID`, `API_KEY_REVOKED`, `API_KEY_EXPIRED`: stop. The client refuses every later call\n by itself; repeated bad calls get the server's address refused.\n- `RATE_OUT_OF_BAND`, `MODIFIER_OUT_OF_BAND`: the value is outside what the hotel allows. It is a\n guard against a typing slip; show the message, never split the change into smaller steps to pass.\n\n## The MCP server\n\nThe package carries an MCP server for you, the agent: `npx -y @zimmerstack/connect mcp`. If it is\nconnected, use it instead of guessing: `zimmerstack_reference` looks up any operation, type, limit\nor error code from the API's own contract, and `zimmerstack_sandbox_read` /\n`zimmerstack_sandbox_write` make one call on the sandbox so you can see real ids and try a body\nbefore you write the code that sends it. `zimmerstack_doctor` says what is wrong when a call is\nrefused or a webhook does not arrive; `zimmerstack_sandbox_limits` prints every budget and how full it\nis; `zimmerstack_sandbox_simulate` makes a real booking or channel event of any type on the sandbox, and\n`zimmerstack_sandbox_events` reads the ordered log, so a receiver and its catch-up can be tried end to\nend. `zimmerstack_sandbox_dry_run` shows what a write would do with nothing written, and its notices;\n`zimmerstack_sandbox_explain` tells one night's whole story; `zimmerstack_sandbox_close` closes or reopens\na room type everywhere; `zimmerstack_sandbox_fault` makes the sandbox's pretend channel refuse, throttle\nor go down, so the code that handles a refused value or an outage can be tried before a live hotel meets\none (in your own tests: `zs.sandbox.faults.set` and `.clear`). It works with a `zsk_test_` key only and refuses a live one. It is for building; the application\nyou write calls the API through the client, never through these tools.\n\n## Before you call the work done\n\n- [ ] The key is read from the environment, on a server, and appears in no committed file or log.\n- [ ] Every screen that writes sends only what the person changed, once, on their action.\n- [ ] No retry loop, no timer and no polling faster than 15 seconds around a call of this package.\n- [ ] Errors show `err.message` to the person and branch on `err.code`.\n- [ ] Tests run against a `zsk_test_` key or a fake `fetch`; none needs a live key.\n- [ ] Where a modifier is saved, the screen says when it takes effect, and the re-send is its own button.\n- [ ] A PMS that pushes room counts applies every website booking to its own calendar before it pushes.\n- [ ] A website booking is cancelled only from a person's own action, with the refund they chose.\n- [ ] A room type or a rate plan is deleted only from a person's own action, after a confirmation that names it.\n- [ ] The webhook receiver saves its place in the event log and catches up from it; nothing depends on a delivery arriving, or arriving in order.\n- [ ] A write's answer is read: `rejected`, `rounded` and a batch that reads `failed` reach the person who saved.\n- [ ] Money is handled as the API's decimal strings with the package's helpers; nothing divides by 100.\n- [ ] Guest contact the application needs is copied when the booking arrives, and `contactWithheld` is handled.\n- [ ] After every save of prices, room counts or stay rules, the notices (`noticesOf`) reach the person who saved.\n- [ ] A button that closes a night says what it closes: one rate plan (stop-sell), the room's count (0), or both (`zs.availability.close`).\n- [ ] A value shown once (a key, a connect link, a webhook secret) is taken with `shownOnce`, stored at once, and never logged.\n- [ ] Code that reads `event.property` runs only after the event is known not to be an incident or a support-ticket event.\n- [ ] No screen asks for, and no code stores, a booking site's password.\n- [ ] `npx @zimmerstack/connect doctor` reports nothing that needs attention.\n";
|
|
5
|
+
export const RULES = "# Building on @zimmerstack/connect: rules for coding agents\n\nYou are writing code that calls the ZimmerStack Connect API through its official package. A write\nthrough it changes a real hotel's prices and rooms on every booking site it sells on. The package\nenforces most of the API's rules for you; this file is the rest. Keep it in the repository (as\nAGENTS.md or CLAUDE.md) and follow it. The whole API reference, in one file an agent can read:\nhttps://docs.zimmerstack.com/llms-full.txt\n\n## The key\n\n- It lives in the environment variable `ZIMMERSTACK_CONNECT_KEY` on a server. Never write it into a\n file that is committed, a log line, an error message, a URL, a test fixture or anything a browser\n or a mobile app receives. Never print it. `new ZimmerStack()` reads it by itself.\n- The package refuses to start in a browser or in React Native. Do not work around that: the\n person's own frontend calls their own server, and the server calls ZimmerStack. Never put the key in\n a variable a bundler sends to the browser (`VITE_`, `NEXT_PUBLIC_`, `REACT_APP_`, `EXPO_PUBLIC_`).\n An app with no server gets the smallest one: https://docs.zimmerstack.com/guides/node-package#no-server. A plain\n `fetch` from a browser is refused too (\"Failed to fetch\"), on purpose.\n- `zsk_test_…` is a sandbox: nothing reaches a channel. Build and test with it. `zsk_live_…` is a real\n hotel. The package refuses to WRITE with a live key under a test runner; never switch that off to\n make a test pass.\n- A software vendor's company key acts on one hotel at a time: `zs.forProperty(propertyId)`\n (`zs.properties.list()` names them), or `ZIMMERSTACK_PROPERTY_ID` in the environment for an app that\n serves one hotel. A test company key that reaches one sandbox finds it by itself; with several,\n name one; a live key never guesses.\n- No key yet: a software company signs up, free, at https://www.zimmerstack.com/partners/pms-companies#join\n and makes its test key in the partner portal: Developers → Create company key → Your sandbox\n (zsk_test_), with \"Also add and remove hotels\" ticked. A hotel's owner makes one in Admin →\n Developers → API keys.\n- A software company builds in the order a hotel is made, all with that test key: `zs.properties.list()`\n (the hotels the key reaches), `zs.properties.create(hotel)` (a test hotel in its sandbox, born with its\n first room type and one room-only rate plan), then on `zs.forProperty(id)`: `roomTypes.save`,\n `ratePlans.save`, `availability.set` and `rates.set`. The same steps, one page each:\n https://docs.zimmerstack.com/partner/test-key\n- A key is zsk_live_ (or zsk_test_ on a sandbox) + 40 letters and digits + a 6-character checksum (the CRC32 of everything before it, in base 62), so a key can be told from a look-alike without asking us. Where a person pastes a key (a settings screen, a\n deploy script), check it with `checkKey(value)` first: it tells a mistyped or cut-short key from a real\n one without sending it anywhere, and its `message` never contains the key.\n- The key your code runs on is replaced by a person, never by code: no route makes, rotates or revokes\n a hotel's own key or a company key. Every key can be rotated, company keys included: the new key is shown once and the old one keeps answering for 24 hours, then answers 401 API_KEY_REVOKED. A key reported as found in a public place (for example by GitHub secret scanning in a public repository) is revoked at once and its holder is emailed: requests on it answer 401 API_KEY_REVOKED.\n So when calls suddenly answer `API_KEY_REVOKED`, do not retry: tell the person to make a new key.\n (The one thing that is by API: the keys a software partner made on a hotel, below.)\n- When something is wrong, run `npx @zimmerstack/connect doctor` before changing code: it checks the\n key, the hotels and scopes it reaches, every budget, the last day's refused requests, the webhook\n endpoints and the sync state, and says what to do about each. It only reads and never prints the key.\n\n## Let the package pace; never work around it\n\n- It reads every budget in the `RateLimit` headers and slows down before one runs out, and sends one\n hotel's writes one at a time, in order. It sends a request again only when that is safe: a 429\n always, after its `Retry-After`; a 5xx or a network failure only for a read, or for a write that\n carries an idempotency key (a delete carries none, and is never sent twice). Anything else is a\n `ZimmerStackError` at once. Do not wrap its calls in your own retry loop, and never resend a 4xx\n other than 429: it is a verdict on the request. Fix the request.\n- Per minute: 120 requests and 30 writes per key; 300 and 60 for all of a hotel's keys together.\n A write is every call that is not a read. A hotel also has budgets per hour and per day that count\n CHANGED cells (at least 10,000 an hour, 30,000\n a day). Hitting one is `error.code === \"RATE_LIMITED\"` with `error.retryAfterSeconds` and\n `error.freesAt`: tell the person when to try again; do not sleep through an hour. A job that may wait\n passes `{ maxWaitSeconds: 3600 }` on the call: the package then holds it and tells `onEvent` when it\n lands. `zs.limits.get()` answers every budget with what is left of it.\n- One instance per process (`new ZimmerStack()` once, in a module). Two instances do not share a pace.\n Under a company key each hotel (`zs.forProperty(id)`) has its own queue and its own pace: one hotel's\n budget never holds up another's calls.\n- Never write on a timer, in a loop over all nights, or \"to be safe\". Send what a person changed,\n when they changed it: `zs.grid.save(edits)` folds nights into ranges and splits a large save.\n- Do not poll faster than every 15 seconds (`zs.batches.wait` already does it right), and stop.\n\n## Every limit, from the API's own table\n\nThe package keeps inside these by itself; they are here so you can size a job. `zs.limits.get()` answers\nthe same rows for your key with what is left of each. \"At least\" is what the smallest hotel gets: a larger\nhotel gets more, and `zs.limits.get()` says exactly.\n\n- `api-address`: 1,200 requests, 60 s fixed, per address, on each API machine.\n- `ip`: 240 requests, 60 s sliding, per address.\n- `ip-auth`: 20 failed authentications, 60 s sliding, per address.\n- `key-auth`: 5 failed authentications, 60 s sliding, per address and key.\n- `global-unauthenticated`: 1,200 requests, 60 s sliding, per everyone without a verified key.\n- `requests`: 120 requests, 60 s sliding, per key.\n- `writes`: 30 writes, 60 s sliding, per key.\n- `property`: 300 requests, 60 s sliding, per property (all its keys).\n- `property-writes`: 60 writes, 60 s sliding, per property (all its keys).\n- `cells`: 20,000 cells, 60 s sliding, per property (all its keys).\n- `company`: 1,200 requests, 60 s sliding, per company key (all its hotels).\n- `global`: 3,000 requests, 60 s sliding, per everyone.\n- `bookings`: 20 bookings, 60 s sliding, per key.\n- `property-bookings`: 40 bookings, 60 s sliding, per property (all its keys).\n- `property-bookings-day`: 500 bookings, rolling 24 hours, per property (all its keys).\n- `direct-cancels`: 10 cancels, 60 s sliding, per key.\n- `property-direct-cancels-day`: 50 cancels, rolling 24 hours, per property (all its keys).\n- `cells-hour`: at least 10,000 changed cells, one clock hour (UTC), per property (all its keys).\n- `cells-day`: at least 30,000 changed cells, rolling 24 hours, per property (all its keys).\n- `vendor-cells-day`: at least 150,000 changed cells, rolling 24 hours, per software vendor (all its hotels).\n- `shield-lane`: at least 500 closing cells, one clock hour (UTC), per property (all its keys).\n- `structure-creates`: 20 new room types and rate plans, 60 s sliding, per property.\n- `structure-creates-day`: 300 new room types and rate plans, rolling 24 hours, per property.\n- `structure-edits-day`: 300 changed room types and rate plans, rolling 24 hours, per property.\n- `structure-deletes-day`: 60 deleted room types and rate plans, rolling 24 hours, per property.\n- `vendor-structure-creates-day`: at least 500 new room types and rate plans, rolling 24 hours, per software vendor (all its hotels).\n- `vendor-remote-properties-day`: 10 hotels, rolling 24 hours, per software vendor.\n- `vendor-property-removals-day`: 10 hotels, rolling 24 hours, per software vendor.\n- `partner-new-properties-hour`: 20 hotels, one hour, per software partner.\n- `partner-new-sandboxes-hour`: 30 sandboxes, rolling hour, per software partner.\n- `connect-links-hour`: 10 connect links, rolling hour, per property.\n- `partner-connect-links-hour`: 120 connect links, rolling hour, per software partner.\n- `modifier-changes-day`: 6 changes, rolling 24 hours, per property.\n- `rate-resends-day`: 3 re-sends, rolling 24 hours, per property.\n- `partner-support-tickets-day`: 20 tickets, rolling 24 hours, per software partner.\n- `partner-support-messages-hour`: 60 messages, rolling hour, per software partner.\n- `maxUpdatesPerRequest`: 1,000 entries, per request.\n- `maxCellsPerRequest`: 5,000 cells, per request.\n- `maxBodyBytes`: 1,048,576 bytes, per request.\n- `horizonDays`: 500 nights, per request.\n- `maxNightsPerBooking`: 90 nights, per request.\n- `newEntitiesPerRequest`: 20 new room types and rate plans, per request.\n- `maxRoomTypes`: 18 room types, per property.\n- `maxRatePlans`: 180 rate plans, per property.\n- `maxActiveKeysPerProperty`: 5 keys, per property.\n- `maxActiveCompanyKeys`: 5 keys, per software partner.\n- `maxSandboxes`: 5 sandboxes, per software partner.\n- `maxAllowedCidrs`: 20 addresses or ranges, per key.\n- `idempotencyRetentionDays`: 7 days, per key.\n- `maxSupportMessageChars`: 5,000 characters, per request.\n- `maxSupportTicketProperties`: 200 hotels, per request.\n\n## Money and dates\n\n- A price is SENT and READ in major units of the hotel's own currency, with that currency's own decimals (ISO 4217: 2 for\n rupees, euros and dollars, 0 for yen; `decimals` on `GET /property`). Send a number or a decimal string (4500.50 or\n \"4500.50\"); read `rate` (\"4500.50\") beside `currency` and `decimals`. It is kept exactly: never round a price yourself.\n `zs.grid.load` gives major units; `zs.grid.save` takes them.\n- `rateMinor` and every other `…Minor` field is HUNDREDTHS of the major unit for every currency (450050 = 4500.50;\n 1500000 = 15000 yen), which is the ISO minor unit only where the currency has two decimals. Prefer `rate`.\n- A price sent as a NUMBER with more decimals than the currency has (4500.505 in rupees) is rounded and named in\n the answer's `rounded` list, and so is a fraction in a currency that has none (15000.5 yen): show that list to\n the person, never hide it. A price sent as a decimal STRING takes at most two decimals: one with more\n (\"4500.505\") is refused, 400 `VALIDATION`, and nothing is written. It is never rounded for you.\n- Never do money arithmetic on floats, and never divide by 100 yourself. The package's helpers work on the\n strings: `toAmount(value, decimals)`, `addAmounts`, `subtractAmounts`, `multiplyAmount(amount, factor, decimals)`,\n `compareAmounts`, `formatAmount(amount, { currency, decimals, locale })`. A ledger that stores whole minor\n units (cents, paise, yen) converts with `amountFromMinorUnits` and `amountToMinorUnits`; an API `…Minor`\n field becomes the string with `amountFromHundredths(rateMinor, decimals)`. `decimals` always comes from the\n API's answer, never from a table of your own.\n- A date is a plain `YYYY-MM-DD` calendar day in the hotel's timezone. Never build one with\n `new Date()` arithmetic in local time; use `eachDate(from, to)`.\n- `stopSell: true` closes ONE rate plan on that night: a switch. The room type's other rate plans keep\n selling, and so does a rate an OTA derives on its own side. A room count of 0 (`zs.availability.set`)\n is a COUNT: it closes the room type everywhere, and an OTA cancellation or your next count moves it. To\n close a room type and keep it closed, do both in one call: `zs.availability.close` (below). Say which\n of these a button does. Never a zero price.\n- Writes may reach 500 days ahead. A write is accepted (202) when it is in ZimmerStack's record; it\n reaches the channels in seconds to minutes. `zs.sync.get()` says how far along it is.\n\n## Sent is not held: read what comes back\n\n- A 202 says \"in ZimmerStack's record\", not \"on the booking sites\". Show \"saving\" until\n `zs.batches.wait(batchId)` reads `landed`. `failed` is not a network error to retry: the channel\n manager refused a value (`parkedCells`, `lastError`) or the write named a room type or rate plan that\n reaches no channel (`unreachable`). A refused value is held, not sent again: send a corrected value for\n those nights. Sending the same value again is refused with the same words.\n- Read every write's answer, not only its status: `rejected` (cells not written, with the reason),\n `rounded` (prices kept differently from what was sent), `priceWarnings` and `warnings`. Show them to the\n person who saved.\n- A value that ZimmerStack's record and the channel manager both already hold is dropped as unchanged\n (`noopCells`): it is not sent again. So sending the same grid twice does no harm, and it does not\n \"refresh\" the channels either: never resend on a timer to be safe.\n- Someone can change a price or a stay rule on the channel manager's side or in an OTA's extranet. A\n nightly read finds it: `channel.drift.detected` names the nights (`data.drift.cells`, your value and\n theirs), your value is sent again unless the hotel switched that repair off, and `channel.drift.healed`\n follows when a later read agrees. `zs.sync.get()` carries `rates.driftCells`. Show it; never answer it\n by pushing the whole calendar every night.\n- `channel.sync.alert` says a problem began (`data.sync.event`: a refused value, a disconnect, prices or\n room counts that stopped going out, a setting changed) and `channel.sync.recovered` that it ended. Show\n both to the hotel; neither is a reason to resend everything.\n- A night more than a year ahead that your software never wrote is closed on the booking sites. A room\n count you write for it is sent as written; otherwise it opens by itself when it comes inside the year.\n\n## See what a write will do, and read what it did not do\n\n- Every answer of `zs.availability.set`, `zs.rates.set` and `zs.restrictions.set` may carry `notices`: what\n the write did NOT do, one sentence each with a stable `code`, a `level` (warning or info) and an\n `action`. Read them after every save with `noticesOf(accepted)` and show the warnings to the person\n who saved (`message` and `action`). Branch on `code` (`NOTICES` lists all 19 with what each\n means); a code you do not know was added later, so show it too. A notice is never an error: the write\n was accepted.\n- The two that explain most surprises: `ROOM_STILL_ON_SALE` (you stop-sold one rate plan and the room\n still sells through `otherRatePlanIds`) and `COUNT_ZERO_IS_NOT_STOP_SELL` (a count of 0 is a count, which\n the next OTA cancellation or your next count moves).\n- `zs.availability.dryRun(updates)`, `zs.rates.dryRun(updates)` and `zs.restrictions.dryRun(updates)` answer\n what the same `set` WOULD do and write nothing: a `WritePreview` (`dryRun: true`, `verdict`, what would\n change, what is already held, the notices), never a `WriteAccepted`. Use one before a large or unusual\n write, or to show a person what a button will do. It spends the minute budgets like the write it\n previews (one request, one write, the same cells), so it is not a free read of the calendar: never\n dry-run on a timer or to \"check\" a night. `zs.rates.get` and its siblings are the reads.\n- `zs.availability.close({ roomTypeId, dateFrom, dateTo })` closes one room type on those nights everywhere:\n its count goes to 0 and stop-sell is switched on for every one of its rate plans. Read `notReached` in\n the answer: it names what the close could not reach (a rate an OTA links on its own side is closed only\n by the count). `zs.availability.reopen` undoes exactly that close; pass `available` when your software\n knows how many rooms are free now. `closeDryRun` and `reopenDryRun` show what each would do. Call\n close and reopen from a person's action or a rule a person set; never from a loop over all rooms.\n- When a person asks \"why is this night not selling as we sent it\", call\n `zs.explain.night({ roomTypeId, date })` and show its `summary`: what your software last sent, what\n ZimmerStack's record holds and who set it, what the channel manager was last seen holding, and any\n value it refused, in its own words. It reads the channel manager's copy as last seen, never a booking\n site's own screen; `seenAt: null` means \"never read back\", not \"wrong\". Never loop it over a calendar.\n\n## Bookings and events: the webhook is the nudge, the log is the truth\n\n- Every event of a hotel (an OTA booking arriving, changing, cancelled; a website booking; a channel\n problem and its end; drift) has a `sequence`, one higher than the hotel's last. The webhook carries it,\n and `GET /events` lists every event once, in that order, for 90 days.\n- Build the receiver so nothing depends on a delivery: verify it (`verifyWebhook`), answer 2xx at once,\n then read the log from the place you saved:\n `for await (const event of zs.events.all({ after: place })) { apply(event); place = event.sequence; }`\n and save `place` with what you applied, in one transaction. Run the same loop on a schedule (every few\n minutes is plenty) and after a restart: a missed, repeated or out-of-order delivery then changes nothing.\n- `event.data.booking.version` counts a booking's events (1, 2, 3 …). A copy you hold with a higher\n version is newer than the event in your hand: do not overwrite it.\n- `onGap` on `zs.events.all` fires when the log no longer holds what follows your place (a first run, or\n an outage longer than the log keeps): read `zs.channelBookings.all({ since })` and\n `zs.directBookings.all({ since })`, then carry on from the log.\n- Narrow an event with `isOtaBookingEvent`, `isWebsiteBookingEvent`, `isSyncEvent`, `isDriftEvent`,\n `isConnectEvent`. A type you do not know is skipped, never an error: new types are added without notice.\n- Two families are about your ACCOUNT, not one hotel: `platform.incident.*` (`isIncidentEvent`) and\n `support.ticket.*` (`isSupportTicketEvent`). They carry no `property` and no `sequence` and are not in\n the event log. Check for them BEFORE any code that reads `event.property`; `zs.status.get()` and\n `zs.supportTickets.get(id)` are the reads behind them.\n- A cancelled room stays in `rooms[]` with `status: \"CANCELLED\"`; `stay` and `occupancy` count the rooms\n still live. `finance.virtualCard: true` means the OTA pays the hotel with a card it issues: the guest\n owes the desk nothing for the room. No card number is ever sent.\n\n## Guest contact\n\n- A guest's phone and email are returned by the API until 30 days after checkout. After that guest.phone and guest.email are null and guest.contactWithheld says \"retention\", so you can tell withheld from a booking that never had one. The name, the stay and the money stay.\n Copy what you need into your own system when the booking arrives; do not plan to read it back later.\n- `guest.contactWithheld` says why `phone` and `email` are null: `\"retention\"` is final, `\"unavailable\"`\n means ask again. Never treat null as \"the guest gave none\" when it is set.\n- Every read that returned contact is logged (the key, the partner behind it, when, which bookings) and the hotel's owner sees the list. Read contact only where a person needs it.\n- An endpoint receives phone and email only while its owner has guest contact switched on; it can be switched at any time. A partner's company endpoint starts with it off.\n\n## Webhook endpoints by API (a software partner's company key)\n\n- With the scope `webhooks:manage` a company key creates, changes, pauses, resumes, tests and recovers\n its own company webhook endpoints: `zs.webhookEndpoints.*`. No hotel is named: an endpoint is the\n partner's. A test key manages test endpoints (your sandboxes' events), a live key live ones.\n- The signing secret is in the answer of `zs.webhookEndpoints.create` and `.rotateSecret`, once. Store it\n in the server's settings at that moment (never in code, a log or a chat); no call reads it back.\n- Before planned downtime call `zs.webhookEndpoints.pause`: events are held and `resume` sends them, oldest\n first. After an outage call `zs.webhookEndpoints.recover(id, since)`, or simply read the log.\n- `zs.webhookEndpoints.delete` is for good and takes the delivery log with it: only on a person's action.\n\n## Going live, connect links and a hotel's keys (a software partner's company key)\n\n- A hotel you add (`zs.properties.create`) is live from the start. A hotel that let you in by your vendor\n code is not: until it is, a call that names it answers `ARI_NOT_AUTHORITATIVE`.\n `zs.forProperty(id).readiness.get()` answers four checks, each with a sentence and what to do.\n- To send a year first, pass `{ beforeGoLive: true }` on each call: `zs.rates.set(prices, { beforeGoLive: true })`.\n Prices and stay rules sent this way are stored and wait (the answer says `heldUntilGoLive: true`).\n A price for every rate plan and night of the year ahead is what the readiness report asks for.\n- ROOM COUNTS ARE NOT SENT AHEAD. Until the hotel is live a room count may only LOWER what is on sale:\n one at or below what is on sale goes to the booking sites at once (a held count would oversell a\n room), and one that raises it is refused in the answer's `rejected` list (`NOTHING_ACCEPTED` when\n nothing else in the request landed), because the hotel's own people may still be running its counts.\n Do not loop on that refusal and do not try to work around it: send the room counts with\n `zs.availability.set` right after `goLive` answers.\n- `zs.readiness.goLive()` makes your software the hotel's source of truth. Call it when a person decided\n to, once `ready` is true. `NOT_READY` lists the checks that did not pass (`err.details`): fix them and\n call again; never retry it in a loop. Only ZimmerStack support switches a hotel back.\n- Connecting a booking site: `zs.connectLinks.create({ propertyId, channel })` (scope `channels:connect`,\n a LIVE key: a test key is refused) answers a one-time `url` for the hotel's own person, who types the\n hotel's id at the booking site (MakeMyTrip also its access token) and confirms every room and rate match\n on ZimmerStack's page. Only Airbnb is connected from the link alone (the host signs in on Airbnb's own\n page): every other booking site must first accept our connectivity partner for the hotel, in its extranet\n or through its support. Send `hotelStep` to the hotel first and the `url` once that step is done. Never\n ask a hotel for a booking site's sign-in, hotel id or token, never store one, and never build a screen\n that takes one: no call accepts it.\n Listen for `channel.connect.completed` and `channel.connect.expired` (match on `data.connect.linkId`).\n- `zs.hotelKeys.list`, `.create`, `.rotate` and `.revoke` (scope `keys:manage`) manage the keys you made on\n a hotel you added; never a company key, never the hotel's own. A rotation makes a new key with the same name, scopes, addresses and expiry; the old one keeps answering for 24 hours (retireAt), then stops.\n- A VALUE SHOWN ONCE is in one answer and nowhere else: the `key` of `zs.hotelKeys.create` and `.rotate`,\n the `url` of `zs.connectLinks.create`, the `secret` of `zs.webhookEndpoints.create` and `.rotateSecret`.\n Take it with `shownOnce(answer)` and put it in the server's secret store in the same step. It is null\n on a retry of the same request: `shownOnce` then throws `ZimmerStackShownOnceError`, whose `nextStep`\n names the call that gets a new one. Never write code that stores `answer.key ?? \"\"`. Log\n `withoutShownOnce(answer)`, never the answer itself.\n\n## Billing, support and status (a software partner's company key)\n\n- `zs.billing.get()`, `.invoices()` and `.nextInvoice()` (scope `billing:read`) READ what the partner\n portal's Billing page shows. Nothing pays or changes anything by API. Amounts are decimal strings in\n major units beside `…Minor`: use the money helpers, and never add amounts of two currencies.\n- `atCost` on `zs.billing.get()` lists what the channel manager charged above its included room types and\n rate plans, passed on at cost. An item with `status: \"RECORDED\"` is on no invoice yet: show it as\n recorded, never as billed.\n- `zs.supportTickets.create({ severity, subject, message, propertyIds })` (scope `support:write`) opens a\n ticket; ZimmerStack attaches what its own records show. The level follows from the hotels you name: many_hotels needs two or more propertyIds or allProperties true; one_hotel needs exactly one; question takes any or none.\n Open one from a person's action or from one alert, never from a loop, and never put a key, a secret or\n a guest's details in the message.\n- Before blaming your own code for a failure across hotels, read `zs.status.get()`: the open incidents\n that touch your hotels. During one, keep what people changed and send it when it is resolved; do not\n resend everything.\n\n## Room types and rate plans\n\n- A hotel sells room types (\"Deluxe Room\") through rate plans (\"Bed and breakfast\"). Create or change\n one with `zs.roomTypes.save({ ref, name, roomCount, adults })` and\n `zs.ratePlans.save({ ref, roomTypeRef, name, mealPlan, defaultRate })`. `ref` is the person's own\n id for it: sending the same ref again changes that entity, it never makes a second one. Several in\n one request: `zs.catalog.upsertRoomTypes` and `zs.catalog.upsertRatePlans`. All need the scope\n `catalog:write`.\n- A new rate plan needs `defaultRate`, its real price for a night: without it the request is refused\n (400 `VALIDATION`, `details.refs` names the plans) and nothing in it is saved. Every date of a new\n plan can be sold at that price until the price of each night is sent, so never write a test number\n or a made-up one; ask the person for the price. `defaultRate: null` is refused for a plan the\n integration made.\n- Every later write names ZimmerStack's numeric `id`, not the ref: room counts name a room type's\n id, prices and stay rules name a rate plan's id. `zs.roomTypes.list()` and `zs.ratePlans.list()`\n give them, and so does the answer of each `save`.\n- `zs.roomTypes.delete(idOrRef)` and `zs.ratePlans.delete(idOrRef)` delete for good, and a room\n type takes its rate plans with it. Call them only when a person chose to delete that one entity on\n a screen, after a confirmation that names it. Never from a loop, a sync job, a \"reset\" or a cleanup\n script, and never to repair a mismatch: send the entity again with `save` instead. A hotel may\n delete 60 entities a day.\n- `CATALOG_CONFLICT` or `CHANNEL_MANAGER_ERROR` on a delete means the hotel still uses it: a\n booking site still sells it, an upcoming stay holds one of its rooms, or rooms are still assigned\n to the room type. Nothing was deleted. Show the message and stop; do not try another way round.\n\n## Adding, changing and removing a hotel (a software partner's company key)\n\n- Only a COMPANY key with the scope `properties:write` can do any of the three; a hotel's own key\n cannot (`COMPANY_KEY_REQUIRED`). The person ticks \"Also add and remove hotels\" when making the key in\n the partner portal; only the account's owner or an Admin is offered that tick box. None of the calls\n names a hotel with `forProperty`.\n- `zs.properties.create({ name, owner, address, roomTypes })` adds a hotel and answers with its `id`:\n act on it with `zs.forProperty(id)`. The owner gets the sign-in details by email, never the caller.\n It joins the partner's monthly invoice. With a `zsk_test_` key the same call makes a sandbox, which\n is never billed. A partner may add 20 hotels an hour.\n- After adding: a hotel added with its room types is put on the channel manager when its billing\n starts, usually at once (`channelManager` in the answer says). If a call answers 409\n CHANNEL_MANAGER_DISABLED, send its room types again with the same refs (`zs.roomTypes.save` or\n `zs.catalog.upsertRoomTypes`); then the rate plans, then room counts and prices.\n- `zs.properties.update(propertyId, { name, address })` changes the name or the address of a hotel the\n partner added. Send only what changes: `name`, and under `address` any of `line1`, `city`,\n `state`, `postalCode`. It never changes the hotel's country, currency, time zone, owner or tax id\n (sending one is `VALIDATION`), and it changes the hotel's record in ZimmerStack, not the name of its\n listing on a booking site. The answer's `changed` lists the fields whose stored value moved; empty\n means everything sent was already stored. `PROPERTY_NOT_CHANGEABLE` means the hotel's owner let the\n partner in, so the owner changes it: show the message and stop. After a new name, `delete` wants that\n new name in `confirm`.\n- `zs.properties.delete(propertyId, { confirm })` (also `zs.properties.remove`) removes a hotel the\n partner added, FOR GOOD: its booking sites are disconnected, its rate plans and then its room types\n are removed from the channel manager, the hotel is closed and it comes off the invoice from the next\n 1st. `confirm` is the hotel's exact name from `zs.properties.list()`. There is no undo, and a\n removed hotel cannot be added again by API.\n- Call `delete` only when a person chose to remove that one hotel on a screen, after typing or\n confirming its name. Never from a loop, a timer, a sync job, a \"reset\", a cleanup or a test against\n a live key, and never to fix a hotel that looks wrong. A partner may remove\n 10 hotels a day.\n- The answer's `channelManager.state` is `REMOVED`, or `RETRYING` when one step is still finishing:\n that is success, ZimmerStack retries it, do not call again in a loop. `PROPERTY_NOT_REMOVABLE` means\n this key may not remove that hotel (its owner let the partner in, or it uses more than the channel\n manager): show the message and stop.\n- Both calls take longer than the others (a removal disconnects the booking sites one after another),\n so the client waits up to 95 seconds for them whatever `timeoutMs` is. If `delete` ends in\n `TIMEOUT` or `NETWORK_ERROR`, the person may press Remove again: a hotel already gone answers\n `replay: true`, one still being removed answers `PROPERTY_BUSY`. Never retry it in a loop.\n\n## A channel's price modifier\n\n- `zs.channels.setModifier(channelId, steps)` moves EVERY price sent to that channel from then on.\n Call it only when a person saved that setting on a screen. Never from a loop, a timer, a seed\n script or a test against a live key. A hotel may change modifiers 6 times a day.\n- Saving a modifier makes the channel manager send that channel every date again, so prices already on the channel move to the new rule within minutes.\n Show that sentence where the person saves (`MODIFIER_TAKES_EFFECT`), and offer\n `zs.rates.resend()` as a separate, deliberate button (\"Apply to nights already on sale\"): 3 a day\n per hotel, never automatic.\n- Keep the grid on the price before any modifier; show a channel's price beside it with\n `channelPrice(rate, steps)`.\n\n## Website bookings: apply them before you push room counts\n\n- When the hotel also sells on its own website through ZimmerStack's booking engine, those bookings\n reach you as the webhooks `direct.booking.created`, `direct.booking.modified` and\n `direct.booking.cancelled` (the endpoint receives each only when it lists that type) and by\n `zs.directBookings.all({ since })` (scope `direct-bookings:read`). They are not OTA bookings:\n `isWebsiteBookingEvent(event)` tells them apart, `channel.otaName` is `\"Website\"` and `finance` is null.\n- `direct.booking.modified` is a no-show and its undo, nothing else yet: the hotel recorded that the guest\n did not arrive, or undid that. It is NOT a cancellation: `status` stays CONFIRMED and the payment is\n untouched, so never refund on it. Read `stayStatus` and each room's `status`: NOSHOW gives the nights\n back (they are on sale again on every channel), UPCOMING again holds them. `changes` names what moved\n (`\"stayStatus\"`, `\"rooms[0].status\"`); `previous` is the booking as it read before, `stayStatus`\n included. On a sandbox, `zs.sandbox.bookings.noShow(bookingId)` makes the real event for a booking\n simulated with `otaName: \"Website\"`, and `{ undo: true }` its undo.\n- A website booking takes one room off the count the channels hold, at once. A PMS that pushes absolute\n room counts must apply the booking to its own calendar BEFORE its next `zs.availability.set` or\n `zs.grid.save`, or that push puts the sold room back on sale. Read `zs.directBookings.all` before a\n full push. Nothing on our side stops the count from going up.\n- `zs.directBookings.cancel(bookingId, { refund, reason })` cancels a whole website booking that is\n still UPCOMING, and moves the guest's money (scope `direct-bookings:cancel`, granted on its own).\n `refund` is `\"policy\"` (the default: what the booking's own cancellation policy gives back, as if the\n guest cancelled), `\"full\"` (everything paid online: the hotel is at fault, an overbooking) or\n `\"none\"` (the hotel settles the money itself). Call it only from a person's own cancel button, with\n the refund they chose on the screen; never from a loop, a sync job or a test against a live key.\n Show `refund.amount` and `refund.status` from the answer. `BOOKING_NOT_CANCELLABLE` (checked in,\n checked out, a no-show) goes to the hotel's desk; do not retry it. `replay: true` means it was\n already cancelled and no money moved. Your own cancel comes back as `direct.booking.cancelled`\n (\"Cancelled by the hotel\"): match it on the booking id and treat it as already applied.\n\n## Errors\n\n```ts\nimport { ZimmerStack, ZimmerStackError } from \"@zimmerstack/connect\";\n\ntry {\n await zs.rates.set(updates);\n} catch (err) {\n if (err instanceof ZimmerStackError) {\n // err.code is stable (RATE_LIMITED, RATE_OUT_OF_BAND, SCOPE_MISSING, …); err.message is for people.\n // Show err.message to the person; branch on err.code; never retry unless err.retryable.\n }\n throw err;\n}\n```\n\n- `SCOPE_MISSING`: the key was not given that permission. Say which one is missing; the hotel's\n owner grants it (Admin → Developers → API keys). Do not look for another route.\n- `API_KEY_INVALID`, `API_KEY_REVOKED`, `API_KEY_EXPIRED`: stop. The client refuses every later call\n by itself; repeated bad calls get the server's address refused.\n- `RATE_OUT_OF_BAND`, `MODIFIER_OUT_OF_BAND`: the value is outside what the hotel allows. It is a\n guard against a typing slip; show the message, never split the change into smaller steps to pass.\n\n## The MCP server\n\nThe package carries an MCP server for you, the agent: `npx -y @zimmerstack/connect mcp`. If it is\nconnected, use it instead of guessing: `zimmerstack_reference` looks up any operation, type, limit\nor error code from the API's own contract, and `zimmerstack_sandbox_read` /\n`zimmerstack_sandbox_write` make one call on the sandbox so you can see real ids and try a body\nbefore you write the code that sends it. `zimmerstack_doctor` says what is wrong when a call is\nrefused or a webhook does not arrive; `zimmerstack_sandbox_limits` prints every budget and how full it\nis; `zimmerstack_sandbox_simulate` makes a real booking or channel event of any type on the sandbox, and\n`zimmerstack_sandbox_events` reads the ordered log, so a receiver and its catch-up can be tried end to\nend. `zimmerstack_sandbox_dry_run` shows what a write would do with nothing written, and its notices;\n`zimmerstack_sandbox_explain` tells one night's whole story; `zimmerstack_sandbox_close` closes or reopens\na room type everywhere; `zimmerstack_sandbox_fault` makes the sandbox's pretend channel refuse, throttle\nor go down, so the code that handles a refused value or an outage can be tried before a live hotel meets\none (in your own tests: `zs.sandbox.faults.set` and `.clear`). It works with a `zsk_test_` key only and refuses a live one. It is for building; the application\nyou write calls the API through the client, never through these tools.\n\n## Before you call the work done\n\n- [ ] The key is read from the environment, on a server, and appears in no committed file or log.\n- [ ] Every screen that writes sends only what the person changed, once, on their action.\n- [ ] No retry loop, no timer and no polling faster than 15 seconds around a call of this package.\n- [ ] Errors show `err.message` to the person and branch on `err.code`.\n- [ ] Tests run against a `zsk_test_` key or a fake `fetch`; none needs a live key.\n- [ ] Where a modifier is saved, the screen says when it takes effect, and the re-send is its own button.\n- [ ] A PMS that pushes room counts applies every website booking to its own calendar before it pushes.\n- [ ] A website booking is cancelled only from a person's own action, with the refund they chose.\n- [ ] A room type or a rate plan is deleted only from a person's own action, after a confirmation that names it.\n- [ ] The webhook receiver saves its place in the event log and catches up from it; nothing depends on a delivery arriving, or arriving in order.\n- [ ] A write's answer is read: `rejected`, `rounded` and a batch that reads `failed` reach the person who saved.\n- [ ] Money is handled as the API's decimal strings with the package's helpers; nothing divides by 100.\n- [ ] Guest contact the application needs is copied when the booking arrives, and `contactWithheld` is handled.\n- [ ] After every save of prices, room counts or stay rules, the notices (`noticesOf`) reach the person who saved.\n- [ ] A button that closes a night says what it closes: one rate plan (stop-sell), the room's count (0), or both (`zs.availability.close`).\n- [ ] A value shown once (a key, a connect link, a webhook secret) is taken with `shownOnce`, stored at once, and never logged.\n- [ ] Code that reads `event.property` runs only after the event is known not to be an incident or a support-ticket event.\n- [ ] No screen asks for, and no code stores, a booking site's password.\n- [ ] `npx @zimmerstack/connect doctor` reports nothing that needs attention.\n";
|
|
6
6
|
export const REFERENCE = {
|
|
7
7
|
"api": "ZimmerStack Connect API v1",
|
|
8
8
|
"base": "https://api.zimmerstack.com/api/v1/connect-api/v1",
|
|
@@ -59,7 +59,7 @@ export const REFERENCE = {
|
|
|
59
59
|
},
|
|
60
60
|
{
|
|
61
61
|
"status": 409,
|
|
62
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
62
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
63
63
|
},
|
|
64
64
|
{
|
|
65
65
|
"status": 429,
|
|
@@ -160,6 +160,83 @@ export const REFERENCE = {
|
|
|
160
160
|
}
|
|
161
161
|
]
|
|
162
162
|
},
|
|
163
|
+
{
|
|
164
|
+
"key": "PATCH /properties/{propertyId}",
|
|
165
|
+
"summary": "Change a hotel",
|
|
166
|
+
"description": "Scope properties:write, company keys only; X-ZS-Property is not read. Changes the hotel's name and its address (line1, city, state, postalCode): send only the fields to change, at least one. Never its country, currency, time zone, owner or tax id: a body that names one is 400 VALIDATION. It changes the hotel's record in ZimmerStack, not the name of a listing on an OTA. Only a hotel you added; who pays for it is not asked. The answer is the hotel in GET /properties' shape with its address and changed, the fields whose stored value moved. With a test key it changes one of your sandboxes. x-zimmerstack.properties has the whole flow.",
|
|
167
|
+
"scope": "properties:write",
|
|
168
|
+
"call": "zs.properties.update(propertyId, changes)",
|
|
169
|
+
"also": [],
|
|
170
|
+
"path": [
|
|
171
|
+
"propertyId"
|
|
172
|
+
],
|
|
173
|
+
"query": [],
|
|
174
|
+
"body": "PropertyChange",
|
|
175
|
+
"response": "PropertyChanged",
|
|
176
|
+
"answerStatus": [
|
|
177
|
+
200
|
|
178
|
+
],
|
|
179
|
+
"idempotent": true,
|
|
180
|
+
"request": {
|
|
181
|
+
"name": "Ganga Riverside Guest House",
|
|
182
|
+
"address": {
|
|
183
|
+
"line1": "16 Assi Ghat Road"
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
"answer": {
|
|
187
|
+
"id": 63,
|
|
188
|
+
"name": "Ganga Riverside Guest House",
|
|
189
|
+
"timezone": "Asia/Kolkata",
|
|
190
|
+
"currency": "INR",
|
|
191
|
+
"channelManager": false,
|
|
192
|
+
"sandbox": false,
|
|
193
|
+
"address": {
|
|
194
|
+
"line1": "16 Assi Ghat Road",
|
|
195
|
+
"city": "Varanasi",
|
|
196
|
+
"state": "Uttar Pradesh",
|
|
197
|
+
"postalCode": "221005",
|
|
198
|
+
"country": "IN"
|
|
199
|
+
},
|
|
200
|
+
"changed": [
|
|
201
|
+
"name",
|
|
202
|
+
"address.line1"
|
|
203
|
+
]
|
|
204
|
+
},
|
|
205
|
+
"refusals": [
|
|
206
|
+
{
|
|
207
|
+
"status": 400,
|
|
208
|
+
"description": "data.code VALIDATION: no field to change was sent, a name or a part of the address outside its length, or a field this request never changes (country, currency, timezone, owner, taxId, roomTypes)"
|
|
209
|
+
},
|
|
210
|
+
{
|
|
211
|
+
"status": 401,
|
|
212
|
+
"description": "Missing, malformed, unknown or revoked key (data.code API_KEY_INVALID | API_KEY_REVOKED | API_KEY_EXPIRED)"
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
"status": 403,
|
|
216
|
+
"description": "COMPANY_KEY_REQUIRED: a hotel's own key was used; SCOPE_MISSING: the company key lacks properties:write; IP_NOT_ALLOWED as everywhere; or WRITES_SUSPENDED: ZimmerStack has suspended your company's writes"
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
"status": 404,
|
|
220
|
+
"description": "No hotel with this id that this key may act on"
|
|
221
|
+
},
|
|
222
|
+
{
|
|
223
|
+
"status": 409,
|
|
224
|
+
"description": "PROPERTY_NOT_CHANGEABLE: not yours to change, data.details.reason is OWNER_ALLOWED (its owner let you in, and its owner changes it); or IDEMPOTENCY_KEY_REUSED / IDEMPOTENCY_IN_FLIGHT"
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
"status": 413,
|
|
228
|
+
"description": "Body larger than 1048576 bytes (x-zimmerstack.limits.maxBodyBytes); nothing was read"
|
|
229
|
+
},
|
|
230
|
+
{
|
|
231
|
+
"status": 429,
|
|
232
|
+
"description": "A per-minute budget. Honour Retry-After"
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
"status": 503,
|
|
236
|
+
"description": "ZimmerStack has paused every write to the channel manager (WRITES_FROZEN), or the write could not be checked against its budgets (SHIELD_UNAVAILABLE). Nothing was written; honour Retry-After"
|
|
237
|
+
}
|
|
238
|
+
]
|
|
239
|
+
},
|
|
163
240
|
{
|
|
164
241
|
"key": "DELETE /properties/{propertyId}",
|
|
165
242
|
"summary": "Remove a hotel you added (a software partner's company key)",
|
|
@@ -311,7 +388,7 @@ export const REFERENCE = {
|
|
|
311
388
|
},
|
|
312
389
|
{
|
|
313
390
|
"status": 409,
|
|
314
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
391
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
315
392
|
},
|
|
316
393
|
{
|
|
317
394
|
"status": 429,
|
|
@@ -464,7 +541,7 @@ export const REFERENCE = {
|
|
|
464
541
|
},
|
|
465
542
|
{
|
|
466
543
|
"status": 409,
|
|
467
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
544
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
468
545
|
},
|
|
469
546
|
{
|
|
470
547
|
"status": 429,
|
|
@@ -564,7 +641,7 @@ export const REFERENCE = {
|
|
|
564
641
|
},
|
|
565
642
|
{
|
|
566
643
|
"status": 409,
|
|
567
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
644
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
568
645
|
},
|
|
569
646
|
{
|
|
570
647
|
"status": 429,
|
|
@@ -726,7 +803,7 @@ export const REFERENCE = {
|
|
|
726
803
|
{
|
|
727
804
|
"key": "PUT /catalog/rate-plans",
|
|
728
805
|
"summary": "Create or change rate plans by your own ref",
|
|
729
|
-
"description": "Scope catalog:write. Up to 100 per request, each ref once; name the room type by our id (roomTypeId) or by the ref you gave it (roomTypeRef, in this request or an earlier one). A ref seen before is updated where the fields differ; a new ref whose name exists under the same room type (with no ref) adopts that plan; anything else is created here and on the channel manager at once, seeded at
|
|
806
|
+
"description": "Scope catalog:write. Up to 100 per request, each ref once; name the room type by our id (roomTypeId) or by the ref you gave it (roomTypeRef, in this request or an earlier one). A ref seen before is updated where the fields differ; a new ref whose name exists under the same room type (with no ref) adopts that plan; anything else is created here and on the channel manager at once, seeded at defaultRate when given. A plan never moves between room types.",
|
|
730
807
|
"scope": "catalog:write",
|
|
731
808
|
"call": "zs.catalog.upsertRatePlans(body)",
|
|
732
809
|
"also": [
|
|
@@ -749,7 +826,7 @@ export const REFERENCE = {
|
|
|
749
826
|
"mealPlan": "CP",
|
|
750
827
|
"occupancy": 2,
|
|
751
828
|
"refundable": true,
|
|
752
|
-
"
|
|
829
|
+
"defaultRate": "4500.00"
|
|
753
830
|
},
|
|
754
831
|
{
|
|
755
832
|
"ref": "rp-ph-ro",
|
|
@@ -758,22 +835,22 @@ export const REFERENCE = {
|
|
|
758
835
|
"mealPlan": "EP",
|
|
759
836
|
"occupancy": 3,
|
|
760
837
|
"refundable": false,
|
|
761
|
-
"
|
|
838
|
+
"defaultRate": 12000
|
|
762
839
|
}
|
|
763
840
|
]
|
|
764
841
|
},
|
|
765
842
|
"answer": {
|
|
766
843
|
"items": [
|
|
767
844
|
{
|
|
768
|
-
"ref": "
|
|
769
|
-
"id":
|
|
845
|
+
"ref": "rp-bb",
|
|
846
|
+
"id": 901,
|
|
770
847
|
"action": "adopted",
|
|
771
848
|
"sync": "IN_SYNC",
|
|
772
849
|
"notice": null
|
|
773
850
|
},
|
|
774
851
|
{
|
|
775
|
-
"ref": "
|
|
776
|
-
"id":
|
|
852
|
+
"ref": "rp-ph-ro",
|
|
853
|
+
"id": 903,
|
|
777
854
|
"action": "created",
|
|
778
855
|
"sync": "IN_SYNC",
|
|
779
856
|
"notice": null
|
|
@@ -905,7 +982,42 @@ export const REFERENCE = {
|
|
|
905
982
|
],
|
|
906
983
|
"idempotent": false,
|
|
907
984
|
"request": null,
|
|
908
|
-
"answer":
|
|
985
|
+
"answer": {
|
|
986
|
+
"from": "2026-12-24",
|
|
987
|
+
"to": "2026-12-26",
|
|
988
|
+
"cells": [
|
|
989
|
+
{
|
|
990
|
+
"roomTypeId": 412,
|
|
991
|
+
"date": "2026-12-24",
|
|
992
|
+
"available": 2
|
|
993
|
+
},
|
|
994
|
+
{
|
|
995
|
+
"roomTypeId": 412,
|
|
996
|
+
"date": "2026-12-25",
|
|
997
|
+
"available": 2
|
|
998
|
+
},
|
|
999
|
+
{
|
|
1000
|
+
"roomTypeId": 412,
|
|
1001
|
+
"date": "2026-12-26",
|
|
1002
|
+
"available": 2
|
|
1003
|
+
},
|
|
1004
|
+
{
|
|
1005
|
+
"roomTypeId": 413,
|
|
1006
|
+
"date": "2026-12-24",
|
|
1007
|
+
"available": 1
|
|
1008
|
+
},
|
|
1009
|
+
{
|
|
1010
|
+
"roomTypeId": 413,
|
|
1011
|
+
"date": "2026-12-25",
|
|
1012
|
+
"available": 1
|
|
1013
|
+
},
|
|
1014
|
+
{
|
|
1015
|
+
"roomTypeId": 413,
|
|
1016
|
+
"date": "2026-12-26",
|
|
1017
|
+
"available": 1
|
|
1018
|
+
}
|
|
1019
|
+
]
|
|
1020
|
+
},
|
|
909
1021
|
"refusals": [
|
|
910
1022
|
{
|
|
911
1023
|
"status": 400,
|
|
@@ -925,7 +1037,7 @@ export const REFERENCE = {
|
|
|
925
1037
|
},
|
|
926
1038
|
{
|
|
927
1039
|
"status": 409,
|
|
928
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
1040
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
929
1041
|
},
|
|
930
1042
|
{
|
|
931
1043
|
"status": 429,
|
|
@@ -955,67 +1067,70 @@ export const REFERENCE = {
|
|
|
955
1067
|
"updates": [
|
|
956
1068
|
{
|
|
957
1069
|
"roomTypeId": 412,
|
|
958
|
-
"dateFrom": "2026-
|
|
959
|
-
"dateTo": "2026-
|
|
1070
|
+
"dateFrom": "2026-12-01",
|
|
1071
|
+
"dateTo": "2026-12-31",
|
|
960
1072
|
"available": 5
|
|
961
1073
|
},
|
|
962
1074
|
{
|
|
963
1075
|
"roomTypeId": 412,
|
|
964
|
-
"dateFrom": "2026-
|
|
965
|
-
"dateTo": "2026-
|
|
1076
|
+
"dateFrom": "2026-12-24",
|
|
1077
|
+
"dateTo": "2026-12-26",
|
|
966
1078
|
"available": 2
|
|
967
1079
|
}
|
|
968
1080
|
]
|
|
969
1081
|
},
|
|
970
1082
|
"answer": {
|
|
971
1083
|
"dryRun": true,
|
|
972
|
-
"resource": "
|
|
1084
|
+
"resource": "availability",
|
|
973
1085
|
"verdict": "would-write",
|
|
974
1086
|
"refusal": null,
|
|
975
|
-
"requestedCells":
|
|
976
|
-
"wouldChangeCells":
|
|
977
|
-
"unchangedCells":
|
|
1087
|
+
"requestedCells": 31,
|
|
1088
|
+
"wouldChangeCells": 3,
|
|
1089
|
+
"unchangedCells": 28,
|
|
978
1090
|
"heldCells": 0,
|
|
979
1091
|
"wouldRejectCells": 0,
|
|
980
1092
|
"lane": false,
|
|
981
1093
|
"wouldChange": [
|
|
982
1094
|
{
|
|
983
|
-
"
|
|
984
|
-
|
|
1095
|
+
"roomTypeIds": [
|
|
1096
|
+
412
|
|
985
1097
|
],
|
|
986
|
-
"dateFrom": "2026-12-
|
|
987
|
-
"dateTo": "2026-12-
|
|
1098
|
+
"dateFrom": "2026-12-24",
|
|
1099
|
+
"dateTo": "2026-12-26",
|
|
988
1100
|
"days": null,
|
|
989
|
-
"cells":
|
|
990
|
-
"
|
|
1101
|
+
"cells": 3,
|
|
1102
|
+
"available": 2
|
|
991
1103
|
}
|
|
992
1104
|
],
|
|
993
|
-
"unchanged": [
|
|
994
|
-
"held": [],
|
|
995
|
-
"wouldReject": [],
|
|
996
|
-
"notices": [
|
|
1105
|
+
"unchanged": [
|
|
997
1106
|
{
|
|
998
|
-
"
|
|
999
|
-
|
|
1000
|
-
"message": "You sent a stop-sell for rate plan 901: a switch on that plan, not on the room. Room type 412 is still on sale on 1 night through its other plan 904.",
|
|
1001
|
-
"action": "To close the room on every plan and every channel, use POST /availability/close for room type 412, or send availability 0 for it (PUT /availability).",
|
|
1002
|
-
"roomTypeId": 412,
|
|
1003
|
-
"ratePlanIds": [
|
|
1004
|
-
901
|
|
1107
|
+
"roomTypeIds": [
|
|
1108
|
+
412
|
|
1005
1109
|
],
|
|
1006
|
-
"
|
|
1007
|
-
|
|
1110
|
+
"dateFrom": "2026-12-01",
|
|
1111
|
+
"dateTo": "2026-12-23",
|
|
1112
|
+
"days": null,
|
|
1113
|
+
"cells": 23,
|
|
1114
|
+
"available": 5
|
|
1115
|
+
},
|
|
1116
|
+
{
|
|
1117
|
+
"roomTypeIds": [
|
|
1118
|
+
412
|
|
1008
1119
|
],
|
|
1009
|
-
"dateFrom": "2026-12-
|
|
1120
|
+
"dateFrom": "2026-12-27",
|
|
1010
1121
|
"dateTo": "2026-12-31",
|
|
1011
|
-
"
|
|
1122
|
+
"days": null,
|
|
1123
|
+
"cells": 5,
|
|
1124
|
+
"available": 5
|
|
1012
1125
|
}
|
|
1013
1126
|
],
|
|
1127
|
+
"held": [],
|
|
1128
|
+
"wouldReject": [],
|
|
1014
1129
|
"spent": {
|
|
1015
|
-
"cells":
|
|
1130
|
+
"cells": 31
|
|
1016
1131
|
},
|
|
1017
1132
|
"wouldSpend": {
|
|
1018
|
-
"changedCells":
|
|
1133
|
+
"changedCells": 3
|
|
1019
1134
|
},
|
|
1020
1135
|
"note": "Nothing was written, queued or sent, and no idempotency key was stored. Send the same body without dryRun to do it. Our record can move between the two: the real answer is the truth."
|
|
1021
1136
|
},
|
|
@@ -1038,7 +1153,7 @@ export const REFERENCE = {
|
|
|
1038
1153
|
},
|
|
1039
1154
|
{
|
|
1040
1155
|
"status": 409,
|
|
1041
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
1156
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1042
1157
|
},
|
|
1043
1158
|
{
|
|
1044
1159
|
"status": 413,
|
|
@@ -1087,7 +1202,56 @@ export const REFERENCE = {
|
|
|
1087
1202
|
],
|
|
1088
1203
|
"idempotent": false,
|
|
1089
1204
|
"request": null,
|
|
1090
|
-
"answer":
|
|
1205
|
+
"answer": {
|
|
1206
|
+
"from": "2026-12-24",
|
|
1207
|
+
"to": "2026-12-26",
|
|
1208
|
+
"currency": "INR",
|
|
1209
|
+
"decimals": 2,
|
|
1210
|
+
"cells": [
|
|
1211
|
+
{
|
|
1212
|
+
"ratePlanId": 901,
|
|
1213
|
+
"date": "2026-12-24",
|
|
1214
|
+
"rate": "4500.00",
|
|
1215
|
+
"rateMinor": 450000,
|
|
1216
|
+
"source": "MANUAL"
|
|
1217
|
+
},
|
|
1218
|
+
{
|
|
1219
|
+
"ratePlanId": 901,
|
|
1220
|
+
"date": "2026-12-25",
|
|
1221
|
+
"rate": "5200.00",
|
|
1222
|
+
"rateMinor": 520000,
|
|
1223
|
+
"source": "MANUAL"
|
|
1224
|
+
},
|
|
1225
|
+
{
|
|
1226
|
+
"ratePlanId": 901,
|
|
1227
|
+
"date": "2026-12-26",
|
|
1228
|
+
"rate": "5200.00",
|
|
1229
|
+
"rateMinor": 520000,
|
|
1230
|
+
"source": "MANUAL"
|
|
1231
|
+
},
|
|
1232
|
+
{
|
|
1233
|
+
"ratePlanId": 904,
|
|
1234
|
+
"date": "2026-12-24",
|
|
1235
|
+
"rate": "4000.00",
|
|
1236
|
+
"rateMinor": 400000,
|
|
1237
|
+
"source": "PLAN_DEFAULT"
|
|
1238
|
+
},
|
|
1239
|
+
{
|
|
1240
|
+
"ratePlanId": 904,
|
|
1241
|
+
"date": "2026-12-25",
|
|
1242
|
+
"rate": "4000.00",
|
|
1243
|
+
"rateMinor": 400000,
|
|
1244
|
+
"source": "PLAN_DEFAULT"
|
|
1245
|
+
},
|
|
1246
|
+
{
|
|
1247
|
+
"ratePlanId": 904,
|
|
1248
|
+
"date": "2026-12-26",
|
|
1249
|
+
"rate": "4000.00",
|
|
1250
|
+
"rateMinor": 400000,
|
|
1251
|
+
"source": "PLAN_DEFAULT"
|
|
1252
|
+
}
|
|
1253
|
+
]
|
|
1254
|
+
},
|
|
1091
1255
|
"refusals": [
|
|
1092
1256
|
{
|
|
1093
1257
|
"status": 400,
|
|
@@ -1107,7 +1271,7 @@ export const REFERENCE = {
|
|
|
1107
1271
|
},
|
|
1108
1272
|
{
|
|
1109
1273
|
"status": 409,
|
|
1110
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
1274
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1111
1275
|
},
|
|
1112
1276
|
{
|
|
1113
1277
|
"status": 429,
|
|
@@ -1137,14 +1301,14 @@ export const REFERENCE = {
|
|
|
1137
1301
|
"updates": [
|
|
1138
1302
|
{
|
|
1139
1303
|
"ratePlanId": 901,
|
|
1140
|
-
"dateFrom": "2026-
|
|
1304
|
+
"dateFrom": "2026-12-01",
|
|
1141
1305
|
"dateTo": "2027-03-31",
|
|
1142
1306
|
"rate": "4500.00",
|
|
1143
1307
|
"currency": "INR"
|
|
1144
1308
|
},
|
|
1145
1309
|
{
|
|
1146
1310
|
"ratePlanId": 901,
|
|
1147
|
-
"dateFrom": "2026-
|
|
1311
|
+
"dateFrom": "2026-12-01",
|
|
1148
1312
|
"dateTo": "2027-03-31",
|
|
1149
1313
|
"days": [
|
|
1150
1314
|
"fr",
|
|
@@ -1157,12 +1321,12 @@ export const REFERENCE = {
|
|
|
1157
1321
|
},
|
|
1158
1322
|
"answer": {
|
|
1159
1323
|
"dryRun": true,
|
|
1160
|
-
"resource": "
|
|
1324
|
+
"resource": "rates",
|
|
1161
1325
|
"verdict": "would-write",
|
|
1162
1326
|
"refusal": null,
|
|
1163
|
-
"requestedCells":
|
|
1164
|
-
"wouldChangeCells":
|
|
1165
|
-
"unchangedCells":
|
|
1327
|
+
"requestedCells": 121,
|
|
1328
|
+
"wouldChangeCells": 34,
|
|
1329
|
+
"unchangedCells": 87,
|
|
1166
1330
|
"heldCells": 0,
|
|
1167
1331
|
"wouldRejectCells": 0,
|
|
1168
1332
|
"lane": false,
|
|
@@ -1171,39 +1335,43 @@ export const REFERENCE = {
|
|
|
1171
1335
|
"ratePlanIds": [
|
|
1172
1336
|
901
|
|
1173
1337
|
],
|
|
1174
|
-
"dateFrom": "2026-12-
|
|
1175
|
-
"dateTo": "
|
|
1176
|
-
"days":
|
|
1177
|
-
|
|
1178
|
-
|
|
1338
|
+
"dateFrom": "2026-12-04",
|
|
1339
|
+
"dateTo": "2027-03-27",
|
|
1340
|
+
"days": [
|
|
1341
|
+
"fr",
|
|
1342
|
+
"sa"
|
|
1343
|
+
],
|
|
1344
|
+
"cells": 34,
|
|
1345
|
+
"rate": "5200.00",
|
|
1346
|
+
"rateMinor": 520000
|
|
1179
1347
|
}
|
|
1180
1348
|
],
|
|
1181
|
-
"unchanged": [
|
|
1182
|
-
"held": [],
|
|
1183
|
-
"wouldReject": [],
|
|
1184
|
-
"notices": [
|
|
1349
|
+
"unchanged": [
|
|
1185
1350
|
{
|
|
1186
|
-
"code": "ROOM_STILL_ON_SALE",
|
|
1187
|
-
"level": "warning",
|
|
1188
|
-
"message": "You sent a stop-sell for rate plan 901: a switch on that plan, not on the room. Room type 412 is still on sale on 1 night through its other plan 904.",
|
|
1189
|
-
"action": "To close the room on every plan and every channel, use POST /availability/close for room type 412, or send availability 0 for it (PUT /availability).",
|
|
1190
|
-
"roomTypeId": 412,
|
|
1191
1351
|
"ratePlanIds": [
|
|
1192
1352
|
901
|
|
1193
1353
|
],
|
|
1194
|
-
"
|
|
1195
|
-
|
|
1354
|
+
"dateFrom": "2026-12-01",
|
|
1355
|
+
"dateTo": "2027-03-31",
|
|
1356
|
+
"days": [
|
|
1357
|
+
"mo",
|
|
1358
|
+
"tu",
|
|
1359
|
+
"we",
|
|
1360
|
+
"th",
|
|
1361
|
+
"su"
|
|
1196
1362
|
],
|
|
1197
|
-
"
|
|
1198
|
-
"
|
|
1199
|
-
"
|
|
1363
|
+
"cells": 87,
|
|
1364
|
+
"rate": "4500.00",
|
|
1365
|
+
"rateMinor": 450000
|
|
1200
1366
|
}
|
|
1201
1367
|
],
|
|
1368
|
+
"held": [],
|
|
1369
|
+
"wouldReject": [],
|
|
1202
1370
|
"spent": {
|
|
1203
|
-
"cells":
|
|
1371
|
+
"cells": 121
|
|
1204
1372
|
},
|
|
1205
1373
|
"wouldSpend": {
|
|
1206
|
-
"changedCells":
|
|
1374
|
+
"changedCells": 34
|
|
1207
1375
|
},
|
|
1208
1376
|
"note": "Nothing was written, queued or sent, and no idempotency key was stored. Send the same body without dryRun to do it. Our record can move between the two: the real answer is the truth."
|
|
1209
1377
|
},
|
|
@@ -1226,7 +1394,7 @@ export const REFERENCE = {
|
|
|
1226
1394
|
},
|
|
1227
1395
|
{
|
|
1228
1396
|
"status": 409,
|
|
1229
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
1397
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1230
1398
|
},
|
|
1231
1399
|
{
|
|
1232
1400
|
"status": 413,
|
|
@@ -1275,7 +1443,42 @@ export const REFERENCE = {
|
|
|
1275
1443
|
],
|
|
1276
1444
|
"idempotent": false,
|
|
1277
1445
|
"request": null,
|
|
1278
|
-
"answer":
|
|
1446
|
+
"answer": {
|
|
1447
|
+
"from": "2026-12-24",
|
|
1448
|
+
"to": "2026-12-26",
|
|
1449
|
+
"cells": [
|
|
1450
|
+
{
|
|
1451
|
+
"ratePlanId": 901,
|
|
1452
|
+
"date": "2026-12-24",
|
|
1453
|
+
"stopSell": null,
|
|
1454
|
+
"closedToArrival": false,
|
|
1455
|
+
"closedToDeparture": null,
|
|
1456
|
+
"minStayArrival": 2,
|
|
1457
|
+
"minStayThrough": null,
|
|
1458
|
+
"maxStay": null
|
|
1459
|
+
},
|
|
1460
|
+
{
|
|
1461
|
+
"ratePlanId": 901,
|
|
1462
|
+
"date": "2026-12-25",
|
|
1463
|
+
"stopSell": null,
|
|
1464
|
+
"closedToArrival": false,
|
|
1465
|
+
"closedToDeparture": null,
|
|
1466
|
+
"minStayArrival": 2,
|
|
1467
|
+
"minStayThrough": null,
|
|
1468
|
+
"maxStay": null
|
|
1469
|
+
},
|
|
1470
|
+
{
|
|
1471
|
+
"ratePlanId": 901,
|
|
1472
|
+
"date": "2026-12-26",
|
|
1473
|
+
"stopSell": null,
|
|
1474
|
+
"closedToArrival": false,
|
|
1475
|
+
"closedToDeparture": null,
|
|
1476
|
+
"minStayArrival": 2,
|
|
1477
|
+
"minStayThrough": null,
|
|
1478
|
+
"maxStay": null
|
|
1479
|
+
}
|
|
1480
|
+
]
|
|
1481
|
+
},
|
|
1279
1482
|
"refusals": [
|
|
1280
1483
|
{
|
|
1281
1484
|
"status": 400,
|
|
@@ -1295,7 +1498,7 @@ export const REFERENCE = {
|
|
|
1295
1498
|
},
|
|
1296
1499
|
{
|
|
1297
1500
|
"status": 409,
|
|
1298
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
1501
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1299
1502
|
},
|
|
1300
1503
|
{
|
|
1301
1504
|
"status": 429,
|
|
@@ -1343,13 +1546,24 @@ export const REFERENCE = {
|
|
|
1343
1546
|
"resource": "restrictions",
|
|
1344
1547
|
"verdict": "would-write",
|
|
1345
1548
|
"refusal": null,
|
|
1346
|
-
"requestedCells":
|
|
1347
|
-
"wouldChangeCells":
|
|
1549
|
+
"requestedCells": 4,
|
|
1550
|
+
"wouldChangeCells": 4,
|
|
1348
1551
|
"unchangedCells": 0,
|
|
1349
1552
|
"heldCells": 0,
|
|
1350
1553
|
"wouldRejectCells": 0,
|
|
1351
1554
|
"lane": false,
|
|
1352
1555
|
"wouldChange": [
|
|
1556
|
+
{
|
|
1557
|
+
"ratePlanIds": [
|
|
1558
|
+
901
|
|
1559
|
+
],
|
|
1560
|
+
"dateFrom": "2026-12-24",
|
|
1561
|
+
"dateTo": "2026-12-26",
|
|
1562
|
+
"days": null,
|
|
1563
|
+
"cells": 3,
|
|
1564
|
+
"closedToArrival": false,
|
|
1565
|
+
"minStayArrival": 2
|
|
1566
|
+
},
|
|
1353
1567
|
{
|
|
1354
1568
|
"ratePlanIds": [
|
|
1355
1569
|
901
|
|
@@ -1383,10 +1597,10 @@ export const REFERENCE = {
|
|
|
1383
1597
|
}
|
|
1384
1598
|
],
|
|
1385
1599
|
"spent": {
|
|
1386
|
-
"cells":
|
|
1600
|
+
"cells": 4
|
|
1387
1601
|
},
|
|
1388
1602
|
"wouldSpend": {
|
|
1389
|
-
"changedCells":
|
|
1603
|
+
"changedCells": 4
|
|
1390
1604
|
},
|
|
1391
1605
|
"note": "Nothing was written, queued or sent, and no idempotency key was stored. Send the same body without dryRun to do it. Our record can move between the two: the real answer is the truth."
|
|
1392
1606
|
},
|
|
@@ -1409,7 +1623,7 @@ export const REFERENCE = {
|
|
|
1409
1623
|
},
|
|
1410
1624
|
{
|
|
1411
1625
|
"status": 409,
|
|
1412
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
1626
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1413
1627
|
},
|
|
1414
1628
|
{
|
|
1415
1629
|
"status": 413,
|
|
@@ -1454,7 +1668,7 @@ export const REFERENCE = {
|
|
|
1454
1668
|
},
|
|
1455
1669
|
"answer": {
|
|
1456
1670
|
"action": "close",
|
|
1457
|
-
"dryRun":
|
|
1671
|
+
"dryRun": true,
|
|
1458
1672
|
"roomTypeId": 412,
|
|
1459
1673
|
"dateFrom": "2026-12-24",
|
|
1460
1674
|
"dateTo": "2026-12-26",
|
|
@@ -1487,18 +1701,7 @@ export const REFERENCE = {
|
|
|
1487
1701
|
}
|
|
1488
1702
|
],
|
|
1489
1703
|
"skippedNights": 0,
|
|
1490
|
-
"batches": [
|
|
1491
|
-
{
|
|
1492
|
-
"resource": "availability",
|
|
1493
|
-
"batchId": "3c2b1a09-8f7e-4d6c-b5a4-938271605f4e",
|
|
1494
|
-
"poll": "/api/v1/connect-api/v1/batches/3c2b1a09-8f7e-4d6c-b5a4-938271605f4e"
|
|
1495
|
-
},
|
|
1496
|
-
{
|
|
1497
|
-
"resource": "restrictions",
|
|
1498
|
-
"batchId": "9e8d7c6b-5a49-4382-a716-0f1e2d3c4b5a",
|
|
1499
|
-
"poll": "/api/v1/connect-api/v1/batches/9e8d7c6b-5a49-4382-a716-0f1e2d3c4b5a"
|
|
1500
|
-
}
|
|
1501
|
-
]
|
|
1704
|
+
"batches": []
|
|
1502
1705
|
},
|
|
1503
1706
|
"refusals": [
|
|
1504
1707
|
{
|
|
@@ -1519,7 +1722,7 @@ export const REFERENCE = {
|
|
|
1519
1722
|
},
|
|
1520
1723
|
{
|
|
1521
1724
|
"status": 409,
|
|
1522
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
1725
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1523
1726
|
},
|
|
1524
1727
|
{
|
|
1525
1728
|
"status": 413,
|
|
@@ -1560,7 +1763,7 @@ export const REFERENCE = {
|
|
|
1560
1763
|
},
|
|
1561
1764
|
"answer": {
|
|
1562
1765
|
"action": "reopen",
|
|
1563
|
-
"dryRun":
|
|
1766
|
+
"dryRun": true,
|
|
1564
1767
|
"roomTypeId": 412,
|
|
1565
1768
|
"dateFrom": "2026-12-24",
|
|
1566
1769
|
"dateTo": "2026-12-26",
|
|
@@ -1587,18 +1790,7 @@ export const REFERENCE = {
|
|
|
1587
1790
|
],
|
|
1588
1791
|
"notReached": [],
|
|
1589
1792
|
"skippedNights": 0,
|
|
1590
|
-
"batches": [
|
|
1591
|
-
{
|
|
1592
|
-
"resource": "restrictions",
|
|
1593
|
-
"batchId": "5d4c3b2a-1908-4f7e-8d6c-b5a493827160",
|
|
1594
|
-
"poll": "/api/v1/connect-api/v1/batches/5d4c3b2a-1908-4f7e-8d6c-b5a493827160"
|
|
1595
|
-
},
|
|
1596
|
-
{
|
|
1597
|
-
"resource": "availability",
|
|
1598
|
-
"batchId": "6f5e4d3c-2b1a-4098-9f7e-6d5c4b3a2910",
|
|
1599
|
-
"poll": "/api/v1/connect-api/v1/batches/6f5e4d3c-2b1a-4098-9f7e-6d5c4b3a2910"
|
|
1600
|
-
}
|
|
1601
|
-
]
|
|
1793
|
+
"batches": []
|
|
1602
1794
|
},
|
|
1603
1795
|
"refusals": [
|
|
1604
1796
|
{
|
|
@@ -1619,7 +1811,7 @@ export const REFERENCE = {
|
|
|
1619
1811
|
},
|
|
1620
1812
|
{
|
|
1621
1813
|
"status": 409,
|
|
1622
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
1814
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1623
1815
|
},
|
|
1624
1816
|
{
|
|
1625
1817
|
"status": 413,
|
|
@@ -1912,7 +2104,7 @@ export const REFERENCE = {
|
|
|
1912
2104
|
},
|
|
1913
2105
|
{
|
|
1914
2106
|
"status": 409,
|
|
1915
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2107
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1916
2108
|
},
|
|
1917
2109
|
{
|
|
1918
2110
|
"status": 429,
|
|
@@ -1966,7 +2158,7 @@ export const REFERENCE = {
|
|
|
1966
2158
|
},
|
|
1967
2159
|
{
|
|
1968
2160
|
"status": 409,
|
|
1969
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2161
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
1970
2162
|
},
|
|
1971
2163
|
{
|
|
1972
2164
|
"status": 429,
|
|
@@ -2028,7 +2220,7 @@ export const REFERENCE = {
|
|
|
2028
2220
|
},
|
|
2029
2221
|
{
|
|
2030
2222
|
"status": 409,
|
|
2031
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2223
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2032
2224
|
},
|
|
2033
2225
|
{
|
|
2034
2226
|
"status": 429,
|
|
@@ -2052,7 +2244,17 @@ export const REFERENCE = {
|
|
|
2052
2244
|
],
|
|
2053
2245
|
"idempotent": false,
|
|
2054
2246
|
"request": null,
|
|
2055
|
-
"answer":
|
|
2247
|
+
"answer": {
|
|
2248
|
+
"active": false,
|
|
2249
|
+
"kind": null,
|
|
2250
|
+
"remaining": null,
|
|
2251
|
+
"until": null,
|
|
2252
|
+
"message": null,
|
|
2253
|
+
"setAt": null,
|
|
2254
|
+
"watch": [
|
|
2255
|
+
"No fault is set: everything you send lands in our record within a minute."
|
|
2256
|
+
]
|
|
2257
|
+
},
|
|
2056
2258
|
"refusals": [
|
|
2057
2259
|
{
|
|
2058
2260
|
"status": 401,
|
|
@@ -2068,7 +2270,7 @@ export const REFERENCE = {
|
|
|
2068
2270
|
},
|
|
2069
2271
|
{
|
|
2070
2272
|
"status": 409,
|
|
2071
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2273
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2072
2274
|
},
|
|
2073
2275
|
{
|
|
2074
2276
|
"status": 429,
|
|
@@ -2092,7 +2294,45 @@ export const REFERENCE = {
|
|
|
2092
2294
|
],
|
|
2093
2295
|
"idempotent": false,
|
|
2094
2296
|
"request": null,
|
|
2095
|
-
"answer":
|
|
2297
|
+
"answer": {
|
|
2298
|
+
"propertyId": 61,
|
|
2299
|
+
"sandbox": false,
|
|
2300
|
+
"ariAuthoritative": true,
|
|
2301
|
+
"inventory": {
|
|
2302
|
+
"state": "IN_SYNC",
|
|
2303
|
+
"pendingCells": 0,
|
|
2304
|
+
"lastOkAt": "2026-12-01T09:13:20.000Z",
|
|
2305
|
+
"lastError": null,
|
|
2306
|
+
"outOfSyncSince": null
|
|
2307
|
+
},
|
|
2308
|
+
"rates": {
|
|
2309
|
+
"dirtyCells": 12,
|
|
2310
|
+
"parkedCells": 0,
|
|
2311
|
+
"lastPushAt": "2026-12-01T09:14:31.000Z",
|
|
2312
|
+
"lastErrorAt": null,
|
|
2313
|
+
"lastError": null,
|
|
2314
|
+
"driftCells": 0,
|
|
2315
|
+
"driftSeenAt": null
|
|
2316
|
+
},
|
|
2317
|
+
"shield": {
|
|
2318
|
+
"level": "CLEAR",
|
|
2319
|
+
"reason": null,
|
|
2320
|
+
"until": null
|
|
2321
|
+
},
|
|
2322
|
+
"newestPendingBatch": {
|
|
2323
|
+
"batchId": "7f1d2c4e-5a6b-4c8d-9e0f-112233445566",
|
|
2324
|
+
"resource": "rates",
|
|
2325
|
+
"createdAt": "2026-12-01T09:14:03.201Z",
|
|
2326
|
+
"requestedCells": 121,
|
|
2327
|
+
"acceptedCells": 34,
|
|
2328
|
+
"noopCells": 87,
|
|
2329
|
+
"rejected": [],
|
|
2330
|
+
"status": "pending",
|
|
2331
|
+
"pendingCells": 12,
|
|
2332
|
+
"parkedCells": 0,
|
|
2333
|
+
"lastError": null
|
|
2334
|
+
}
|
|
2335
|
+
},
|
|
2096
2336
|
"refusals": [
|
|
2097
2337
|
{
|
|
2098
2338
|
"status": 401,
|
|
@@ -2108,7 +2348,7 @@ export const REFERENCE = {
|
|
|
2108
2348
|
},
|
|
2109
2349
|
{
|
|
2110
2350
|
"status": 409,
|
|
2111
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2351
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2112
2352
|
},
|
|
2113
2353
|
{
|
|
2114
2354
|
"status": 429,
|
|
@@ -2151,27 +2391,79 @@ export const REFERENCE = {
|
|
|
2151
2391
|
],
|
|
2152
2392
|
"idempotent": false,
|
|
2153
2393
|
"request": null,
|
|
2154
|
-
"answer":
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2394
|
+
"answer": {
|
|
2395
|
+
"since": "2026-12-03T09:20:00.000Z",
|
|
2396
|
+
"items": [
|
|
2397
|
+
{
|
|
2398
|
+
"bookingId": 48213,
|
|
2399
|
+
"reference": "SB-7KQ2MX9D",
|
|
2400
|
+
"externalReference": "WEB-2026-000123",
|
|
2401
|
+
"status": "UPCOMING",
|
|
2402
|
+
"checkIn": "2026-12-20",
|
|
2403
|
+
"checkOut": "2026-12-23",
|
|
2404
|
+
"nights": 3,
|
|
2405
|
+
"currency": "INR",
|
|
2406
|
+
"totalAmount": "27000.00",
|
|
2407
|
+
"totalPaid": "9000.00",
|
|
2408
|
+
"balanceDue": "18000.00",
|
|
2409
|
+
"guest": {
|
|
2410
|
+
"name": "Asha Verma",
|
|
2411
|
+
"phone": "+919876543210",
|
|
2412
|
+
"email": "asha@example.com"
|
|
2413
|
+
},
|
|
2414
|
+
"rooms": [
|
|
2415
|
+
{
|
|
2416
|
+
"bookingRoomId": 90001,
|
|
2417
|
+
"roomTypeId": 412,
|
|
2418
|
+
"ratePlanId": 901,
|
|
2419
|
+
"mealPlan": "CP",
|
|
2420
|
+
"adults": 2,
|
|
2421
|
+
"children": 1,
|
|
2422
|
+
"nightlyRate": "4500.00",
|
|
2423
|
+
"status": "UPCOMING"
|
|
2424
|
+
},
|
|
2425
|
+
{
|
|
2426
|
+
"bookingRoomId": 90002,
|
|
2427
|
+
"roomTypeId": 412,
|
|
2428
|
+
"ratePlanId": 901,
|
|
2429
|
+
"mealPlan": "CP",
|
|
2430
|
+
"adults": 2,
|
|
2431
|
+
"children": 0,
|
|
2432
|
+
"nightlyRate": "4500.00",
|
|
2433
|
+
"status": "UPCOMING"
|
|
2434
|
+
}
|
|
2435
|
+
],
|
|
2436
|
+
"inventory": {
|
|
2437
|
+
"eventRecorded": true,
|
|
2438
|
+
"channelManager": true,
|
|
2439
|
+
"pushedBy": "inventory-drain"
|
|
2440
|
+
},
|
|
2441
|
+
"replay": false,
|
|
2442
|
+
"createdAt": "2026-12-10T09:14:03.201Z",
|
|
2443
|
+
"cancelledAt": null
|
|
2444
|
+
}
|
|
2445
|
+
]
|
|
2446
|
+
},
|
|
2447
|
+
"refusals": [
|
|
2448
|
+
{
|
|
2449
|
+
"status": 400,
|
|
2450
|
+
"description": "Bad query (data.code VALIDATION)"
|
|
2451
|
+
},
|
|
2452
|
+
{
|
|
2453
|
+
"status": 401,
|
|
2454
|
+
"description": "Missing, malformed, unknown or revoked key (data.code API_KEY_INVALID | API_KEY_REVOKED)"
|
|
2455
|
+
},
|
|
2456
|
+
{
|
|
2457
|
+
"status": 403,
|
|
2458
|
+
"description": "The key lacks the scope this route needs (SCOPE_MISSING, details.needed / details.held), or the request came from outside the key's address allowlist (IP_NOT_ALLOWED)"
|
|
2459
|
+
},
|
|
2460
|
+
{
|
|
2461
|
+
"status": 404,
|
|
2462
|
+
"description": "X-ZS-Property names a property this key may not act on (PROPERTY_NOT_FOUND): for a company key, one outside its hotels; for a hotel key, any other property. A company key without the header is 400 PROPERTY_REQUIRED"
|
|
2463
|
+
},
|
|
2172
2464
|
{
|
|
2173
2465
|
"status": 409,
|
|
2174
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2466
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2175
2467
|
},
|
|
2176
2468
|
{
|
|
2177
2469
|
"status": 429,
|
|
@@ -2249,7 +2541,7 @@ export const REFERENCE = {
|
|
|
2249
2541
|
{
|
|
2250
2542
|
"bookingRoomId": 90001,
|
|
2251
2543
|
"roomTypeId": 412,
|
|
2252
|
-
"ratePlanId":
|
|
2544
|
+
"ratePlanId": 901,
|
|
2253
2545
|
"mealPlan": "CP",
|
|
2254
2546
|
"adults": 2,
|
|
2255
2547
|
"children": 1,
|
|
@@ -2259,7 +2551,7 @@ export const REFERENCE = {
|
|
|
2259
2551
|
{
|
|
2260
2552
|
"bookingRoomId": 90002,
|
|
2261
2553
|
"roomTypeId": 412,
|
|
2262
|
-
"ratePlanId":
|
|
2554
|
+
"ratePlanId": 901,
|
|
2263
2555
|
"mealPlan": "CP",
|
|
2264
2556
|
"adults": 2,
|
|
2265
2557
|
"children": 0,
|
|
@@ -2272,8 +2564,8 @@ export const REFERENCE = {
|
|
|
2272
2564
|
"channelManager": true,
|
|
2273
2565
|
"pushedBy": "inventory-drain"
|
|
2274
2566
|
},
|
|
2275
|
-
"replay":
|
|
2276
|
-
"createdAt": "2026-
|
|
2567
|
+
"replay": true,
|
|
2568
|
+
"createdAt": "2026-12-10T09:14:03.201Z",
|
|
2277
2569
|
"cancelledAt": null
|
|
2278
2570
|
},
|
|
2279
2571
|
"refusals": [
|
|
@@ -2346,7 +2638,7 @@ export const REFERENCE = {
|
|
|
2346
2638
|
{
|
|
2347
2639
|
"bookingRoomId": 90001,
|
|
2348
2640
|
"roomTypeId": 412,
|
|
2349
|
-
"ratePlanId":
|
|
2641
|
+
"ratePlanId": 901,
|
|
2350
2642
|
"mealPlan": "CP",
|
|
2351
2643
|
"adults": 2,
|
|
2352
2644
|
"children": 1,
|
|
@@ -2356,7 +2648,7 @@ export const REFERENCE = {
|
|
|
2356
2648
|
{
|
|
2357
2649
|
"bookingRoomId": 90002,
|
|
2358
2650
|
"roomTypeId": 412,
|
|
2359
|
-
"ratePlanId":
|
|
2651
|
+
"ratePlanId": 901,
|
|
2360
2652
|
"mealPlan": "CP",
|
|
2361
2653
|
"adults": 2,
|
|
2362
2654
|
"children": 0,
|
|
@@ -2370,7 +2662,7 @@ export const REFERENCE = {
|
|
|
2370
2662
|
"pushedBy": "inventory-drain"
|
|
2371
2663
|
},
|
|
2372
2664
|
"replay": false,
|
|
2373
|
-
"createdAt": "2026-
|
|
2665
|
+
"createdAt": "2026-12-10T09:14:03.201Z",
|
|
2374
2666
|
"cancelledAt": null
|
|
2375
2667
|
},
|
|
2376
2668
|
"refusals": [
|
|
@@ -2388,7 +2680,7 @@ export const REFERENCE = {
|
|
|
2388
2680
|
},
|
|
2389
2681
|
{
|
|
2390
2682
|
"status": 409,
|
|
2391
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2683
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2392
2684
|
},
|
|
2393
2685
|
{
|
|
2394
2686
|
"status": 429,
|
|
@@ -2416,7 +2708,54 @@ export const REFERENCE = {
|
|
|
2416
2708
|
"request": {
|
|
2417
2709
|
"reason": "Guest cancelled on the website"
|
|
2418
2710
|
},
|
|
2419
|
-
"answer":
|
|
2711
|
+
"answer": {
|
|
2712
|
+
"bookingId": 48213,
|
|
2713
|
+
"reference": "SB-7KQ2MX9D",
|
|
2714
|
+
"externalReference": "WEB-2026-000123",
|
|
2715
|
+
"status": "CANCELLED",
|
|
2716
|
+
"checkIn": "2026-12-20",
|
|
2717
|
+
"checkOut": "2026-12-23",
|
|
2718
|
+
"nights": 3,
|
|
2719
|
+
"currency": "INR",
|
|
2720
|
+
"totalAmount": "27000.00",
|
|
2721
|
+
"totalPaid": "9000.00",
|
|
2722
|
+
"balanceDue": "18000.00",
|
|
2723
|
+
"guest": {
|
|
2724
|
+
"name": "Asha Verma",
|
|
2725
|
+
"phone": "+919876543210",
|
|
2726
|
+
"email": "asha@example.com"
|
|
2727
|
+
},
|
|
2728
|
+
"rooms": [
|
|
2729
|
+
{
|
|
2730
|
+
"bookingRoomId": 90001,
|
|
2731
|
+
"roomTypeId": 412,
|
|
2732
|
+
"ratePlanId": 901,
|
|
2733
|
+
"mealPlan": "CP",
|
|
2734
|
+
"adults": 2,
|
|
2735
|
+
"children": 1,
|
|
2736
|
+
"nightlyRate": "4500.00",
|
|
2737
|
+
"status": "CANCELLED"
|
|
2738
|
+
},
|
|
2739
|
+
{
|
|
2740
|
+
"bookingRoomId": 90002,
|
|
2741
|
+
"roomTypeId": 412,
|
|
2742
|
+
"ratePlanId": 901,
|
|
2743
|
+
"mealPlan": "CP",
|
|
2744
|
+
"adults": 2,
|
|
2745
|
+
"children": 0,
|
|
2746
|
+
"nightlyRate": "4500.00",
|
|
2747
|
+
"status": "CANCELLED"
|
|
2748
|
+
}
|
|
2749
|
+
],
|
|
2750
|
+
"inventory": {
|
|
2751
|
+
"eventRecorded": true,
|
|
2752
|
+
"channelManager": true,
|
|
2753
|
+
"pushedBy": "inventory-drain"
|
|
2754
|
+
},
|
|
2755
|
+
"replay": false,
|
|
2756
|
+
"createdAt": "2026-12-10T09:14:03.201Z",
|
|
2757
|
+
"cancelledAt": "2026-12-11T08:02:19.000Z"
|
|
2758
|
+
},
|
|
2420
2759
|
"refusals": [
|
|
2421
2760
|
{
|
|
2422
2761
|
"status": 401,
|
|
@@ -2483,7 +2822,53 @@ export const REFERENCE = {
|
|
|
2483
2822
|
],
|
|
2484
2823
|
"idempotent": false,
|
|
2485
2824
|
"request": null,
|
|
2486
|
-
"answer":
|
|
2825
|
+
"answer": {
|
|
2826
|
+
"since": "2026-12-09T12:05:00.000Z",
|
|
2827
|
+
"retentionDays": 7,
|
|
2828
|
+
"items": [
|
|
2829
|
+
{
|
|
2830
|
+
"id": "5820417",
|
|
2831
|
+
"at": "2026-12-10T12:04:31.118Z",
|
|
2832
|
+
"method": "GET",
|
|
2833
|
+
"route": "/sync",
|
|
2834
|
+
"status": 200,
|
|
2835
|
+
"errorCode": null,
|
|
2836
|
+
"address": "203.0.113.24",
|
|
2837
|
+
"durationMs": 41,
|
|
2838
|
+
"requestId": "rq_mxhiep729f2c1a7e",
|
|
2839
|
+
"propertyId": 61,
|
|
2840
|
+
"keyId": 14
|
|
2841
|
+
},
|
|
2842
|
+
{
|
|
2843
|
+
"id": "5820398",
|
|
2844
|
+
"at": "2026-12-10T12:04:16.902Z",
|
|
2845
|
+
"method": "PUT",
|
|
2846
|
+
"route": "/rates",
|
|
2847
|
+
"status": 202,
|
|
2848
|
+
"errorCode": null,
|
|
2849
|
+
"address": "203.0.113.24",
|
|
2850
|
+
"durationMs": 187,
|
|
2851
|
+
"requestId": "rq_mxhiee864be07d31",
|
|
2852
|
+
"propertyId": 61,
|
|
2853
|
+
"keyId": 14
|
|
2854
|
+
},
|
|
2855
|
+
{
|
|
2856
|
+
"id": "5820371",
|
|
2857
|
+
"at": "2026-12-10T12:03:58.440Z",
|
|
2858
|
+
"method": "PUT",
|
|
2859
|
+
"route": "/rates",
|
|
2860
|
+
"status": 429,
|
|
2861
|
+
"errorCode": "RATE_LIMITED",
|
|
2862
|
+
"address": "203.0.113.24",
|
|
2863
|
+
"durationMs": 6,
|
|
2864
|
+
"requestId": "rq_mxhidzzcc81a5e06",
|
|
2865
|
+
"propertyId": 61,
|
|
2866
|
+
"keyId": 14
|
|
2867
|
+
}
|
|
2868
|
+
],
|
|
2869
|
+
"more": false,
|
|
2870
|
+
"nextCursor": null
|
|
2871
|
+
},
|
|
2487
2872
|
"refusals": [
|
|
2488
2873
|
{
|
|
2489
2874
|
"status": 400,
|
|
@@ -2503,7 +2888,7 @@ export const REFERENCE = {
|
|
|
2503
2888
|
},
|
|
2504
2889
|
{
|
|
2505
2890
|
"status": 409,
|
|
2506
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2891
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2507
2892
|
},
|
|
2508
2893
|
{
|
|
2509
2894
|
"status": 429,
|
|
@@ -2577,7 +2962,7 @@ export const REFERENCE = {
|
|
|
2577
2962
|
},
|
|
2578
2963
|
{
|
|
2579
2964
|
"status": 409,
|
|
2580
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
2965
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2581
2966
|
},
|
|
2582
2967
|
{
|
|
2583
2968
|
"status": 429,
|
|
@@ -2713,7 +3098,7 @@ export const REFERENCE = {
|
|
|
2713
3098
|
},
|
|
2714
3099
|
{
|
|
2715
3100
|
"status": 409,
|
|
2716
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3101
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2717
3102
|
},
|
|
2718
3103
|
{
|
|
2719
3104
|
"status": 429,
|
|
@@ -2767,7 +3152,7 @@ export const REFERENCE = {
|
|
|
2767
3152
|
"idempotent": false,
|
|
2768
3153
|
"request": null,
|
|
2769
3154
|
"answer": {
|
|
2770
|
-
"since": "2026-
|
|
3155
|
+
"since": "2026-12-03T12:30:00.000Z",
|
|
2771
3156
|
"items": [
|
|
2772
3157
|
{
|
|
2773
3158
|
"id": 100001,
|
|
@@ -2781,8 +3166,8 @@ export const REFERENCE = {
|
|
|
2781
3166
|
"sourceGroup": "INDIRECT"
|
|
2782
3167
|
},
|
|
2783
3168
|
"stay": {
|
|
2784
|
-
"checkIn": "2026-
|
|
2785
|
-
"checkOut": "2026-
|
|
3169
|
+
"checkIn": "2026-12-24",
|
|
3170
|
+
"checkOut": "2026-12-26",
|
|
2786
3171
|
"nights": 2,
|
|
2787
3172
|
"dayUse": false
|
|
2788
3173
|
},
|
|
@@ -2804,12 +3189,12 @@ export const REFERENCE = {
|
|
|
2804
3189
|
{
|
|
2805
3190
|
"roomTypeId": 412,
|
|
2806
3191
|
"ratePlanId": 901,
|
|
2807
|
-
"roomTypeName": "Deluxe
|
|
3192
|
+
"roomTypeName": "Deluxe Garden Room",
|
|
2808
3193
|
"mealPlan": "CP",
|
|
2809
3194
|
"adults": 2,
|
|
2810
3195
|
"children": 0,
|
|
2811
|
-
"checkIn": "2026-
|
|
2812
|
-
"checkOut": "2026-
|
|
3196
|
+
"checkIn": "2026-12-24",
|
|
3197
|
+
"checkOut": "2026-12-26",
|
|
2813
3198
|
"nights": 2,
|
|
2814
3199
|
"dayUse": false,
|
|
2815
3200
|
"ratePerNight": 2700,
|
|
@@ -2834,12 +3219,12 @@ export const REFERENCE = {
|
|
|
2834
3219
|
"netPayoutAmount": 4050
|
|
2835
3220
|
},
|
|
2836
3221
|
"cancellation": null,
|
|
2837
|
-
"createdAt": "2026-
|
|
2838
|
-
"updatedAt": "2026-
|
|
3222
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
3223
|
+
"updatedAt": "2026-12-10T12:00:00.000Z"
|
|
2839
3224
|
}
|
|
2840
3225
|
],
|
|
2841
3226
|
"more": false,
|
|
2842
|
-
"nextCursor": "
|
|
3227
|
+
"nextCursor": "WyIyMDI2LTEyLTEwVDEyOjAwOjAwLjAwMFoiLDEwMDAwMV0"
|
|
2843
3228
|
},
|
|
2844
3229
|
"refusals": [
|
|
2845
3230
|
{
|
|
@@ -2856,7 +3241,7 @@ export const REFERENCE = {
|
|
|
2856
3241
|
},
|
|
2857
3242
|
{
|
|
2858
3243
|
"status": 409,
|
|
2859
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3244
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2860
3245
|
},
|
|
2861
3246
|
{
|
|
2862
3247
|
"status": 429,
|
|
@@ -2894,8 +3279,8 @@ export const REFERENCE = {
|
|
|
2894
3279
|
"sourceGroup": "INDIRECT"
|
|
2895
3280
|
},
|
|
2896
3281
|
"stay": {
|
|
2897
|
-
"checkIn": "2026-
|
|
2898
|
-
"checkOut": "2026-
|
|
3282
|
+
"checkIn": "2026-12-24",
|
|
3283
|
+
"checkOut": "2026-12-26",
|
|
2899
3284
|
"nights": 2,
|
|
2900
3285
|
"dayUse": false
|
|
2901
3286
|
},
|
|
@@ -2917,12 +3302,12 @@ export const REFERENCE = {
|
|
|
2917
3302
|
{
|
|
2918
3303
|
"roomTypeId": 412,
|
|
2919
3304
|
"ratePlanId": 901,
|
|
2920
|
-
"roomTypeName": "Deluxe
|
|
3305
|
+
"roomTypeName": "Deluxe Garden Room",
|
|
2921
3306
|
"mealPlan": "CP",
|
|
2922
3307
|
"adults": 2,
|
|
2923
3308
|
"children": 0,
|
|
2924
|
-
"checkIn": "2026-
|
|
2925
|
-
"checkOut": "2026-
|
|
3309
|
+
"checkIn": "2026-12-24",
|
|
3310
|
+
"checkOut": "2026-12-26",
|
|
2926
3311
|
"nights": 2,
|
|
2927
3312
|
"dayUse": false,
|
|
2928
3313
|
"ratePerNight": 2700,
|
|
@@ -2947,8 +3332,8 @@ export const REFERENCE = {
|
|
|
2947
3332
|
"netPayoutAmount": 4050
|
|
2948
3333
|
},
|
|
2949
3334
|
"cancellation": null,
|
|
2950
|
-
"createdAt": "2026-
|
|
2951
|
-
"updatedAt": "2026-
|
|
3335
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
3336
|
+
"updatedAt": "2026-12-10T12:00:00.000Z"
|
|
2952
3337
|
},
|
|
2953
3338
|
"refusals": [
|
|
2954
3339
|
{
|
|
@@ -2965,7 +3350,7 @@ export const REFERENCE = {
|
|
|
2965
3350
|
},
|
|
2966
3351
|
{
|
|
2967
3352
|
"status": 409,
|
|
2968
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3353
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
2969
3354
|
},
|
|
2970
3355
|
{
|
|
2971
3356
|
"status": 429,
|
|
@@ -2989,7 +3374,42 @@ export const REFERENCE = {
|
|
|
2989
3374
|
],
|
|
2990
3375
|
"idempotent": false,
|
|
2991
3376
|
"request": null,
|
|
2992
|
-
"answer":
|
|
3377
|
+
"answer": {
|
|
3378
|
+
"items": [
|
|
3379
|
+
{
|
|
3380
|
+
"id": 7,
|
|
3381
|
+
"mode": "live",
|
|
3382
|
+
"url": "https://example.com/zimmerstack/webhooks",
|
|
3383
|
+
"description": "Bookings and channel alerts for our PMS",
|
|
3384
|
+
"apiVersion": "2026-09-01",
|
|
3385
|
+
"eventTypes": [
|
|
3386
|
+
"channel.booking.created",
|
|
3387
|
+
"channel.booking.modified",
|
|
3388
|
+
"channel.booking.cancelled",
|
|
3389
|
+
"channel.sync.alert",
|
|
3390
|
+
"channel.sync.recovered"
|
|
3391
|
+
],
|
|
3392
|
+
"includeGuestContact": false,
|
|
3393
|
+
"status": "ACTIVE",
|
|
3394
|
+
"statusReason": null,
|
|
3395
|
+
"secretVersion": 1,
|
|
3396
|
+
"previousSecretExpiresAt": null,
|
|
3397
|
+
"notifyEmail": null,
|
|
3398
|
+
"createdAt": "2026-12-10T09:30:00.000Z",
|
|
3399
|
+
"updatedAt": "2026-12-10T12:00:03.000Z",
|
|
3400
|
+
"lastStoppedAt": null,
|
|
3401
|
+
"health": {
|
|
3402
|
+
"state": "healthy",
|
|
3403
|
+
"consecutiveFailures": 0,
|
|
3404
|
+
"failingSince": null,
|
|
3405
|
+
"lastSuccessAt": "2026-12-10T12:00:03.000Z",
|
|
3406
|
+
"lastFailureAt": null,
|
|
3407
|
+
"lastErrorMessage": null
|
|
3408
|
+
}
|
|
3409
|
+
}
|
|
3410
|
+
],
|
|
3411
|
+
"limit": 3
|
|
3412
|
+
},
|
|
2993
3413
|
"refusals": [
|
|
2994
3414
|
{
|
|
2995
3415
|
"status": 401,
|
|
@@ -3005,7 +3425,7 @@ export const REFERENCE = {
|
|
|
3005
3425
|
},
|
|
3006
3426
|
{
|
|
3007
3427
|
"status": 409,
|
|
3008
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3428
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3009
3429
|
},
|
|
3010
3430
|
{
|
|
3011
3431
|
"status": 429,
|
|
@@ -3028,8 +3448,45 @@ export const REFERENCE = {
|
|
|
3028
3448
|
201
|
|
3029
3449
|
],
|
|
3030
3450
|
"idempotent": true,
|
|
3031
|
-
"request":
|
|
3032
|
-
|
|
3451
|
+
"request": {
|
|
3452
|
+
"url": "https://example.com/zimmerstack/webhooks",
|
|
3453
|
+
"description": "Bookings and channel alerts for our PMS",
|
|
3454
|
+
"dataAck": true
|
|
3455
|
+
},
|
|
3456
|
+
"answer": {
|
|
3457
|
+
"endpoint": {
|
|
3458
|
+
"id": 7,
|
|
3459
|
+
"mode": "live",
|
|
3460
|
+
"url": "https://example.com/zimmerstack/webhooks",
|
|
3461
|
+
"description": "Bookings and channel alerts for our PMS",
|
|
3462
|
+
"apiVersion": "2026-09-01",
|
|
3463
|
+
"eventTypes": [
|
|
3464
|
+
"channel.booking.created",
|
|
3465
|
+
"channel.booking.modified",
|
|
3466
|
+
"channel.booking.cancelled",
|
|
3467
|
+
"channel.sync.alert",
|
|
3468
|
+
"channel.sync.recovered"
|
|
3469
|
+
],
|
|
3470
|
+
"includeGuestContact": false,
|
|
3471
|
+
"status": "ACTIVE",
|
|
3472
|
+
"statusReason": null,
|
|
3473
|
+
"secretVersion": 1,
|
|
3474
|
+
"previousSecretExpiresAt": null,
|
|
3475
|
+
"notifyEmail": null,
|
|
3476
|
+
"createdAt": "2026-12-10T09:30:00.000Z",
|
|
3477
|
+
"updatedAt": "2026-12-10T09:30:00.000Z",
|
|
3478
|
+
"lastStoppedAt": null,
|
|
3479
|
+
"health": {
|
|
3480
|
+
"state": "healthy",
|
|
3481
|
+
"consecutiveFailures": 0,
|
|
3482
|
+
"failingSince": null,
|
|
3483
|
+
"lastSuccessAt": null,
|
|
3484
|
+
"lastFailureAt": null,
|
|
3485
|
+
"lastErrorMessage": null
|
|
3486
|
+
}
|
|
3487
|
+
},
|
|
3488
|
+
"secret": "whsec_…"
|
|
3489
|
+
},
|
|
3033
3490
|
"refusals": [
|
|
3034
3491
|
{
|
|
3035
3492
|
"status": 401,
|
|
@@ -3071,7 +3528,37 @@ export const REFERENCE = {
|
|
|
3071
3528
|
],
|
|
3072
3529
|
"idempotent": false,
|
|
3073
3530
|
"request": null,
|
|
3074
|
-
"answer":
|
|
3531
|
+
"answer": {
|
|
3532
|
+
"id": 7,
|
|
3533
|
+
"mode": "live",
|
|
3534
|
+
"url": "https://example.com/zimmerstack/webhooks",
|
|
3535
|
+
"description": "Bookings and channel alerts for our PMS",
|
|
3536
|
+
"apiVersion": "2026-09-01",
|
|
3537
|
+
"eventTypes": [
|
|
3538
|
+
"channel.booking.created",
|
|
3539
|
+
"channel.booking.modified",
|
|
3540
|
+
"channel.booking.cancelled",
|
|
3541
|
+
"channel.sync.alert",
|
|
3542
|
+
"channel.sync.recovered"
|
|
3543
|
+
],
|
|
3544
|
+
"includeGuestContact": false,
|
|
3545
|
+
"status": "ACTIVE",
|
|
3546
|
+
"statusReason": null,
|
|
3547
|
+
"secretVersion": 1,
|
|
3548
|
+
"previousSecretExpiresAt": null,
|
|
3549
|
+
"notifyEmail": null,
|
|
3550
|
+
"createdAt": "2026-12-10T09:30:00.000Z",
|
|
3551
|
+
"updatedAt": "2026-12-10T12:00:03.000Z",
|
|
3552
|
+
"lastStoppedAt": null,
|
|
3553
|
+
"health": {
|
|
3554
|
+
"state": "healthy",
|
|
3555
|
+
"consecutiveFailures": 0,
|
|
3556
|
+
"failingSince": null,
|
|
3557
|
+
"lastSuccessAt": "2026-12-10T12:00:03.000Z",
|
|
3558
|
+
"lastFailureAt": null,
|
|
3559
|
+
"lastErrorMessage": null
|
|
3560
|
+
}
|
|
3561
|
+
},
|
|
3075
3562
|
"refusals": [
|
|
3076
3563
|
{
|
|
3077
3564
|
"status": 401,
|
|
@@ -3087,7 +3574,7 @@ export const REFERENCE = {
|
|
|
3087
3574
|
},
|
|
3088
3575
|
{
|
|
3089
3576
|
"status": 409,
|
|
3090
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3577
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3091
3578
|
},
|
|
3092
3579
|
{
|
|
3093
3580
|
"status": 429,
|
|
@@ -3112,8 +3599,53 @@ export const REFERENCE = {
|
|
|
3112
3599
|
200
|
|
3113
3600
|
],
|
|
3114
3601
|
"idempotent": true,
|
|
3115
|
-
"request":
|
|
3116
|
-
|
|
3602
|
+
"request": {
|
|
3603
|
+
"eventTypes": [
|
|
3604
|
+
"channel.booking.created",
|
|
3605
|
+
"channel.booking.modified",
|
|
3606
|
+
"channel.booking.cancelled",
|
|
3607
|
+
"channel.sync.alert",
|
|
3608
|
+
"channel.sync.recovered",
|
|
3609
|
+
"direct.booking.created",
|
|
3610
|
+
"direct.booking.modified",
|
|
3611
|
+
"direct.booking.cancelled"
|
|
3612
|
+
],
|
|
3613
|
+
"includeGuestContact": true
|
|
3614
|
+
},
|
|
3615
|
+
"answer": {
|
|
3616
|
+
"id": 7,
|
|
3617
|
+
"mode": "live",
|
|
3618
|
+
"url": "https://example.com/zimmerstack/webhooks",
|
|
3619
|
+
"description": "Bookings and channel alerts for our PMS",
|
|
3620
|
+
"apiVersion": "2026-09-01",
|
|
3621
|
+
"eventTypes": [
|
|
3622
|
+
"channel.booking.created",
|
|
3623
|
+
"channel.booking.modified",
|
|
3624
|
+
"channel.booking.cancelled",
|
|
3625
|
+
"channel.sync.alert",
|
|
3626
|
+
"channel.sync.recovered",
|
|
3627
|
+
"direct.booking.created",
|
|
3628
|
+
"direct.booking.modified",
|
|
3629
|
+
"direct.booking.cancelled"
|
|
3630
|
+
],
|
|
3631
|
+
"includeGuestContact": true,
|
|
3632
|
+
"status": "ACTIVE",
|
|
3633
|
+
"statusReason": null,
|
|
3634
|
+
"secretVersion": 1,
|
|
3635
|
+
"previousSecretExpiresAt": null,
|
|
3636
|
+
"notifyEmail": null,
|
|
3637
|
+
"createdAt": "2026-12-10T09:30:00.000Z",
|
|
3638
|
+
"updatedAt": "2026-12-10T12:10:00.000Z",
|
|
3639
|
+
"lastStoppedAt": null,
|
|
3640
|
+
"health": {
|
|
3641
|
+
"state": "healthy",
|
|
3642
|
+
"consecutiveFailures": 0,
|
|
3643
|
+
"failingSince": null,
|
|
3644
|
+
"lastSuccessAt": "2026-12-10T12:00:03.000Z",
|
|
3645
|
+
"lastFailureAt": null,
|
|
3646
|
+
"lastErrorMessage": null
|
|
3647
|
+
}
|
|
3648
|
+
},
|
|
3117
3649
|
"refusals": [
|
|
3118
3650
|
{
|
|
3119
3651
|
"status": 401,
|
|
@@ -3129,7 +3661,7 @@ export const REFERENCE = {
|
|
|
3129
3661
|
},
|
|
3130
3662
|
{
|
|
3131
3663
|
"status": 409,
|
|
3132
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3664
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3133
3665
|
},
|
|
3134
3666
|
{
|
|
3135
3667
|
"status": 429,
|
|
@@ -3155,7 +3687,10 @@ export const REFERENCE = {
|
|
|
3155
3687
|
],
|
|
3156
3688
|
"idempotent": false,
|
|
3157
3689
|
"request": null,
|
|
3158
|
-
"answer":
|
|
3690
|
+
"answer": {
|
|
3691
|
+
"id": 7,
|
|
3692
|
+
"deleted": true
|
|
3693
|
+
},
|
|
3159
3694
|
"refusals": [
|
|
3160
3695
|
{
|
|
3161
3696
|
"status": 401,
|
|
@@ -3171,7 +3706,7 @@ export const REFERENCE = {
|
|
|
3171
3706
|
},
|
|
3172
3707
|
{
|
|
3173
3708
|
"status": 409,
|
|
3174
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3709
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3175
3710
|
},
|
|
3176
3711
|
{
|
|
3177
3712
|
"status": 429,
|
|
@@ -3197,7 +3732,37 @@ export const REFERENCE = {
|
|
|
3197
3732
|
],
|
|
3198
3733
|
"idempotent": true,
|
|
3199
3734
|
"request": null,
|
|
3200
|
-
"answer":
|
|
3735
|
+
"answer": {
|
|
3736
|
+
"id": 7,
|
|
3737
|
+
"mode": "live",
|
|
3738
|
+
"url": "https://example.com/zimmerstack/webhooks",
|
|
3739
|
+
"description": "Bookings and channel alerts for our PMS",
|
|
3740
|
+
"apiVersion": "2026-09-01",
|
|
3741
|
+
"eventTypes": [
|
|
3742
|
+
"channel.booking.created",
|
|
3743
|
+
"channel.booking.modified",
|
|
3744
|
+
"channel.booking.cancelled",
|
|
3745
|
+
"channel.sync.alert",
|
|
3746
|
+
"channel.sync.recovered"
|
|
3747
|
+
],
|
|
3748
|
+
"includeGuestContact": false,
|
|
3749
|
+
"status": "PAUSED",
|
|
3750
|
+
"statusReason": "Paused by the vendor",
|
|
3751
|
+
"secretVersion": 1,
|
|
3752
|
+
"previousSecretExpiresAt": null,
|
|
3753
|
+
"notifyEmail": null,
|
|
3754
|
+
"createdAt": "2026-12-10T09:30:00.000Z",
|
|
3755
|
+
"updatedAt": "2026-12-10T12:30:00.000Z",
|
|
3756
|
+
"lastStoppedAt": "2026-12-10T12:30:00.000Z",
|
|
3757
|
+
"health": {
|
|
3758
|
+
"state": "paused",
|
|
3759
|
+
"consecutiveFailures": 0,
|
|
3760
|
+
"failingSince": null,
|
|
3761
|
+
"lastSuccessAt": "2026-12-10T12:00:03.000Z",
|
|
3762
|
+
"lastFailureAt": null,
|
|
3763
|
+
"lastErrorMessage": null
|
|
3764
|
+
}
|
|
3765
|
+
},
|
|
3201
3766
|
"refusals": [
|
|
3202
3767
|
{
|
|
3203
3768
|
"status": 401,
|
|
@@ -3213,7 +3778,7 @@ export const REFERENCE = {
|
|
|
3213
3778
|
},
|
|
3214
3779
|
{
|
|
3215
3780
|
"status": 409,
|
|
3216
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3781
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3217
3782
|
},
|
|
3218
3783
|
{
|
|
3219
3784
|
"status": 429,
|
|
@@ -3239,7 +3804,38 @@ export const REFERENCE = {
|
|
|
3239
3804
|
],
|
|
3240
3805
|
"idempotent": true,
|
|
3241
3806
|
"request": null,
|
|
3242
|
-
"answer":
|
|
3807
|
+
"answer": {
|
|
3808
|
+
"id": 7,
|
|
3809
|
+
"mode": "live",
|
|
3810
|
+
"url": "https://example.com/zimmerstack/webhooks",
|
|
3811
|
+
"description": "Bookings and channel alerts for our PMS",
|
|
3812
|
+
"apiVersion": "2026-09-01",
|
|
3813
|
+
"eventTypes": [
|
|
3814
|
+
"channel.booking.created",
|
|
3815
|
+
"channel.booking.modified",
|
|
3816
|
+
"channel.booking.cancelled",
|
|
3817
|
+
"channel.sync.alert",
|
|
3818
|
+
"channel.sync.recovered"
|
|
3819
|
+
],
|
|
3820
|
+
"includeGuestContact": false,
|
|
3821
|
+
"status": "ACTIVE",
|
|
3822
|
+
"statusReason": null,
|
|
3823
|
+
"secretVersion": 1,
|
|
3824
|
+
"previousSecretExpiresAt": null,
|
|
3825
|
+
"notifyEmail": null,
|
|
3826
|
+
"createdAt": "2026-12-10T09:30:00.000Z",
|
|
3827
|
+
"updatedAt": "2026-12-10T12:40:00.000Z",
|
|
3828
|
+
"lastStoppedAt": "2026-12-10T12:30:00.000Z",
|
|
3829
|
+
"health": {
|
|
3830
|
+
"state": "healthy",
|
|
3831
|
+
"consecutiveFailures": 0,
|
|
3832
|
+
"failingSince": null,
|
|
3833
|
+
"lastSuccessAt": "2026-12-10T12:00:03.000Z",
|
|
3834
|
+
"lastFailureAt": null,
|
|
3835
|
+
"lastErrorMessage": null
|
|
3836
|
+
},
|
|
3837
|
+
"heldEvents": 3
|
|
3838
|
+
},
|
|
3243
3839
|
"refusals": [
|
|
3244
3840
|
{
|
|
3245
3841
|
"status": 401,
|
|
@@ -3255,7 +3851,7 @@ export const REFERENCE = {
|
|
|
3255
3851
|
},
|
|
3256
3852
|
{
|
|
3257
3853
|
"status": 409,
|
|
3258
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3854
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3259
3855
|
},
|
|
3260
3856
|
{
|
|
3261
3857
|
"status": 429,
|
|
@@ -3281,7 +3877,11 @@ export const REFERENCE = {
|
|
|
3281
3877
|
],
|
|
3282
3878
|
"idempotent": true,
|
|
3283
3879
|
"request": null,
|
|
3284
|
-
"answer":
|
|
3880
|
+
"answer": {
|
|
3881
|
+
"secret": "whsec_…",
|
|
3882
|
+
"secretVersion": 2,
|
|
3883
|
+
"previousExpiresAt": "2026-12-11T12:50:00.000Z"
|
|
3884
|
+
},
|
|
3285
3885
|
"refusals": [
|
|
3286
3886
|
{
|
|
3287
3887
|
"status": 401,
|
|
@@ -3297,7 +3897,7 @@ export const REFERENCE = {
|
|
|
3297
3897
|
},
|
|
3298
3898
|
{
|
|
3299
3899
|
"status": 409,
|
|
3300
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
3900
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3301
3901
|
},
|
|
3302
3902
|
{
|
|
3303
3903
|
"status": 429,
|
|
@@ -3322,8 +3922,14 @@ export const REFERENCE = {
|
|
|
3322
3922
|
202
|
|
3323
3923
|
],
|
|
3324
3924
|
"idempotent": true,
|
|
3325
|
-
"request":
|
|
3326
|
-
|
|
3925
|
+
"request": {
|
|
3926
|
+
"eventType": "channel.booking.created"
|
|
3927
|
+
},
|
|
3928
|
+
"answer": {
|
|
3929
|
+
"deliveryId": "48211",
|
|
3930
|
+
"eventId": "e3a1f0c8-6d2b-4c57-b9a4-0f1e2d3c4b5a",
|
|
3931
|
+
"eventType": "channel.booking.created"
|
|
3932
|
+
},
|
|
3327
3933
|
"refusals": [
|
|
3328
3934
|
{
|
|
3329
3935
|
"status": 401,
|
|
@@ -3364,8 +3970,15 @@ export const REFERENCE = {
|
|
|
3364
3970
|
202
|
|
3365
3971
|
],
|
|
3366
3972
|
"idempotent": true,
|
|
3367
|
-
"request":
|
|
3368
|
-
|
|
3973
|
+
"request": {
|
|
3974
|
+
"since": "2026-12-09T00:00:00.000Z"
|
|
3975
|
+
},
|
|
3976
|
+
"answer": {
|
|
3977
|
+
"reset": 2,
|
|
3978
|
+
"created": 5,
|
|
3979
|
+
"scanned": 41,
|
|
3980
|
+
"truncated": false
|
|
3981
|
+
},
|
|
3369
3982
|
"refusals": [
|
|
3370
3983
|
{
|
|
3371
3984
|
"status": 401,
|
|
@@ -3450,7 +4063,41 @@ export const REFERENCE = {
|
|
|
3450
4063
|
],
|
|
3451
4064
|
"idempotent": false,
|
|
3452
4065
|
"request": null,
|
|
3453
|
-
"answer":
|
|
4066
|
+
"answer": {
|
|
4067
|
+
"items": [
|
|
4068
|
+
{
|
|
4069
|
+
"id": "48211",
|
|
4070
|
+
"eventId": "e3a1f0c8-6d2b-4c57-b9a4-0f1e2d3c4b5a",
|
|
4071
|
+
"eventType": "channel.booking.created",
|
|
4072
|
+
"mode": "TEST",
|
|
4073
|
+
"status": "DELIVERED",
|
|
4074
|
+
"attempts": 1,
|
|
4075
|
+
"nextAttemptAt": "2026-12-10T13:00:00.000Z",
|
|
4076
|
+
"lastError": null,
|
|
4077
|
+
"occurredAt": "2026-12-10T13:00:00.000Z",
|
|
4078
|
+
"deliveredAt": "2026-12-10T13:00:01.000Z",
|
|
4079
|
+
"createdAt": "2026-12-10T13:00:00.000Z",
|
|
4080
|
+
"payloadBytes": 1422,
|
|
4081
|
+
"payloadAvailable": true
|
|
4082
|
+
},
|
|
4083
|
+
{
|
|
4084
|
+
"id": "48209",
|
|
4085
|
+
"eventId": "5c0e7a1d-2b64-4f3a-9d18-7e6a4b3c2f10",
|
|
4086
|
+
"eventType": "channel.booking.created",
|
|
4087
|
+
"mode": "LIVE",
|
|
4088
|
+
"status": "DELIVERED",
|
|
4089
|
+
"attempts": 1,
|
|
4090
|
+
"nextAttemptAt": "2026-12-10T12:00:02.000Z",
|
|
4091
|
+
"lastError": null,
|
|
4092
|
+
"occurredAt": "2026-12-10T12:00:00.000Z",
|
|
4093
|
+
"deliveredAt": "2026-12-10T12:00:03.000Z",
|
|
4094
|
+
"createdAt": "2026-12-10T12:00:02.000Z",
|
|
4095
|
+
"payloadBytes": 1439,
|
|
4096
|
+
"payloadAvailable": true
|
|
4097
|
+
}
|
|
4098
|
+
],
|
|
4099
|
+
"nextCursor": null
|
|
4100
|
+
},
|
|
3454
4101
|
"refusals": [
|
|
3455
4102
|
{
|
|
3456
4103
|
"status": 401,
|
|
@@ -3466,7 +4113,7 @@ export const REFERENCE = {
|
|
|
3466
4113
|
},
|
|
3467
4114
|
{
|
|
3468
4115
|
"status": 409,
|
|
3469
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
4116
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3470
4117
|
},
|
|
3471
4118
|
{
|
|
3472
4119
|
"status": 429,
|
|
@@ -3476,8 +4123,8 @@ export const REFERENCE = {
|
|
|
3476
4123
|
},
|
|
3477
4124
|
{
|
|
3478
4125
|
"key": "GET /webhook-endpoints/{endpointId}/deliveries/{deliveryId}",
|
|
3479
|
-
"summary": "One delivery: the body as sent, and every attempt",
|
|
3480
|
-
"description": "Scope webhooks:manage. Each attempt carries the status your receiver answered and the first 2 KB of its body.
|
|
4126
|
+
"summary": "One delivery: the body as sent, guest contact masked, and every attempt",
|
|
4127
|
+
"description": "Scope webhooks:manage. Each attempt carries the status your receiver answered and the first 2 KB of its body. payload is the event as it was sent, except that a guest's phone and email are always masked in this read, whatever the endpoint's guest-contact switch was when the delivery was made: reading a delivery leaves no line on the hotel's list of who read guest contact, so it never carries it. The bookings reads carry contact (x-zimmerstack.guestContact).",
|
|
3481
4128
|
"scope": "webhooks:manage",
|
|
3482
4129
|
"call": "zs.webhookEndpoints.deliveries.get(endpointId, deliveryId)",
|
|
3483
4130
|
"also": [],
|
|
@@ -3493,7 +4140,130 @@ export const REFERENCE = {
|
|
|
3493
4140
|
],
|
|
3494
4141
|
"idempotent": false,
|
|
3495
4142
|
"request": null,
|
|
3496
|
-
"answer":
|
|
4143
|
+
"answer": {
|
|
4144
|
+
"id": "48209",
|
|
4145
|
+
"eventId": "5c0e7a1d-2b64-4f3a-9d18-7e6a4b3c2f10",
|
|
4146
|
+
"eventType": "channel.booking.created",
|
|
4147
|
+
"mode": "LIVE",
|
|
4148
|
+
"status": "DELIVERED",
|
|
4149
|
+
"attempts": 1,
|
|
4150
|
+
"nextAttemptAt": "2026-12-10T12:00:02.000Z",
|
|
4151
|
+
"lastError": null,
|
|
4152
|
+
"occurredAt": "2026-12-10T12:00:00.000Z",
|
|
4153
|
+
"deliveredAt": "2026-12-10T12:00:03.000Z",
|
|
4154
|
+
"createdAt": "2026-12-10T12:00:02.000Z",
|
|
4155
|
+
"payloadBytes": 1439,
|
|
4156
|
+
"payloadAvailable": true,
|
|
4157
|
+
"payload": {
|
|
4158
|
+
"id": "evt_5c0e7a1d-2b64-4f3a-9d18-7e6a4b3c2f10",
|
|
4159
|
+
"type": "channel.booking.created",
|
|
4160
|
+
"apiVersion": "2026-09-01",
|
|
4161
|
+
"occurredAt": "2026-12-10T12:00:00.000Z",
|
|
4162
|
+
"mode": "live",
|
|
4163
|
+
"sequence": 42,
|
|
4164
|
+
"property": {
|
|
4165
|
+
"id": 61,
|
|
4166
|
+
"name": "The Lantern House",
|
|
4167
|
+
"currency": "INR",
|
|
4168
|
+
"timezone": "Asia/Kolkata"
|
|
4169
|
+
},
|
|
4170
|
+
"data": {
|
|
4171
|
+
"booking": {
|
|
4172
|
+
"id": 100001,
|
|
4173
|
+
"reference": "TEST-ZS-8K3Q2M",
|
|
4174
|
+
"status": "CONFIRMED",
|
|
4175
|
+
"stayStatus": "UPCOMING",
|
|
4176
|
+
"channel": {
|
|
4177
|
+
"otaName": "MakeMyTrip",
|
|
4178
|
+
"otaReservationCode": "TEST-ZS-8K3Q2M",
|
|
4179
|
+
"source": "CHANNEL_MANAGER",
|
|
4180
|
+
"sourceGroup": "INDIRECT"
|
|
4181
|
+
},
|
|
4182
|
+
"stay": {
|
|
4183
|
+
"checkIn": "2026-12-24",
|
|
4184
|
+
"checkOut": "2026-12-26",
|
|
4185
|
+
"nights": 2,
|
|
4186
|
+
"dayUse": false
|
|
4187
|
+
},
|
|
4188
|
+
"guest": {
|
|
4189
|
+
"fullName": "Asha Verma",
|
|
4190
|
+
"firstName": "Asha",
|
|
4191
|
+
"lastName": "Verma",
|
|
4192
|
+
"country": "IN",
|
|
4193
|
+
"language": "en"
|
|
4194
|
+
},
|
|
4195
|
+
"guestNotes": "Late arrival around 22:00. Non-smoking room please. (test event)",
|
|
4196
|
+
"occupancy": {
|
|
4197
|
+
"adults": 2,
|
|
4198
|
+
"children": 0
|
|
4199
|
+
},
|
|
4200
|
+
"rooms": [
|
|
4201
|
+
{
|
|
4202
|
+
"roomTypeId": 412,
|
|
4203
|
+
"ratePlanId": 901,
|
|
4204
|
+
"roomTypeName": "Deluxe Garden Room",
|
|
4205
|
+
"mealPlan": "CP",
|
|
4206
|
+
"adults": 2,
|
|
4207
|
+
"children": 0,
|
|
4208
|
+
"checkIn": "2026-12-24",
|
|
4209
|
+
"checkOut": "2026-12-26",
|
|
4210
|
+
"nights": 2,
|
|
4211
|
+
"dayUse": false,
|
|
4212
|
+
"ratePerNight": 2700,
|
|
4213
|
+
"amount": 5400,
|
|
4214
|
+
"status": "UPCOMING"
|
|
4215
|
+
}
|
|
4216
|
+
],
|
|
4217
|
+
"amounts": {
|
|
4218
|
+
"currency": "INR",
|
|
4219
|
+
"total": 5400,
|
|
4220
|
+
"paid": 0,
|
|
4221
|
+
"balanceDue": 5400,
|
|
4222
|
+
"paymentCollect": "property"
|
|
4223
|
+
},
|
|
4224
|
+
"finance": {
|
|
4225
|
+
"otaName": "MakeMyTrip",
|
|
4226
|
+
"amountBasis": "GROSS_TOTAL",
|
|
4227
|
+
"currency": "INR",
|
|
4228
|
+
"grossAmount": 5400,
|
|
4229
|
+
"commissionAmount": 1350,
|
|
4230
|
+
"taxAmount": 648,
|
|
4231
|
+
"netPayoutAmount": 4050
|
|
4232
|
+
},
|
|
4233
|
+
"cancellation": null,
|
|
4234
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
4235
|
+
"updatedAt": "2026-12-10T12:00:00.000Z"
|
|
4236
|
+
}
|
|
4237
|
+
},
|
|
4238
|
+
"changes": null,
|
|
4239
|
+
"previous": null
|
|
4240
|
+
},
|
|
4241
|
+
"attempts_log": [
|
|
4242
|
+
{
|
|
4243
|
+
"id": "91377",
|
|
4244
|
+
"attemptNo": 1,
|
|
4245
|
+
"startedAt": "2026-12-10T12:00:02.412Z",
|
|
4246
|
+
"durationMs": 318,
|
|
4247
|
+
"outcome": "SUCCESS",
|
|
4248
|
+
"responseStatus": 200,
|
|
4249
|
+
"responseBodySnippet": "ok",
|
|
4250
|
+
"errorMessage": null,
|
|
4251
|
+
"resolvedIp": "203.0.113.80"
|
|
4252
|
+
}
|
|
4253
|
+
],
|
|
4254
|
+
"request": {
|
|
4255
|
+
"headers": {
|
|
4256
|
+
"content-type": "application/json; charset=utf-8",
|
|
4257
|
+
"webhook-id": "evt_5c0e7a1d-2b64-4f3a-9d18-7e6a4b3c2f10",
|
|
4258
|
+
"webhook-timestamp": "<unix seconds at send time>",
|
|
4259
|
+
"webhook-signature": "v1,<base64 HMAC-SHA256>",
|
|
4260
|
+
"x-zimmerstack-event": "channel.booking.created",
|
|
4261
|
+
"x-zimmerstack-delivery": "dlv_48209",
|
|
4262
|
+
"x-zimmerstack-api-version": "2026-09-01",
|
|
4263
|
+
"idempotency-key": "evt_5c0e7a1d-2b64-4f3a-9d18-7e6a4b3c2f10"
|
|
4264
|
+
}
|
|
4265
|
+
}
|
|
4266
|
+
},
|
|
3497
4267
|
"refusals": [
|
|
3498
4268
|
{
|
|
3499
4269
|
"status": 401,
|
|
@@ -3509,7 +4279,7 @@ export const REFERENCE = {
|
|
|
3509
4279
|
},
|
|
3510
4280
|
{
|
|
3511
4281
|
"status": 409,
|
|
3512
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
4282
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3513
4283
|
},
|
|
3514
4284
|
{
|
|
3515
4285
|
"status": 429,
|
|
@@ -3536,7 +4306,21 @@ export const REFERENCE = {
|
|
|
3536
4306
|
],
|
|
3537
4307
|
"idempotent": true,
|
|
3538
4308
|
"request": null,
|
|
3539
|
-
"answer":
|
|
4309
|
+
"answer": {
|
|
4310
|
+
"id": "48209",
|
|
4311
|
+
"eventId": "5c0e7a1d-2b64-4f3a-9d18-7e6a4b3c2f10",
|
|
4312
|
+
"eventType": "channel.booking.created",
|
|
4313
|
+
"mode": "LIVE",
|
|
4314
|
+
"status": "PENDING",
|
|
4315
|
+
"attempts": 0,
|
|
4316
|
+
"nextAttemptAt": "2026-12-10T12:45:00.000Z",
|
|
4317
|
+
"lastError": null,
|
|
4318
|
+
"occurredAt": "2026-12-10T12:00:00.000Z",
|
|
4319
|
+
"deliveredAt": "2026-12-10T12:00:03.000Z",
|
|
4320
|
+
"createdAt": "2026-12-10T12:00:02.000Z",
|
|
4321
|
+
"payloadBytes": 1439,
|
|
4322
|
+
"payloadAvailable": true
|
|
4323
|
+
},
|
|
3540
4324
|
"refusals": [
|
|
3541
4325
|
{
|
|
3542
4326
|
"status": 401,
|
|
@@ -3737,7 +4521,7 @@ export const REFERENCE = {
|
|
|
3737
4521
|
},
|
|
3738
4522
|
{
|
|
3739
4523
|
"status": 409,
|
|
3740
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
4524
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3741
4525
|
},
|
|
3742
4526
|
{
|
|
3743
4527
|
"status": 429,
|
|
@@ -3860,7 +4644,7 @@ export const REFERENCE = {
|
|
|
3860
4644
|
},
|
|
3861
4645
|
{
|
|
3862
4646
|
"status": 409,
|
|
3863
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
4647
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3864
4648
|
},
|
|
3865
4649
|
{
|
|
3866
4650
|
"status": 429,
|
|
@@ -3947,7 +4731,7 @@ export const REFERENCE = {
|
|
|
3947
4731
|
},
|
|
3948
4732
|
{
|
|
3949
4733
|
"status": 409,
|
|
3950
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
4734
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
3951
4735
|
},
|
|
3952
4736
|
{
|
|
3953
4737
|
"status": 429,
|
|
@@ -4081,7 +4865,7 @@ export const REFERENCE = {
|
|
|
4081
4865
|
},
|
|
4082
4866
|
{
|
|
4083
4867
|
"status": 409,
|
|
4084
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
4868
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4085
4869
|
},
|
|
4086
4870
|
{
|
|
4087
4871
|
"status": 429,
|
|
@@ -4126,7 +4910,34 @@ export const REFERENCE = {
|
|
|
4126
4910
|
],
|
|
4127
4911
|
"idempotent": false,
|
|
4128
4912
|
"request": null,
|
|
4129
|
-
"answer":
|
|
4913
|
+
"answer": {
|
|
4914
|
+
"items": [
|
|
4915
|
+
{
|
|
4916
|
+
"id": 1042,
|
|
4917
|
+
"subject": "Bookings from Booking.com stopped arriving on two hotels",
|
|
4918
|
+
"severity": "many_hotels",
|
|
4919
|
+
"status": "OPEN",
|
|
4920
|
+
"mode": "live",
|
|
4921
|
+
"properties": {
|
|
4922
|
+
"all": false,
|
|
4923
|
+
"ids": [
|
|
4924
|
+
61,
|
|
4925
|
+
62
|
|
4926
|
+
]
|
|
4927
|
+
},
|
|
4928
|
+
"openedAt": "2026-11-22T04:05:12.000Z",
|
|
4929
|
+
"lastMessageAt": "2026-11-22T08:52:31.000Z",
|
|
4930
|
+
"firstReply": {
|
|
4931
|
+
"target": "Within 60 minutes, 9:00 to 21:00 IST, every day. Opened outside those hours: by 10:00 IST.",
|
|
4932
|
+
"dueAt": "2026-11-22T05:05:12.000Z",
|
|
4933
|
+
"repliedAt": "2026-11-22T04:31:40.000Z"
|
|
4934
|
+
},
|
|
4935
|
+
"closedAt": null,
|
|
4936
|
+
"closedBy": null
|
|
4937
|
+
}
|
|
4938
|
+
],
|
|
4939
|
+
"nextCursor": null
|
|
4940
|
+
},
|
|
4130
4941
|
"refusals": [
|
|
4131
4942
|
{
|
|
4132
4943
|
"status": 401,
|
|
@@ -4142,7 +4953,7 @@ export const REFERENCE = {
|
|
|
4142
4953
|
},
|
|
4143
4954
|
{
|
|
4144
4955
|
"status": 409,
|
|
4145
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
4956
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4146
4957
|
},
|
|
4147
4958
|
{
|
|
4148
4959
|
"status": 429,
|
|
@@ -4312,7 +5123,7 @@ export const REFERENCE = {
|
|
|
4312
5123
|
},
|
|
4313
5124
|
{
|
|
4314
5125
|
"status": 409,
|
|
4315
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
5126
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4316
5127
|
},
|
|
4317
5128
|
{
|
|
4318
5129
|
"status": 429,
|
|
@@ -4472,7 +5283,7 @@ export const REFERENCE = {
|
|
|
4472
5283
|
},
|
|
4473
5284
|
{
|
|
4474
5285
|
"status": 409,
|
|
4475
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
5286
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4476
5287
|
},
|
|
4477
5288
|
{
|
|
4478
5289
|
"status": 429,
|
|
@@ -4500,35 +5311,165 @@ export const REFERENCE = {
|
|
|
4500
5311
|
"request": {
|
|
4501
5312
|
"message": "It started again at 14:20 IST on hotel 61 only."
|
|
4502
5313
|
},
|
|
4503
|
-
"answer":
|
|
4504
|
-
|
|
4505
|
-
|
|
4506
|
-
|
|
4507
|
-
|
|
4508
|
-
|
|
4509
|
-
{
|
|
4510
|
-
"
|
|
4511
|
-
"
|
|
4512
|
-
|
|
4513
|
-
|
|
4514
|
-
|
|
4515
|
-
"description": "No such ticket of yours in this key's mode"
|
|
5314
|
+
"answer": {
|
|
5315
|
+
"id": 1042,
|
|
5316
|
+
"subject": "Bookings from Booking.com stopped arriving on two hotels",
|
|
5317
|
+
"severity": "many_hotels",
|
|
5318
|
+
"status": "OPEN",
|
|
5319
|
+
"mode": "live",
|
|
5320
|
+
"properties": {
|
|
5321
|
+
"all": false,
|
|
5322
|
+
"ids": [
|
|
5323
|
+
61,
|
|
5324
|
+
62
|
|
5325
|
+
]
|
|
4516
5326
|
},
|
|
4517
|
-
|
|
4518
|
-
|
|
4519
|
-
|
|
5327
|
+
"openedAt": "2026-11-22T04:05:12.000Z",
|
|
5328
|
+
"lastMessageAt": "2026-11-22T08:52:31.000Z",
|
|
5329
|
+
"firstReply": {
|
|
5330
|
+
"target": "Within 60 minutes, 9:00 to 21:00 IST, every day. Opened outside those hours: by 10:00 IST.",
|
|
5331
|
+
"dueAt": "2026-11-22T05:05:12.000Z",
|
|
5332
|
+
"repliedAt": "2026-11-22T04:31:40.000Z"
|
|
4520
5333
|
},
|
|
4521
|
-
|
|
4522
|
-
|
|
4523
|
-
|
|
4524
|
-
|
|
4525
|
-
|
|
4526
|
-
|
|
4527
|
-
|
|
4528
|
-
|
|
4529
|
-
|
|
4530
|
-
|
|
4531
|
-
|
|
5334
|
+
"closedAt": null,
|
|
5335
|
+
"closedBy": null,
|
|
5336
|
+
"messages": [
|
|
5337
|
+
{
|
|
5338
|
+
"id": 3310,
|
|
5339
|
+
"author": "partner",
|
|
5340
|
+
"body": "Since about 09:10 IST no new Booking.com booking has reached our webhook for either hotel. Their extranets show three bookings made since then. Other booking sites are arriving.",
|
|
5341
|
+
"createdAt": "2026-11-22T04:05:12.000Z"
|
|
5342
|
+
},
|
|
5343
|
+
{
|
|
5344
|
+
"id": 3311,
|
|
5345
|
+
"author": "zimmerstack",
|
|
5346
|
+
"body": "Booking.com signed both hotels out at 09:11 IST. Both are connected again since 09:58 IST, and the three bookings made in between have reached your webhook. Write here if anything is still missing.",
|
|
5347
|
+
"createdAt": "2026-11-22T04:31:40.000Z"
|
|
5348
|
+
},
|
|
5349
|
+
{
|
|
5350
|
+
"id": 3312,
|
|
5351
|
+
"author": "partner",
|
|
5352
|
+
"body": "It started again at 14:20 IST on hotel 61 only.",
|
|
5353
|
+
"createdAt": "2026-11-22T08:52:31.000Z"
|
|
5354
|
+
}
|
|
5355
|
+
],
|
|
5356
|
+
"diagnostic": {
|
|
5357
|
+
"takenAt": "2026-11-22T04:05:12.000Z",
|
|
5358
|
+
"windowHours": 24,
|
|
5359
|
+
"requests": {
|
|
5360
|
+
"refused": 3,
|
|
5361
|
+
"byCode": [
|
|
5362
|
+
{
|
|
5363
|
+
"status": 429,
|
|
5364
|
+
"errorCode": "RATE_LIMITED",
|
|
5365
|
+
"count": 3,
|
|
5366
|
+
"lastAt": "2026-11-22T03:58:40.000Z"
|
|
5367
|
+
}
|
|
5368
|
+
],
|
|
5369
|
+
"lastRefused": [
|
|
5370
|
+
{
|
|
5371
|
+
"requestId": "rq_mi8x3k2a9f2c1a7e",
|
|
5372
|
+
"at": "2026-11-22T03:58:40.000Z",
|
|
5373
|
+
"method": "PUT",
|
|
5374
|
+
"route": "/rates",
|
|
5375
|
+
"status": 429,
|
|
5376
|
+
"errorCode": "RATE_LIMITED",
|
|
5377
|
+
"propertyId": 61
|
|
5378
|
+
}
|
|
5379
|
+
]
|
|
5380
|
+
},
|
|
5381
|
+
"hotels": [
|
|
5382
|
+
{
|
|
5383
|
+
"propertyId": 61,
|
|
5384
|
+
"inventory": {
|
|
5385
|
+
"pendingCells": 0,
|
|
5386
|
+
"outOfSyncSince": null,
|
|
5387
|
+
"lastOkAt": "2026-11-22T04:03:55.000Z"
|
|
5388
|
+
},
|
|
5389
|
+
"rates": {
|
|
5390
|
+
"waitingCells": 0,
|
|
5391
|
+
"refusedCells": 0,
|
|
5392
|
+
"lastPushAt": "2026-11-22T03:59:02.000Z",
|
|
5393
|
+
"lastErrorAt": null,
|
|
5394
|
+
"consecutiveFailures": 0
|
|
5395
|
+
},
|
|
5396
|
+
"channelIssues": [
|
|
5397
|
+
{
|
|
5398
|
+
"event": "disconnect_channel",
|
|
5399
|
+
"count": 1,
|
|
5400
|
+
"since": "2026-11-22T03:41:18.000Z"
|
|
5401
|
+
}
|
|
5402
|
+
],
|
|
5403
|
+
"shield": {
|
|
5404
|
+
"level": "CLEAR",
|
|
5405
|
+
"until": null
|
|
5406
|
+
},
|
|
5407
|
+
"usage": {
|
|
5408
|
+
"cellsChanged": 1138,
|
|
5409
|
+
"refusals": 0,
|
|
5410
|
+
"refusedByChannelManager": 0
|
|
5411
|
+
}
|
|
5412
|
+
}
|
|
5413
|
+
],
|
|
5414
|
+
"hotelsNotShown": 0,
|
|
5415
|
+
"partner": {
|
|
5416
|
+
"shield": {
|
|
5417
|
+
"level": "CLEAR",
|
|
5418
|
+
"until": null
|
|
5419
|
+
},
|
|
5420
|
+
"usage": {
|
|
5421
|
+
"cellsChanged": 20914,
|
|
5422
|
+
"refusals": 0,
|
|
5423
|
+
"refusedByChannelManager": 0
|
|
5424
|
+
}
|
|
5425
|
+
},
|
|
5426
|
+
"webhooks": [
|
|
5427
|
+
{
|
|
5428
|
+
"endpointId": 7,
|
|
5429
|
+
"status": "ACTIVE",
|
|
5430
|
+
"consecutiveFailures": 0,
|
|
5431
|
+
"failingSince": null,
|
|
5432
|
+
"lastSuccessAt": "2026-11-22T03:39:50.000Z",
|
|
5433
|
+
"lastFailureAt": null,
|
|
5434
|
+
"deliveries": {
|
|
5435
|
+
"delivered": 212,
|
|
5436
|
+
"failed": 0,
|
|
5437
|
+
"pending": 0
|
|
5438
|
+
},
|
|
5439
|
+
"lastFailed": []
|
|
5440
|
+
}
|
|
5441
|
+
],
|
|
5442
|
+
"incomplete": []
|
|
5443
|
+
}
|
|
5444
|
+
},
|
|
5445
|
+
"refusals": [
|
|
5446
|
+
{
|
|
5447
|
+
"status": 401,
|
|
5448
|
+
"description": "Missing, malformed, unknown or revoked key (data.code API_KEY_INVALID | API_KEY_REVOKED)"
|
|
5449
|
+
},
|
|
5450
|
+
{
|
|
5451
|
+
"status": 403,
|
|
5452
|
+
"description": "The key lacks the scope this route needs (SCOPE_MISSING, details.needed / details.held), or the request came from outside the key's address allowlist (IP_NOT_ALLOWED)"
|
|
5453
|
+
},
|
|
5454
|
+
{
|
|
5455
|
+
"status": 404,
|
|
5456
|
+
"description": "No such ticket of yours in this key's mode"
|
|
5457
|
+
},
|
|
5458
|
+
{
|
|
5459
|
+
"status": 409,
|
|
5460
|
+
"description": "The ticket is closed: open a new one and name this one in it"
|
|
5461
|
+
},
|
|
5462
|
+
{
|
|
5463
|
+
"status": 429,
|
|
5464
|
+
"description": "A per-minute budget, or partner-support-messages-hour: the most messages your company may add in a rolling hour. Honour Retry-After"
|
|
5465
|
+
}
|
|
5466
|
+
]
|
|
5467
|
+
},
|
|
5468
|
+
{
|
|
5469
|
+
"key": "POST /support-tickets/{ticketId}/close",
|
|
5470
|
+
"summary": "Close your own ticket",
|
|
5471
|
+
"description": "Scope support:write. The problem is gone on your side. Closing a closed ticket answers it as it is.",
|
|
5472
|
+
"scope": "support:write",
|
|
4532
5473
|
"call": "zs.supportTickets.close(ticketId)",
|
|
4533
5474
|
"also": [],
|
|
4534
5475
|
"path": [
|
|
@@ -4542,7 +5483,137 @@ export const REFERENCE = {
|
|
|
4542
5483
|
],
|
|
4543
5484
|
"idempotent": true,
|
|
4544
5485
|
"request": null,
|
|
4545
|
-
"answer":
|
|
5486
|
+
"answer": {
|
|
5487
|
+
"id": 1042,
|
|
5488
|
+
"subject": "Bookings from Booking.com stopped arriving on two hotels",
|
|
5489
|
+
"severity": "many_hotels",
|
|
5490
|
+
"status": "CLOSED",
|
|
5491
|
+
"mode": "live",
|
|
5492
|
+
"properties": {
|
|
5493
|
+
"all": false,
|
|
5494
|
+
"ids": [
|
|
5495
|
+
61,
|
|
5496
|
+
62
|
|
5497
|
+
]
|
|
5498
|
+
},
|
|
5499
|
+
"openedAt": "2026-11-22T04:05:12.000Z",
|
|
5500
|
+
"lastMessageAt": "2026-11-22T08:52:31.000Z",
|
|
5501
|
+
"firstReply": {
|
|
5502
|
+
"target": "Within 60 minutes, 9:00 to 21:00 IST, every day. Opened outside those hours: by 10:00 IST.",
|
|
5503
|
+
"dueAt": "2026-11-22T05:05:12.000Z",
|
|
5504
|
+
"repliedAt": "2026-11-22T04:31:40.000Z"
|
|
5505
|
+
},
|
|
5506
|
+
"closedAt": "2026-11-22T10:15:00.000Z",
|
|
5507
|
+
"closedBy": "partner",
|
|
5508
|
+
"messages": [
|
|
5509
|
+
{
|
|
5510
|
+
"id": 3310,
|
|
5511
|
+
"author": "partner",
|
|
5512
|
+
"body": "Since about 09:10 IST no new Booking.com booking has reached our webhook for either hotel. Their extranets show three bookings made since then. Other booking sites are arriving.",
|
|
5513
|
+
"createdAt": "2026-11-22T04:05:12.000Z"
|
|
5514
|
+
},
|
|
5515
|
+
{
|
|
5516
|
+
"id": 3311,
|
|
5517
|
+
"author": "zimmerstack",
|
|
5518
|
+
"body": "Booking.com signed both hotels out at 09:11 IST. Both are connected again since 09:58 IST, and the three bookings made in between have reached your webhook. Write here if anything is still missing.",
|
|
5519
|
+
"createdAt": "2026-11-22T04:31:40.000Z"
|
|
5520
|
+
},
|
|
5521
|
+
{
|
|
5522
|
+
"id": 3312,
|
|
5523
|
+
"author": "partner",
|
|
5524
|
+
"body": "It started again at 14:20 IST on hotel 61 only.",
|
|
5525
|
+
"createdAt": "2026-11-22T08:52:31.000Z"
|
|
5526
|
+
}
|
|
5527
|
+
],
|
|
5528
|
+
"diagnostic": {
|
|
5529
|
+
"takenAt": "2026-11-22T04:05:12.000Z",
|
|
5530
|
+
"windowHours": 24,
|
|
5531
|
+
"requests": {
|
|
5532
|
+
"refused": 3,
|
|
5533
|
+
"byCode": [
|
|
5534
|
+
{
|
|
5535
|
+
"status": 429,
|
|
5536
|
+
"errorCode": "RATE_LIMITED",
|
|
5537
|
+
"count": 3,
|
|
5538
|
+
"lastAt": "2026-11-22T03:58:40.000Z"
|
|
5539
|
+
}
|
|
5540
|
+
],
|
|
5541
|
+
"lastRefused": [
|
|
5542
|
+
{
|
|
5543
|
+
"requestId": "rq_mi8x3k2a9f2c1a7e",
|
|
5544
|
+
"at": "2026-11-22T03:58:40.000Z",
|
|
5545
|
+
"method": "PUT",
|
|
5546
|
+
"route": "/rates",
|
|
5547
|
+
"status": 429,
|
|
5548
|
+
"errorCode": "RATE_LIMITED",
|
|
5549
|
+
"propertyId": 61
|
|
5550
|
+
}
|
|
5551
|
+
]
|
|
5552
|
+
},
|
|
5553
|
+
"hotels": [
|
|
5554
|
+
{
|
|
5555
|
+
"propertyId": 61,
|
|
5556
|
+
"inventory": {
|
|
5557
|
+
"pendingCells": 0,
|
|
5558
|
+
"outOfSyncSince": null,
|
|
5559
|
+
"lastOkAt": "2026-11-22T04:03:55.000Z"
|
|
5560
|
+
},
|
|
5561
|
+
"rates": {
|
|
5562
|
+
"waitingCells": 0,
|
|
5563
|
+
"refusedCells": 0,
|
|
5564
|
+
"lastPushAt": "2026-11-22T03:59:02.000Z",
|
|
5565
|
+
"lastErrorAt": null,
|
|
5566
|
+
"consecutiveFailures": 0
|
|
5567
|
+
},
|
|
5568
|
+
"channelIssues": [
|
|
5569
|
+
{
|
|
5570
|
+
"event": "disconnect_channel",
|
|
5571
|
+
"count": 1,
|
|
5572
|
+
"since": "2026-11-22T03:41:18.000Z"
|
|
5573
|
+
}
|
|
5574
|
+
],
|
|
5575
|
+
"shield": {
|
|
5576
|
+
"level": "CLEAR",
|
|
5577
|
+
"until": null
|
|
5578
|
+
},
|
|
5579
|
+
"usage": {
|
|
5580
|
+
"cellsChanged": 1138,
|
|
5581
|
+
"refusals": 0,
|
|
5582
|
+
"refusedByChannelManager": 0
|
|
5583
|
+
}
|
|
5584
|
+
}
|
|
5585
|
+
],
|
|
5586
|
+
"hotelsNotShown": 0,
|
|
5587
|
+
"partner": {
|
|
5588
|
+
"shield": {
|
|
5589
|
+
"level": "CLEAR",
|
|
5590
|
+
"until": null
|
|
5591
|
+
},
|
|
5592
|
+
"usage": {
|
|
5593
|
+
"cellsChanged": 20914,
|
|
5594
|
+
"refusals": 0,
|
|
5595
|
+
"refusedByChannelManager": 0
|
|
5596
|
+
}
|
|
5597
|
+
},
|
|
5598
|
+
"webhooks": [
|
|
5599
|
+
{
|
|
5600
|
+
"endpointId": 7,
|
|
5601
|
+
"status": "ACTIVE",
|
|
5602
|
+
"consecutiveFailures": 0,
|
|
5603
|
+
"failingSince": null,
|
|
5604
|
+
"lastSuccessAt": "2026-11-22T03:39:50.000Z",
|
|
5605
|
+
"lastFailureAt": null,
|
|
5606
|
+
"deliveries": {
|
|
5607
|
+
"delivered": 212,
|
|
5608
|
+
"failed": 0,
|
|
5609
|
+
"pending": 0
|
|
5610
|
+
},
|
|
5611
|
+
"lastFailed": []
|
|
5612
|
+
}
|
|
5613
|
+
],
|
|
5614
|
+
"incomplete": []
|
|
5615
|
+
}
|
|
5616
|
+
},
|
|
4546
5617
|
"refusals": [
|
|
4547
5618
|
{
|
|
4548
5619
|
"status": 401,
|
|
@@ -4558,7 +5629,7 @@ export const REFERENCE = {
|
|
|
4558
5629
|
},
|
|
4559
5630
|
{
|
|
4560
5631
|
"status": 409,
|
|
4561
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
5632
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4562
5633
|
},
|
|
4563
5634
|
{
|
|
4564
5635
|
"status": 429,
|
|
@@ -4583,8 +5654,33 @@ export const REFERENCE = {
|
|
|
4583
5654
|
200
|
|
4584
5655
|
],
|
|
4585
5656
|
"idempotent": true,
|
|
4586
|
-
"request":
|
|
4587
|
-
|
|
5657
|
+
"request": {
|
|
5658
|
+
"undo": false
|
|
5659
|
+
},
|
|
5660
|
+
"answer": {
|
|
5661
|
+
"bookingId": 90312,
|
|
5662
|
+
"reference": "SBX-9001-MXHIYLXC7B3E",
|
|
5663
|
+
"channelBookingId": "sbx-7b3e94a1-0c5d-4f62-8e17-3a9d2c6b5f48",
|
|
5664
|
+
"otaName": "Website",
|
|
5665
|
+
"status": "UPCOMING",
|
|
5666
|
+
"guestName": "Priya Nair",
|
|
5667
|
+
"checkIn": "2026-12-24",
|
|
5668
|
+
"checkOut": "2026-12-26",
|
|
5669
|
+
"nights": 2,
|
|
5670
|
+
"rooms": 1,
|
|
5671
|
+
"roomTypeId": 412,
|
|
5672
|
+
"nightlyRate": 4850,
|
|
5673
|
+
"total": 9700,
|
|
5674
|
+
"currency": "INR",
|
|
5675
|
+
"paidByOta": true,
|
|
5676
|
+
"oversold": false,
|
|
5677
|
+
"createdAt": "2026-12-10T12:20:00.000Z",
|
|
5678
|
+
"webhook": {
|
|
5679
|
+
"eventType": "direct.booking.modified",
|
|
5680
|
+
"queued": true
|
|
5681
|
+
},
|
|
5682
|
+
"stayStatus": "NOSHOW"
|
|
5683
|
+
},
|
|
4588
5684
|
"refusals": [
|
|
4589
5685
|
{
|
|
4590
5686
|
"status": 401,
|
|
@@ -4600,7 +5696,7 @@ export const REFERENCE = {
|
|
|
4600
5696
|
},
|
|
4601
5697
|
{
|
|
4602
5698
|
"status": 409,
|
|
4603
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
5699
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4604
5700
|
},
|
|
4605
5701
|
{
|
|
4606
5702
|
"status": 429,
|
|
@@ -4627,7 +5723,17 @@ export const REFERENCE = {
|
|
|
4627
5723
|
"type": "channel.sync.alert",
|
|
4628
5724
|
"event": "rate_error"
|
|
4629
5725
|
},
|
|
4630
|
-
"answer":
|
|
5726
|
+
"answer": {
|
|
5727
|
+
"event": "rate_error",
|
|
5728
|
+
"channelId": "b53ff702-be2d-44ee-8a7e-d1153f096dba",
|
|
5729
|
+
"channelKind": "BookingCom",
|
|
5730
|
+
"raisedAt": "2026-12-10T12:30:00.000Z",
|
|
5731
|
+
"resolvedAt": null,
|
|
5732
|
+
"webhook": {
|
|
5733
|
+
"eventType": "channel.sync.alert",
|
|
5734
|
+
"queued": true
|
|
5735
|
+
}
|
|
5736
|
+
},
|
|
4631
5737
|
"refusals": [
|
|
4632
5738
|
{
|
|
4633
5739
|
"status": 401,
|
|
@@ -4643,7 +5749,7 @@ export const REFERENCE = {
|
|
|
4643
5749
|
},
|
|
4644
5750
|
{
|
|
4645
5751
|
"status": 409,
|
|
4646
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
5752
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4647
5753
|
},
|
|
4648
5754
|
{
|
|
4649
5755
|
"status": 429,
|
|
@@ -4704,7 +5810,7 @@ export const REFERENCE = {
|
|
|
4704
5810
|
},
|
|
4705
5811
|
{
|
|
4706
5812
|
"status": 409,
|
|
4707
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
5813
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4708
5814
|
},
|
|
4709
5815
|
{
|
|
4710
5816
|
"status": 429,
|
|
@@ -4754,7 +5860,7 @@ export const REFERENCE = {
|
|
|
4754
5860
|
"idempotent": false,
|
|
4755
5861
|
"request": null,
|
|
4756
5862
|
"answer": {
|
|
4757
|
-
"since": "2026-
|
|
5863
|
+
"since": "2026-12-03T12:30:00.000Z",
|
|
4758
5864
|
"items": [
|
|
4759
5865
|
{
|
|
4760
5866
|
"id": 100001,
|
|
@@ -4768,8 +5874,8 @@ export const REFERENCE = {
|
|
|
4768
5874
|
"sourceGroup": "DIRECT"
|
|
4769
5875
|
},
|
|
4770
5876
|
"stay": {
|
|
4771
|
-
"checkIn": "2026-
|
|
4772
|
-
"checkOut": "2026-
|
|
5877
|
+
"checkIn": "2026-12-24",
|
|
5878
|
+
"checkOut": "2026-12-26",
|
|
4773
5879
|
"nights": 2,
|
|
4774
5880
|
"dayUse": false
|
|
4775
5881
|
},
|
|
@@ -4791,12 +5897,12 @@ export const REFERENCE = {
|
|
|
4791
5897
|
{
|
|
4792
5898
|
"roomTypeId": 412,
|
|
4793
5899
|
"ratePlanId": 901,
|
|
4794
|
-
"roomTypeName": "Deluxe
|
|
5900
|
+
"roomTypeName": "Deluxe Garden Room",
|
|
4795
5901
|
"mealPlan": "CP",
|
|
4796
5902
|
"adults": 2,
|
|
4797
5903
|
"children": 0,
|
|
4798
|
-
"checkIn": "2026-
|
|
4799
|
-
"checkOut": "2026-
|
|
5904
|
+
"checkIn": "2026-12-24",
|
|
5905
|
+
"checkOut": "2026-12-26",
|
|
4800
5906
|
"nights": 2,
|
|
4801
5907
|
"dayUse": false,
|
|
4802
5908
|
"ratePerNight": 2700,
|
|
@@ -4813,12 +5919,12 @@ export const REFERENCE = {
|
|
|
4813
5919
|
},
|
|
4814
5920
|
"finance": null,
|
|
4815
5921
|
"cancellation": null,
|
|
4816
|
-
"createdAt": "2026-
|
|
4817
|
-
"updatedAt": "2026-
|
|
5922
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
5923
|
+
"updatedAt": "2026-12-10T12:00:00.000Z"
|
|
4818
5924
|
}
|
|
4819
5925
|
],
|
|
4820
5926
|
"more": false,
|
|
4821
|
-
"nextCursor": "
|
|
5927
|
+
"nextCursor": "WyIyMDI2LTEyLTEwVDEyOjAwOjAwLjAwMFoiLDEwMDAwMV0"
|
|
4822
5928
|
},
|
|
4823
5929
|
"refusals": [
|
|
4824
5930
|
{
|
|
@@ -4835,7 +5941,7 @@ export const REFERENCE = {
|
|
|
4835
5941
|
},
|
|
4836
5942
|
{
|
|
4837
5943
|
"status": 409,
|
|
4838
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
5944
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4839
5945
|
},
|
|
4840
5946
|
{
|
|
4841
5947
|
"status": 429,
|
|
@@ -4873,8 +5979,8 @@ export const REFERENCE = {
|
|
|
4873
5979
|
"sourceGroup": "DIRECT"
|
|
4874
5980
|
},
|
|
4875
5981
|
"stay": {
|
|
4876
|
-
"checkIn": "2026-
|
|
4877
|
-
"checkOut": "2026-
|
|
5982
|
+
"checkIn": "2026-12-24",
|
|
5983
|
+
"checkOut": "2026-12-26",
|
|
4878
5984
|
"nights": 2,
|
|
4879
5985
|
"dayUse": false
|
|
4880
5986
|
},
|
|
@@ -4896,12 +6002,12 @@ export const REFERENCE = {
|
|
|
4896
6002
|
{
|
|
4897
6003
|
"roomTypeId": 412,
|
|
4898
6004
|
"ratePlanId": 901,
|
|
4899
|
-
"roomTypeName": "Deluxe
|
|
6005
|
+
"roomTypeName": "Deluxe Garden Room",
|
|
4900
6006
|
"mealPlan": "CP",
|
|
4901
6007
|
"adults": 2,
|
|
4902
6008
|
"children": 0,
|
|
4903
|
-
"checkIn": "2026-
|
|
4904
|
-
"checkOut": "2026-
|
|
6009
|
+
"checkIn": "2026-12-24",
|
|
6010
|
+
"checkOut": "2026-12-26",
|
|
4905
6011
|
"nights": 2,
|
|
4906
6012
|
"dayUse": false,
|
|
4907
6013
|
"ratePerNight": 2700,
|
|
@@ -4918,8 +6024,8 @@ export const REFERENCE = {
|
|
|
4918
6024
|
},
|
|
4919
6025
|
"finance": null,
|
|
4920
6026
|
"cancellation": null,
|
|
4921
|
-
"createdAt": "2026-
|
|
4922
|
-
"updatedAt": "2026-
|
|
6027
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
6028
|
+
"updatedAt": "2026-12-10T12:00:00.000Z"
|
|
4923
6029
|
},
|
|
4924
6030
|
"refusals": [
|
|
4925
6031
|
{
|
|
@@ -4936,7 +6042,7 @@ export const REFERENCE = {
|
|
|
4936
6042
|
},
|
|
4937
6043
|
{
|
|
4938
6044
|
"status": 409,
|
|
4939
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
6045
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
4940
6046
|
},
|
|
4941
6047
|
{
|
|
4942
6048
|
"status": 429,
|
|
@@ -4970,7 +6076,7 @@ export const REFERENCE = {
|
|
|
4970
6076
|
"id": 100001,
|
|
4971
6077
|
"reference": "TEST-WEB-4H7P9D",
|
|
4972
6078
|
"status": "CANCELLED",
|
|
4973
|
-
"stayStatus": "
|
|
6079
|
+
"stayStatus": "CANCELLED",
|
|
4974
6080
|
"channel": {
|
|
4975
6081
|
"otaName": "Website",
|
|
4976
6082
|
"otaReservationCode": "TEST-WEB-4H7P9D",
|
|
@@ -4978,8 +6084,8 @@ export const REFERENCE = {
|
|
|
4978
6084
|
"sourceGroup": "DIRECT"
|
|
4979
6085
|
},
|
|
4980
6086
|
"stay": {
|
|
4981
|
-
"checkIn": "2026-
|
|
4982
|
-
"checkOut": "2026-
|
|
6087
|
+
"checkIn": "2026-12-24",
|
|
6088
|
+
"checkOut": "2026-12-26",
|
|
4983
6089
|
"nights": 2,
|
|
4984
6090
|
"dayUse": false
|
|
4985
6091
|
},
|
|
@@ -5001,12 +6107,12 @@ export const REFERENCE = {
|
|
|
5001
6107
|
{
|
|
5002
6108
|
"roomTypeId": 412,
|
|
5003
6109
|
"ratePlanId": 901,
|
|
5004
|
-
"roomTypeName": "Deluxe
|
|
6110
|
+
"roomTypeName": "Deluxe Garden Room",
|
|
5005
6111
|
"mealPlan": "CP",
|
|
5006
6112
|
"adults": 2,
|
|
5007
6113
|
"children": 0,
|
|
5008
|
-
"checkIn": "2026-
|
|
5009
|
-
"checkOut": "2026-
|
|
6114
|
+
"checkIn": "2026-12-24",
|
|
6115
|
+
"checkOut": "2026-12-26",
|
|
5010
6116
|
"nights": 2,
|
|
5011
6117
|
"dayUse": false,
|
|
5012
6118
|
"ratePerNight": 2700,
|
|
@@ -5023,11 +6129,11 @@ export const REFERENCE = {
|
|
|
5023
6129
|
},
|
|
5024
6130
|
"finance": null,
|
|
5025
6131
|
"cancellation": {
|
|
5026
|
-
"at": "2026-
|
|
6132
|
+
"at": "2026-12-11T09:15:00.000Z",
|
|
5027
6133
|
"reason": "Cancelled by the hotel"
|
|
5028
6134
|
},
|
|
5029
|
-
"createdAt": "2026-
|
|
5030
|
-
"updatedAt": "2026-
|
|
6135
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
6136
|
+
"updatedAt": "2026-12-11T09:15:00.000Z"
|
|
5031
6137
|
},
|
|
5032
6138
|
"refund": {
|
|
5033
6139
|
"requested": "policy",
|
|
@@ -5080,25 +6186,25 @@ export const REFERENCE = {
|
|
|
5080
6186
|
"bookings": [
|
|
5081
6187
|
{
|
|
5082
6188
|
"bookingId": 90311,
|
|
5083
|
-
"reference": "SBX-9001-
|
|
6189
|
+
"reference": "SBX-9001-MXHI8W001F6D",
|
|
5084
6190
|
"channelBookingId": "sbx-1f6d0c2e-7b53-4a0e-9c5a-2d8f3b1e4c70",
|
|
5085
6191
|
"otaName": "Booking.com",
|
|
5086
6192
|
"status": "UPCOMING",
|
|
5087
6193
|
"guestName": "Asha Verma",
|
|
5088
|
-
"checkIn": "2026-12-
|
|
5089
|
-
"checkOut": "2026-12-
|
|
6194
|
+
"checkIn": "2026-12-24",
|
|
6195
|
+
"checkOut": "2026-12-26",
|
|
5090
6196
|
"nights": 2,
|
|
5091
6197
|
"rooms": 1,
|
|
5092
6198
|
"roomTypeId": 412,
|
|
5093
|
-
"nightlyRate":
|
|
5094
|
-
"total":
|
|
6199
|
+
"nightlyRate": 4850,
|
|
6200
|
+
"total": 9700,
|
|
5095
6201
|
"currency": "INR",
|
|
5096
6202
|
"paidByOta": false,
|
|
5097
6203
|
"oversold": false,
|
|
5098
|
-
"createdAt": "2026-
|
|
6204
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
5099
6205
|
"webhook": {
|
|
5100
6206
|
"eventType": "channel.booking.created",
|
|
5101
|
-
"queued":
|
|
6207
|
+
"queued": false
|
|
5102
6208
|
}
|
|
5103
6209
|
}
|
|
5104
6210
|
]
|
|
@@ -5118,7 +6224,7 @@ export const REFERENCE = {
|
|
|
5118
6224
|
},
|
|
5119
6225
|
{
|
|
5120
6226
|
"status": 409,
|
|
5121
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
6227
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
5122
6228
|
},
|
|
5123
6229
|
{
|
|
5124
6230
|
"status": 429,
|
|
@@ -5143,7 +6249,7 @@ export const REFERENCE = {
|
|
|
5143
6249
|
"idempotent": true,
|
|
5144
6250
|
"request": {
|
|
5145
6251
|
"roomTypeId": 412,
|
|
5146
|
-
"checkIn": "2026-12-
|
|
6252
|
+
"checkIn": "2026-12-24",
|
|
5147
6253
|
"nights": 2,
|
|
5148
6254
|
"rooms": 1,
|
|
5149
6255
|
"adults": 2,
|
|
@@ -5153,22 +6259,22 @@ export const REFERENCE = {
|
|
|
5153
6259
|
},
|
|
5154
6260
|
"answer": {
|
|
5155
6261
|
"bookingId": 90311,
|
|
5156
|
-
"reference": "SBX-9001-
|
|
6262
|
+
"reference": "SBX-9001-MXHI8W001F6D",
|
|
5157
6263
|
"channelBookingId": "sbx-1f6d0c2e-7b53-4a0e-9c5a-2d8f3b1e4c70",
|
|
5158
6264
|
"otaName": "Booking.com",
|
|
5159
6265
|
"status": "UPCOMING",
|
|
5160
6266
|
"guestName": "Asha Verma",
|
|
5161
|
-
"checkIn": "2026-12-
|
|
5162
|
-
"checkOut": "2026-12-
|
|
6267
|
+
"checkIn": "2026-12-24",
|
|
6268
|
+
"checkOut": "2026-12-26",
|
|
5163
6269
|
"nights": 2,
|
|
5164
6270
|
"rooms": 1,
|
|
5165
6271
|
"roomTypeId": 412,
|
|
5166
|
-
"nightlyRate":
|
|
5167
|
-
"total":
|
|
6272
|
+
"nightlyRate": 4850,
|
|
6273
|
+
"total": 9700,
|
|
5168
6274
|
"currency": "INR",
|
|
5169
6275
|
"paidByOta": false,
|
|
5170
6276
|
"oversold": false,
|
|
5171
|
-
"createdAt": "2026-
|
|
6277
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
5172
6278
|
"webhook": {
|
|
5173
6279
|
"eventType": "channel.booking.created",
|
|
5174
6280
|
"queued": true
|
|
@@ -5215,7 +6321,29 @@ export const REFERENCE = {
|
|
|
5215
6321
|
],
|
|
5216
6322
|
"idempotent": true,
|
|
5217
6323
|
"request": null,
|
|
5218
|
-
"answer":
|
|
6324
|
+
"answer": {
|
|
6325
|
+
"bookingId": 90311,
|
|
6326
|
+
"reference": "SBX-9001-MXHI8W001F6D",
|
|
6327
|
+
"channelBookingId": "sbx-1f6d0c2e-7b53-4a0e-9c5a-2d8f3b1e4c70",
|
|
6328
|
+
"otaName": "Booking.com",
|
|
6329
|
+
"status": "CANCELLED",
|
|
6330
|
+
"guestName": "Asha Verma-Rao",
|
|
6331
|
+
"checkIn": "2026-12-24",
|
|
6332
|
+
"checkOut": "2026-12-27",
|
|
6333
|
+
"nights": 3,
|
|
6334
|
+
"rooms": 1,
|
|
6335
|
+
"roomTypeId": 412,
|
|
6336
|
+
"nightlyRate": 4966.67,
|
|
6337
|
+
"total": 14900,
|
|
6338
|
+
"currency": "INR",
|
|
6339
|
+
"paidByOta": false,
|
|
6340
|
+
"oversold": false,
|
|
6341
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
6342
|
+
"webhook": {
|
|
6343
|
+
"eventType": "channel.booking.cancelled",
|
|
6344
|
+
"queued": true
|
|
6345
|
+
}
|
|
6346
|
+
},
|
|
5219
6347
|
"refusals": [
|
|
5220
6348
|
{
|
|
5221
6349
|
"status": 401,
|
|
@@ -5260,7 +6388,29 @@ export const REFERENCE = {
|
|
|
5260
6388
|
"nights": 3,
|
|
5261
6389
|
"guestName": "Asha Verma-Rao"
|
|
5262
6390
|
},
|
|
5263
|
-
"answer":
|
|
6391
|
+
"answer": {
|
|
6392
|
+
"bookingId": 90311,
|
|
6393
|
+
"reference": "SBX-9001-MXHI8W001F6D",
|
|
6394
|
+
"channelBookingId": "sbx-1f6d0c2e-7b53-4a0e-9c5a-2d8f3b1e4c70",
|
|
6395
|
+
"otaName": "Booking.com",
|
|
6396
|
+
"status": "UPCOMING",
|
|
6397
|
+
"guestName": "Asha Verma-Rao",
|
|
6398
|
+
"checkIn": "2026-12-24",
|
|
6399
|
+
"checkOut": "2026-12-27",
|
|
6400
|
+
"nights": 3,
|
|
6401
|
+
"rooms": 1,
|
|
6402
|
+
"roomTypeId": 412,
|
|
6403
|
+
"nightlyRate": 4966.67,
|
|
6404
|
+
"total": 14900,
|
|
6405
|
+
"currency": "INR",
|
|
6406
|
+
"paidByOta": false,
|
|
6407
|
+
"oversold": false,
|
|
6408
|
+
"createdAt": "2026-12-10T12:00:00.000Z",
|
|
6409
|
+
"webhook": {
|
|
6410
|
+
"eventType": "channel.booking.modified",
|
|
6411
|
+
"queued": true
|
|
6412
|
+
}
|
|
6413
|
+
},
|
|
5264
6414
|
"refusals": [
|
|
5265
6415
|
{
|
|
5266
6416
|
"status": 400,
|
|
@@ -5309,10 +6459,10 @@ export const REFERENCE = {
|
|
|
5309
6459
|
"answer": {
|
|
5310
6460
|
"batchId": "7f1d2c4e-5a6b-4c8d-9e0f-112233445566",
|
|
5311
6461
|
"resource": "rates",
|
|
5312
|
-
"createdAt": "2026-
|
|
5313
|
-
"requestedCells":
|
|
5314
|
-
"acceptedCells":
|
|
5315
|
-
"noopCells":
|
|
6462
|
+
"createdAt": "2026-12-01T09:14:03.201Z",
|
|
6463
|
+
"requestedCells": 121,
|
|
6464
|
+
"acceptedCells": 34,
|
|
6465
|
+
"noopCells": 87,
|
|
5316
6466
|
"rejected": [],
|
|
5317
6467
|
"status": "pending",
|
|
5318
6468
|
"pendingCells": 12,
|
|
@@ -5334,7 +6484,7 @@ export const REFERENCE = {
|
|
|
5334
6484
|
},
|
|
5335
6485
|
{
|
|
5336
6486
|
"status": 409,
|
|
5337
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
6487
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
5338
6488
|
},
|
|
5339
6489
|
{
|
|
5340
6490
|
"status": 429,
|
|
@@ -5411,7 +6561,7 @@ export const REFERENCE = {
|
|
|
5411
6561
|
},
|
|
5412
6562
|
{
|
|
5413
6563
|
"status": 409,
|
|
5414
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
6564
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
5415
6565
|
},
|
|
5416
6566
|
{
|
|
5417
6567
|
"status": 429,
|
|
@@ -5422,7 +6572,7 @@ export const REFERENCE = {
|
|
|
5422
6572
|
{
|
|
5423
6573
|
"key": "POST /connect-links",
|
|
5424
6574
|
"summary": "Make a one-time connect link for one hotel and one booking site",
|
|
5425
|
-
"description": "Scope channels:connect; a live key. The answer carries the link's url, shown once
|
|
6575
|
+
"description": "Scope channels:connect; a live key. The answer carries the link's url, shown once, and hotelStep, what the hotel does at the booking site first (every booking site but Airbnb). Send hotelStep to the hotel first and the url once that step is done; the hotel's own person then types the hotel's id at the booking site on our hosted page, matches and starts selling. The body takes no booking-site detail and no room match. A second link for the same hotel and booking site withdraws an earlier one nobody opened.",
|
|
5426
6576
|
"scope": "channels:connect",
|
|
5427
6577
|
"call": "zs.connectLinks.create(body)",
|
|
5428
6578
|
"also": [],
|
|
@@ -5543,7 +6693,7 @@ export const REFERENCE = {
|
|
|
5543
6693
|
},
|
|
5544
6694
|
{
|
|
5545
6695
|
"status": 409,
|
|
5546
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
6696
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
5547
6697
|
},
|
|
5548
6698
|
{
|
|
5549
6699
|
"status": 429,
|
|
@@ -5569,7 +6719,27 @@ export const REFERENCE = {
|
|
|
5569
6719
|
],
|
|
5570
6720
|
"idempotent": true,
|
|
5571
6721
|
"request": null,
|
|
5572
|
-
"answer":
|
|
6722
|
+
"answer": {
|
|
6723
|
+
"id": "3f2b6c1e-8a4d-4e7b-9c05-1d2e3f4a5b6c",
|
|
6724
|
+
"propertyId": 61,
|
|
6725
|
+
"channel": "bookingcom",
|
|
6726
|
+
"channelName": "Booking.com",
|
|
6727
|
+
"status": "revoked",
|
|
6728
|
+
"createdAt": "2026-11-23T09:30:00.000Z",
|
|
6729
|
+
"expiresAt": "2026-11-26T09:30:00.000Z",
|
|
6730
|
+
"openedAt": null,
|
|
6731
|
+
"connectedAt": null,
|
|
6732
|
+
"completedAt": null,
|
|
6733
|
+
"revokedAt": "2026-11-23T10:05:00.000Z",
|
|
6734
|
+
"channelId": null,
|
|
6735
|
+
"reference": "onboarding-4471",
|
|
6736
|
+
"returnUrl": null,
|
|
6737
|
+
"createdByKey": {
|
|
6738
|
+
"id": 12,
|
|
6739
|
+
"name": "Aarohan PMS, production",
|
|
6740
|
+
"maskedKey": "zsk_live_aB3…"
|
|
6741
|
+
}
|
|
6742
|
+
},
|
|
5573
6743
|
"refusals": [
|
|
5574
6744
|
{
|
|
5575
6745
|
"status": 401,
|
|
@@ -5585,7 +6755,7 @@ export const REFERENCE = {
|
|
|
5585
6755
|
},
|
|
5586
6756
|
{
|
|
5587
6757
|
"status": 409,
|
|
5588
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
6758
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
5589
6759
|
},
|
|
5590
6760
|
{
|
|
5591
6761
|
"status": 429,
|
|
@@ -5705,7 +6875,7 @@ export const REFERENCE = {
|
|
|
5705
6875
|
},
|
|
5706
6876
|
{
|
|
5707
6877
|
"status": 409,
|
|
5708
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
6878
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
5709
6879
|
},
|
|
5710
6880
|
{
|
|
5711
6881
|
"status": 429,
|
|
@@ -5826,7 +6996,7 @@ export const REFERENCE = {
|
|
|
5826
6996
|
},
|
|
5827
6997
|
{
|
|
5828
6998
|
"status": 409,
|
|
5829
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
6999
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
5830
7000
|
},
|
|
5831
7001
|
{
|
|
5832
7002
|
"status": 429,
|
|
@@ -5935,7 +7105,57 @@ export const REFERENCE = {
|
|
|
5935
7105
|
],
|
|
5936
7106
|
"idempotent": true,
|
|
5937
7107
|
"request": null,
|
|
5938
|
-
"answer":
|
|
7108
|
+
"answer": {
|
|
7109
|
+
"key": "zsk_live_…",
|
|
7110
|
+
"view": {
|
|
7111
|
+
"id": 88,
|
|
7112
|
+
"propertyId": 61,
|
|
7113
|
+
"name": "Aarohan PMS, The Lantern House",
|
|
7114
|
+
"maskedKey": "zsk_live_Xr4…",
|
|
7115
|
+
"mode": "live",
|
|
7116
|
+
"status": "ACTIVE",
|
|
7117
|
+
"scopes": [
|
|
7118
|
+
"ari:read",
|
|
7119
|
+
"ari:write",
|
|
7120
|
+
"channel-bookings:read"
|
|
7121
|
+
],
|
|
7122
|
+
"allowedCidrs": [
|
|
7123
|
+
"203.0.113.0/24"
|
|
7124
|
+
],
|
|
7125
|
+
"createdAt": "2026-11-24T08:00:00.000Z",
|
|
7126
|
+
"lastUsedAt": null,
|
|
7127
|
+
"lastUsedIp": null,
|
|
7128
|
+
"expiresAt": null,
|
|
7129
|
+
"retireAt": null,
|
|
7130
|
+
"rotatedToId": null,
|
|
7131
|
+
"revokedAt": null,
|
|
7132
|
+
"revokedReason": null
|
|
7133
|
+
},
|
|
7134
|
+
"retired": {
|
|
7135
|
+
"id": 87,
|
|
7136
|
+
"propertyId": 61,
|
|
7137
|
+
"name": "Aarohan PMS, The Lantern House",
|
|
7138
|
+
"maskedKey": "zsk_live_Qm7…",
|
|
7139
|
+
"mode": "live",
|
|
7140
|
+
"status": "ACTIVE",
|
|
7141
|
+
"scopes": [
|
|
7142
|
+
"ari:read",
|
|
7143
|
+
"ari:write",
|
|
7144
|
+
"channel-bookings:read"
|
|
7145
|
+
],
|
|
7146
|
+
"allowedCidrs": [
|
|
7147
|
+
"203.0.113.0/24"
|
|
7148
|
+
],
|
|
7149
|
+
"createdAt": "2026-11-23T12:45:00.000Z",
|
|
7150
|
+
"lastUsedAt": "2026-11-24T07:59:12.000Z",
|
|
7151
|
+
"lastUsedIp": "203.0.113.24",
|
|
7152
|
+
"expiresAt": null,
|
|
7153
|
+
"retireAt": "2026-11-25T08:00:00.000Z",
|
|
7154
|
+
"rotatedToId": 88,
|
|
7155
|
+
"revokedAt": null,
|
|
7156
|
+
"revokedReason": null
|
|
7157
|
+
}
|
|
7158
|
+
},
|
|
5939
7159
|
"refusals": [
|
|
5940
7160
|
{
|
|
5941
7161
|
"status": 401,
|
|
@@ -5980,7 +7200,30 @@ export const REFERENCE = {
|
|
|
5980
7200
|
"request": {
|
|
5981
7201
|
"reason": "The old server was switched off"
|
|
5982
7202
|
},
|
|
5983
|
-
"answer":
|
|
7203
|
+
"answer": {
|
|
7204
|
+
"id": 87,
|
|
7205
|
+
"propertyId": 61,
|
|
7206
|
+
"name": "Aarohan PMS, The Lantern House",
|
|
7207
|
+
"maskedKey": "zsk_live_Qm7…",
|
|
7208
|
+
"mode": "live",
|
|
7209
|
+
"status": "REVOKED",
|
|
7210
|
+
"scopes": [
|
|
7211
|
+
"ari:read",
|
|
7212
|
+
"ari:write",
|
|
7213
|
+
"channel-bookings:read"
|
|
7214
|
+
],
|
|
7215
|
+
"allowedCidrs": [
|
|
7216
|
+
"203.0.113.0/24"
|
|
7217
|
+
],
|
|
7218
|
+
"createdAt": "2026-11-23T12:45:00.000Z",
|
|
7219
|
+
"lastUsedAt": "2026-11-24T07:59:12.000Z",
|
|
7220
|
+
"lastUsedIp": "203.0.113.24",
|
|
7221
|
+
"expiresAt": null,
|
|
7222
|
+
"retireAt": null,
|
|
7223
|
+
"rotatedToId": null,
|
|
7224
|
+
"revokedAt": "2026-11-24T08:05:00.000Z",
|
|
7225
|
+
"revokedReason": "The old server was switched off"
|
|
7226
|
+
},
|
|
5984
7227
|
"refusals": [
|
|
5985
7228
|
{
|
|
5986
7229
|
"status": 400,
|
|
@@ -6000,7 +7243,7 @@ export const REFERENCE = {
|
|
|
6000
7243
|
},
|
|
6001
7244
|
{
|
|
6002
7245
|
"status": 409,
|
|
6003
|
-
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on
|
|
7246
|
+
"description": "The property is deleted or demo (PROPERTY_UNAVAILABLE); on a channel-manager route its channel manager is off (CHANNEL_MANAGER_DISABLED; data.details.reason is not_on_channel_manager, a hotel never put on it: send its room types and rate plans or press Finish setup in the Channels app, or switched_off, which only the hotel's owner undoes), or, on a company key, its rates are not the source of truth (ARI_NOT_AUTHORITATIVE); on a booking route it has no PMS (PMS_NOT_AVAILABLE)"
|
|
6004
7247
|
},
|
|
6005
7248
|
{
|
|
6006
7249
|
"status": 429,
|
|
@@ -6010,23 +7253,25 @@ export const REFERENCE = {
|
|
|
6010
7253
|
}
|
|
6011
7254
|
],
|
|
6012
7255
|
"types": {
|
|
6013
|
-
"Error": "export interface Error {\n statuscode: number;\n /** Human-readable, may change; branch on data.code */\n message: string;\n data: {\n code: \"API_KEY_INVALID\" | \"API_KEY_REVOKED\" | \"API_KEY_EXPIRED\" | \"CONNECT_API_NOT_CONFIGURED\" | \"IP_NOT_ALLOWED\" | \"SCOPE_MISSING\" | \"PROPERTY_UNAVAILABLE\" | \"CHANNEL_MANAGER_DISABLED\" | \"PMS_NOT_AVAILABLE\" | \"VALIDATION\" | \"RANGE_INVALID\" | \"HORIZON\" | \"TOO_MANY_UPDATES\" | \"TOO_MANY_CELLS\" | \"UNKNOWN_ROOM_TYPE\" | \"UNKNOWN_RATE_PLAN\" | \"CURRENCY_MISMATCH\" | \"RATE_LIMITED\" | \"NOTHING_ACCEPTED\" | \"BATCH_NOT_FOUND\" | \"IDEMPOTENCY_KEY_INVALID\" | \"IDEMPOTENCY_KEY_REUSED\" | \"IDEMPOTENCY_IN_FLIGHT\" | \"STAY_INVALID\" | \"UNKNOWN_ROOM_TYPE_FOR_PLAN\" | \"OCCUPANCY_EXCEEDED\" | \"NO_AVAILABILITY\" | \"EXTERNAL_REFERENCE_REUSED\" | \"PAYMENT_NOT_ALLOWED\" | \"PAYMENT_EXCEEDS_TOTAL\" | \"TAXES_NOT_CONFIGURED\" | \"TAXES_INSIDE_RATES\" | \"BOOKING_NOT_FOUND\" | \"BOOKING_NOT_CANCELLABLE\" | \"MODULE_NOT_ENTITLED\" | \"SANDBOX_ONLY\" | \"ROOM_TYPE_NOT_FOUND\" | \"RATE_PLAN_NOT_FOUND\" | \"CATALOG_CONFLICT\" | \"CATALOG_BUSY\" | \"CHANNEL_MANAGER_ERROR\" | \"WEBHOOK_ENDPOINT_NOT_FOUND\" | \"WEBHOOK_DELIVERY_NOT_FOUND\" | \"WEBHOOK_ENDPOINT_LIMIT\" | \"WEBHOOK_ENDPOINT_NOT_ACTIVE\" | \"WEBHOOK_ENDPOINT_SUSPENDED\" | \"WEBHOOK_PAYLOAD_EXPIRED\" | \"WEBHOOK_ACCESS_ENDED\" | \"WEBHOOKS_UNAVAILABLE\" | \"PROPERTY_REQUIRED\" | \"PROPERTY_NOT_FOUND\" | \"ARI_NOT_AUTHORITATIVE\" | \"ROUTE_NOT_FOUND\" | \"PAYLOAD_TOO_LARGE\" | \"AUTH_BACKEND_UNAVAILABLE\" | \"BOOKING_NOT_MODIFIABLE\" | \"SANDBOX_NOT_FOUND\" | \"SANDBOX_INCOMPLETE\" | \"WRITES_FROZEN\" | \"WRITES_SUSPENDED\" | \"SHIELD_UNAVAILABLE\" | \"CATALOG_LIMIT_REACHED\" | \"TOO_MANY_NEW_ENTITIES\" | \"RATE_OUT_OF_BAND\" | \"CHANNEL_NOT_FOUND\" | \"CHANNEL_SHARED\" | \"MODIFIER_OUT_OF_BAND\" | \"COMPANY_KEY_REQUIRED\" | \"BILLING_SETUP_REQUIRED\" | \"OWNER_HAS_ACCOUNT\" | \"SANDBOX_LIMIT\" | \"CONFIRMATION_MISMATCH\" | \"PROPERTY_NOT_REMOVABLE\" | \"PROPERTY_BUSY\" | \"PRICE_UNAVAILABLE\" | \"CONNECT_LINK_NOT_FOUND\" | \"CONNECT_LINKS_UNAVAILABLE\" | \"CHANNEL_NOT_AVAILABLE\" | \"LIVE_KEY_REQUIRED\" | \"NOT_READY\" | \"KEY_NOT_FOUND\" | \"KEY_LIMIT\" | \"KEY_REVOKED\" | \"KEY_ALREADY_ROTATING\" | \"SCOPES_INVALID\" | \"ALLOWED_CIDRS_INVALID\" | \"REASON_REQUIRED\" | \"SUPPORT_TICKET_NOT_FOUND\" | \"SUPPORT_TICKET_CLOSED\";\n details?: unknown;\n };\n}",
|
|
7256
|
+
"Error": "export interface Error {\n statuscode: number;\n /** Human-readable, may change; branch on data.code */\n message: string;\n data: {\n code: \"API_KEY_INVALID\" | \"API_KEY_REVOKED\" | \"API_KEY_EXPIRED\" | \"CONNECT_API_NOT_CONFIGURED\" | \"IP_NOT_ALLOWED\" | \"SCOPE_MISSING\" | \"PROPERTY_UNAVAILABLE\" | \"CHANNEL_MANAGER_DISABLED\" | \"PMS_NOT_AVAILABLE\" | \"VALIDATION\" | \"RANGE_INVALID\" | \"HORIZON\" | \"TOO_MANY_UPDATES\" | \"TOO_MANY_CELLS\" | \"UNKNOWN_ROOM_TYPE\" | \"UNKNOWN_RATE_PLAN\" | \"CURRENCY_MISMATCH\" | \"RATE_LIMITED\" | \"NOTHING_ACCEPTED\" | \"BATCH_NOT_FOUND\" | \"IDEMPOTENCY_KEY_INVALID\" | \"IDEMPOTENCY_KEY_REUSED\" | \"IDEMPOTENCY_IN_FLIGHT\" | \"STAY_INVALID\" | \"UNKNOWN_ROOM_TYPE_FOR_PLAN\" | \"OCCUPANCY_EXCEEDED\" | \"NO_AVAILABILITY\" | \"EXTERNAL_REFERENCE_REUSED\" | \"PAYMENT_NOT_ALLOWED\" | \"PAYMENT_EXCEEDS_TOTAL\" | \"TAXES_NOT_CONFIGURED\" | \"TAXES_INSIDE_RATES\" | \"BOOKING_NOT_FOUND\" | \"BOOKING_NOT_CANCELLABLE\" | \"MODULE_NOT_ENTITLED\" | \"SANDBOX_ONLY\" | \"ROOM_TYPE_NOT_FOUND\" | \"RATE_PLAN_NOT_FOUND\" | \"CATALOG_CONFLICT\" | \"CATALOG_BUSY\" | \"CHANNEL_MANAGER_ERROR\" | \"WEBHOOK_ENDPOINT_NOT_FOUND\" | \"WEBHOOK_DELIVERY_NOT_FOUND\" | \"WEBHOOK_ENDPOINT_LIMIT\" | \"WEBHOOK_ENDPOINT_NOT_ACTIVE\" | \"WEBHOOK_ENDPOINT_SUSPENDED\" | \"WEBHOOK_PAYLOAD_EXPIRED\" | \"WEBHOOK_ACCESS_ENDED\" | \"WEBHOOKS_UNAVAILABLE\" | \"PROPERTY_REQUIRED\" | \"PROPERTY_NOT_FOUND\" | \"ARI_NOT_AUTHORITATIVE\" | \"ROUTE_NOT_FOUND\" | \"PAYLOAD_TOO_LARGE\" | \"AUTH_BACKEND_UNAVAILABLE\" | \"BOOKING_NOT_MODIFIABLE\" | \"SANDBOX_NOT_FOUND\" | \"SANDBOX_INCOMPLETE\" | \"WRITES_FROZEN\" | \"WRITES_SUSPENDED\" | \"SHIELD_UNAVAILABLE\" | \"CATALOG_LIMIT_REACHED\" | \"TOO_MANY_NEW_ENTITIES\" | \"RATE_OUT_OF_BAND\" | \"CHANNEL_NOT_FOUND\" | \"CHANNEL_SHARED\" | \"MODIFIER_OUT_OF_BAND\" | \"COMPANY_KEY_REQUIRED\" | \"BILLING_SETUP_REQUIRED\" | \"OWNER_HAS_ACCOUNT\" | \"SANDBOX_LIMIT\" | \"CONFIRMATION_MISMATCH\" | \"PROPERTY_NOT_REMOVABLE\" | \"PROPERTY_NOT_CHANGEABLE\" | \"PROPERTY_BUSY\" | \"PRICE_UNAVAILABLE\" | \"CONNECT_LINK_NOT_FOUND\" | \"CONNECT_LINKS_UNAVAILABLE\" | \"CHANNEL_NOT_AVAILABLE\" | \"LIVE_KEY_REQUIRED\" | \"NOT_READY\" | \"KEY_NOT_FOUND\" | \"KEY_LIMIT\" | \"KEY_REVOKED\" | \"KEY_ALREADY_ROTATING\" | \"SCOPES_INVALID\" | \"ALLOWED_CIDRS_INVALID\" | \"REASON_REQUIRED\" | \"SUPPORT_TICKET_NOT_FOUND\" | \"SUPPORT_TICKET_CLOSED\";\n details?: unknown;\n };\n}",
|
|
6014
7257
|
"Property": "export interface Property {\n id: number;\n name: string;\n /** IANA; every date in this API is a calendar date in this zone */\n timezone: string;\n /** ISO 4217; every rate must be sent in it */\n currency: string;\n /** Digits after the decimal point this currency's prices carry (ISO 4217): 2 for rupees, euros and dollars, 0 for yen. Every amount this API reads back as a decimal string has exactly this many (§2.10) */\n decimals?: number;\n inventoryScope: \"PMS_CM\" | \"CM_ONLY\" | \"PMS_CUTOVER\" | \"OWNER_SITE\";\n /** true when this key is a zsk_test_ key on the owner's sandbox: nothing you send reaches a channel, and POST /sandbox/bookings simulates an OTA booking */\n sandbox: boolean;\n /** last writable night = today + horizonDays */\n horizonDays: number;\n ariAuthoritative: boolean;\n /** what THIS key may do: ari:read · ari:write · bookings:read · bookings:write · bookings:payments */\n scopes: Array<string>;\n products: {\n /** the ARI routes need it */\n channelManager: boolean;\n /** the booking routes need it */\n pms: boolean;\n };\n limits: {\n requestsPerMinute: number;\n writesPerMinute: number;\n maxUpdatesPerRequest: number;\n maxCellsPerRequest: number;\n bookingsPerMinute: number;\n /** Changed cells this property may take per clock hour (UTC), all its keys together. A cell that already holds the value sent is not counted */\n cellsPerHour: number;\n /** Changed cells this property may take per rolling 24 hours */\n cellsPerDay: number;\n /** Room types this property may hold */\n maxRoomTypes: number;\n /** Rate plans this property may hold */\n maxRatePlans: number;\n /** A vacation rental: rate plans this property may hold per room type, counted over the whole property. null on a hotel, where maxRatePlans is the rule */\n ratePlansPerRoomType: number | null;\n /** New room types or rate plans one request, and one minute, may create */\n newEntitiesPerMinute: number;\n };\n /** What this property has used of its long budgets (§6.6) */\n usage: {\n /** Changed cells counted against cellsPerHour so far this clock hour */\n cellsThisHour: number;\n /** Changed cells counted against cellsPerDay over the last 24 hours */\n cellsLast24h: number;\n };\n /** Where this integration stands with the channel shield. Reads and bookings are never affected */\n shield: {\n /** CLEAR nothing held against the integration · WATCH noted, nothing refused · PAUSED only writes that close inventory are accepted · SUSPENDED every write refused until ZimmerStack releases it */\n level: \"CLEAR\" | \"WATCH\" | \"PAUSED\" | \"SUSPENDED\";\n /** Why, when the level is not CLEAR */\n reason: string | null;\n /** When a pause ends on its own (ISO instant); null = until released, or not paused */\n until: string | null;\n };\n sync: {\n state: \"IN_SYNC\" | \"PENDING\" | \"OUT_OF_SYNC\" | \"DISABLED\";\n pendingCells: number;\n };\n}",
|
|
6015
7258
|
"Limits": "export interface Limits {\n /** ISO 8601 instant the windows were read */\n asOf: string;\n key: {\n kind: \"hotel\" | \"company\";\n mode: \"live\" | \"test\";\n /** The hotel these budgets are for; null on a company key that named none */\n propertyId: number | null;\n };\n /** The budgets the key guard and the routes measure: a minute, or a rolling day */\n budgets: Array<{\n /** The budget's name: data.scope on the 429 that names it */\n scope: string;\n /** Its name in the RateLimit-Policy / RateLimit headers; null when it is not reported there */\n header: string | null;\n /** Whose traffic is counted together */\n per: string;\n /** The window in words: 60 s sliding, one clock hour (UTC), rolling 24 hours */\n window: string;\n windowSeconds: number | null;\n /** The most the window holds, for THIS key, property and company */\n quota: number;\n /** What is counted: requests, writes, cells, bookings… */\n unit: string;\n /** Counted in the window now; null when this route cannot read it */\n used: number | null;\n /** What is left; null with used */\n remaining: number | null;\n /** Seconds until it has room again when nothing is left; otherwise until the oldest counted item leaves the window. 0 when nothing is counted */\n resetSeconds: number | null;\n /** What is counted, in a sentence */\n counts: string;\n }>;\n /** Where the integration stands and its long budgets; null on a company key that named no hotel */\n shield: {\n standing: {\n level: \"CLEAR\" | \"WATCH\" | \"PAUSED\" | \"SUSPENDED\";\n reason: string | null;\n until: string | null;\n };\n /** The budgets over an hour and a day, with this property's own quotas */\n budgets: Array<{\n /** The budget's name: data.scope on the 429 that names it */\n scope: string;\n /** Its name in the RateLimit-Policy / RateLimit headers; null when it is not reported there */\n header: string | null;\n /** Whose traffic is counted together */\n per: string;\n /** The window in words: 60 s sliding, one clock hour (UTC), rolling 24 hours */\n window: string;\n windowSeconds: number | null;\n /** The most the window holds, for THIS key, property and company */\n quota: number;\n /** What is counted: requests, writes, cells, bookings… */\n unit: string;\n /** Counted in the window now; null when this route cannot read it */\n used: number | null;\n /** What is left; null with used */\n remaining: number | null;\n /** Seconds until it has room again when nothing is left; otherwise until the oldest counted item leaves the window. 0 when nothing is counted */\n resetSeconds: number | null;\n /** What is counted, in a sentence */\n counts: string;\n }>;\n } | null;\n /** The most one request may carry, and the most of a thing that may exist */\n caps: Array<{\n scope: string;\n per: string;\n quota: number;\n unit: string;\n counts: string;\n }>;\n note: string;\n}",
|
|
6016
|
-
"Catalog": "export interface Catalog {\n /** ISO 4217; the property's, and the one every rate and booking is sent in */\n currency: string;\n /** Digits after the decimal point this currency's prices carry (§2.10) */\n decimals?: number;\n /** Every room type on the property, stable ids, in the order they were created */\n roomTypes: Array<{\n /** The number every availability write and every booking room names as roomTypeId */\n id: number;\n /** Your own id for it, when your system wrote it through PUT /catalog/room-types; null otherwise */\n ref: string | null;\n /** As the owner named it in ZimmerStack */\n name: string;\n /** Most adults one room takes; null = not set */\n maxAdults: number | null;\n /** Most children one room takes; null = not set */\n maxChildren: number | null;\n /** \"room\" unless the owner chose another kind of unit */\n roomKind: string;\n /** IN_SYNC the channel manager has it · PENDING / SENDING on its way · FAILED stopped retrying (the owner's screen offers Retry) · DRIFTED someone changed it inside the channel manager · NOT_LINKED saved here, never added there · DISABLED the property is not connected */\n sync: \"IN_SYNC\" | \"PENDING\" | \"SENDING\" | \"FAILED\" | \"DRIFTED\" | \"NOT_LINKED\" | \"DISABLED\";\n }>;\n /** Every rate plan, each under one room type */\n ratePlans: Array<{\n /** The number rate and restriction writes name as ratePlanId; optional on a booking room */\n id: number;\n /** Your own id for it, when your system wrote it through PUT /catalog/rate-plans; null otherwise */\n ref: string | null;\n /** The room type this plan sells; a booking may only pair the two */\n roomTypeId: number;\n /** As the owner named it */\n name: string;\n /** EP room only · CP breakfast · MAP half board · AP full board; null = not set */\n mealPlan: \"EP\" | \"CP\" | \"MAP\" | \"AP\" | null;\n /** The occupancy this plan is priced for; null = any */\n occupancy: number | null;\n currency: string;\n /** The plan's standing price in major units, as a decimal string with the currency's own decimals (\"4500.50\"): the same field PUT /catalog/rate-plans takes. null = it follows the room type's base rate */\n defaultRate?: string | null;\n /** false = a non-refundable plan */\n refundable: boolean;\n /** IN_SYNC the channel manager has it · PENDING / SENDING on its way · FAILED stopped retrying (the owner's screen offers Retry) · DRIFTED someone changed it inside the channel manager · NOT_LINKED saved here, never added there · DISABLED the property is not connected */\n sync: \"IN_SYNC\" | \"PENDING\" | \"SENDING\" | \"FAILED\" | \"DRIFTED\" | \"NOT_LINKED\" | \"DISABLED\";\n }>;\n}",
|
|
7259
|
+
"Catalog": "export interface Catalog {\n /** ISO 4217; the property's, and the one every rate and booking is sent in */\n currency: string;\n /** Digits after the decimal point this currency's prices carry (§2.10) */\n decimals?: number;\n /** Every room type on the property, stable ids, in the order they were created */\n roomTypes: Array<{\n /** The number every availability write and every booking room names as roomTypeId */\n id: number;\n /** Your own id for it, when your system wrote it through PUT /catalog/room-types; null otherwise */\n ref: string | null;\n /** As the owner named it in ZimmerStack */\n name: string;\n /** Most adults one room takes; null = not set */\n maxAdults: number | null;\n /** Most children one room takes; null = not set */\n maxChildren: number | null;\n /** \"room\" unless the owner chose another kind of unit */\n roomKind: string;\n /** IN_SYNC the channel manager has it · PENDING / SENDING on its way · FAILED stopped retrying (the owner's screen offers Retry) · DRIFTED someone changed it inside the channel manager · NOT_LINKED saved here, never added there · DISABLED the property is not connected */\n sync: \"IN_SYNC\" | \"PENDING\" | \"SENDING\" | \"FAILED\" | \"DRIFTED\" | \"NOT_LINKED\" | \"DISABLED\";\n }>;\n /** Every rate plan, each under one room type */\n ratePlans: Array<{\n /** The number rate and restriction writes name as ratePlanId; optional on a booking room */\n id: number;\n /** Your own id for it, when your system wrote it through PUT /catalog/rate-plans; null otherwise */\n ref: string | null;\n /** The room type this plan sells; a booking may only pair the two */\n roomTypeId: number;\n /** As the owner named it */\n name: string;\n /** EP room only · CP breakfast · MAP half board · AP full board; null = not set */\n mealPlan: \"EP\" | \"CP\" | \"MAP\" | \"AP\" | null;\n /** The occupancy this plan is priced for; null = any */\n occupancy: number | null;\n currency: string;\n /** The plan's standing price in major units, as a decimal string with the currency's own decimals (\"4500.50\"): the same field PUT /catalog/rate-plans takes, and the price every date of the plan opens for booking at. null = it follows the room type's base rate, which only a plan made on the hotel's own screens can do */\n defaultRate?: string | null;\n /** false = a non-refundable plan */\n refundable: boolean;\n /** IN_SYNC the channel manager has it · PENDING / SENDING on its way · FAILED stopped retrying (the owner's screen offers Retry) · DRIFTED someone changed it inside the channel manager · NOT_LINKED saved here, never added there · DISABLED the property is not connected */\n sync: \"IN_SYNC\" | \"PENDING\" | \"SENDING\" | \"FAILED\" | \"DRIFTED\" | \"NOT_LINKED\" | \"DISABLED\";\n }>;\n}",
|
|
6017
7260
|
"Properties": "export interface Properties {\n /** company: a software vendor's key, the hotel named in X-ZS-Property on every request. property: one hotel's own key, no header needed. */\n keyKind: \"company\" | \"property\";\n /** A company key: every property it may act on. A hotel key: its one property. */\n properties: Array<{\n /** The id a company key names in the X-ZS-Property header */\n id: number;\n name: string;\n timezone: string;\n currency: string;\n /** The property publishes to its channels */\n channelManager: boolean;\n /** A sandbox: everything lands locally, nothing reaches a channel */\n sandbox: boolean;\n }>;\n}",
|
|
6018
7261
|
"PropertyCreate": "export interface PropertyCreate {\n /** The hotel's name, as its guests know it */\n name: string;\n /** The person who owns the hotel's account */\n owner: {\n name: string;\n /** The owner's own address. The sign-in details are sent here, never to you */\n email: string;\n /** Digits, with an optional + and spaces, dots, dashes or brackets */\n phone: string;\n };\n address: {\n line1: string;\n city: string;\n state?: string;\n postalCode?: string;\n /** ISO 3166-1 alpha-2, for example IN, LK, PT */\n country: string;\n };\n /** ISO 4217: what the hotel sells in. Default: the country's own currency. A hotel in India sells in INR */\n currency?: string;\n /** An IANA zone of the hotel's country. Default: the country's main zone */\n timezone?: string;\n /** India only: the hotel's GSTIN when it is registered under GST. Leave it out when it is not, and for a hotel in any other country */\n taxId?: string;\n /** At least one. Each is born with one room-only rate plan at its defaultRate */\n roomTypes: Array<{\n /** Your own id for this room type. Send the same ref to PUT /catalog/room-types later and it updates this one instead of making a second */\n ref?: string;\n /** Shown to the owner and sent to the channel manager as the title; each name once per request */\n name: string;\n /** Sellable rooms of this type */\n roomCount: number;\n /** Most adults one room takes; default 2 */\n adults?: number;\n /** The nightly price new dates open at, in MAJOR units of the hotel's currency (e.g. 4500 or \"4500.00\") */\n defaultRate: number | string;\n }>;\n}",
|
|
6019
|
-
"PropertyCreated": "export interface PropertyCreated {\n /** The id your company key names in the X-ZS-Property header from now on */\n id: number;\n /** As stored. A sandbox's name ends in (sandbox) and is at most 60 characters */\n name: string;\n timezone: string;\n currency: string;\n /** The property publishes to its channels.
|
|
7262
|
+
"PropertyCreated": "export interface PropertyCreated {\n /** The id your company key names in the X-ZS-Property header from now on */\n id: number;\n /** As stored. A sandbox's name ends in (sandbox) and is at most 60 characters */\n name: string;\n timezone: string;\n currency: string;\n /** The property publishes to its channels. A new hotel is put on the channel manager when its billing starts, usually before this answer; while it is false, PUT /catalog/room-types with the same refs tries again. Always true for a sandbox */\n channelManager: boolean;\n /** true when a test key made it: everything lands locally, nothing reaches a channel and nothing is billed */\n sandbox: boolean;\n billing: {\n /** ACTIVE: its billing has started, it is on your next monthly invoice · WAITING: the hotel is live, its billing has not started yet · NOT_BILLED: a sandbox */\n state: \"ACTIVE\" | \"WAITING\" | \"NOT_BILLED\";\n /** Why billing waits; null otherwise. SETUP: your billing setup is not complete · OVERDUE: one of your invoices is overdue · UNPAID_LIMIT: you have added as many hotels as you may before your first paid invoice · REVIEW: ZimmerStack starts it */\n reason: \"SETUP\" | \"OVERDUE\" | \"UNPAID_LIMIT\" | \"REVIEW\" | null;\n /** The same in one sentence, with what to do next; may change, branch on state and reason */\n message: string;\n };\n /** true: an earlier request with this X-Idempotency-Key already added this hotel; nothing new was made */\n replay: boolean;\n}",
|
|
7263
|
+
"PropertyChange": "export interface PropertyChange {\n /** The hotel's new name, as its guests know it. A sandbox's name keeps its ending, (sandbox) */\n name?: string;\n /** Only the parts you send change. The country is not one of them: it never changes by this request */\n address?: {\n /** The first line of the address */\n line1?: string;\n city?: string;\n /** An empty string clears it */\n state?: string;\n /** An empty string clears it */\n postalCode?: string;\n };\n}",
|
|
7264
|
+
"PropertyChanged": "export interface PropertyChanged {\n id: number;\n /** As stored now. A sandbox's name ends in (sandbox) */\n name: string;\n timezone: string;\n currency: string;\n /** The property publishes to its channels. Not changed by this request */\n channelManager: boolean;\n sandbox: boolean;\n /** The hotel's address as stored now. A part the record does not hold is null */\n address: {\n line1: string | null;\n city: string | null;\n state: string | null;\n postalCode: string | null;\n /** ISO 3166-1 alpha-2. Never changed by this request */\n country: string | null;\n };\n /** The fields whose stored value this request changed, by the names you send (name, address.line1, address.city, address.state, address.postalCode). Empty when everything you sent was already stored */\n changed: Array<string>;\n}",
|
|
6020
7265
|
"PropertyRemoved": "export interface PropertyRemoved {\n id: number;\n /** The hotel's name; null only for a sandbox removed before its name was recorded */\n name: string | null;\n removed: true;\n /** true: it was already removed before this request; the rest of the answer is where it stands now */\n replay: boolean;\n sandbox: boolean;\n /** Nobody signs in to the hotel's account any more and no key reaches it */\n access: \"CLOSED\";\n billing: {\n /** CANCELLED: the hotel's subscription is cancelled · NOT_BILLED: a sandbox, never billed */\n state: \"CANCELLED\" | \"NOT_BILLED\";\n /** ISO 8601 instant the subscription was cancelled; null for a sandbox */\n cancelledAt: string | null;\n };\n channelManager: {\n /** REMOVED: its channel connections, rate plans, room types and listing are gone from the channel manager · RETRYING: a step is still pending; ZimmerStack retries it and nothing is needed from you · NOT_CONNECTED: it was never on the channel manager */\n state: \"REMOVED\" | \"RETRYING\" | \"NOT_CONNECTED\";\n /** While RETRYING, the step that is pending, in the order they run: the channel connections, then the rate plans, then the room types, then the property. null otherwise, and on a replay */\n step: \"CHANNELS\" | \"RATE_PLANS\" | \"ROOM_TYPES\" | \"PROPERTY\" | null;\n /** While RETRYING, what was still on the channel manager when this request ended; null otherwise, and on a replay */\n stillConnected: {\n channels: number;\n ratePlans: number | null;\n roomTypes: number | null;\n property: boolean;\n } | null;\n };\n}",
|
|
6021
7266
|
"RoomTypesUpsert": "export interface RoomTypesUpsert {\n /** Each ref once per request */\n roomTypes: Array<{\n /** Your own id for this entity: the upsert key, stable across sends (1–64 of A–Z a–z 0–9 . _ : -) */\n ref: string;\n /** Shown to the owner and sent to the channel manager as the title */\n name: string;\n /** Sellable rooms of this type. On a channel-manager-only hotel a later change is written too, to the channel manager first; a count below the rooms holding upcoming stays is refused. The count does not cap a night: an availability above it is accepted with a warning, reaches the booking sites, and is what a price by rooms counts for that month. On a hotel that runs our PMS the count comes from its room list and a different value is not written (the answer's notice says so) */\n roomCount: number;\n /** Most adults one room takes */\n adults: number;\n /** Most children one room takes; default 0 */\n children?: number;\n }>;\n}",
|
|
6022
|
-
"RatePlansUpsert": "export interface RatePlansUpsert {\n /** Each ref once per request */\n ratePlans: Array<{\n /** Your own id for this entity: the upsert key, stable across sends (1–64 of A–Z a–z 0–9 . _ : -) */\n ref: string;\n /** The room type this plan sells (GET /catalog); or name it by roomTypeRef */\n roomTypeId?: number;\n /** The room type by the ref you gave it, in this request or an earlier one */\n roomTypeRef?: string;\n /** Shown to the owner and sent to the channel manager as the title */\n name: string;\n /** EP room only · CP breakfast · MAP half board · AP full board; null = not set */\n mealPlan?: \"EP\" | \"CP\" | \"MAP\" | \"AP\" | null;\n /** The occupancy this plan is priced for; null = the room type's default */\n occupancy?: number | null;\n /** false = a non-refundable plan; default true */\n refundable?: boolean;\n /** The plan's standing price in MAJOR units, a number or a decimal string (4500 or \"4500.50\"), like every rate here: what
|
|
7267
|
+
"RatePlansUpsert": "export interface RatePlansUpsert {\n /** Each ref once per request */\n ratePlans: Array<{\n /** Your own id for this entity: the upsert key, stable across sends (1–64 of A–Z a–z 0–9 . _ : -) */\n ref: string;\n /** The room type this plan sells (GET /catalog); or name it by roomTypeRef */\n roomTypeId?: number;\n /** The room type by the ref you gave it, in this request or an earlier one */\n roomTypeRef?: string;\n /** Shown to the owner and sent to the channel manager as the title */\n name: string;\n /** EP room only · CP breakfast · MAP half board · AP full board; null = not set */\n mealPlan?: \"EP\" | \"CP\" | \"MAP\" | \"AP\" | null;\n /** The occupancy this plan is priced for; null = the room type's default */\n occupancy?: number | null;\n /** false = a non-refundable plan; default true */\n refundable?: boolean;\n /** The plan's standing price in MAJOR units, a number or a decimal string (4500 or \"4500.50\"), like every rate here: what every date of the plan opens for booking at, mirrored to the channel manager. REQUIRED when the plan is new: a request that would create a plan without it is 400 VALIDATION and writes nothing. On a plan you already sent, omit it to leave the price as it is. null (follow the room type's base rate) is accepted only where the hotel has typed a base rate in ZimmerStack, and is 400 VALIDATION otherwise. Kept to the currency's own decimals (§2.10) */\n defaultRate?: number | string | null;\n /** Deprecated: the same standing price in hundredths of the major unit (450050 is 4500.50). Send defaultRate instead; never both */\n defaultRateMinor?: number | null;\n }>;\n}",
|
|
6023
7268
|
"CatalogUpsertResult": "export interface CatalogUpsertResult {\n /** One per entity sent, in the order sent */\n items: Array<{\n ref: string;\n /** The ZimmerStack id: what every availability, rate and booking write names from now on */\n id: number;\n /** created: new here and on the channel manager · updated: fields changed · adopted: an entity the owner had already made with this name is now yours by ref · unchanged: nothing differed */\n action: \"created\" | \"updated\" | \"adopted\" | \"unchanged\";\n /** IN_SYNC the channel manager has it · PENDING / SENDING on its way · FAILED stopped retrying (the owner's screen offers Retry) · DRIFTED someone changed it inside the channel manager · NOT_LINKED saved here, never added there · DISABLED the property is not connected */\n sync: \"IN_SYNC\" | \"PENDING\" | \"SENDING\" | \"FAILED\" | \"DRIFTED\" | \"NOT_LINKED\" | \"DISABLED\";\n /** Saved, but something to know (for example the property is not on the channel manager yet); null when nothing */\n notice: string | null;\n }>;\n /** Where the property stands after this write; a sandbox always says enabled */\n channelManager: {\n /** The property publishes to its channels */\n enabled: boolean;\n /** Why not, when enabled is false (for example: a room type still has no rate plan) */\n reason: string | null;\n };\n /** Standing prices this request sent that could not be kept exactly as sent, each with what was kept and why (§2.10). Absent when every price was kept as sent */\n rounded?: Array<{\n /** Where in the request the amount sat, for example \"updates[3].rate\" */\n field: string;\n /** The amount as it was sent */\n sent: string;\n /** The amount as it is kept, in major units with the currency's own decimals */\n kept: string;\n /** Why, in a sentence; may change, do not branch on it */\n reason: string;\n }>;\n}",
|
|
6024
7269
|
"CatalogDeleteResult": "export interface CatalogDeleteResult {\n id: number;\n deleted: true;\n /** The channel manager's copy is gone too (a sandbox has none) */\n channelManagerDeleted: boolean;\n /** For a room type: the plans that went with it */\n deletedRatePlanIds: Array<number>;\n}",
|
|
6025
7270
|
"RangeQuery": "export interface RangeQuery {\n /** default: today in the property's timezone */\n from?: string;\n /** default: from + 30 days; at most 500 days after from */\n to?: string;\n}",
|
|
6026
7271
|
"AvailabilityRead": "export interface AvailabilityRead {\n /** Hotel-local calendar date, YYYY-MM-DD */\n from: string;\n /** Hotel-local calendar date, YYYY-MM-DD */\n to: string;\n cells: Array<{\n roomTypeId: number;\n /** Hotel-local calendar date, YYYY-MM-DD */\n date: string;\n available: number;\n }>;\n}",
|
|
6027
7272
|
"AvailabilityWrite": "export interface AvailabilityWrite {\n updates: Array<{\n /** ZimmerStack room type id (GET /catalog) */\n roomTypeId: number;\n /** Hotel-local calendar date, YYYY-MM-DD */\n dateFrom: string;\n /** Hotel-local calendar date, YYYY-MM-DD */\n dateTo: string;\n /** ABSOLUTE count of rooms of this type for sale on each night of the range */\n available: number;\n }>;\n /** true: decide everything a real write decides (what would change, what is unchanged, what is held, what would be refused, the notices) and write nothing. Answers 200 with the preview instead of 202. Default false */\n dryRun?: boolean;\n}",
|
|
6028
7273
|
"RatesRead": "export interface RatesRead {\n /** Hotel-local calendar date, YYYY-MM-DD */\n from: string;\n /** Hotel-local calendar date, YYYY-MM-DD */\n to: string;\n /** ISO 4217: the property's currency, the one every rate here is in */\n currency: string;\n /** Digits after the decimal point this currency's prices carry (ISO 4217): 2, 0 or 3 (§2.10) */\n decimals?: number;\n cells: Array<{\n ratePlanId: number;\n /** Hotel-local calendar date, YYYY-MM-DD */\n date: string;\n /** The price in MAJOR units, as a decimal string with the currency's own decimals: \"4500.50\" in rupees, \"4500\" in yen. The same value PUT /rates takes */\n rate?: string;\n /** The same price in HUNDREDTHS of the major unit (450050 is 4500.50), for every currency. That is the ISO 4217 minor unit only where the currency has two decimals: prefer rate */\n rateMinor: number;\n source: \"MANUAL\" | \"BASE\" | \"ENGINE\" | \"CHANNEX_SEED\" | \"PLAN_DEFAULT\" | \"STANDING\";\n }>;\n}",
|
|
6029
|
-
"RatesWrite": "export interface RatesWrite {\n updates: Array<{\n /** ZimmerStack rate plan id (GET /catalog) */\n ratePlanId: number;\n /** Hotel-local calendar date, YYYY-MM-DD */\n dateFrom: string;\n /** Hotel-local calendar date, YYYY-MM-DD */\n dateTo: string;\n days?: Array<\"mo\" | \"tu\" | \"we\" | \"th\" | \"fr\" | \"sa\" | \"su\">;\n /** Nightly sell price in MAJOR units, a number or a decimal string (4500, 4500.5 or \"4500.50\"), 1 to 21474836. Kept exactly, to the currency's own decimals (GET /property decimals): two for rupees, euros and dollars, none for yen. A
|
|
7274
|
+
"RatesWrite": "export interface RatesWrite {\n updates: Array<{\n /** ZimmerStack rate plan id (GET /catalog) */\n ratePlanId: number;\n /** Hotel-local calendar date, YYYY-MM-DD */\n dateFrom: string;\n /** Hotel-local calendar date, YYYY-MM-DD */\n dateTo: string;\n days?: Array<\"mo\" | \"tu\" | \"we\" | \"th\" | \"fr\" | \"sa\" | \"su\">;\n /** Nightly sell price in MAJOR units, a number or a decimal string (4500, 4500.5 or \"4500.50\"), 1 to 21474836. Kept exactly, to the currency's own decimals (GET /property decimals): two for rupees, euros and dollars, none for yen. A number with more decimals than the currency has is rounded to them and named in the answer's rounded list; so is a fraction in a currency that has none. A decimal string takes at most two decimals: one with more is refused (400 VALIDATION) */\n rate: number | string;\n /** ISO 4217; must equal the property's currency (GET /property) */\n currency: string;\n }>;\n /** true: decide everything a real write decides (what would change, what is unchanged, what is held, what would be refused, the notices) and write nothing. Answers 200 with the preview instead of 202. Default false */\n dryRun?: boolean;\n}",
|
|
6030
7275
|
"RestrictionsRead": "export interface RestrictionsRead {\n /** Hotel-local calendar date, YYYY-MM-DD */\n from: string;\n /** Hotel-local calendar date, YYYY-MM-DD */\n to: string;\n cells: Array<{\n ratePlanId: number;\n /** Hotel-local calendar date, YYYY-MM-DD */\n date: string;\n stopSell: boolean | null;\n closedToArrival: boolean | null;\n closedToDeparture: boolean | null;\n minStayArrival: number | null;\n minStayThrough: number | null;\n maxStay: number | null;\n }>;\n}",
|
|
6031
7276
|
"RestrictionsWrite": "export interface RestrictionsWrite {\n updates: Array<{\n /** ZimmerStack rate plan id (GET /catalog) */\n ratePlanId: number;\n /** Hotel-local calendar date, YYYY-MM-DD */\n dateFrom: string;\n /** Hotel-local calendar date, YYYY-MM-DD */\n dateTo: string;\n days?: Array<\"mo\" | \"tu\" | \"we\" | \"th\" | \"fr\" | \"sa\" | \"su\">;\n stopSell?: boolean;\n closedToArrival?: boolean;\n closedToDeparture?: boolean;\n minStayArrival?: number;\n minStayThrough?: number;\n maxStay?: number;\n }>;\n /** true: decide everything a real write decides (what would change, what is unchanged, what is held, what would be refused, the notices) and write nothing. Answers 200 with the preview instead of 202. Default false */\n dryRun?: boolean;\n}",
|
|
6032
7277
|
"WriteAccepted": "export interface WriteAccepted {\n batchId: string;\n resource: \"availability\" | \"rates\" | \"restrictions\";\n /** distinct cells after per-request coalescing (last write wins) */\n requestedCells: number;\n /** cells that differed from our record and were written; they will be pushed */\n acceptedCells: number;\n /** cells that already held the requested value; nothing written, nothing pushed */\n noopCells: number;\n /** groups our record refused (e.g. a plan whose policy forbids exceptions) */\n rejected: Array<{\n cells: number;\n error: string;\n }>;\n pushedBy: \"inventory-drain\" | \"ari-projector\";\n /** GET path to watch this batch land */\n poll: string;\n /** Accepted, but worth a look: an availability above the room type's room count (an oversell the channels will sell). Absent when there is nothing to say */\n warnings?: Array<{\n roomTypeId: number;\n /** Rooms of this type in our record */\n units: number;\n /** The highest count this request set for it */\n requested: number;\n message: string;\n }>;\n /** Accepted, but far outside the plan's standing price, on a property whose price band only warns (§6.6). At most 20; absent when there is nothing to say */\n priceWarnings?: Array<{\n ratePlanId: number;\n /** Hotel-local calendar date, YYYY-MM-DD */\n date: string;\n /** The price this request set, in hundredths of the major unit */\n rateMinor: number;\n /** The plan's standing price, in hundredths of the major unit */\n standingMinor: number;\n /** The same price in major units, as a decimal string (\"4500.50\") */\n rate?: string;\n /** The plan's standing price in major units, as a decimal string */\n standing?: string;\n message: string;\n }>;\n /** Prices this request sent that could not be kept exactly as sent, each with what was kept and why (§2.10): more decimals than the currency has, or a fraction in a currency that has none. At most 20; absent when every price was kept as sent */\n rounded?: Array<{\n /** Where in the request the amount sat, for example \"updates[3].rate\" */\n field: string;\n /** The amount as it was sent */\n sent: string;\n /** The amount as it is kept, in major units with the currency's own decimals */\n kept: string;\n /** Why, in a sentence; may change, do not branch on it */\n reason: string;\n }>;\n /** How many of the request's prices were rounded in all; present with rounded */\n roundedCount?: number;\n /** true when the write was taken through the safety lane: the integration is paused or over a budget, and this write only closed inventory (§6.6) */\n lane?: boolean;\n /** true on PUT /rates and PUT /restrictions for a hotel that is not live yet (§2.15): the values are in our record and are pushed when the hotel goes live (POST /go-live), not before. Absent on a live hotel, and on PUT /availability: a room count is sent at once, live or not */\n heldUntilGoLive?: boolean;\n /** What this write did not do, or will not go on doing, one plain sentence each with a stable code and what to do (§2.20). Warnings first. At most 20; absent when there is nothing to say */\n notices?: Array<{\n /** Stable: branch on it. A code you do not know is a notice added later; show its message */\n code: \"NOT_SOURCE_OF_TRUTH\" | \"ROOM_TYPE_NOT_LINKED\" | \"PLAN_NOT_LINKED\" | \"PLAN_NOT_MAPPED\" | \"ROOM_STILL_ON_SALE\" | \"OTA_LINKED_RATES_NOT_REACHED\" | \"STAY_RULES_FROM_ANOTHER_PLAN\" | \"PER_OTA_PLANS_FOLLOW\" | \"PER_OTA_PLAN_FOLLOWS_PARENT\" | \"VALUE_HELD\" | \"COUNT_WAS_REFUSED\" | \"COUNT_ZERO_IS_NOT_STOP_SELL\" | \"STOP_SELL_IS_NOT_A_COUNT\" | \"COUNT_OPEN_BUT_PLANS_STOPPED\" | \"NEW_DATES_OPEN_CLOSED\" | \"FAR_NIGHTS_NEED_A_COUNT\" | \"ENGINE_WILL_REPRICE\" | \"ENGINE_WILL_RECOUNT\" | \"DRIFT_REPAIR_OFF\";\n /** warning: our record shows what you sent does not do the whole job (something still sells, nothing is sent, a rule will undo it) · info: how it works, said so the next surprise is not one */\n level: \"warning\" | \"info\";\n /** What is going on, in a sentence a person can read; may change, do not branch on it */\n message: string;\n /** What to do about it, naming the call */\n action: string;\n /** The room type it is about */\n roomTypeId?: number;\n /** The rate plans it is about (the ones you wrote) */\n ratePlanIds?: Array<number>;\n /** Other plans it names: the ones still selling, the plan that carries the star, the per-OTA plans */\n otherRatePlanIds?: Array<number>;\n /** The connected channels it is about */\n channels?: Array<{\n channelId: string;\n /** BookingCom, Expedia, Agoda, Goibibo, AirBNB, … */\n kind: string;\n }>;\n /** The first night it is about */\n dateFrom?: string;\n /** The last night it is about */\n dateTo?: string;\n /** How many nights between dateFrom and dateTo it is about (they need not be consecutive) */\n nights?: number;\n }>;\n /** How many more notices there were past the 20 listed; present only when some were left out */\n noticesOmitted?: number;\n}",
|
|
@@ -6067,7 +7312,7 @@ export const REFERENCE = {
|
|
|
6067
7312
|
"WebhookRecoverResult": "export interface WebhookRecoverResult {\n /** Failed deliveries queued again */\n reset: number;\n /** Events that had no delivery and now have one */\n created: number;\n scanned: number;\n /** More events than one run queues: run it again for the rest */\n truncated: boolean;\n}",
|
|
6068
7313
|
"WebhookDeliveryList": "export interface WebhookDeliveryList {\n items: Array<{\n id: string;\n eventId: string;\n eventType: string;\n mode: \"LIVE\" | \"TEST\";\n status: \"PENDING\" | \"DELIVERED\" | \"FAILED\";\n attempts: number;\n nextAttemptAt: string;\n lastError: string | null;\n occurredAt: string;\n deliveredAt: string | null;\n createdAt: string;\n payloadBytes: number;\n /** false once the stored body has been dropped (14 days); a redeliver rebuilds it from the event while that is kept (90 days) */\n payloadAvailable: boolean;\n }>;\n nextCursor: string | null;\n}",
|
|
6069
7314
|
"WebhookDelivery": "export interface WebhookDelivery {\n id: string;\n eventId: string;\n eventType: string;\n mode: \"LIVE\" | \"TEST\";\n status: \"PENDING\" | \"DELIVERED\" | \"FAILED\";\n attempts: number;\n nextAttemptAt: string;\n lastError: string | null;\n occurredAt: string;\n deliveredAt: string | null;\n createdAt: string;\n payloadBytes: number;\n /** false once the stored body has been dropped (14 days); a redeliver rebuilds it from the event while that is kept (90 days) */\n payloadAvailable: boolean;\n}",
|
|
6070
|
-
"WebhookDeliveryDetail": "export interface WebhookDeliveryDetail {\n id: string;\n eventId: string;\n eventType: string;\n mode: \"LIVE\" | \"TEST\";\n status: \"PENDING\" | \"DELIVERED\" | \"FAILED\";\n attempts: number;\n nextAttemptAt: string;\n lastError: string | null;\n occurredAt: string;\n deliveredAt: string | null;\n createdAt: string;\n payloadBytes: number;\n /** false once the stored body has been dropped (14 days); a redeliver rebuilds it from the event while that is kept (90 days) */\n payloadAvailable: boolean;\n /** The event as it was sent (the webhook's envelope); null once the stored body has been dropped (payloadAvailable: false) */\n payload: unknown;\n /** Every attempt, oldest first */\n attempts_log: Array<{\n id: string;\n /** 1 for the first send, one more for each retry */\n attemptNo: number;\n startedAt: string;\n durationMs: number;\n /** SUCCESS, HTTP_ERROR, TIMEOUT, CONNECTION_ERROR, TLS_ERROR or BLOCKED_URL; more may come */\n outcome: string;\n /** The HTTP status your receiver answered; null when it never answered */\n responseStatus: number | null;\n /** The first 2 KB of what your receiver answered */\n responseBodySnippet: string | null;\n errorMessage: string | null;\n /** The address your URL resolved to for this attempt */\n resolvedIp: string | null;\n }>;\n request: {\n /** The headers the delivery carried; the timestamp and the signature are shown as placeholders */\n headers: Record<string, string>;\n };\n}",
|
|
7315
|
+
"WebhookDeliveryDetail": "export interface WebhookDeliveryDetail {\n id: string;\n eventId: string;\n eventType: string;\n mode: \"LIVE\" | \"TEST\";\n status: \"PENDING\" | \"DELIVERED\" | \"FAILED\";\n attempts: number;\n nextAttemptAt: string;\n lastError: string | null;\n occurredAt: string;\n deliveredAt: string | null;\n createdAt: string;\n payloadBytes: number;\n /** false once the stored body has been dropped (14 days); a redeliver rebuilds it from the event while that is kept (90 days) */\n payloadAvailable: boolean;\n /** The event as it was sent (the webhook's envelope), with a guest's phone and email masked in this read; null once the stored body has been dropped (payloadAvailable: false) */\n payload: unknown;\n /** Every attempt, oldest first */\n attempts_log: Array<{\n id: string;\n /** 1 for the first send, one more for each retry */\n attemptNo: number;\n startedAt: string;\n durationMs: number;\n /** SUCCESS, HTTP_ERROR, TIMEOUT, CONNECTION_ERROR, TLS_ERROR or BLOCKED_URL; more may come */\n outcome: string;\n /** The HTTP status your receiver answered; null when it never answered */\n responseStatus: number | null;\n /** The first 2 KB of what your receiver answered */\n responseBodySnippet: string | null;\n errorMessage: string | null;\n /** The address your URL resolved to for this attempt */\n resolvedIp: string | null;\n }>;\n request: {\n /** The headers the delivery carried; the timestamp and the signature are shown as placeholders */\n headers: Record<string, string>;\n };\n}",
|
|
6071
7316
|
"WebhookEndpointResumed": "export interface WebhookEndpointResumed {\n id: number;\n /** live: the events of the hotels you may act on · test: your sandboxes'. A key manages the endpoints of its own mode */\n mode: \"live\" | \"test\";\n url: string;\n description: string | null;\n apiVersion: string;\n eventTypes: Array<string>;\n includeGuestContact: boolean;\n status: \"ACTIVE\" | \"PAUSED\" | \"SUSPENDED\";\n statusReason: string | null;\n secretVersion: number;\n /** While set, deliveries are also signed with the secret before the last rotation */\n previousSecretExpiresAt: string | null;\n notifyEmail: string | null;\n createdAt: string;\n updatedAt: string;\n /** When it was last paused or suspended: where a recover usually starts */\n lastStoppedAt: string | null;\n health: {\n state: \"healthy\" | \"failing\" | \"paused\" | \"suspended\";\n consecutiveFailures: number;\n failingSince: string | null;\n lastSuccessAt: string | null;\n lastFailureAt: string | null;\n lastErrorMessage: string | null;\n };\n /** How many events the pause held; they are being sent now, oldest first */\n heldEvents: number;\n}",
|
|
6072
7317
|
"WebhookEndpointDeleted": "export interface WebhookEndpointDeleted {\n id: number;\n deleted: true;\n}",
|
|
6073
7318
|
"WebhookTestQueued": "export interface WebhookTestQueued {\n /** The delivery in the log: GET /webhook-endpoints/{endpointId}/deliveries/{deliveryId} says what your receiver answered */\n deliveryId: string;\n eventId: string;\n /** The type that was sent */\n eventType: string;\n}",
|
|
@@ -6087,7 +7332,7 @@ export const REFERENCE = {
|
|
|
6087
7332
|
"ConnectLink": "export interface ConnectLink {\n /** The link's id: what the reads, the revoke and the webhook name it by. Never its token */\n id: string;\n propertyId: number;\n /** Our key of the booking site */\n channel: string;\n /** Its name as a person reads it */\n channelName: string;\n /** pending: made, not opened · opened: someone is on the page · completed: Start selling was pressed · expired: it ran out first · revoked: you withdrew it, or a newer link replaced it */\n status: \"pending\" | \"opened\" | \"completed\" | \"expired\" | \"revoked\";\n createdAt: string;\n /** The link opens until this instant */\n expiresAt: string;\n openedAt: string | null;\n /** When the page saved the connection (paused until Start selling) */\n connectedAt: string | null;\n completedAt: string | null;\n revokedAt: string | null;\n /** The connection, as GET /channels lists it, once the page saved one */\n channelId: string | null;\n reference: string | null;\n returnUrl: string | null;\n /** The company key that made the link: named on the hotel's activity log beside everything the link does */\n createdByKey: {\n id: number;\n name: string;\n maskedKey: string;\n };\n}",
|
|
6088
7333
|
"ConnectLinkList": "export interface ConnectLinkList {\n items: Array<{\n /** The link's id: what the reads, the revoke and the webhook name it by. Never its token */\n id: string;\n propertyId: number;\n /** Our key of the booking site */\n channel: string;\n /** Its name as a person reads it */\n channelName: string;\n /** pending: made, not opened · opened: someone is on the page · completed: Start selling was pressed · expired: it ran out first · revoked: you withdrew it, or a newer link replaced it */\n status: \"pending\" | \"opened\" | \"completed\" | \"expired\" | \"revoked\";\n createdAt: string;\n /** The link opens until this instant */\n expiresAt: string;\n openedAt: string | null;\n /** When the page saved the connection (paused until Start selling) */\n connectedAt: string | null;\n completedAt: string | null;\n revokedAt: string | null;\n /** The connection, as GET /channels lists it, once the page saved one */\n channelId: string | null;\n reference: string | null;\n returnUrl: string | null;\n /** The company key that made the link: named on the hotel's activity log beside everything the link does */\n createdByKey: {\n id: number;\n name: string;\n maskedKey: string;\n };\n }>;\n}",
|
|
6089
7334
|
"ConnectLinkCreate": "export interface ConnectLinkCreate {\n /** The hotel, by its id from GET /properties */\n propertyId: number;\n /** The booking site to connect: one link connects one */\n channel: \"bookingcom\" | \"gommt\" | \"agoda\" | \"expedia\" | \"tripcom\" | \"yatra\" | \"hostelworld\" | \"airbnb\";\n /** How long the link opens for, 1 to 168 hours; default 72 */\n expiresInHours?: number;\n /** Your own reference for this link; answered back by the reads, never shown to the hotel */\n reference?: string;\n /** Where the page offers to send the person when it is done (your own screen); https only */\n returnUrl?: string;\n}",
|
|
6090
|
-
"ConnectLinkCreated": "export interface ConnectLinkCreated {\n link: {\n /** The link's id: what the reads, the revoke and the webhook name it by. Never its token */\n id: string;\n propertyId: number;\n /** Our key of the booking site */\n channel: string;\n /** Its name as a person reads it */\n channelName: string;\n /** pending: made, not opened · opened: someone is on the page · completed: Start selling was pressed · expired: it ran out first · revoked: you withdrew it, or a newer link replaced it */\n status: \"pending\" | \"opened\" | \"completed\" | \"expired\" | \"revoked\";\n createdAt: string;\n /** The link opens until this instant */\n expiresAt: string;\n openedAt: string | null;\n /** When the page saved the connection (paused until Start selling) */\n connectedAt: string | null;\n completedAt: string | null;\n revokedAt: string | null;\n /** The connection, as GET /channels lists it, once the page saved one */\n channelId: string | null;\n reference: string | null;\n returnUrl: string | null;\n /** The company key that made the link: named on the hotel's activity log beside everything the link does */\n createdByKey: {\n id: number;\n name: string;\n maskedKey: string;\n };\n };\n /** The address to send to the hotel's own person. It opens ONCE and is in this answer only: we keep a hash of its token, never the token. null on a replay of the same request (X-Idempotent-Replay: true): we keep no copy to show again, so make a new link if the first answer was lost (it withdraws this one) */\n url: string | null;\n /** What the hotel does at the booking site before it opens the link, naming our connectivity partner as that booking site lists it.
|
|
7335
|
+
"ConnectLinkCreated": "export interface ConnectLinkCreated {\n link: {\n /** The link's id: what the reads, the revoke and the webhook name it by. Never its token */\n id: string;\n propertyId: number;\n /** Our key of the booking site */\n channel: string;\n /** Its name as a person reads it */\n channelName: string;\n /** pending: made, not opened · opened: someone is on the page · completed: Start selling was pressed · expired: it ran out first · revoked: you withdrew it, or a newer link replaced it */\n status: \"pending\" | \"opened\" | \"completed\" | \"expired\" | \"revoked\";\n createdAt: string;\n /** The link opens until this instant */\n expiresAt: string;\n openedAt: string | null;\n /** When the page saved the connection (paused until Start selling) */\n connectedAt: string | null;\n completedAt: string | null;\n revokedAt: string | null;\n /** The connection, as GET /channels lists it, once the page saved one */\n channelId: string | null;\n reference: string | null;\n returnUrl: string | null;\n /** The company key that made the link: named on the hotel's activity log beside everything the link does */\n createdByKey: {\n id: number;\n name: string;\n maskedKey: string;\n };\n };\n /** The address to send to the hotel's own person. It opens ONCE and is in this answer only: we keep a hash of its token, never the token. null on a replay of the same request (X-Idempotent-Replay: true): we keep no copy to show again, so make a new link if the first answer was lost (it withdraws this one) */\n url: string | null;\n /** What the hotel does at the booking site before it opens the link (in its extranet or through its support), naming our connectivity partner as that booking site lists it. Send it to the hotel first, and the url once the hotel has done it; null where there is no such step (Airbnb) */\n hotelStep: string | null;\n /** Earlier links for this hotel and booking site that nobody had opened, withdrawn by this one */\n withdrawn: number;\n}",
|
|
6091
7336
|
"Readiness": "export interface Readiness {\n propertyId: number;\n /** true: your software is already this hotel's source of truth; there is nothing to do */\n live: boolean;\n /** true: every check passed, so POST /go-live will switch it on (also true when live) */\n ready: boolean;\n /** The nights the checks looked at, in the hotel's calendar */\n nights: {\n from: string;\n to: string;\n count: number;\n };\n /** Which of the two ways nothing_stale passed: our record matches the channels, or your software sent the whole year first. null when it did not pass, or the hotel is already live */\n passedBy: \"record_matches\" | \"full_year_sent\" | null;\n checks: Array<{\n id: \"channel_manager\" | \"catalog_linked\" | \"prices_hold\" | \"nothing_stale\";\n passed: boolean;\n /** What we found, in a sentence */\n summary: string;\n /** What to do when it did not pass; null when it passed */\n action: string | null;\n /** The numbers behind the sentence */\n details?: Record<string, unknown>;\n }>;\n}",
|
|
6092
7337
|
"GoLiveResult": "export interface GoLiveResult {\n propertyId: number;\n live: true;\n /** true: the hotel was already live and nothing changed */\n replay: boolean;\n /** When this call switched it on; null on a replay */\n wentLiveAt: string | null;\n passedBy: \"record_matches\" | \"full_year_sent\" | null;\n /** What happens now, and what to send */\n next: Array<string>;\n}",
|
|
6093
7338
|
"HotelKey": "export interface HotelKey {\n id: number;\n propertyId: number;\n name: string;\n /** The key's first twelve characters: the only form it has after the answer that made it */\n maskedKey: string;\n mode: \"live\" | \"test\";\n status: \"ACTIVE\" | \"REVOKED\";\n scopes: Array<string>;\n allowedCidrs: Array<string>;\n createdAt: string;\n lastUsedAt: string | null;\n lastUsedIp: string | null;\n expiresAt: string | null;\n /** Set while a rotation's overlap runs: this key stops answering at this instant */\n retireAt: string | null;\n /** The key that replaced this one */\n rotatedToId: number | null;\n revokedAt: string | null;\n revokedReason: string | null;\n}",
|
|
@@ -6106,21 +7351,21 @@ export const REFERENCE = {
|
|
|
6106
7351
|
"SandboxFaultView": "export interface SandboxFaultView {\n /** A fault is in force on this sandbox's pretend channel */\n active: boolean;\n kind: \"refuse\" | \"throttle\" | \"outage\" | null;\n /** refuse: nights still to be refused */\n remaining: number | null;\n /** throttle, outage: when the pretend channel answers normally again (ISO 8601, UTC) */\n until: string | null;\n /** refuse: the pretend channel's words */\n message: string | null;\n setAt: string | null;\n /** What to do next and what your software should then see, step by step */\n watch: Array<string>;\n}"
|
|
6107
7352
|
},
|
|
6108
7353
|
"topics": {
|
|
6109
|
-
"keys": "## auth\nscheme: Authorization: Bearer zsk_live_… (zsk_test_… on a sandbox)\nkeyShape: zsk_live_ (or zsk_test_ on a sandbox) + 40 letters and digits + a 6-character checksum (the CRC32 of everything before it, in base 62), so a key can be told from a look-alike without asking us; a key minted before 22 Nov 2026 is zsk_live_ + 43 base64url characters and keeps working until it is rotated; shown once at creation; a hotel key = one property, a company key = a software vendor's hotels\nrotation: Every key can be rotated, company keys included: the new key is shown once and the old one keeps answering for 24 hours, then answers 401 API_KEY_REVOKED. A person rotates a hotel's own keys in ZimmerStack (Developers) and a partner's company keys in the partner portal (Developers); no API route does either. The keys a partner made on a hotel are rotated in the partner portal too, or by API with a company key that holds keys:manage (x-zimmerstack.hotelKeys).\nleaks: A key reported as found in a public place (for example by GitHub secret scanning in a public repository) is revoked at once and its holder is emailed: requests on it answer 401 API_KEY_REVOKED. Mint a new key and keep it in your server's settings, never in code.\nrequestLog: Every request made with a key is kept 7 days and read back with GET /requests: time, route, status, error code, address, duration and request id; never a body or a guest's data.\nnever:\n - query string\n - x-api-key\n - user-api-key\nexpiry: The owner may give a key an end of life (expiresAt); past it every request is 401 API_KEY_EXPIRED, like a revocation. A rotation keeps the life.\nscopes:\n - scope: ari:read · does: Read availability, rates, restrictions and sync state from our record\n - scope: ari:write · does: Set availability, rates and restrictions (pushed to every connected channel)\n - scope: catalog:write · does: Create and change room types and rate plans (created on the channel manager and mirrored there)\n - scope: channel-modifiers:write · does: Set a channel's price modifier: one change moves every price sent to that channel from then on\n - scope: channel-bookings:read · does: Read the OTA bookings the channel manager delivered to this property, in the webhook's shape\n - scope: direct-bookings:read · does: Read the bookings guests made on the hotel's own website (our booking engine), in the webhook's shape\n - scope: direct-bookings:cancel · does: Cancel a booking guests made on the hotel's own website and refund it: per the booking's policy, in full, or not at all\n - scope: bookings:read · does: Read bookings this key created\n - scope: bookings:write · does: Create and cancel bookings in the PMS (inventory updates and reaches the channels)\n - scope: bookings:payments · does: Record a payment on a booking it creates (needs bookings:write)\n - scope: properties:write · does: Add a hotel, and remove a hotel you added (a software partner's company key only)\n - scope: webhooks:manage · does: Manage your company webhook endpoints: create, change, pause, test, recover, redeliver and read deliveries (a software partner's company key only)\n - scope: channels:connect · does: Make one-time connect links: the hotel's own person connects one booking site on our hosted page (a software partner's company key only)\n - scope: keys:manage · does: List, mint, rotate and revoke the keys you made on a hotel; never a company key (a software partner's company key only)\n - scope: billing:read · does: Read your own invoices, what your next invoice is made of, money paid ahead and your property quota (a software partner's company key only; nothing here pays or changes anything)\n - scope: support:write · does: Open a support ticket, read your tickets, add a message and close one (a software partner's company key only)\nscopeRule: A key holds the scopes the owner granted at creation (editable later without rotating). Every route names the one scope it needs; a key without it is 403 SCOPE_MISSING. bookings:payments needs bookings:write. GET /property echoes this key's scopes.\nallowlist: Optional per key: up to 20 IPv4/IPv6 addresses or CIDR ranges. Set it to your servers' egress addresses: a request from anywhere else is 403 IP_NOT_ALLOWED, counts against the address's authentication budget, and is shown to the owner.\nwhichKey: Two kinds of key, one API. A HOTEL KEY is bound to one property: the property is implicit and needs no header (an X-ZS-Property naming another property is 404 PROPERTY_NOT_FOUND). A COMPANY KEY belongs to a software vendor and reaches every hotel the vendor may act on: name the hotel on every request with the X-ZS-Property header, its id from GET /properties. GET /properties says which kind you hold (keyKind). Routes, bodies and answers are the same for both.\ncompanyKey:\n header: X-ZS-Property: <property id from GET /properties>\n missingHeader: 400 PROPERTY_REQUIRED (the routes about your own company need no header and read none: GET /properties, POST /properties, DELETE /properties/{propertyId}, /properties/{propertyId}/keys, /webhook-endpoints, /connect-links, /billing, /support-tickets; GET /requests, GET /limits and GET /status answer for the company without it and for one hotel with it)\n notReachable: 404 PROPERTY_NOT_FOUND for a property the key may not act on, whether or not it exists\n reach: A live company key reaches the hotels the vendor enrolled and any hotel whose owner allowed the vendor (Integrations → Software vendors, by the vendor code); the owner can revoke that any time and the key stops reaching the hotel at once. A test company key reaches the vendor's own sandboxes only.\n scopes: The channel-manager scopes (ari:read, ari:write, catalog:write, channel-modifiers:write, channel-bookings:read, direct-bookings:read, direct-bookings:cancel) and the six scopes only a company key can hold, none ticked by default: properties:write (add and remove hotels), webhooks:manage (manage your company webhook endpoints, x-zimmerstack.webhookEndpoints), channels:connect (make one-time connect links, x-zimmerstack.connectLinks), keys:manage (the keys you made on a hotel, x-zimmerstack.hotelKeys), billing:read (read your own invoices and quota, x-zimmerstack.billing) and support:write (your own support tickets, x-zimmerstack.support). A hotel's PMS bookings (bookings:*) need that hotel's own key.\n properties: With properties:write a company key adds a hotel (POST /properties) and removes a hotel it added (DELETE /properties/{propertyId}): x-zimmerstack.properties. A key that holds only properties:write acts on no hotel (403 SCOPE_MISSING when it names one). In the partner portal a key with this scope is made by the account owner or an Admin, the people who may add a hotel there. Two more of the six are given only by someone who holds the matching power there: channels:connect by someone who may act for a hotel, billing:read by someone who may open the Billing page. Whoever may make a company key in Developers may give webhooks:manage, keys:manage and support:write.\n budgets: Each hotel keeps its own per-key and per-property budgets; the company key also has one budget across all its hotels (x-zimmerstack.limits.companyRequestsPerMinute).\n writes: An ARI write to a hotel whose local rates and availability are not the channels' source of truth is 409 ARI_NOT_AUTHORITATIVE (a hotel a vendor enrols is born the source of truth).\n minted: In the ZimmerStack partner portal (Developers), shown once, revoked there.\n webhooks: One company webhook endpoint (made in the partner portal, Developers, or by API with the webhooks:manage scope: /webhook-endpoints) receives the booking and sync events of every hotel a live company key reaches; each event names its hotel in property.id. A sandbox endpoint receives the vendor's sandbox. A pause holds events: they are kept (up to 90 days) and sent in order on resume. A suspension (72 hours of failures) drops them; Recover since (the portal, or POST /webhook-endpoints/{endpointId}/recover) replays them, for a hotels endpoint only from hotels that allowed the vendor when the event happened and still do.\n\n",
|
|
6110
|
-
"money-and-dates": "## dates\nYYYY-MM-DD, calendar dates in the property's timezone (GET /property); a stay occupies [checkIn, checkOut) — the checkout day is not a night\n\n## money\none shape both ways: an amount is SENT and RETURNED in major units with the property's currency, as a number or a decimal string with the currency's own decimals (rate \"4500.50\"), beside currency and decimals; rateMinor stays, in hundredths of the major unit (x-zimmerstack.moneyByCurrency)\n\n## moneyByCurrency\nunits: ISO 4217 gives every currency a MAJOR unit (the rupee, the euro, the yen) and a MINOR unit, with 0, 2 or 3 decimals between them. Amounts here are major units. Every field named …Minor is one HUNDREDTH of the major unit in EVERY currency, which is the ISO minor unit only where the currency has two decimals: a rate of 15000 yen reads rateMinor 1500000, a rate of 1850000 rupiah reads 185000000. Divide by 100, always; or read the decimal string beside it (rate), which needs no arithmetic.\ndecimals: What your software sends is kept exactly, to the currency's own decimals (GET /property decimals): 4500.50 rupees is stored and returned as 4500.50, 89.50 euros as 89.50. A currency without decimals (yen, dong) is whole: a price sent with a fraction is rounded and named in the answer's rounded list. A price with more decimals than the currency has
|
|
6111
|
-
"samplesByPlace": "## samplesByPlace\nlisbon:\n about: A guest house in Lisbon. It sells in euros, so a price keeps its cents (89.50 stays 89.50), and it has confirmed Portugal's accommodation VAT, which sits inside its prices and is worked out night by night.\n property:\n id: 204\n name: Casa do Miradouro\n timezone: Europe/Lisbon\n currency: EUR\n catalog:\n currency: EUR\n roomTypes:\n - id: 731 · ref: rt-double · name: Double Room, River View · maxAdults: 2 · maxChildren: 1 · roomKind: room · sync: IN_SYNC\n ratePlans:\n - id: 1502 · ref: rp-bb · roomTypeId: 731 · name: Bed and breakfast · mealPlan: CP · occupancy: 2 · currency: EUR · refundable: true · sync: IN_SYNC\n ratesWrite:\n updates:\n - ratePlanId: 1502 · dateFrom: 2026-
|
|
7354
|
+
"keys": "## auth\nscheme: Authorization: Bearer zsk_live_… (zsk_test_… on a sandbox)\nkeyShape: zsk_live_ (or zsk_test_ on a sandbox) + 40 letters and digits + a 6-character checksum (the CRC32 of everything before it, in base 62), so a key can be told from a look-alike without asking us; a key minted before 22 Nov 2026 is zsk_live_ + 43 base64url characters and keeps working until it is rotated; shown once at creation; a hotel key = one property, a company key = a software vendor's hotels\nrotation: Every key can be rotated, company keys included: the new key is shown once and the old one keeps answering for 24 hours, then answers 401 API_KEY_REVOKED. A person rotates a hotel's own keys in ZimmerStack (Developers) and a partner's company keys in the partner portal (Developers); no API route does either. The keys a partner made on a hotel are rotated in the partner portal too, or by API with a company key that holds keys:manage (x-zimmerstack.hotelKeys).\nleaks: A key reported as found in a public place (for example by GitHub secret scanning in a public repository) is revoked at once and its holder is emailed: requests on it answer 401 API_KEY_REVOKED. Mint a new key and keep it in your server's settings, never in code.\nrequestLog: Every request made with a key is kept 7 days and read back with GET /requests: time, route, status, error code, address, duration and request id; never a body or a guest's data.\nnever:\n - query string\n - x-api-key\n - user-api-key\nexpiry: The owner may give a key an end of life (expiresAt); past it every request is 401 API_KEY_EXPIRED, like a revocation. A rotation keeps the life.\nscopes:\n - scope: ari:read · does: Read availability, rates, restrictions and sync state from our record\n - scope: ari:write · does: Set availability, rates and restrictions (pushed to every connected channel)\n - scope: catalog:write · does: Create and change room types and rate plans (created on the channel manager and mirrored there)\n - scope: channel-modifiers:write · does: Set a channel's price modifier: one change moves every price sent to that channel from then on\n - scope: channel-bookings:read · does: Read the OTA bookings the channel manager delivered to this property, in the webhook's shape\n - scope: direct-bookings:read · does: Read the bookings guests made on the hotel's own website (our booking engine), in the webhook's shape\n - scope: direct-bookings:cancel · does: Cancel a booking guests made on the hotel's own website and refund it: per the booking's policy, in full, or not at all\n - scope: bookings:read · does: Read bookings this key created\n - scope: bookings:write · does: Create and cancel bookings in the PMS (inventory updates and reaches the channels)\n - scope: bookings:payments · does: Record a payment on a booking it creates (needs bookings:write)\n - scope: properties:write · does: Add a hotel, and change or remove a hotel you added (a software partner's company key only)\n - scope: webhooks:manage · does: Manage your company webhook endpoints: create, change, pause, test, recover, redeliver and read deliveries (a software partner's company key only)\n - scope: channels:connect · does: Make one-time connect links: the hotel's own person connects one booking site on our hosted page (a software partner's company key only)\n - scope: keys:manage · does: List, mint, rotate and revoke the keys you made on a hotel; never a company key (a software partner's company key only)\n - scope: billing:read · does: Read your own invoices, what your next invoice is made of, money paid ahead and your property quota (a software partner's company key only; nothing here pays or changes anything)\n - scope: support:write · does: Open a support ticket, read your tickets, add a message and close one (a software partner's company key only)\nscopeRule: A key holds the scopes the owner granted at creation (editable later without rotating). Every route names the one scope it needs; a key without it is 403 SCOPE_MISSING. bookings:payments needs bookings:write. GET /property echoes this key's scopes.\nallowlist: Optional per key: up to 20 IPv4/IPv6 addresses or CIDR ranges. Set it to your servers' egress addresses: a request from anywhere else is 403 IP_NOT_ALLOWED, counts against the address's authentication budget, and is shown to the owner.\nwhichKey: Two kinds of key, one API. A HOTEL KEY is bound to one property: the property is implicit and needs no header (an X-ZS-Property naming another property is 404 PROPERTY_NOT_FOUND). A COMPANY KEY belongs to a software vendor and reaches every hotel the vendor may act on: name the hotel on every request with the X-ZS-Property header, its id from GET /properties. GET /properties says which kind you hold (keyKind). Routes, bodies and answers are the same for both.\ncompanyKey:\n header: X-ZS-Property: <property id from GET /properties>\n missingHeader: 400 PROPERTY_REQUIRED, whose data.details lists the first 20 hotels your key reaches (properties: id and name; total: how many there are), so you can pick one at once (the routes about your own company need no header and read none: GET /properties, POST /properties, PATCH /properties/{propertyId}, DELETE /properties/{propertyId}, /properties/{propertyId}/keys, /webhook-endpoints, /connect-links, /billing, /support-tickets; GET /requests, GET /limits and GET /status answer for the company without it and for one hotel with it)\n notReachable: 404 PROPERTY_NOT_FOUND for a property the key may not act on, whether or not it exists\n reach: A live company key reaches the hotels the vendor enrolled and any hotel whose owner allowed the vendor (Integrations → Software vendors, by the vendor code); the owner can revoke that any time and the key stops reaching the hotel at once. A test company key reaches the vendor's own sandboxes only.\n scopes: The channel-manager scopes (ari:read, ari:write, catalog:write, channel-modifiers:write, channel-bookings:read, direct-bookings:read, direct-bookings:cancel) and the six scopes only a company key can hold, none ticked by default: properties:write (add, change and remove hotels), webhooks:manage (manage your company webhook endpoints, x-zimmerstack.webhookEndpoints), channels:connect (make one-time connect links, x-zimmerstack.connectLinks), keys:manage (the keys you made on a hotel, x-zimmerstack.hotelKeys), billing:read (read your own invoices and quota, x-zimmerstack.billing) and support:write (your own support tickets, x-zimmerstack.support). A hotel's PMS bookings (bookings:*) need that hotel's own key.\n properties: With properties:write a company key adds a hotel (POST /properties), changes the name and address of a hotel it added (PATCH /properties/{propertyId}) and removes a hotel it added (DELETE /properties/{propertyId}): x-zimmerstack.properties. A key that holds only properties:write acts on no hotel (403 SCOPE_MISSING when it names one). In the partner portal a key with this scope is made by the account owner or an Admin, the people who may add a hotel there. Two more of the six are given only by someone who holds the matching power there: channels:connect by someone who may act for a hotel, billing:read by someone who may open the Billing page. Whoever may make a company key in Developers may give webhooks:manage, keys:manage and support:write.\n budgets: Each hotel keeps its own per-key and per-property budgets; the company key also has one budget across all its hotels (x-zimmerstack.limits.companyRequestsPerMinute).\n writes: An ARI write to a hotel whose local rates and availability are not the channels' source of truth is 409 ARI_NOT_AUTHORITATIVE (a hotel a vendor enrols is born the source of truth).\n minted: In the ZimmerStack partner portal (Developers), shown once, revoked there.\n webhooks: One company webhook endpoint (made in the partner portal, Developers, or by API with the webhooks:manage scope: /webhook-endpoints) receives the booking and sync events of every hotel a live company key reaches; each event names its hotel in property.id. A sandbox endpoint receives the vendor's sandbox. A pause holds events: they are kept (up to 90 days) and sent in order on resume. A suspension (72 hours of failures) drops them; Recover since (the portal, or POST /webhook-endpoints/{endpointId}/recover) replays them, for a hotels endpoint only from hotels that allowed the vendor when the event happened and still do.\n\n",
|
|
7355
|
+
"money-and-dates": "## dates\nYYYY-MM-DD, calendar dates in the property's timezone (GET /property); a stay occupies [checkIn, checkOut) — the checkout day is not a night\n\n## money\none shape both ways: an amount is SENT and RETURNED in major units with the property's currency, as a number or a decimal string with the currency's own decimals (rate \"4500.50\"), beside currency and decimals; rateMinor stays, in hundredths of the major unit (x-zimmerstack.moneyByCurrency)\n\n## moneyByCurrency\nunits: ISO 4217 gives every currency a MAJOR unit (the rupee, the euro, the yen) and a MINOR unit, with 0, 2 or 3 decimals between them. Amounts here are major units. Every field named …Minor is one HUNDREDTH of the major unit in EVERY currency, which is the ISO minor unit only where the currency has two decimals: a rate of 15000 yen reads rateMinor 1500000, a rate of 1850000 rupiah reads 185000000. Divide by 100, always; or read the decimal string beside it (rate), which needs no arithmetic.\ndecimals: What your software sends is kept exactly, to the currency's own decimals (GET /property decimals): 4500.50 rupees is stored and returned as 4500.50, 89.50 euros as 89.50. A currency without decimals (yen, dong) is whole: a price sent with a fraction (15000.5, or \"15000.50\") is rounded and named in the answer's rounded list. A price sent as a NUMBER with more decimals than the currency has (4500.505 in rupees) is rounded half up to them and named too. A price sent as a decimal STRING carries at most two decimals: one with three or more (\"4500.505\") is refused, 400 VALIDATION, and nothing is written. A currency with three decimals (the Gulf dinars) is kept as a whole amount for now, and the answer says so. Nothing is rounded silently. How a hotel keeps a price its own staff type on ZimmerStack's screens is the hotel's setting and never changes what you send.\ntable:\n - currency: INR · name: Indian rupee · decimals: 2 · send: 4500.50 · rate: 4500.50 · rateMinor: 450050 · isoMinorUnits: 450050 · note: rateMinor is the ISO minor unit here · example: INR 4500.50\n - currency: EUR · name: Euro · decimals: 2 · send: 89.50 · rate: 89.50 · rateMinor: 8950 · isoMinorUnits: 8950 · note: rateMinor is the ISO minor unit here · example: EUR 89.50\n - currency: USD · name: US dollar · decimals: 2 · send: 129.99 · rate: 129.99 · rateMinor: 12999 · isoMinorUnits: 12999 · note: rateMinor is the ISO minor unit here · example: USD 129.99\n - currency: IDR · name: Indonesian rupiah · decimals: 2 · send: 1850000 · rate: 1850000.00 · rateMinor: 185000000 · isoMinorUnits: 185000000 · note: rateMinor is the ISO minor unit here · example: IDR 1850000.00\n - currency: JPY · name: Japanese yen · decimals: 0 · send: 15000 · rate: 15000 · rateMinor: 1500000 · isoMinorUnits: null · note: rateMinor is hundredths, not the ISO minor unit: read rate · example: JPY 15000\n - currency: KWD · name: Kuwaiti dinar · decimals: 3 · send: 45.75 · rate: 46.000 · rateMinor: 4600 · isoMinorUnits: null · note: KWD prices cannot be kept to three decimal places yet, so the price is kept as a whole amount. · example: KWD 46.000\nlimits: A rate may be 1 to 21474836 in any currency. A rate plan's standing price and a modifier's fixed step are limited to 1000000 for a property selling in rupees, and to 21474836 for any other currency.\ntaxes: A hotel outside India that has confirmed its own tax lines gets them on a booking: POST /bookings reads nightlyRateIncludesTaxes. Default true: the rate is what the guest paid online; it is split into the lines and totalAmount does not move, except for a line the hotel collects at the property itself (a city tax per person a night), which is added and paid at the hotel. false: the rate is as the hotel sells it at its desk; lines the hotel adds on top are added, lines it keeps inside its prices stay inside. The booking answers carry taxes; always read totalAmount from the answer. A hotel in India, or one with no confirmed lines, has no taxes block and refuses false with TAXES_NOT_CONFIGURED; a hotel whose taxes all sit inside its prices refuses false with TAXES_INSIDE_RATES.\nchannelBookings: An OTA may send a booking in another currency than the property's. Nothing is converted: amounts.receivedCurrency names the currency the amounts are in, and is absent on every other booking. A booking's taxes block carries the hotel's own lines once it is assessed.\n\n## writes\nabsolute values, last write wins within a request, unchanged cells are dropped before anything is written\n\n## idempotency\nheader: x-idempotency-key\nretentionDays: 7\n\n",
|
|
7356
|
+
"samplesByPlace": "## samplesByPlace\nlisbon:\n about: A guest house in Lisbon. It sells in euros, so a price keeps its cents (89.50 stays 89.50), and it has confirmed Portugal's accommodation VAT, which sits inside its prices and is worked out night by night.\n property:\n id: 204\n name: Casa do Miradouro\n timezone: Europe/Lisbon\n currency: EUR\n catalog:\n currency: EUR\n roomTypes:\n - id: 731 · ref: rt-double · name: Double Room, River View · maxAdults: 2 · maxChildren: 1 · roomKind: room · sync: IN_SYNC\n ratePlans:\n - id: 1502 · ref: rp-bb · roomTypeId: 731 · name: Bed and breakfast · mealPlan: CP · occupancy: 2 · currency: EUR · refundable: true · sync: IN_SYNC\n ratesWrite:\n updates:\n - ratePlanId: 1502 · dateFrom: 2026-12-01 · dateTo: 2027-03-31 · rate: 89.50 · currency: EUR\n - ratePlanId: 1502 · dateFrom: 2026-12-01 · dateTo: 2027-03-31 · days: [\"fr\",\"sa\"] · rate: 112 · currency: EUR\n ratePlansUpsert:\n ratePlans:\n - ref: rp-bb · roomTypeRef: rt-double · name: Bed and breakfast · mealPlan: CP · occupancy: 2 · refundable: true · defaultRate: 89.50\n bookingCreate:\n externalReference: WEB-2026-LX-0412\n checkIn: 2026-12-20\n checkOut: 2026-12-23\n currency: EUR\n guest:\n name: Inês Carvalho\n phone: +351912345678\n email: ines@example.com\n notes: Arriving by train, around 21:00\n rooms:\n - roomTypeId: 731 · ratePlanId: 1502 · adults: 2 · nightlyRate: 89.50\n payment:\n amount: 89.50\n method: CARD\n reference: pay_LxQ81n4\n bookingView:\n bookingId: 61877\n reference: CM-4TQ8ZK2P\n externalReference: WEB-2026-LX-0412\n status: UPCOMING\n checkIn: 2026-12-20\n checkOut: 2026-12-23\n nights: 3\n currency: EUR\n totalAmount: 268.50\n totalPaid: 89.50\n balanceDue: 179.00\n guest:\n name: Inês Carvalho\n phone: +351912345678\n email: ines@example.com\n rooms:\n - bookingRoomId: 120441 · roomTypeId: 731 · ratePlanId: 1502 · mealPlan: CP · adults: 2 · children: 0 · nightlyRate: 89.50 · status: UPCOMING\n inventory:\n eventRecorded: true\n channelManager: true\n pushedBy: inventory-drain\n replay: false\n createdAt: 2026-11-17T10:02:44.118Z\n cancelledAt: null\n taxes:\n nightlyRateIncludesTaxes: true\n lines:\n - code: PT-VAT-ACCOMMODATION · name: VAT 6% · kind: TAX · includedInRate: true · amount: 15.21\n includedInRates: 15.21\n addedToTotal: 0.00\nbali:\n about: A villa in Ubud, Bali. It sells in rupiah: a nightly price is seven digits and has no cents in practice. It has confirmed a 10% service charge and the 10% hotel tax (PBJT) on the room plus service, both added on top, and its booking engine sends prices before taxes.\n property:\n id: 318\n name: Villa Sawah Ubud\n timezone: Asia/Makassar\n currency: IDR\n catalog:\n currency: IDR\n roomTypes:\n - id: 902 · ref: rt-villa · name: One-Bedroom Pool Villa · maxAdults: 2 · maxChildren: 1 · roomKind: room · sync: IN_SYNC\n ratePlans:\n - id: 2210 · ref: rp-ro · roomTypeId: 902 · name: Room only · mealPlan: EP · occupancy: 2 · currency: IDR · refundable: true · sync: IN_SYNC\n ratesWrite:\n updates:\n - ratePlanId: 2210 · dateFrom: 2026-12-01 · dateTo: 2027-03-31 · rate: 1850000 · currency: IDR\n - ratePlanId: 2210 · dateFrom: 2026-12-24 · dateTo: 2027-01-02 · rate: 2400000 · currency: IDR\n ratePlansUpsert:\n ratePlans:\n - ref: rp-ro · roomTypeRef: rt-villa · name: Room only · mealPlan: EP · occupancy: 2 · refundable: true · defaultRate: 1850000\n bookingCreate:\n externalReference: WEB-2026-UBD-0077\n checkIn: 2026-12-10\n checkOut: 2026-12-12\n currency: IDR\n nightlyRateIncludesTaxes: false\n guest:\n name: Made Wirawan\n phone: +6281234567890\n email: made@example.com\n rooms:\n - roomTypeId: 902 · ratePlanId: 2210 · adults: 2 · nightlyRate: 1850000\n bookingView:\n bookingId: 70312\n reference: CM-9HX3PW7N\n externalReference: WEB-2026-UBD-0077\n status: UPCOMING\n checkIn: 2026-12-10\n checkOut: 2026-12-12\n nights: 2\n currency: IDR\n totalAmount: 4477000.00\n totalPaid: 0.00\n balanceDue: 4477000.00\n guest:\n name: Made Wirawan\n phone: +6281234567890\n email: made@example.com\n rooms:\n - bookingRoomId: 131907 · roomTypeId: 902 · ratePlanId: 2210 · mealPlan: EP · adults: 2 · children: 0 · nightlyRate: 1850000.00 · status: UPCOMING\n inventory:\n eventRecorded: true\n channelManager: true\n pushedBy: inventory-drain\n replay: false\n createdAt: 2026-11-17T03:40:09.552Z\n cancelledAt: null\n taxes:\n nightlyRateIncludesTaxes: false\n lines:\n - code: SERVICE_CHARGE · name: Service charge 10% · kind: FEE · includedInRate: false · amount: 370000.00\n - code: ID-PBJT-PERHOTELAN · name: Hotel tax (PBJT) 10% · kind: TAX · includedInRate: false · amount: 407000.00\n includedInRates: 0.00\n addedToTotal: 777000.00\n\n",
|
|
6112
7357
|
"limits": "## limits\nrequestsPerMinute: 120\nwritesPerMinute: 30\npropertyRequestsPerMinute: 300\npropertyWritesPerMinute: 60\npropertyCellsPerMinute: 20000\nipRequestsPerMinute: 240\nipAuthFailuresPerMinute: 20\nkeyAuthFailuresPerMinute: 5\nglobalUnauthenticatedPerMinute: 1200\nglobalRequestsPerMinute: 3000\nmaxUpdatesPerRequest: 1000\nmaxCellsPerRequest: 5000\nmaxBodyBytes: 1048576\nhorizonDays: 500\nbookingsPerMinute: 20\npropertyBookingsPerMinute: 40\npropertyBookingsPerDay: 500\ndirectCancelsPerMinute: 10\npropertyDirectCancelsPerDay: 50\ncompanyRequestsPerMinute: 1200\nmaxNightsPerBooking: 90\n\n## rateLimits\nwindow: 60 s sliding, shared by every API machine; counters are exact, not per machine\nscopes:\n - scope: api-address · perMinute: 1200 · counts: every request to any ZimmerStack API route from one address (an IPv6 /56 counts as one address), counted on each API machine: the guard in front of everything, the Connect API included · header: api-address · per: address, on each API machine · window: 60 s fixed · windowSeconds: 60\n - scope: ip · perMinute: 240 · counts: requests from one address (an IPv6 /56 counts as one address) that carry no key verified from it in the last ten minutes, checked before the key is read. A key that has authenticated from that address is counted against its own budgets, not here · header: ip · per: address · window: 60 s sliding · windowSeconds: 60\n - scope: ip-auth · perMinute: 20 · counts: 401 answers, and 403 IP_NOT_ALLOWED, to one address; past it the address's unverified requests are refused before any lookup. A key that authenticated from that address in the last ten minutes keeps working · header: ip-auth · per: address · window: 60 s sliding · windowSeconds: 60\n - scope: key-auth · perMinute: 5 · counts: 401 and 403 IP_NOT_ALLOWED answers to one key (its first twelve characters) from one address; past it that key is refused from that address before any lookup, so one revoked key never uses up its address's budget · header: key-auth · per: address and key · window: 60 s sliding · windowSeconds: 60\n - scope: global-unauthenticated · perMinute: 1200 · counts: requests from every address together that carry no recently verified key and so cost a key lookup: the most a flood of made-up keys can ask of the database · header: global-unauthenticated · per: everyone without a verified key · window: 60 s sliding · windowSeconds: 60\n - scope: requests · perMinute: 120 · counts: every request on one key · header: key · per: key · window: 60 s sliding · windowSeconds: 60\n - scope: writes · perMinute: 30 · counts: every request on one key that is not a GET (PUT, POST and DELETE); a dry run (dryRun: true) is a write here · header: key-writes · per: key · window: 60 s sliding · windowSeconds: 60\n - scope: property · perMinute: 300 · counts: every request on all of a property's keys together (five keys are not five budgets) · header: property · per: property (all its keys) · window: 60 s sliding · windowSeconds: 60\n - scope: property-writes · perMinute: 60 · counts: every request that is not a GET on all of a property's keys together · header: property-writes · per: property (all its keys) · window: 60 s sliding · windowSeconds: 60\n - scope: cells · perMinute: 20000 · counts: cells a property's writes name after range expansion, charged before anything is read or written. A dry run is charged the same cells as the write it previews; a close or a reopen (POST /availability/close) is charged the room type's count and each of its rate plans for every night · header: cells · per: property (all its keys) · window: 60 s sliding · windowSeconds: 60\n - scope: company · perMinute: 1200 · counts: every request on one company key, across all its hotels (each hotel keeps its own key and property budgets too) · header: company · per: company key (all its hotels) · window: 60 s sliding · windowSeconds: 60\n - scope: global · perMinute: 3000 · counts: every authenticated request on the Connect API, all keys together; test keys count in a ceiling of their own of the same size, so a sandbox never spends what live hotels use · header: global · per: everyone · window: 60 s sliding · windowSeconds: 60\n - scope: bookings · perMinute: 20 · counts: POST /bookings on one key · header: bookings · per: key · window: 60 s sliding · windowSeconds: 60\n - scope: property-bookings · perMinute: 40 · counts: POST /bookings on all of a property's keys together · header: property-bookings · per: property (all its keys) · window: 60 s sliding · windowSeconds: 60\n - scope: property-bookings-day · perMinute: 500 · counts: POST /bookings per property per ROLLING 24 HOURS (not per minute); the owner can raise it per property · header: null · per: property (all its keys) · window: rolling 24 hours · windowSeconds: 86400\n - scope: direct-cancels · perMinute: 10 · counts: POST /direct-bookings/{bookingId}/cancel on one key (a replay is not counted) · header: direct-cancels · per: key · window: 60 s sliding · windowSeconds: 60\n - scope: property-direct-cancels-day · perMinute: 50 · counts: POST /direct-bookings/{bookingId}/cancel per property per ROLLING 24 HOURS (not per minute) · header: null · per: property (all its keys) · window: rolling 24 hours · windowSeconds: 86400\naddress: An address is one IPv4 address or one IPv6 /56. The ip, ip-auth and global-unauthenticated budgets are for requests we cannot name yet: a key that has authenticated from its address in the last ten minutes is counted against its own budgets (and its company's), not against them, and is never refused for another key's failures. A key that keeps failing is refused alone (key-auth) before it can use up its address's budget.\nwrites: A write is every request that is not a GET: PUT, POST and DELETE count against the writes budgets alike.\nheaders:\n RateLimit-Policy: on every answer, one quoted policy per budget the request was measured against, with its quota and its window in seconds, the key's own first — \"key\";q=120;w=60, \"key-writes\";q=30;w=60, \"property\";q=300;w=60, \"global\";q=3000;w=60\n RateLimit: on every answer, for the same budgets, what is left and the seconds until it has room — \"key\";r=117;t=42, \"key-writes\";r=29;t=42, \"property\";r=296;t=42, \"global\";r=2990;t=58\n names: The name in the header is the budget's data.scope, except the key's own two: requests is \"key\" and writes is \"key-writes\". A write route also carries its own minute budgets (cells, bookings, property-bookings, direct-cancels). The headers carry the budgets of a minute only: a budget over an hour or a day is not there, and GET /limits answers it.\n Retry-After: on every 429, whole seconds to wait; the body's data.scope says which budget refused, and its line in RateLimit reads r=0\nonRefusal: 429 RATE_LIMITED. Wait Retry-After, then resend the same request. Never retry in a tight loop; never retry any other 4xx.\ntooLarge: 413 when the JSON body exceeds 1048576 bytes; split the updates array\npace:\n - Batch: one PUT per resource carrying ranges (dateFrom..dateTo, optional days) — a 365-night calendar for three plans is a handful of updates, not a thousand\n - Send on change, not on a timer: unchanged cells are dropped and cost nothing, but they still spend your request budget\n - Read RateLimit on every answer and slow down when r approaches 0, instead of waiting for a 429\n - Reuse x-idempotency-key on a retry so a timed-out request can never land twice\n - Poll GET /batches/{batchId} and GET /sync no more than every 15 s; the push to the channels is asynchronous and bounded by the channel manager's own budget\nchannelManager:\n whyAsynchronous: Your 202 means the cells are in our record. Pushing them to the channel manager is paced by its budget — ten rate/restriction reads a minute for the whole account and a per-property write budget — so a full calendar takes minutes, never seconds, and is never lost.\n whatWeDo: We coalesce your cells into the fewest channel-manager calls, drop what did not change, pace every call, stop before the channel manager's last token, and back off on its Retry-After — you never have to think about its limits, only about ours.\n\n",
|
|
6113
7358
|
"bookings": "## bookings\nwho: Hotels that run the ZimmerStack PMS and their OWN booking engine: hand us the reservation your website sold and it lands in the PMS exactly as a front-desk booking — guest, folio, inventory, channels.\npricing: You price the stay. Send the nightly rate you charged per room; we store it and never re-quote. currency must equal the property's.\ninventory: Availability is checked inside the booking transaction under the property's inventory lock (a sold-out night is 409 NO_AVAILABILITY, nothing written). The inventory event commits with the booking; the drain pushes the new counts to every connected channel within seconds.\nidempotency: externalReference is YOUR reservation id and is unique per property: the same value again from the same key (or the key it was rotated from), while that booking is live, returns the same booking with HTTP 200 and replay: true. Use it on every retry. A reference another key already used on this property, or one that belongs to a booking you cancelled, is 409 EXTERNAL_REFERENCE_REUSED: after a cancel, the new stay needs a new reference.\npayments: A payment is recorded only when the key holds bookings:payments and never above the stay total. Nothing collected = omit payment; the desk collects at check-in.\nguest: By default the guest hears from YOUR site only; the owner can switch on our confirmation per property (admin → Developers → Settings).\ncancel: POST /bookings/{bookingId}/cancel cancels the whole booking and re-opens its nights on the channels; a booking already checked in is 409 BOOKING_NOT_CANCELLABLE. Date or room changes: cancel and re-create under a NEW externalReference (a modify endpoint is planned).\nscope: A key reads and cancels only the bookings it (or the key it was rotated from) created on its property; another key's, front-desk and OTA bookings are never visible (BOOKING_NOT_FOUND).\n\n",
|
|
6114
7359
|
"compatibility": "## compatibility\npromise: v1 never breaks. It only grows: new routes, new optional request fields, new fields and new values in answers, new headers. Ignore what you do not know: an unknown field, an unknown data.code (treat it by its HTTP status), an unknown budget name in RateLimit.\nneverWithoutNotice: A route's path and method; a field's name, type and meaning; what is required and what is optional; a data.code and the HTTP status it comes with; the units of money and dates; the names key and key-writes in the RateLimit headers; the idempotency rules.\ndeprecation: Something we would rather you stopped using is deprecated, not removed: it keeps working, and every answer that involved it carries Deprecation (RFC 9745: the instant it became deprecated, \"@\" and Unix seconds) and a Link with rel=\"deprecation\" to the page that names the replacement.\nsunset: A removal gets at least 12 months' notice: from the day it is announced (the changelog, an email to every partner with a live key, the compatibility page) every answer that involved it also carries Sunset (RFC 8594: the instant it stops working), never less than 12 months after the announcement.\nnumbers: A budget's quota is a number, not a shape: it can change, and is announced in the changelog. Read RateLimit and GET /limits instead of hard-coding one. Tightening a budget live integrations are using gets notice like a removal.\nversions: There is no /v2 and no dated version per key: what comes next is an edition of v1, never a migration.\nnoticeMonths: 12\npage: https://docs.zimmerstack.com/compatibility\ndeprecations:\n - id: rate-plan-default-rate-minor · what: defaultRateMinor on PUT /catalog/rate-plans (the standing price in hundredths of the currency's unit) · use: defaultRate: the same price in major units (4500 or \"4500.00\"), like every rate you send · deprecatedOn: 2026-11-16 · sunsetAnnouncedOn: null · sunsetOn: null · headers: {\"Deprecation\":\"@1794787200\",\"Sunset\":null}\n\n",
|
|
6115
7360
|
"limitsTable": "## limitsTable\nwhat: Every budget and cap an integration can meet, one row each. kind budget: a window the key guard or a route measures. kind shield: a budget over an hour or a day (x-zimmerstack.shield); its quota is the least any property gets when atLeast is true. kind cap: the most one request may carry, or the most of a thing that may exist. GET /limits answers the same rows for your key with what is left and when it refills.\nlive: GET /limits\nrows:\n - scope: api-address · header: api-address · kind: budget · per: address, on each API machine · window: 60 s fixed · windowSeconds: 60 · quota: 1200 · unit: requests · atLeast: false · counts: every request to any ZimmerStack API route from one address (an IPv6 /56 counts as one address), counted on each API machine: the guard in front of everything, the Connect API included\n - scope: ip · header: ip · kind: budget · per: address · window: 60 s sliding · windowSeconds: 60 · quota: 240 · unit: requests · atLeast: false · counts: requests from one address (an IPv6 /56 counts as one address) that carry no key verified from it in the last ten minutes, checked before the key is read. A key that has authenticated from that address is counted against its own budgets, not here\n - scope: ip-auth · header: ip-auth · kind: budget · per: address · window: 60 s sliding · windowSeconds: 60 · quota: 20 · unit: failed authentications · atLeast: false · counts: 401 answers, and 403 IP_NOT_ALLOWED, to one address; past it the address's unverified requests are refused before any lookup. A key that authenticated from that address in the last ten minutes keeps working\n - scope: key-auth · header: key-auth · kind: budget · per: address and key · window: 60 s sliding · windowSeconds: 60 · quota: 5 · unit: failed authentications · atLeast: false · counts: 401 and 403 IP_NOT_ALLOWED answers to one key (its first twelve characters) from one address; past it that key is refused from that address before any lookup, so one revoked key never uses up its address's budget\n - scope: global-unauthenticated · header: global-unauthenticated · kind: budget · per: everyone without a verified key · window: 60 s sliding · windowSeconds: 60 · quota: 1200 · unit: requests · atLeast: false · counts: requests from every address together that carry no recently verified key and so cost a key lookup: the most a flood of made-up keys can ask of the database\n - scope: requests · header: key · kind: budget · per: key · window: 60 s sliding · windowSeconds: 60 · quota: 120 · unit: requests · atLeast: false · counts: every request on one key\n - scope: writes · header: key-writes · kind: budget · per: key · window: 60 s sliding · windowSeconds: 60 · quota: 30 · unit: writes · atLeast: false · counts: every request on one key that is not a GET (PUT, POST and DELETE); a dry run (dryRun: true) is a write here\n - scope: property · header: property · kind: budget · per: property (all its keys) · window: 60 s sliding · windowSeconds: 60 · quota: 300 · unit: requests · atLeast: false · counts: every request on all of a property's keys together (five keys are not five budgets)\n - scope: property-writes · header: property-writes · kind: budget · per: property (all its keys) · window: 60 s sliding · windowSeconds: 60 · quota: 60 · unit: writes · atLeast: false · counts: every request that is not a GET on all of a property's keys together\n - scope: cells · header: cells · kind: budget · per: property (all its keys) · window: 60 s sliding · windowSeconds: 60 · quota: 20000 · unit: cells · atLeast: false · counts: cells a property's writes name after range expansion, charged before anything is read or written. A dry run is charged the same cells as the write it previews; a close or a reopen (POST /availability/close) is charged the room type's count and each of its rate plans for every night\n - scope: company · header: company · kind: budget · per: company key (all its hotels) · window: 60 s sliding · windowSeconds: 60 · quota: 1200 · unit: requests · atLeast: false · counts: every request on one company key, across all its hotels (each hotel keeps its own key and property budgets too)\n - scope: global · header: global · kind: budget · per: everyone · window: 60 s sliding · windowSeconds: 60 · quota: 3000 · unit: requests · atLeast: false · counts: every authenticated request on the Connect API, all keys together; test keys count in a ceiling of their own of the same size, so a sandbox never spends what live hotels use\n - scope: bookings · header: bookings · kind: budget · per: key · window: 60 s sliding · windowSeconds: 60 · quota: 20 · unit: bookings · atLeast: false · counts: POST /bookings on one key\n - scope: property-bookings · header: property-bookings · kind: budget · per: property (all its keys) · window: 60 s sliding · windowSeconds: 60 · quota: 40 · unit: bookings · atLeast: false · counts: POST /bookings on all of a property's keys together\n - scope: property-bookings-day · header: null · kind: budget · per: property (all its keys) · window: rolling 24 hours · windowSeconds: 86400 · quota: 500 · unit: bookings · atLeast: false · counts: POST /bookings per property per ROLLING 24 HOURS (not per minute); the owner can raise it per property\n - scope: direct-cancels · header: direct-cancels · kind: budget · per: key · window: 60 s sliding · windowSeconds: 60 · quota: 10 · unit: cancels · atLeast: false · counts: POST /direct-bookings/{bookingId}/cancel on one key (a replay is not counted)\n - scope: property-direct-cancels-day · header: null · kind: budget · per: property (all its keys) · window: rolling 24 hours · windowSeconds: 86400 · quota: 50 · unit: cancels · atLeast: false · counts: POST /direct-bookings/{bookingId}/cancel per property per ROLLING 24 HOURS (not per minute)\n - scope: cells-hour · header: null · kind: shield · per: property (all its keys) · window: one clock hour (UTC) · windowSeconds: 3600 · quota: 10000 · unit: changed cells · atLeast: true · counts: changed cells, all of a property's keys together. At least this many; a larger property gets two of its own full calendars an hour. A dry run changes nothing and is never counted here\n - scope: cells-day · header: null · kind: shield · per: property (all its keys) · window: rolling 24 hours · windowSeconds: 86400 · quota: 30000 · unit: changed cells · atLeast: true · counts: changed cells, all of a property's keys together. At least this many; a larger property gets six of its own full calendars a day. A dry run changes nothing and is never counted here\n - scope: vendor-cells-day · header: null · kind: shield · per: software vendor (all its hotels) · window: rolling 24 hours · windowSeconds: 86400 · quota: 150000 · unit: changed cells · atLeast: true · counts: a software vendor's changed cells across all its hotels (company keys and keys it minted). At least this many, plus 15,000 for each hotel it serves; a sandbox is never counted here\n - scope: shield-lane · header: null · kind: shield · per: property (all its keys) · window: one clock hour (UTC) · windowSeconds: 3600 · quota: 500 · unit: closing cells · atLeast: true · counts: cells of writes that only close inventory, accepted while the property is out of budget or paused (the safety lane). At least this many; sixty nights of every room type\n - scope: structure-creates · header: null · kind: shield · per: property · window: 60 s sliding · windowSeconds: 60 · quota: 20 · unit: new room types and rate plans · atLeast: false · counts: new room types and rate plans per property; a row already here that the write puts on the channel manager counts when it gets there, never when the answer's notice says it could not; also the most one request may create (TOO_MANY_NEW_ENTITIES)\n - scope: structure-creates-day · header: null · kind: shield · per: property · window: rolling 24 hours · windowSeconds: 86400 · quota: 300 · unit: new room types and rate plans · atLeast: false · counts: new room types and rate plans per property\n - scope: structure-edits-day · header: null · kind: shield · per: property · window: rolling 24 hours · windowSeconds: 86400 · quota: 300 · unit: changed room types and rate plans · atLeast: false · counts: changed room types and rate plans per property\n - scope: structure-deletes-day · header: null · kind: shield · per: property · window: rolling 24 hours · windowSeconds: 86400 · quota: 60 · unit: deleted room types and rate plans · atLeast: false · counts: deleted room types and rate plans per property\n - scope: vendor-structure-creates-day · header: null · kind: shield · per: software vendor (all its hotels) · window: rolling 24 hours · windowSeconds: 86400 · quota: 500 · unit: new room types and rate plans · atLeast: true · counts: a software vendor's new room types and rate plans across all its hotels\n - scope: vendor-remote-properties-day · header: null · kind: shield · per: software vendor · window: rolling 24 hours · windowSeconds: 86400 · quota: 10 · unit: hotels · atLeast: false · counts: hotels a software vendor puts on the channel manager for the first time\n - scope: vendor-property-removals-day · header: null · kind: shield · per: software vendor · window: rolling 24 hours · windowSeconds: 86400 · quota: 10 · unit: hotels · atLeast: false · counts: hotels a software partner removes (DELETE /properties/{propertyId}, and Remove hotel in the partner portal); a sandbox is never counted\n - scope: partner-new-properties-hour · header: null · kind: shield · per: software partner · window: one hour · windowSeconds: 3600 · quota: 20 · unit: hotels · atLeast: false · counts: hotels a partner adds, POST /properties and the partner portal's form together; a sandbox is never counted\n - scope: partner-new-sandboxes-hour · header: null · kind: shield · per: software partner · window: rolling hour · windowSeconds: 3600 · quota: 30 · unit: sandboxes · atLeast: false · counts: sandboxes a partner makes with a test key (POST /properties), counted when one is made; the partner portal's own sandbox button is not counted\n - scope: connect-links-hour · header: null · kind: shield · per: property · window: rolling hour · windowSeconds: 3600 · quota: 10 · unit: connect links · atLeast: false · counts: one-time connect links a software partner makes for one hotel (POST /connect-links), every booking site together; a link that was withdrawn or ran out still counts\n - scope: partner-connect-links-hour · header: null · kind: shield · per: software partner · window: rolling hour · windowSeconds: 3600 · quota: 120 · unit: connect links · atLeast: false · counts: one-time connect links a software partner makes across all its hotels (POST /connect-links)\n - scope: modifier-changes-day · header: null · kind: shield · per: property · window: rolling 24 hours · windowSeconds: 86400 · quota: 6 · unit: changes · atLeast: false · counts: changes to a channel's price modifier per property (PUT /channels/{channelId}/modifier); steps the channel already holds are not counted\n - scope: rate-resends-day · header: null · kind: shield · per: property · window: rolling 24 hours · windowSeconds: 86400 · quota: 3 · unit: re-sends · atLeast: false · counts: times a property's prices are sent to the channels again (POST /rates/resend)\n - scope: partner-support-tickets-day · header: null · kind: shield · per: software partner · window: rolling 24 hours · windowSeconds: 86400 · quota: 20 · unit: tickets · atLeast: false · counts: support tickets a partner opens (POST /support-tickets), both key modes together; a replayed idempotency key is not counted\n - scope: partner-support-messages-hour · header: null · kind: shield · per: software partner · window: rolling hour · windowSeconds: 3600 · quota: 60 · unit: messages · atLeast: false · counts: messages a partner adds to its support tickets (POST /support-tickets/{ticketId}/messages)\n - scope: maxUpdatesPerRequest · header: null · kind: cap · per: request · window: one request · windowSeconds: null · quota: 1000 · unit: entries · atLeast: false · counts: entries in one updates array (400 TOO_MANY_UPDATES past it)\n - scope: maxCellsPerRequest · header: null · kind: cap · per: request · window: one request · windowSeconds: null · quota: 5000 · unit: cells · atLeast: false · counts: cells (entity × night) one request may name after range expansion (400 TOO_MANY_CELLS past it)\n - scope: maxBodyBytes · header: null · kind: cap · per: request · window: one request · windowSeconds: null · quota: 1048576 · unit: bytes · atLeast: false · counts: the JSON body; larger is 413 PAYLOAD_TOO_LARGE before a byte is validated\n - scope: horizonDays · header: null · kind: cap · per: request · window: one request · windowSeconds: null · quota: 500 · unit: nights · atLeast: false · counts: the last writable night and the last bookable arrival: today + this many, in the property's calendar (400 HORIZON past it)\n - scope: maxNightsPerBooking · header: null · kind: cap · per: request · window: one request · windowSeconds: null · quota: 90 · unit: nights · atLeast: false · counts: nights in one POST /bookings\n - scope: newEntitiesPerRequest · header: null · kind: cap · per: request · window: one request · windowSeconds: null · quota: 20 · unit: new room types and rate plans · atLeast: false · counts: new room types or rate plans one structure write may create (400 TOO_MANY_NEW_ENTITIES past it)\n - scope: maxRoomTypes · header: null · kind: cap · per: property · window: one request · windowSeconds: null · quota: 18 · unit: room types · atLeast: false · counts: live room types on a hotel (a vacation rental has figures of its own, on GET /limits): 409 CATALOG_LIMIT_REACHED past it\n - scope: maxRatePlans · header: null · kind: cap · per: property · window: one request · windowSeconds: null · quota: 180 · unit: rate plans · atLeast: false · counts: live rate plans on a hotel: 409 CATALOG_LIMIT_REACHED past it\n - scope: maxActiveKeysPerProperty · header: null · kind: cap · per: property · window: one request · windowSeconds: null · quota: 5 · unit: keys · atLeast: false · counts: active hotel keys on one property (409 KEY_LIMIT past it)\n - scope: maxActiveCompanyKeys · header: null · kind: cap · per: software partner · window: one request · windowSeconds: null · quota: 5 · unit: keys · atLeast: false · counts: active company keys of one software partner\n - scope: maxSandboxes · header: null · kind: cap · per: software partner · window: one request · windowSeconds: null · quota: 5 · unit: sandboxes · atLeast: false · counts: sandboxes one software partner may hold at once\n - scope: maxAllowedCidrs · header: null · kind: cap · per: key · window: one request · windowSeconds: null · quota: 20 · unit: addresses or ranges · atLeast: false · counts: entries in one key's address allowlist\n - scope: idempotencyRetentionDays · header: null · kind: cap · per: key · window: one request · windowSeconds: null · quota: 7 · unit: days · atLeast: false · counts: how long an x-idempotency-key replays its first answer\n - scope: maxSupportMessageChars · header: null · kind: cap · per: request · window: one request · windowSeconds: null · quota: 5000 · unit: characters · atLeast: false · counts: characters in one support ticket message, the first included (400 VALIDATION past it)\n - scope: maxSupportTicketProperties · header: null · kind: cap · per: request · window: one request · windowSeconds: null · quota: 200 · unit: hotels · atLeast: false · counts: hotels one support ticket may name in propertyIds; past it send allProperties (400 VALIDATION)\n\n",
|
|
6116
7361
|
"budgets-and-standing": "## shield\nwhat: On top of the per-minute budgets, every property has budgets over an hour and a day, hard limits on its structure, and a standing ZimmerStack can change. They exist because every changed cell is forwarded by the channel manager to every connected channel: an integration that re-sends, flaps or loops is the hotel's and the channels' problem within a minute. GET /property carries this property's own figures (limits), what it has used (usage) and where it stands (shield).\ncounted: A budget counts CHANGED cells: cells whose value differs from our record. Re-sending a calendar we already hold costs nothing here. So send on change, in ranges.\ncalendar:\n what: One full calendar of a property is (2 × its rate plans + its room types) × 500 nights: a price and a stay-rule cell for every plan night, an availability cell for every room-type night. The figures in the table are the least any property gets; a larger one gets whole calendars.\n horizonDays: 500\n perHour: 2\n perDay: 6\n vendorPerDayBase: 150000\n vendorPerDayPerHotel: 15000\n perProperty: Every key on a property spends the same budget: a second key, or a company key beside a hotel key, is not a second budget.\nbudgets:\n - scope: cells-hour · window: one clock hour (UTC) · floor: 10000 · counts: changed cells, all of a property's keys together. At least this many; a larger property gets two of its own full calendars an hour. A dry run changes nothing and is never counted here\n - scope: cells-day · window: rolling 24 hours · floor: 30000 · counts: changed cells, all of a property's keys together. At least this many; a larger property gets six of its own full calendars a day. A dry run changes nothing and is never counted here\n - scope: vendor-cells-day · window: rolling 24 hours · floor: 150000 · counts: a software vendor's changed cells across all its hotels (company keys and keys it minted). At least this many, plus 15,000 for each hotel it serves; a sandbox is never counted here\n - scope: shield-lane · window: one clock hour (UTC) · floor: 500 · counts: cells of writes that only close inventory, accepted while the property is out of budget or paused (the safety lane). At least this many; sixty nights of every room type\n - scope: structure-creates · window: 60 s sliding · floor: 20 · counts: new room types and rate plans per property; a row already here that the write puts on the channel manager counts when it gets there, never when the answer's notice says it could not; also the most one request may create (TOO_MANY_NEW_ENTITIES)\n - scope: structure-creates-day · window: rolling 24 hours · floor: 300 · counts: new room types and rate plans per property\n - scope: structure-edits-day · window: rolling 24 hours · floor: 300 · counts: changed room types and rate plans per property\n - scope: structure-deletes-day · window: rolling 24 hours · floor: 60 · counts: deleted room types and rate plans per property\n - scope: vendor-structure-creates-day · window: rolling 24 hours · floor: 500 · counts: a software vendor's new room types and rate plans across all its hotels\n - scope: vendor-remote-properties-day · window: rolling 24 hours · floor: 10 · counts: hotels a software vendor puts on the channel manager for the first time\n - scope: vendor-property-removals-day · window: rolling 24 hours · floor: 10 · counts: hotels a software partner removes (DELETE /properties/{propertyId}, and Remove hotel in the partner portal); a sandbox is never counted\n - scope: partner-new-properties-hour · window: one hour · floor: 20 · counts: hotels a partner adds, POST /properties and the partner portal's form together; a sandbox is never counted\n - scope: partner-new-sandboxes-hour · window: rolling hour · floor: 30 · counts: sandboxes a partner makes with a test key (POST /properties), counted when one is made; the partner portal's own sandbox button is not counted\n - scope: connect-links-hour · window: rolling hour · floor: 10 · counts: one-time connect links a software partner makes for one hotel (POST /connect-links), every booking site together; a link that was withdrawn or ran out still counts\n - scope: partner-connect-links-hour · window: rolling hour · floor: 120 · counts: one-time connect links a software partner makes across all its hotels (POST /connect-links)\n - scope: modifier-changes-day · window: rolling 24 hours · floor: 6 · counts: changes to a channel's price modifier per property (PUT /channels/{channelId}/modifier); steps the channel already holds are not counted\n - scope: rate-resends-day · window: rolling 24 hours · floor: 3 · counts: times a property's prices are sent to the channels again (POST /rates/resend)\n - scope: partner-support-tickets-day · window: rolling 24 hours · floor: 20 · counts: support tickets a partner opens (POST /support-tickets), both key modes together; a replayed idempotency key is not counted\n - scope: partner-support-messages-hour · window: rolling hour · floor: 60 · counts: messages a partner adds to its support tickets (POST /support-tickets/{ticketId}/messages)\ncaps:\n maxRoomTypes: 18\n maxRatePlans: 180\n why: Each cap sits a tenth under what the channel manager includes for that kind of property before it bills extra, so an integration never runs a hotel into overage. GET /property carries this property's own caps.\n byCategory:\n - category: hotel · maxRoomTypes: 18 · maxRatePlans: 180 · ratePlansPerRoomType: null\n - category: vacation rental · maxRoomTypes: 45 · maxRatePlans: 405 · ratePlansPerRoomType: 9\n onRefusal: 409 CATALOG_LIMIT_REACHED (details.limit, details.current, details.requested). Delete what is unused, or ask ZimmerStack support.\nonRefusal: 429 RATE_LIMITED with data.scope naming the budget and Retry-After in whole seconds: to the next clock hour for cells-hour, until enough of the day has aged out for a rolling day. Nothing was written. Wait, then send what still needs to change.\nsafetyLane: A hotel must not oversell because its integration ran out of budget or was paused. A write that only CLOSES inventory (a lower availability count or 0, or stopSell / closedToArrival / closedToDeparture switched on, and nothing else in the request) is still accepted in both cases, against its own hourly allowance (at least 500 cells); its 202 carries lane: true. A write that opens inventory or changes a price waits.\npriceBand:\n what: PUT /rates takes prices in MAJOR units, and reads answer the same price as rate, a decimal string in major units (the older rateMinor beside it is hundredths of the major unit, which is not every currency's minor unit). A price below a tenth or above ten times its plan's standing price (the plan's defaultRate, or its room type's base rate) is not taken on trust: the whole request is 422 RATE_OUT_OF_BAND and nothing is written. A plan with no standing price is never judged.\n minPct: 10\n maxPct: 1000\n wayOut: If the price is meant, move the plan's standing price first (PUT /catalog/rate-plans defaultRate): the band moves with it. ZimmerStack support can set a property to warn only (the 202 then carries priceWarnings) or switch its band off; the hotel's owner asks for it.\nstanding:\n levels:\n CLEAR: Nothing held against the integration.\n WATCH: Something notable happened (a budget was used up). Nothing is refused.\n PAUSED: Only writes that close inventory are accepted (the safety lane); anything else is 429 RATE_LIMITED with data.scope shield-pause and a Retry-After that ends with the pause. Set automatically for a while when the channel manager refuses the integration's values or it uses up a budget on two of three days (15 minutes, then 1 hour, 6 hours, a day), or by ZimmerStack support until released.\n SUSPENDED: Every write is 403 WRITES_SUSPENDED until ZimmerStack support releases it.\n frozen: 503 WRITES_FROZEN with Retry-After: ZimmerStack has paused every integration's writes at once. Rare, short, and never your integration alone.\n never: Reads, GET /channel-bookings, webhooks and POST /bookings are never refused by any of this: a guest's reservation and its news always travel.\nrejectedValues: A rate or restriction value the channel manager itself refuses is held, not re-sent: GET /sync counts it (rates.parkedCells), its batch reads failed with the reason, and the property's other cells keep landing. Send a corrected value for those nights.\nsandbox: A sandbox meets the same budgets, limits and band on its own property, so you learn them before going live. It is never frozen and never counts against your company's budgets.\n\n",
|
|
6117
|
-
"properties": "## properties\nwhat: A software partner's company key adds a hotel and removes a hotel it added, without the partner portal: POST /properties and DELETE /properties/{propertyId}. Scope properties:write, which only a company key can hold; a hotel's own key is 403 COMPANY_KEY_REQUIRED.
|
|
7362
|
+
"properties": "## properties\nwhat: A software partner's company key adds a hotel, changes a hotel it added and removes a hotel it added, without the partner portal: POST /properties, PATCH /properties/{propertyId} and DELETE /properties/{propertyId}. Scope properties:write, which only a company key can hold; a hotel's own key is 403 COMPANY_KEY_REQUIRED. None of the three reads X-ZS-Property.\nadd: POST /properties makes what the partner portal's \"Add a hotel\" form makes: a channel-manager hotel with its own owner account, its room types (1 to 20, each with one room-only rate plan at its defaultRate), on your invoice at your price. The owner gets their sign-in details by email; you never see them. The answer is the hotel in GET /properties' shape: name its id in X-ZS-Property from then on.\nafterAdding: A hotel added with its room types is put on the channel manager when its billing starts (billing.state ACTIVE), usually before this request answers; channelManager says whether it is there. While it is false, a write for the hotel answers 409 CHANNEL_MANAGER_DISABLED: send its room types again with PUT /catalog/room-types (the same refs you gave here, or the same names, so they become those room types instead of a second set), or press Finish setup on the hotel's page in the partner portal. Either puts it there. Then send your other room types and rate plans, and your availability and rates.\nchange: PATCH /properties/{propertyId} changes a hotel's name and its address (line1, city, state, postalCode): only the fields you send, and the answer is the hotel in GET /properties' shape with its address and changed, the fields whose stored value moved (empty when everything you sent was already stored). It never changes the hotel's country, currency, time zone, owner or tax id: a request that names one of them is 400 VALIDATION, and so is a request that sends nothing to change. It changes the hotel's record in ZimmerStack, not the name of a listing on an OTA. Only a hotel you added: one whose owner let you in is 409 PROPERTY_NOT_CHANGEABLE (data.details.reason OWNER_ALLOWED: its owner changes it), and a hotel you cannot reach is 404 PROPERTY_NOT_FOUND. Who pays for the hotel and what else it uses are not asked, unlike a removal. With a test key it changes one of your sandboxes, whose name keeps its ending, (sandbox). x-idempotency-key is optional here, as on every write but the add.\nidempotency: POST /properties needs x-idempotency-key (400 IDEMPOTENCY_KEY_INVALID without one): the same key never makes a second hotel, even when the first answer was lost. A test key and a live key never share a key's answer. A 4xx answer is kept under its key for 7 days, like every verdict: once you have changed what it asked for (your billing setup done, a sandbox removed), send the request under a new key. A 429 or a 503 is never kept: send the same request, with the same key, after Retry-After.\nbilling: billing.state says where the new hotel's billing stands. ACTIVE: its billing has started and it is on your next monthly invoice (under the public price list your live hotels are counted on the 1st of each month, so the days before the next 1st are free). WAITING: the hotel is live and its billing has not started; billing.reason says why (SETUP, OVERDUE, UNPAID_LIMIT or REVIEW) and billing.message what to do. Before your first hotel, accept the price list and add your billing details in the partner portal (409 BILLING_SETUP_REQUIRED until then).\nowner: One owner account per email address. An address that already has an account is 409 OWNER_HAS_ACCOUNT: a hotel that exists already joins you when its owner enters your vendor code under Integrations.\nremove: DELETE /properties/{propertyId}?confirm=<the hotel's exact name> removes a hotel for good, in one call: its subscription is cancelled, then its channel connections, its rate plans, its room types and its listing are taken off the channel manager, your keys stop reaching it and nobody signs in to it any more. Its bookings and bills are kept. 200 when nothing is left on the channel manager; 202 when a step there is still pending, which ZimmerStack retries by itself (channelManager.state RETRYING, with the step and what is still connected). Call it again any time: once the hotel is gone the answer is 200 with replay: true and where it stands, and no confirm is needed.\nwhichHotels: Only a hotel you added and pay for, that runs the channel manager alone and is the one property of its owner's account. Anything else is 409 PROPERTY_NOT_REMOVABLE, and data.details.reason says who can do it: OWNER_ALLOWED (its owner let you in: the owner removes your access) · NOT_BILLED_TO_YOU, OTHER_PRODUCTS, SHARES_ACCOUNT (ZimmerStack removes it: write to support). A hotel you cannot reach is 404 PROPERTY_NOT_FOUND.\nrefusals: 400 CONFIRMATION_MISMATCH: confirm is not the hotel's exact name. 503 PROPERTY_BUSY: a hotel of yours is being added or removed right now, one at a time; retry after Retry-After. 503 PROPERTY_BUSY with a Retry-After of an hour on a removal: it has started and could not finish, ZimmerStack has been told and finishes it, and nothing is needed from you; call again later for where it stands. 429 RATE_LIMITED with data.scope vendor-property-removals-day: the most hotels your company may remove in a day (10; a removal that had already started is finished whatever the day's count), partner-new-properties-hour: the most it may add in an hour (20), or partner-new-sandboxes-hour: the most sandboxes a test key may make in an hour (30). 503 PRICE_UNAVAILABLE: the hotel could not be priced just now; retry. 400 VALIDATION whose message says the request is held (data.details.reason): the hotel could not be created from a request already on file, so sending it again, under this key or a new one, will not help; write to ZimmerStack support.\nsandbox: With a test key (zsk_test_) the same two calls make and delete one of your sandboxes (up to 5 at once; 409 SANDBOX_LIMIT beyond, and at most 30 made in any hour; 429 RATE_LIMITED with data.scope partner-new-sandboxes-hour beyond): the body is checked exactly as a live one, the sandbox takes its room types, and nothing is billed or reaches a channel. Its name ends in (sandbox) and is at most 60 characters: confirm a delete with the name the answer returned.\n\n",
|
|
6118
7363
|
"room-types-and-rate-plans": "## structure\nwhat: PUT /catalog/room-types and PUT /catalog/rate-plans (scope catalog:write) let the PMS own the hotel's structure: an upsert by ref, your own id. A new entity is created on the channel manager at once; every later change mirrors there with retries and a nightly drift check; the answer names our id, the action and the sync status per entity. GET /catalog carries ref and sync from now on.\nadoption: A room type the owner already made with the same name (and no ref) becomes yours by ref (action: adopted); a plan likewise under the same room type. A plan never moves between room types (409 CATALOG_CONFLICT): delete it and send it again.\nswitchOn: A channel-manager-only hotel with no channel-manager property yet gets one on the first write, and the channel manager is switched on once a room type and a plan are mapped; channelManager.enabled in the answer says where it stands, reason why not.\nidempotent: Twice over: ref is the upsert key here, and the channel-manager create adopts an existing entity with the same title instead of creating it again, so a retry never duplicates on either side. Send x-idempotency-key on retries as on every write.\nnotHere: A room count after creation (it lives on the channel manager), photos, descriptions, amenities, cancellation policies and stay rules: the owner's Rooms & rates screen, or the restrictions routes.\nsandbox: On a sandbox everything lands locally and reads IN_SYNC, through the same code path.\n\n",
|
|
6119
7364
|
"ota-bookings": "## channelBookings\nwhat: GET /channel-bookings lists the OTA bookings the channel manager delivered to the property — the SAME booking object the webhooks carry, so one parser serves both. Scope channel-bookings:read, granted separately from the ARI pair.\nsince: since is on the booking's last change (created, modified or cancelled), default the last 7 days; page with limit (≤100) and pass the answer's nextCursor as cursor while more is true. nextCursor is returned on every page, the last one included: keep it and ask with it next time, so a poller needs no clock of its own.\nmatchesWebhook: The booking is what its last event said: finance (with paymentType, virtualCard and feeAmount), guestNotes, guest.country, guest.language, amounts.paymentCollect and an OTA cancellation's reason are read from our stored copy of the revision, so a pull is never poorer than the webhook. version is the booking's current version: a copy of yours with a lower one has missed an event.\nwhy: Recover a missed webhook, or poll instead of receiving: the webhooks remain the push path, this is the pull path over the same shape.\nnever: Front-desk, booking-engine and Connect API bookings are never listed here; they are not channel bookings. The booking engine's are GET /direct-bookings.\n\n",
|
|
6120
7365
|
"website-bookings": "## directBookings\nwhat: A hotel that sells on its own website through the ZimmerStack booking engine takes bookings no OTA sent. They reach a PMS under their own names: the webhooks direct.booking.created, direct.booking.modified and direct.booking.cancelled, and GET /direct-bookings for the pull. The booking object is the one channel.booking.* carries, so one parser serves both families.\ntellApart: channel.source is DIRECT_WEB, channel.sourceGroup is DIRECT and channel.otaName is \"Website\". finance is null (no OTA, no commission); amounts.paymentCollect is \"property\"; amounts.paid is what the guest paid online, amounts.balanceDue what the desk collects.\nsubscribe: An endpoint receives them only when it lists the event types, each ticked on its own. An endpoint registered before a type existed receives none of it until its owner ticks it: direct.booking.modified was added on 21 Nov 2026, so an endpoint that listed created and cancelled before then still receives exactly those two.\napplyFirst: A website booking takes one room off the count the channels hold, at once. A PMS that pushes absolute room counts must apply the booking to its own calendar BEFORE its next PUT /availability, or that push puts the sold room back on sale. Read GET /direct-bookings before a full push to catch anything a webhook has not delivered yet.\nevents: created: a nightly or an hourly booking the guest confirmed. modified: the hotel recorded in ZimmerStack that the guest did not arrive (a no-show), or undid that. The booking is not cancelled, so status stays CONFIRMED and the payment is untouched; stayStatus and each room's status say NOSHOW (the nights are on sale again on every channel: free the room) or, after an undo, UPCOMING again (the nights are taken again: hold the room). changes names what moved (\"stayStatus\", \"rooms[0].status\") and previous carries the booking as it read before, stayStatus included. cancelled: the guest cancelled on the booking page, or the hotel cancelled or deleted the booking in ZimmerStack or through POST /direct-bookings/{bookingId}/cancel; cancellation.reason says which (\"Cancelled by the guest\" or \"Cancelled by the hotel\"). A cancel your own PMS made comes back to you as this event too: match it on the booking id and treat it as already applied.\nafterwards: Anything else the hotel changes on a website booking in ZimmerStack afterwards (other dates, one room of several cancelled, a payment taken at the desk) sends no event yet; modified is a no-show and its undo only, and changes is how a later kind of change will say what it is. GET /direct-bookings lists that booking again, because since is on its last change: read it on a slow schedule too (once an hour is plenty), not only before a push. A modified or a cancelled event can also arrive for a booking whose created your endpoint never received (it ticked the types later): treat an unknown booking id as new and read it with GET /direct-bookings/{bookingId}.\npull: GET /direct-bookings takes the same since, status, limit and cursor as GET /channel-bookings and pages the same way. Scope direct-bookings:read, granted separately from channel-bookings:read. A booking deleted in ZimmerStack stays listed, as CANCELLED.\nnever: OTA bookings (GET /channel-bookings), front-desk bookings and bookings a key created (GET /bookings) are never listed here.\ncancel: POST /direct-bookings/{bookingId}/cancel cancels a whole website booking that is still UPCOMING and says what the guest gets back: refund \"policy\" (the default: what the booking's own cancellation policy gives now, exactly as if the guest cancelled on the booking page), \"full\" (everything paid online) or \"none\" (the hotel settles any money itself). The refund goes back to the guest's online payment, never more than it; the hotel's share of that payment is taken back first. The nights go back on sale on the channels, the guest gets the usual cancellation message, and direct.booking.cancelled says \"Cancelled by the hotel\". Scope direct-bookings:cancel, granted on its own and never by default. A checked-in, checked-out or no-show booking is 409 BOOKING_NOT_CANCELLABLE; an already-cancelled one answers 200 with replay: true and moves no money. Send x-idempotency-key: a retry with the same key gets the first answer back. Budgets: 10 per key per minute, 50 per property per rolling day.\nsandbox: POST /sandbox/bookings with otaName \"Website\" simulates one and sends the real direct.booking.created; its cancel sends direct.booking.cancelled. Its modify is 409 BOOKING_NOT_MODIFIABLE. POST /direct-bookings/{bookingId}/cancel works on a sandbox website booking with a test key: the nights come back and the event says \"Cancelled by the hotel\", and no money moves (refund.status NONE).\n\n",
|
|
6121
7366
|
"event-log": "## events\nwhat: GET /events?after=&limit= is the hotel's ordered event log: every event a webhook can carry for it (OTA bookings, website bookings, channel alerts), once, oldest first. The webhooks are the nudge; the log is the truth.\nhow: Each event of a hotel has a sequence, one higher than the hotel's last. Keep the last sequence you applied and ask for everything after it: after an outage, on a schedule, or whenever a webhook arrives whose sequence is not your next one. nextAfter is your new place; more: true means ask again at once. Nothing depends on a delivery having arrived or on the order deliveries arrived in.\nitem: An item is the webhook's own envelope (id, type, occurredAt, mode, sequence, property, data, changes, previous), so one parser serves both. The same sequence rides the webhook, its redelivery and its replay.\nversion: data.booking.version is our own counter of a booking's events: 1 on its first event, one more on each later one. A higher version is a later state, whatever order deliveries arrived in.\nscopes: channel-bookings:read reads the channel events (channel.booking.*, channel.sync.*); direct-bookings:read the website's (direct.booking.*). A key with one of them sees the other family's numbers skipped: the sequence is the hotel's. With neither, 403 SCOPE_MISSING.\nretention: Kept 90 days. earliestSequence is the lowest sequence still kept: when it is more than one above your after, the events in between are gone; reconcile with GET /channel-bookings and GET /direct-bookings, then carry on from nextAfter.\nnotHere: A Test button's sample event (it has no sequence), and events from before 22 Nov 2026.\n\n",
|
|
6122
7367
|
"webhook-endpoints": "## webhookEndpoints\nwhat: A software partner's company key manages its own company webhook endpoints without the partner portal: list, create, change (address, event types, notify email, the guest-contact switch), pause, resume, rotate the signing secret, delete, send a test of any event type, recover since an instant, redeliver one delivery and read the delivery log. Scope webhooks:manage, which only a company key can hold and which is never ticked by default; a hotel's own key is 403 COMPANY_KEY_REQUIRED. No route reads X-ZS-Property: an endpoint belongs to you, not to a hotel.\nmodes: A live key manages your live endpoints (the events of every hotel you may act on); a test key your test ones (your sandboxes' events). The other mode's endpoint is 404 WEBHOOK_ENDPOINT_NOT_FOUND. Up to three endpoints, both modes together (409 WEBHOOK_ENDPOINT_LIMIT).\nsecret: The signing secret (whsec_…) is in the answer that creates the endpoint or rotates its secret, and nowhere else: no route reads an existing secret back. After a rotation both secrets sign for 24 hours.\nguestContact: An endpoint made by API starts with guest contact off. PATCH includeGuestContact to switch it at any time: it applies to every delivery made from then on.\nevents: With no eventTypes a new endpoint takes the OTA booking events and both channel.sync events. The website booking events (direct.booking.*) are ticked on their own.\npause: A paused endpoint's events are held and go out oldest first on resume (data.heldEvents). An endpoint ZimmerStack suspended is resumed by ZimmerStack (403 WEBHOOK_ENDPOINT_SUSPENDED); it drops events, which recover queues again.\ntest: POST /webhook-endpoints/{endpointId}/test with eventType: any type an endpoint can receive, or zimmerstack.ping (the default). The sample says mode: test and carries no sequence. On a sandbox the real events are made by POST /sandbox/… (x-zimmerstack.sandbox).\nrecover: POST /webhook-endpoints/{endpointId}/recover with since queues again every subscribed event since then that failed or never had a delivery: at most 90 days back and 10,000 events a run (truncated: true means run it again). A live endpoint is sent only the events of hotels you could act on then and still can. GET /events is the other way to catch up, and needs no endpoint at all.\nidempotency: Send x-idempotency-key on the writes, as on every write: a retry with the same key gets the first answer back. A 4xx is kept under its key for 7 days, so after changing what it asked for (resuming a paused endpoint, removing one of three) send the request under a new key. A 429 or a 503 is never kept.\nrefusals: 404 WEBHOOK_ENDPOINT_NOT_FOUND · 404 WEBHOOK_DELIVERY_NOT_FOUND · 409 WEBHOOK_ENDPOINT_LIMIT · 409 WEBHOOK_ENDPOINT_NOT_ACTIVE (test, recover and redeliver need an active endpoint) · 403 WEBHOOK_ENDPOINT_SUSPENDED · 403 WEBHOOK_ACCESS_ENDED (the hotel ended your access before the event was sent) · 410 WEBHOOK_PAYLOAD_EXPIRED (the event is older than 90 days) · 400 VALIDATION with data.details.reason for an address, event type, email or date we refuse · 429 RATE_LIMITED with data.scope webhook-endpoint (so many tests, rotations, recovers or redeliveries an hour) · 503 WEBHOOKS_UNAVAILABLE.\nportalOnly: Reading an existing signing secret, and everything about company keys, prices and team members, stay with a person in the partner portal.\n\n",
|
|
6123
|
-
"connect-links": "## connectLinks\nwhat: A one-time connect link lets the hotel's own person connect ONE booking site for ONE hotel, without your partner portal
|
|
7368
|
+
"connect-links": "## connectLinks\nwhat: A one-time connect link lets the hotel's own person connect ONE booking site for ONE hotel, without your partner portal. Your company key asks for the link (POST /connect-links) and you send its url to the hotel. On our hosted page that person types the hotel's id at the booking site (MakeMyTrip and Goibibo also the access token they give), confirms every room and rate match and presses Start selling. Nobody signs in to a booking site on the page, except on Airbnb: the host signs in on Airbnb's own page and allows the connection. Only Airbnb is connected from the link alone; every other booking site needs the hotel's step there first (hotelStep). You hear channel.connect.completed, or channel.connect.expired if the link ran out first.\nscope: channels:connect, which only a company key can hold and which is never ticked by default: a key with it can start a hotel selling on a booking site. It is given by someone in your company who may act for hotels. A hotel's own key is 403 COMPANY_KEY_REQUIRED. No route reads X-ZS-Property: the hotel is propertyId in the create's body. A live key only: a test key is 409 LIVE_KEY_REQUIRED.\nnever: The API takes no booking-site detail (no hotel id there, no access token, no password) and no room or rate match, in any field: the create's body is the hotel, the booking site and three options, and an unknown field is 400 VALIDATION. The details and the matching are given by a person, on the page.\nlink: The url opens once and is in the answer that makes the link, nowhere else: we keep a hash of its token. It opens for 72 hours unless expiresInHours says otherwise (up to 168); once opened, the page has 120 minutes. A second link for the same hotel and booking site withdraws an earlier one nobody opened, and picks up a connection an earlier link saved without starting it. A replay of the create (the same x-idempotency-key) answers url: null: make a new link.\npage: The page can do one thing: this connection for this hotel. It cannot pause or remove a connection, read the hotel's other connections, or change a price. It carries your brand when ZimmerStack serves your hotels under it; otherwise it names your company as the sender. Everything it does is on the hotel's activity log, naming the key that made the link.\nhotelStep: Every booking site but Airbnb must first accept our connectivity partner for the hotel: in its extranet (Booking.com, Agoda, Expedia) or through its support (MakeMyTrip and Goibibo, which then give an access token; Trip.com; Yatra; Hostelworld for a hostel new to channel managers). It can take days, and no API call does it. hotelStep, in the create's answer, is that step in a sentence, with our connectivity partner's name as the booking site lists it: send it to the hotel first, and send the url once the hotel has done it (an opened page has 120 minutes; a link that ran out meanwhile is replaced by a new one). It is null for Airbnb. The page itself does not print the name.\nlimits: One connection per hotel and booking site unless ZimmerStack allowed that hotel more: the page says so if the hotel already has one. 10 links an hour per hotel and 120 an hour across your hotels (429 RATE_LIMITED, data.scope connect-links-hour or partner-connect-links-hour).\nstatus: GET /connect-links/{linkId}: pending (made, not opened), opened (someone is on the page), completed (Start selling was pressed), expired, revoked. POST /connect-links/{linkId}/revoke withdraws a link; an open page stops at its next step.\nwebhooks: channel.connect.completed and channel.connect.expired are event types of their own: tick them on your endpoint (PATCH /webhook-endpoints/{endpointId}). Both are in the hotel's event log (GET /events) with a sequence. completed carries the connection's id (GET /channels) and what became of the booking site's upcoming bookings; expired says whether anyone opened the link and whether a connection was saved, paused.\nrefusals: 404 PROPERTY_NOT_FOUND (not a hotel this key may act on) · 409 CHANNEL_NOT_AVAILABLE (details.reason switched_off or not_offered_here) · 409 CHANNEL_MANAGER_DISABLED (send the hotel's room types and rate plans first) · 409 LIVE_KEY_REQUIRED · 404 CONNECT_LINK_NOT_FOUND · 429 RATE_LIMITED · 503 CONNECT_LINKS_UNAVAILABLE.\n\n",
|
|
6124
7369
|
"going-live": "## goLive\nwhat: Going live makes your software the source of truth for a hotel: from then on every price, stay rule and room count you send is pushed to its booking sites. A hotel you add with POST /properties is live from the start. Any other hotel (one whose owner let you in by your code) goes live with POST /go-live, once GET /readiness says it is ready. Both name the hotel in X-ZS-Property.\nwhy: A hotel that ran on our screens first has a record full of prices nobody chose for the booking sites. Switched on without a check, those would be sent over the hotel's real prices. The report is how we know that will not happen.\nchecks: GET /readiness answers four checks, each passed or not, with a sentence and what to do: channel_manager (the hotel is on the channel manager) · catalog_linked (so is every room type and rate plan) · prices_hold (ZimmerStack's own pricing does not overwrite a price you send) · nothing_stale, which passes one of two ways: our record matches the channels for the next 365 nights (nothing waiting to be sent, nothing different from what the channel manager was read holding in the last 48 hours), or your software has sent the next 365 nights first. It reads our record only, so ask as often as you like.\nsendFirst: To send a full year first: PUT /rates for every rate plan and night, each request carrying the header X-ZS-Before-Go-Live: true. Without the header a hotel that is not live answers 409 ARI_NOT_AUTHORITATIVE, as before. Prices and stay rules sent ahead are stored and wait (the answer says heldUntilGoLive: true). Room counts are different: until the hotel is live, a count that lowers what is on sale is sent to the booking sites at once (a held count would oversell a room), and a count that raises it is refused in the answer's rejected list, because the hotel's own people may still be running its counts. Send your room counts again right after going live.\nswitch: POST /go-live needs ari:write. Ready: 200 with live: true. Not ready: 409 NOT_READY with the checks that did not pass, and that refusal is never kept under an x-idempotency-key, so send the same request again once you have fixed them. Already live: 200 with replay: true. It is written on the hotel's activity log and in our audit as an automated act, naming your key.\nafter: Nights past the next 365 that your software never wrote are sent closed until it writes them. The hotel's owner can end your access at any time; switching a hotel back is done by ZimmerStack support.\n\n",
|
|
6125
7370
|
"hotel-keys": "## hotelKeys\nwhat: A company key lists, mints, rotates and revokes the keys you made on a hotel, without your partner portal: GET and POST /properties/{propertyId}/keys, POST …/keys/{keyId}/rotate and …/revoke. The hotel is in the path; X-ZS-Property is not read.\nscope: keys:manage, which only a company key can hold and which is never ticked by default: a key with it mints more keys. A hotel's own key is 403 COMPANY_KEY_REQUIRED.\nreach: The hotels you added and still have access to (a live key), or your sandboxes (a test key). Only the keys you made: a hotel's own keys are its owner's and are never listed, rotated or revoked here. A company key is never made, rotated or revoked by API: that stays with a person in your partner portal.\nsecret: The secret is in the answer that mints or rotates a key and nowhere else: we keep its hash. A replay of that request (the same x-idempotency-key) answers key: null.\nrotate: A rotation makes a new key with the same name, scopes, addresses and expiry; the old one keeps answering for 24 hours (retireAt), then stops.\nrules: The rules are a hotel key's own: any scope a hotel's key may hold (never a company key's own scopes), at most 5 active keys a hotel (409 KEY_LIMIT), ari:read and ari:write only on a hotel that is live (409 ARI_NOT_AUTHORITATIVE: go live first). Every mint, rotation and revoke is on the hotel's activity log, naming the company key that did it.\nrefusals: 404 PROPERTY_NOT_FOUND · 404 KEY_NOT_FOUND · 409 KEY_LIMIT · 409 KEY_REVOKED · 409 KEY_ALREADY_ROTATING · 400 SCOPES_INVALID · 400 ALLOWED_CIDRS_INVALID · 400 REASON_REQUIRED · 400 VALIDATION.\n\n",
|
|
6126
7371
|
"billing": "## billing\nwhat: A software partner's company key reads what its Billing page shows: GET /billing (what is owed, the onboarding fee, your property quota, money paid ahead, the days of an unpaid invoice, and what was passed on at cost), GET /billing/invoices (your issued invoices, each before and after tax, with its lines) and GET /billing/next-invoice (what your next monthly invoice is made of, hotel by hotel). Scope billing:read, which only a company key can hold and which is never ticked by default; a hotel's own key is 403 COMPANY_KEY_REQUIRED. No route reads X-ZS-Property. The same answer for a live key and a test key: a bill is your company's.\nreadOnly: Nothing here pays, accepts a price or changes billing details: those stay with a person in the partner portal. No payment link is answered.\nwhoMayGiveIt: A key that reads your bills is made by someone who may open the portal's Billing page (the account owner, an Admin). A Developer cannot make one.\nnextInvoice: Each line says how its price was reached: the rooms counted (what the hotel declared, or the most it has on sale on one night when that is more), the room band they fall in, how many of your hotels share that band (which picks a volume price), the price list it was read from, and the conversion when the list is in another currency. It is read today; the invoice reads rooms, prices and the exchange rate again on the day it is made, and that is the bill.\ncounting: A hotel is on a month's invoice when it is live on the 1st, connected to a booking site or not, in full for the month starting; a hotel added after the 1st is first billed on the next 1st, and nothing is refunded for a hotel removed mid-month.\nquota: quota.properties says how many hotels you may have live (allowed), how many you have (used) and how many you may still add (free). quota.next says the next level and about what paying ahead opens it today; paying ahead is done in the partner portal. Past the quota, POST /properties answers 409 BILLING_SETUP_REQUIRED with details.reason QUOTA_FULL.\nunpaid: unpaidInvoiceDays gives the rule (due by the end of dueDay, booking-site connections paused on pauseDay, the hotels' service ended endAfterDays later) and, for each unpaid monthly invoice, its own instants: dueAt, pauseAt, endAt. applies false means the rule is not in force for you yet (quota.startsOn says from when).\natCost: A hotel includes a number of room types and rate plans; past them the channel manager charges for each one. Our limits sit under what is included, so nothing is charged unless ZimmerStack raises a hotel's limit. When it does, what the hotel holds above the included number is recorded against you at the channel manager's own price, nothing added, and listed under atCost with its month, its hotel and whether it is on an invoice yet.\natCostInvoicing: atCost.invoicing says how a recorded line reaches an invoice today, and atCost.rule says it in a sentence. BY_ZIMMERSTACK: our team adds it to one of your invoices. AUTOMATIC: your next monthly invoice carries it by itself, one line for each, converted from US dollars to your invoice's currency at the same exchange rate as your price list that day, with the rate and its date printed on the line. Each line's standing says where it is for you (ON_INVOICE with its invoiceNumber, ON_NEXT_INVOICE, ADDED_BY_ZIMMERSTACK or NOT_CHARGED); GET /billing/next-invoice lists the lines that are on no invoice yet under its own atCost.\nmoney: Amounts are major units as decimal strings beside …Minor in hundredths, in the invoice's currency (x-zimmerstack.moneyByCurrency). The quota's pay-ahead figure, the onboarding fee and the at-cost lines are in US dollars.\n\n",
|
|
@@ -6130,8 +7375,8 @@ export const REFERENCE = {
|
|
|
6130
7375
|
"channels-and-modifiers": "## channels\nwhat: GET /channels lists the connections the channel manager holds for the property, from our record (the nightly settings sweep), with every unresolved problem the channel manager reported (rate_error, sync_error, disconnect_channel, the inventory pipe out of sync).\nfreshness: asOf says when the list was captured; a channel connected today appears after the next sweep. Problems are live.\npushed: The same problems are pushed as webhooks: channel.sync.alert when one is raised (channelKind names the channel; a change to a channel's money settings is one too, event settings_changed) and channel.sync.recovered when it ends: the channel reconnected, a re-check found it working, the hotel marked it as handled, or the inventory pipe recovered. recovered carries the alert's own event, channelId and raisedAt, so the two pair up (docs/webhooks).\n\n## modifiers\nwhat: One price per rate plan per night goes to every channel the plan is mapped to. A channel's modifier is the one thing that differs per channel: up to five ordered steps (raise or lower, by a percentage or a fixed amount in major units) the channel manager applies to every price it sends that channel. GET /channels shows each channel's steps; PUT /channels/{channelId}/modifier replaces them (scope channel-modifiers:write: one call moves every price on that channel. A software partner's keys hold it by default; a hotel's own key holds it when the owner ticked it).\ntakesEffect: Saving a modifier makes the channel manager send that channel every date again, so prices already on the channel move to the new rule within minutes.\nresend: Not needed after a modifier: the channel manager re-sends that channel every date itself. POST /rates/resend (scope ari:write) is for the rare case where the channel should get our record's prices and stay rules again, unchanged; re-sending the same price through PUT /rates does nothing, because a value our record already holds is dropped before anything is sent. A hotel may ask for it only a few times a day (data.scope rate-resends-day).\nworkflow:\n - GET /channels: find the channel (channelId, kind) and read the steps it holds\n - PUT /channels/{channelId}/modifier with the whole list of steps; [] removes the modifier\n - Nothing else: the channel manager sends that channel every date again, so prices already there move within minutes\nband:\n maxDecreasePct: 50\n maxIncreasePct: 100\nbandRule: The steps together may not lower a price by more or raise it by more than the band: 422 MODIFIER_OUT_OF_BAND, nothing changed. A fixed amount is judged at the property's lowest and highest standing price.\nshared: A connection that serves more than one property (one Airbnb or Booking.com account for sister hotels) is refused, 409 CHANNEL_SHARED: its modifier would move another hotel's prices. The hotels' owner sets it in ZimmerStack.\ngrid: GET /rates always answers the price before any modifier. What a channel is sent is that price with the channel's steps applied in order.\nmarkupPlan: markupPlan on GET /channels is a separate adjustment the owner may have set in the ZimmerStack Channels app; it applies before the modifier and is read-only here.\nsandbox: A sandbox has three pretend channels (Booking.com, MakeMyTrip, Agoda) so the whole workflow can be tried with a test key; nothing leaves our record.\n\n",
|
|
6131
7376
|
"sandbox": "## sandbox\nwhat: The owner creates a sandbox from a real property (admin → Developers → API keys, Channels → Integrations): a copy of its room types and rate plans that no channel ever sees. Keys minted there start with zsk_test_ and work ONLY there; a live key never reaches it.\npushes: Every route behaves as in production. A push lands in our record and stops: GET /sync reports IN_SYNC and GET /batches/{batchId} reports landed within a minute, through the same code path as a live property. GET /property says sandbox: true.\nmodify: POST /sandbox/bookings/{bookingId}/modify sends a modified revision — new dates, length, rooms or guest — and the REAL channel.booking.modified webhook with changes and previous, the old nights back on availability and the new ones off.\nbookings: POST /sandbox/bookings simulates an OTA booking end to end — the booking, the sandbox's availability moved down, the inventory event, and the REAL channel.booking.created webhook to every endpoint registered on the sandbox. POST /sandbox/bookings/{bookingId}/cancel does the same for a cancellation. With otaName \"Website\" the booking is one made on the hotel's own website instead, and the events are direct.booking.created and direct.booking.cancelled (x-zimmerstack.directBookings). A live key gets 403 SANDBOX_ONLY.\neveryType: A real event of every type can be made on a sandbox. channel.booking.created, .modified, .cancelled and direct.booking.created, .cancelled: the three booking routes above. direct.booking.modified: POST /sandbox/bookings/{bookingId}/no-show on a Website booking marks the guest a no-show (stayStatus NOSHOW, the nights back on sale), and { undo: true } takes it back. channel.sync.alert and channel.sync.recovered: POST /sandbox/sync-events with type, and event for which problem (rate_error, sync_error, disconnect_channel, settings_changed, inventory_out_of_sync); the problem is on one of the sandbox's pretend channels and GET /channels lists it until recovered clears it. A cancellation that arrives with no booking before it: POST /sandbox/bookings with arrivesCancelled: true sends channel.booking.cancelled alone. Each has a sequence and is in GET /events, which a Test button's sample is not.\nlimits: The same budgets as production (one sandbox per owner, up to five per software partner, at most five keys on each). Nothing you do there is billed or pushed to a channel.\ngoLive: Ask the owner for a zsk_live_ key on the real property, swap the key, keep the code.\n\n",
|
|
6132
7377
|
"dry-run-notices-explain": "## explain\nwhat: Before your software writes, it can see what the write will do; after it writes, the answer says what the write did NOT do; and any night's whole story is one call. A 202 only ever said the values were in our record. These say whether they do what you meant.\ndryRun:\n how: Add dryRun: true to the body of PUT /availability, PUT /rates or PUT /restrictions. The request is validated, coalesced and judged exactly as a real one, and stops before the first write. It answers 200 with a preview instead of 202.\n answers: verdict (would-write, nothing-to-write or would-refuse, with the refusal a real request would get now), the ranges that would change with the value sent, the ranges already held by our record and the channel manager, the ranges held after a refusal with the channel manager's words, what our record would refuse, prices that would be rounded, and the same notices the real write carries.\n costs: Charged like the write it previews against the budgets of a minute: one request and one write on the key and the property, and the same cells on the property's cells budget (x-zimmerstack.limitsTable). Never counted against the hour and day budgets of changed cells: it changes none. So a dry run is not a free read of the calendar; GET /availability, /rates and /restrictions are the reads.\n storesNothing: No batch, no queue entry, no idempotency key: send the same body without dryRun, under the same key if you like, to do it. Our record can move between the two; the real answer is the truth.\n limits: Each list of a preview holds at most 50 ranges; the field beside it (wouldChangeOmitted, unchangedOmitted, heldOmitted) says how many were left out. wouldReject foretells the refusals our record can know without writing: a real write can still refuse a group for a reason only the write meets.\n alsoOn: POST /availability/close and POST /availability/reopen take dryRun too.\nnotices:\n what: Every answer of an ARI write, and every preview, may carry notices: one plain sentence each, with a stable code, what it is about (room type, rate plans, nights, channels) and what to do. Warnings first; at most 20, with noticesOmitted for the rest. Absent when there is nothing to say.\n levels: warning: our record shows what you sent does not do the whole job (something still sells, nothing is sent, a rule of the hotel will undo it). info: how it works, said so the next surprise is not one.\n rule: Branch on code, show message and action to a person. A code you do not know is one added later: show it. Codes are never renamed and never change meaning.\n zeroAndStopSell: Two different things. Availability 0 is a COUNT of the room type: it closes the room on every rate plan and every channel, the rates an OTA links on its own side included, and it moves: an OTA cancellation puts a room back, your next count replaces it. A stop-sell is a SWITCH on ONE rate plan: it holds whatever the count does, and it stops that plan only, so the room keeps selling through its other plans and through any rate an OTA derives on its side. To close a room and keep it closed, do both: POST /availability/close.\n codes:\n - code: NOT_SOURCE_OF_TRUTH · level: warning · on: every write · means: The hotel is not live for this software yet: prices and stay rules sent now are stored and wait for go-live, and of room counts only one that lowers what is on sale goes out.\n - code: ROOM_TYPE_NOT_LINKED · level: warning · on: availability · means: The room type has no link to the channel manager: its count is kept and sent nowhere.\n - code: PLAN_NOT_LINKED · level: warning · on: rates, restrictions · means: The rate plan has no link to the channel manager: its values are kept and sent nowhere.\n - code: PLAN_NOT_MAPPED · level: warning · on: rates, restrictions · means: The rate plan is on the channel manager and no connected channel that is switched on sells it: nothing sells or stops because of this write.\n - code: ROOM_STILL_ON_SALE · level: warning · on: restrictions · means: You stop-sold one rate plan; the room is still on sale through its other plans (otherRatePlanIds).\n - code: OTA_LINKED_RATES_NOT_REACHED · level: info · on: restrictions · means: A stop-sell does not reach a rate an OTA links on its own side: only the room's count closes it.\n - code: STAY_RULES_FROM_ANOTHER_PLAN · level: warning · on: restrictions · means: On a channel, the OTA rate this plan sells takes its stay rules from another plan's row (otherRatePlanIds): a stay rule here alone does not reach it.\n - code: PER_OTA_PLANS_FOLLOW · level: info · on: rates, restrictions · means: The plan has per-OTA plans: its price is copied onto them and they follow its stay rules.\n - code: PER_OTA_PLAN_FOLLOWS_PARENT · level: warning · on: rates, restrictions · means: The plan you wrote is a per-OTA plan: its parent's price and stay rules replace what is set here.\n - code: VALUE_HELD · level: warning · on: rates, restrictions · means: The value equals one the channel manager refused: it is held with its words, not sent again.\n - code: COUNT_WAS_REFUSED · level: warning · on: availability · means: The last count sent for these nights was refused by the channel manager and nothing has landed since.\n - code: COUNT_ZERO_IS_NOT_STOP_SELL · level: info · on: availability · means: You sent availability 0: a count that closes every plan and channel, and that the next OTA cancellation or your next count moves. Not a switch.\n - code: STOP_SELL_IS_NOT_A_COUNT · level: info · on: restrictions · means: You sent a stop-sell: a switch on those plans. The room's count is untouched.\n - code: COUNT_OPEN_BUT_PLANS_STOPPED · level: warning · on: availability · means: You sent a count above 0 for nights on which every plan of the room is stop-sold: the room does not sell.\n - code: NEW_DATES_OPEN_CLOSED · level: warning · on: availability · means: The hotel's rule \"new dates open closed\" will set these nights to 0 when they come on sale.\n - code: FAR_NIGHTS_NEED_A_COUNT · level: warning · on: rates, restrictions · means: A night past day 365 with no count of its own goes out closed, whatever its price or stay rules.\n - code: ENGINE_WILL_REPRICE · level: warning · on: rates · means: The hotel's pricing engine is set to win: it replaces a price sent here at its next hourly update.\n - code: ENGINE_WILL_RECOUNT · level: warning · on: availability · means: The hotel publishes the count its bookings work out: a count above 0 sent here is replaced. A 0 holds.\n - code: DRIFT_REPAIR_OFF · level: info · on: rates, restrictions · means: The hotel switched the nightly repair off: a value changed on the channel manager's side is reported, not sent again.\nclose:\n what: POST /availability/close closes one room type on a range of nights everywhere, in one call: it sets the room type's count to 0 and switches stop-sell on for every one of its rate plans (their per-OTA plans take it from them on the channel manager). You do not need to know the hotel's plans. Scope ari:write.\n answer: What was closed (count.changedNights, and each rate plan with its nights), what was already closed, and notReached: every plan that is not linked or that no channel sells, and the one thing no stop-sell reaches, a rate an OTA links on its own side, which only the count closes.\n reopen: POST /availability/reopen undoes exactly that close and nothing else: it lifts the stop-sell on the plans the close switched on (a plan that was already stop-sold before stays stopped) and puts back the count each night held before. Name available to set a count yourself instead: only your software knows how many rooms are free now. A night whose count was changed after the close is left as it is, and a night the close had not closed is skipped (skippedNights).\n writes: Both are ordinary writes underneath: 202 with a batch for the count and one for the stay rules to watch with GET /batches/{batchId}; 200 when nothing had to change, and on a dry run. Charged the room type's count and each of its plans for every night against the cells budget.\n shield: A close only closes inventory, so it is accepted while the integration is paused or out of budget, on the safety lane (lane: true). A reopen opens inventory and waits like any other open (429 RATE_LIMITED, data.scope shield-pause).\nnight:\n what: GET /explain?roomTypeId=&date=, optionally &ratePlanId=: one night's whole story from our record. Scope ari:read. No call is made to the channel manager, so it can be asked at any time.\n answers: For the room type's count and for each rate plan's price and stay rules: what your software last sent and when (with its batch id), what our record holds and who set it, what the channel manager was last seen holding and when; every send of the count we still hold and how it ended, a refused value in the channel manager's own words; the plan's per-OTA plans; every connection and whether it sells the plan; the rules in force that night; the bookings that hold or held a room (ids and times, never a guest); and summary, the same in plain sentences.\n honest: Where we do not know, the answer says so: seenAt null means the night was never read back from the channel manager; lastSent null means the write is older than the ones we kept the values of (searched says how far we looked); channels.known false means the hotel's connections have not been read yet.\n notOtas: We hold the channel manager's copy, not each OTA's: what an OTA shows is what the channel manager passed to it.\nnotMapped: A rate plan can be on the channel manager and sold by no connected channel. What each connection maps is read from the channel manager every night and kept (channels.seenAt on GET /explain). Such a plan is named three ways: the notice PLAN_NOT_MAPPED on a write, unreachable[] with status not-mapped on its batch (which still lands: the values are sent), and reach on GET /explain.\nsandboxFaults:\n what: On a sandbox the pretend channel takes everything. POST /sandbox/faults makes it misbehave, so you can watch your software handle what a live hotel meets on a bad day. Test keys only (403 SANDBOX_ONLY). Prices and stay rules only: room counts land as before.\n kinds:\n refuse: The next values (rate plan × night) are refused as the channel manager refuses: the nights are held with its words, the batch reads failed with parkedCells, GET /sync counts them, your webhook receives channel.sync.alert (value_refused), and the same value sent again is answered as held.\n throttle: For minutes, every push is answered \"too many requests\": batches wait (pending, then failed from the fifth attempt in a row, as on a live hotel), nothing is lost, no alert is sent, and it lands by itself afterwards.\n outage: For minutes, every push fails. After five failed attempts, one a minute on a sandbox, your webhook receives channel.sync.alert (rates_out_of_sync) and the batch reads failed; when the outage ends the next attempt lands and channel.sync.recovered follows.\n answer: The fault in force and watch: what to do next and what your software should then see, step by step. GET /sandbox/faults reads it; DELETE /sandbox/faults ends it. One fault at a time; a new one replaces it.\n\n",
|
|
6133
|
-
"errors": "Every refusal is { statuscode, message, data: { code, … } }. Branch on data.code (the client: err.code): it is stable. message is for a person and may change.\nRetry only 429, 5xx and IDEMPOTENCY_IN_FLIGHT, after Retry-After; every other code is a verdict on the request. A 429 is always safe to send again; a 5xx only for a read or a write that carries an idempotency key. The client does this by itself.\n\n- API_KEY_INVALID (401): \"Unauthorized\"\n- API_KEY_REVOKED (401): \"Unauthorized\"\n- API_KEY_EXPIRED (401): \"Unauthorized\" [POST /properties, DELETE /properties/{propertyId}]\n- CONNECT_API_NOT_CONFIGURED\n- IP_NOT_ALLOWED (403): \"This API key may not be used from this address. The property owner restricts it to an allowlist.\"\n- SCOPE_MISSING (403): \"This API key does not have the bookings:write scope. The property owner grants scopes when creating or editing a key.\"\n- PROPERTY_UNAVAILABLE (409): \"This property is not available to the API any more. Contact the property owner.\"\n- CHANNEL_MANAGER_DISABLED (409): \"This property's channel manager is switched off, so writes would not reach any channel. Contact the property owner.\"\n- PMS_NOT_AVAILABLE (409): \"This property runs the channel manager only; there is no PMS to put a booking in.\"\n- VALIDATION (400): \"updates[0].available: Expected number, received string\"\n- RANGE_INVALID (400)\n- HORIZON (400): \"updates[0]: 2028-06-01 is beyond the horizon (last writable night is 2028-02-24, today + 500 days)\" [PUT /availability, PUT /rates, PUT /restrictions, POST /availability/close, POST /availability/reopen]\n- TOO_MANY_UPDATES (400) [PUT /availability, PUT /rates, PUT /restrictions]\n- TOO_MANY_CELLS (400): \"a request may name at most 5000 cells (entity × night); split the calendar into several requests\" [PUT /availability, PUT /rates, PUT /restrictions, POST /availability/close, POST /availability/reopen]\n- UNKNOWN_ROOM_TYPE (400)\n- UNKNOWN_RATE_PLAN (400): \"rate plan(s) 77 do not belong to this property (see GET /catalog)\" [PUT /rates, PUT /restrictions, GET /explain, POST /bookings]\n- CURRENCY_MISMATCH (400): \"rates must be sent in INR (got EUR)\" [PUT /rates, POST /bookings]\n- RATE_LIMITED (429): \"Too many requests on this API key. Slow down and retry after the Retry-After interval.\"\n- NOTHING_ACCEPTED (422): \"exceptions are switched off for this property — move the base rate instead\" [PUT /availability, PUT /rates, PUT /restrictions]\n- BATCH_NOT_FOUND (404): \"Batch not found.\"\n- IDEMPOTENCY_KEY_INVALID (400) [POST /properties]\n- IDEMPOTENCY_KEY_REUSED (409): \"This idempotency key was already used with a different request body.\" [POST /properties]\n- IDEMPOTENCY_IN_FLIGHT (409) [POST /properties]\n- STAY_INVALID (400): \"checkIn 2026-10-01 is in the past (today at the property is 2026-10-20)\" [POST /bookings, POST /sandbox/bookings, POST /sandbox/bookings/{bookingId}/modify]\n- UNKNOWN_ROOM_TYPE_FOR_PLAN (400) [POST /bookings]\n- OCCUPANCY_EXCEEDED (400): \"rooms[0]: Deluxe takes at most 3 adults (got 4)\" [POST /bookings]\n- NO_AVAILABILITY (409): \"room type 412 has 0 left on 2026-12-21; 1 requested\" [POST /bookings]\n- EXTERNAL_REFERENCE_REUSED (409) [POST /bookings]\n- PAYMENT_NOT_ALLOWED (403): \"This API key may not record payments. The property owner grants the bookings:payments scope.\" [POST /bookings]\n- PAYMENT_EXCEEDS_TOTAL (400): \"payment.amount 30000.00 exceeds the stay total 27000.00\" [POST /bookings]\n- TAXES_NOT_CONFIGURED (409): \"This property has no confirmed tax lines, so a rate before taxes cannot be completed. Send nightlyRate as the guest pays it (leave nightlyRateIncludesTaxes out), or ask the hotel to confirm its taxes in admin, Policies, Taxes. Either way send the booking again with a new x-idempotency-key.\" [POST /bookings]\n- TAXES_INSIDE_RATES (409): \"This property's taxes are inside its prices, so there is nothing to add to a rate before taxes. Send nightlyRate as the guest pays it (leave nightlyRateIncludesTaxes out), with a new x-idempotency-key.\" [POST /bookings]\n- BOOKING_NOT_FOUND (404): \"Booking not found.\"\n- BOOKING_NOT_CANCELLABLE (409): \"Booking already checked in. Ask the hotel to handle it at the desk.\"\n- MODULE_NOT_ENTITLED (402): \"This property's plan does not include the PMS.\"\n- SANDBOX_ONLY (403): \"The sandbox routes answer only to a test key (zsk_test_…) on a sandbox property. This key is a live key.\" [POST /sandbox/bookings, POST /sandbox/bookings/{bookingId}/cancel, POST /sandbox/bookings/{bookingId}/modify]\n- ROOM_TYPE_NOT_FOUND (404): \"That room type doesn't exist.\"\n- RATE_PLAN_NOT_FOUND (404): \"That rate plan doesn't exist.\"\n- CATALOG_CONFLICT (409): \"A room type with this name already exists.\" [PUT /catalog/room-types, PUT /catalog/rate-plans]\n- CATALOG_BUSY (409): \"Another room-type or rate-plan write for this property is still running. Retry in a few seconds.\"\n- CHANNEL_MANAGER_ERROR (502): \"The channel manager refused the delete. Nothing changed here; try again in a moment.\"\n- WEBHOOK_ENDPOINT_NOT_FOUND\n- WEBHOOK_DELIVERY_NOT_FOUND\n- WEBHOOK_ENDPOINT_LIMIT\n- WEBHOOK_ENDPOINT_NOT_ACTIVE\n- WEBHOOK_ENDPOINT_SUSPENDED\n- WEBHOOK_PAYLOAD_EXPIRED\n- WEBHOOK_ACCESS_ENDED\n- WEBHOOKS_UNAVAILABLE\n- PROPERTY_REQUIRED (400): \"This is a company key: name the hotel in the X-ZS-Property header, with its id from GET /properties.\"\n- PROPERTY_NOT_FOUND (404): \"No property with this id that this key may act on (see GET /properties).\"\n- ARI_NOT_AUTHORITATIVE (409): \"This property's local rates and availability are not the channels' source of truth yet, so API writes would never be pushed. Contact ZimmerStack support.\"\n- ROUTE_NOT_FOUND (404): \"No GET /api/v1/connect-api/v1/nope in the Connect API; the contract lists every route.\"\n- PAYLOAD_TOO_LARGE (413): \"The request body is larger than the API accepts. Split the updates array across requests.\"\n- AUTH_BACKEND_UNAVAILABLE\n- BOOKING_NOT_MODIFIABLE (409): \"A cancelled booking cannot be modified from the sandbox.\"\n- SANDBOX_NOT_FOUND\n- SANDBOX_INCOMPLETE\n- WRITES_FROZEN (503): \"ZimmerStack has paused every write to the channel manager for now. Nothing was written. Retry after the Retry-After interval; reads and bookings are not affected.\"\n- WRITES_SUSPENDED (403): \"ZimmerStack has suspended writes for this integration: it kept sending after repeated notices. Reads and bookings still work. Contact ZimmerStack support to have it released.\"\n- SHIELD_UNAVAILABLE (503): \"The write could not be checked against this property's budgets right now. Nothing was written. Retry after the Retry-After interval.\"\n- CATALOG_LIMIT_REACHED (409): \"This property holds 298 rate plans and may hold 300; this request would add 6. Delete what is unused, or ask ZimmerStack support to raise the limit.\" [PUT /catalog/room-types, PUT /catalog/rate-plans]\n- TOO_MANY_NEW_ENTITIES (400): \"This request would create 34 new room types or rate plans; one request may create at most 20. Entities that already exist do not count. Split the new ones across requests.\" [PUT /catalog/room-types, PUT /catalog/rate-plans]\n- RATE_OUT_OF_BAND (422): \"rate plan 901 on 2026-12-01: 45 INR is below the band around this plan's standing price 4500 INR (lowest accepted 450) (and 29 more cells). Rates are sent in major units (4500, not 450000). If the price is meant, change the plan's standing price first (PUT /catalog/rate-plans defaultRate), or ask ZimmerStack support to lift the band for this property.\" [PUT /availability, PUT /rates, PUT /restrictions]\n- CHANNEL_NOT_FOUND (404): \"No connected channel with this id on this property. GET /channels lists them.\" [PUT /channels/{channelId}/modifier]\n- CHANNEL_SHARED (409): \"This connection serves more than one property, so its modifier would move another hotel's prices too. It is set by the hotels' owner in ZimmerStack, not through this API. Nothing was changed.\" [PUT /channels/{channelId}/modifier]\n- MODIFIER_OUT_OF_BAND (422): \"These steps would change what the channel is sent by +180%; a channel's modifier must stay between 50% lower and 100% higher. Nothing was changed.\"\n- COMPANY_KEY_REQUIRED (403): \"Hotels are added and removed with your company key. This key belongs to one hotel.\"\n- BILLING_SETUP_REQUIRED (409): \"Accept the price list and add your billing details on the Billing page of the partner portal first. Then send the request again under a new idempotency key.\" [POST /properties]\n- OWNER_HAS_ACCOUNT (409): \"This owner already has an account you did not create. Ask them to enter your vendor code under Integrations.\" [POST /properties]\n- SANDBOX_LIMIT (409): \"You hold 5 sandboxes, the most one company may have. Remove one first. Then send the request again under a new idempotency key.\" [POST /properties]\n- CONFIRMATION_MISMATCH (400): \"Send confirm= with the hotel's exact name, as GET /properties prints it.\"\n- PROPERTY_NOT_REMOVABLE (409): \"You did not add this hotel: its owner let you in. Ask the owner to remove your access under Integrations.\"\n- PROPERTY_BUSY (503): \"This hotel, or another of yours, is still being added or removed. Retry shortly.\" [POST /properties, DELETE /properties/{propertyId}]\n- PRICE_UNAVAILABLE (503): \"This hotel cannot be priced right now. Retry in a few minutes.\" [POST /properties]\n- CONNECT_LINK_NOT_FOUND (404): \"Connect link not found.\" [GET /connect-links/{linkId}, POST /connect-links/{linkId}/revoke]\n- CONNECT_LINKS_UNAVAILABLE\n- CHANNEL_NOT_AVAILABLE (409): \"MakeMyTrip · Goibibo is available to hotels in India.\" [POST /connect-links]\n- LIVE_KEY_REQUIRED (409): \"A connect link connects a real booking site, so it is made with a live key. To see what a link tells you when it ends, send yourself a test event (POST /webhook-endpoints/{endpointId}/test with eventType channel.connect.completed).\" [POST /connect-links]\n- NOT_READY (409): \"This hotel is not ready to go live: Your software has not sent the next 365 nights yet.\" [POST /go-live]\n- KEY_NOT_FOUND (404): \"No such key among the ones you created on this property.\" [POST /properties/{propertyId}/keys/{keyId}/rotate, POST /properties/{propertyId}/keys/{keyId}/revoke]\n- KEY_LIMIT (409): \"A property may hold at most 5 active API keys. Revoke one first.\" [POST /properties/{propertyId}/keys]\n- KEY_REVOKED (401)\n- KEY_ALREADY_ROTATING (409) [POST /properties/{propertyId}/keys/{keyId}/rotate]\n- SCOPES_INVALID (400) [POST /properties/{propertyId}/keys]\n- ALLOWED_CIDRS_INVALID (400) [POST /properties/{propertyId}/keys]\n- REASON_REQUIRED (400) [POST /properties/{propertyId}/keys/{keyId}/revoke]\n- SUPPORT_TICKET_NOT_FOUND (404): \"Support ticket not found.\"\n- SUPPORT_TICKET_CLOSED (409): \"This ticket is closed. Open a new one and name this ticket in it.\"\n",
|
|
7378
|
+
"errors": "Every refusal is { statuscode, message, data: { code, … } }. Branch on data.code (the client: err.code): it is stable. message is for a person and may change.\nRetry only 429, 5xx and IDEMPOTENCY_IN_FLIGHT, after Retry-After; every other code is a verdict on the request. A 429 is always safe to send again; a 5xx only for a read or a write that carries an idempotency key. The client does this by itself.\n\n- API_KEY_INVALID (401): \"Unauthorized\"\n- API_KEY_REVOKED (401): \"Unauthorized\"\n- API_KEY_EXPIRED (401): \"Unauthorized\" [POST /properties, PATCH /properties/{propertyId}, DELETE /properties/{propertyId}]\n- CONNECT_API_NOT_CONFIGURED\n- IP_NOT_ALLOWED (403): \"This API key may not be used from this address. The property owner restricts it to an allowlist.\"\n- SCOPE_MISSING (403): \"This API key does not have the bookings:write scope. The property owner grants scopes when creating or editing a key.\"\n- PROPERTY_UNAVAILABLE (409): \"This property is not available to the API any more. Contact the property owner.\"\n- CHANNEL_MANAGER_DISABLED (409): \"This hotel is not on the channel manager yet. Send its room types and rate plans (PUT /catalog/room-types, then PUT /catalog/rate-plans), or press Finish setup in the Channels app. Either puts it there.\"\n- PMS_NOT_AVAILABLE (409): \"This property runs the channel manager only; there is no PMS to put a booking in.\"\n- VALIDATION (400): \"updates[0].available: Expected number, received string\"\n- RANGE_INVALID (400)\n- HORIZON (400): \"updates[0]: 2028-06-01 is beyond the horizon (last writable night is 2028-02-24, today + 500 days)\" [PUT /availability, PUT /rates, PUT /restrictions, POST /availability/close, POST /availability/reopen]\n- TOO_MANY_UPDATES (400) [PUT /availability, PUT /rates, PUT /restrictions]\n- TOO_MANY_CELLS (400): \"a request may name at most 5000 cells (entity × night); split the calendar into several requests\" [PUT /availability, PUT /rates, PUT /restrictions, POST /availability/close, POST /availability/reopen]\n- UNKNOWN_ROOM_TYPE (400)\n- UNKNOWN_RATE_PLAN (400): \"rate plan(s) 77 do not belong to this property (see GET /catalog)\" [PUT /rates, PUT /restrictions, GET /explain, POST /bookings]\n- CURRENCY_MISMATCH (400): \"rates must be sent in INR (got EUR)\" [PUT /rates, POST /bookings]\n- RATE_LIMITED (429): \"Too many requests on this API key. Slow down and retry after the Retry-After interval.\"\n- NOTHING_ACCEPTED (422): \"exceptions are switched off for this property — move the base rate instead\" [PUT /availability, PUT /rates, PUT /restrictions]\n- BATCH_NOT_FOUND (404): \"Batch not found.\"\n- IDEMPOTENCY_KEY_INVALID (400) [POST /properties]\n- IDEMPOTENCY_KEY_REUSED (409): \"This idempotency key was already used with a different request body.\" [POST /properties, PATCH /properties/{propertyId}]\n- IDEMPOTENCY_IN_FLIGHT (409) [POST /properties, PATCH /properties/{propertyId}]\n- STAY_INVALID (400): \"checkIn 2026-10-01 is in the past (today at the property is 2026-10-20)\" [POST /bookings, POST /sandbox/bookings, POST /sandbox/bookings/{bookingId}/modify]\n- UNKNOWN_ROOM_TYPE_FOR_PLAN (400) [POST /bookings]\n- OCCUPANCY_EXCEEDED (400): \"rooms[0]: Deluxe takes at most 3 adults (got 4)\" [POST /bookings]\n- NO_AVAILABILITY (409): \"room type 412 has 0 left on 2026-12-21; 1 requested\" [POST /bookings]\n- EXTERNAL_REFERENCE_REUSED (409) [POST /bookings]\n- PAYMENT_NOT_ALLOWED (403): \"This API key may not record payments. The property owner grants the bookings:payments scope.\" [POST /bookings]\n- PAYMENT_EXCEEDS_TOTAL (400): \"payment.amount 30000.00 exceeds the stay total 27000.00\" [POST /bookings]\n- TAXES_NOT_CONFIGURED (409): \"This property has no confirmed tax lines, so a rate before taxes cannot be completed. Send nightlyRate as the guest pays it (leave nightlyRateIncludesTaxes out), or ask the hotel to confirm its taxes in admin, Policies, Taxes. Either way send the booking again with a new x-idempotency-key.\" [POST /bookings]\n- TAXES_INSIDE_RATES (409): \"This property's taxes are inside its prices, so there is nothing to add to a rate before taxes. Send nightlyRate as the guest pays it (leave nightlyRateIncludesTaxes out), with a new x-idempotency-key.\" [POST /bookings]\n- BOOKING_NOT_FOUND (404): \"Booking not found.\"\n- BOOKING_NOT_CANCELLABLE (409): \"Booking already checked in. Ask the hotel to handle it at the desk.\"\n- MODULE_NOT_ENTITLED (402): \"This property's plan does not include the PMS.\"\n- SANDBOX_ONLY (403): \"The sandbox routes answer only to a test key (zsk_test_…) on a sandbox property. This key is a live key.\" [POST /sandbox/bookings, POST /sandbox/bookings/{bookingId}/cancel, POST /sandbox/bookings/{bookingId}/modify]\n- ROOM_TYPE_NOT_FOUND (404): \"That room type doesn't exist.\"\n- RATE_PLAN_NOT_FOUND (404): \"That rate plan doesn't exist.\"\n- CATALOG_CONFLICT (409): \"A room type with this name already exists.\" [PUT /catalog/room-types, PUT /catalog/rate-plans]\n- CATALOG_BUSY (409): \"Another room-type or rate-plan write for this property is still running. Retry in a few seconds.\"\n- CHANNEL_MANAGER_ERROR (502): \"The channel manager refused the delete. Nothing changed here; try again in a moment.\"\n- WEBHOOK_ENDPOINT_NOT_FOUND\n- WEBHOOK_DELIVERY_NOT_FOUND\n- WEBHOOK_ENDPOINT_LIMIT\n- WEBHOOK_ENDPOINT_NOT_ACTIVE\n- WEBHOOK_ENDPOINT_SUSPENDED\n- WEBHOOK_PAYLOAD_EXPIRED\n- WEBHOOK_ACCESS_ENDED\n- WEBHOOKS_UNAVAILABLE\n- PROPERTY_REQUIRED (400): \"This is a company key, so each request names its hotel in the X-ZS-Property header, with the hotel's id. GET /properties lists your hotels.\"\n- PROPERTY_NOT_FOUND (404): \"No property with this id that this key may act on (see GET /properties).\"\n- ARI_NOT_AUTHORITATIVE (409): \"This property's local rates and availability are not the channels' source of truth yet, so API writes would never be pushed. Contact ZimmerStack support.\"\n- ROUTE_NOT_FOUND (404): \"No GET /api/v1/connect-api/v1/nope in the Connect API; the contract lists every route.\"\n- PAYLOAD_TOO_LARGE (413): \"The request body is larger than the API accepts. Split the updates array across requests.\"\n- AUTH_BACKEND_UNAVAILABLE\n- BOOKING_NOT_MODIFIABLE (409): \"A cancelled booking cannot be modified from the sandbox.\"\n- SANDBOX_NOT_FOUND\n- SANDBOX_INCOMPLETE\n- WRITES_FROZEN (503): \"ZimmerStack has paused every write to the channel manager for now. Nothing was written. Retry after the Retry-After interval; reads and bookings are not affected.\"\n- WRITES_SUSPENDED (403): \"ZimmerStack has suspended writes for this integration: it kept sending after repeated notices. Reads and bookings still work. Contact ZimmerStack support to have it released.\"\n- SHIELD_UNAVAILABLE (503): \"The write could not be checked against this property's budgets right now. Nothing was written. Retry after the Retry-After interval.\"\n- CATALOG_LIMIT_REACHED (409): \"This property holds 298 rate plans and may hold 300; this request would add 6. Delete what is unused, or ask ZimmerStack support to raise the limit.\" [PUT /catalog/room-types, PUT /catalog/rate-plans]\n- TOO_MANY_NEW_ENTITIES (400): \"This request would create 34 new room types or rate plans; one request may create at most 20. Entities that already exist do not count. Split the new ones across requests.\" [PUT /catalog/room-types, PUT /catalog/rate-plans]\n- RATE_OUT_OF_BAND (422): \"rate plan 901 on 2026-12-01: 45 INR is below the band around this plan's standing price 4500 INR (lowest accepted 450) (and 29 more cells). Rates are sent in major units (4500, not 450000). If the price is meant, change the plan's standing price first (PUT /catalog/rate-plans defaultRate), or ask ZimmerStack support to lift the band for this property.\" [PUT /availability, PUT /rates, PUT /restrictions]\n- CHANNEL_NOT_FOUND (404): \"No connected channel with this id on this property. GET /channels lists them.\" [PUT /channels/{channelId}/modifier]\n- CHANNEL_SHARED (409): \"This connection serves more than one property, so its modifier would move another hotel's prices too. It is set by the hotels' owner in ZimmerStack, not through this API. Nothing was changed.\" [PUT /channels/{channelId}/modifier]\n- MODIFIER_OUT_OF_BAND (422): \"These steps would change what the channel is sent by +180%; a channel's modifier must stay between 50% lower and 100% higher. Nothing was changed.\"\n- COMPANY_KEY_REQUIRED (403): \"Hotels are added and removed with your company key. This key belongs to one hotel.\"\n- BILLING_SETUP_REQUIRED (409): \"Accept the price list and add your billing details on the Billing page of the partner portal first. Then send the request again under a new idempotency key.\" [POST /properties]\n- OWNER_HAS_ACCOUNT (409): \"This owner already has an account you did not create. Ask them to enter your vendor code under Integrations.\" [POST /properties]\n- SANDBOX_LIMIT (409): \"You hold 5 sandboxes, the most one company may have. Remove one first. Then send the request again under a new idempotency key.\" [POST /properties]\n- CONFIRMATION_MISMATCH (400): \"Send confirm= with the hotel's exact name, as GET /properties prints it.\"\n- PROPERTY_NOT_REMOVABLE (409): \"You did not add this hotel: its owner let you in. Ask the owner to remove your access under Integrations.\"\n- PROPERTY_NOT_CHANGEABLE (409): \"You did not add this hotel: its owner let you in. Its name and address are the owner's to change.\" [PATCH /properties/{propertyId}]\n- PROPERTY_BUSY (503): \"This hotel, or another of yours, is still being added or removed. Retry shortly.\" [POST /properties, DELETE /properties/{propertyId}]\n- PRICE_UNAVAILABLE (503): \"This hotel cannot be priced right now. Retry in a few minutes.\" [POST /properties]\n- CONNECT_LINK_NOT_FOUND (404): \"Connect link not found.\" [GET /connect-links/{linkId}, POST /connect-links/{linkId}/revoke]\n- CONNECT_LINKS_UNAVAILABLE\n- CHANNEL_NOT_AVAILABLE (409): \"MakeMyTrip · Goibibo is available to hotels in India.\" [POST /connect-links]\n- LIVE_KEY_REQUIRED (409): \"A connect link connects a real booking site, so it is made with a live key. To see what a link tells you when it ends, send yourself a test event (POST /webhook-endpoints/{endpointId}/test with eventType channel.connect.completed).\" [POST /connect-links]\n- NOT_READY (409): \"This hotel is not ready to go live: Your software has not sent the next 365 nights yet.\" [POST /go-live]\n- KEY_NOT_FOUND (404): \"No such key among the ones you created on this property.\" [POST /properties/{propertyId}/keys/{keyId}/rotate, POST /properties/{propertyId}/keys/{keyId}/revoke]\n- KEY_LIMIT (409): \"A property may hold at most 5 active API keys. Revoke one first.\" [POST /properties/{propertyId}/keys]\n- KEY_REVOKED (401)\n- KEY_ALREADY_ROTATING (409) [POST /properties/{propertyId}/keys/{keyId}/rotate]\n- SCOPES_INVALID (400) [POST /properties/{propertyId}/keys]\n- ALLOWED_CIDRS_INVALID (400) [POST /properties/{propertyId}/keys]\n- REASON_REQUIRED (400) [POST /properties/{propertyId}/keys/{keyId}/revoke]\n- SUPPORT_TICKET_NOT_FOUND (404): \"Support ticket not found.\"\n- SUPPORT_TICKET_CLOSED (409): \"This ticket is closed. Open a new one and name this ticket in it.\"\n",
|
|
6134
7379
|
"webhooks": "ZimmerStack POSTs a signed JSON event to the endpoint the hotel's owner (or a software vendor) registered.\n- Three more families, each only for an endpoint that lists its types: channel.connect.completed and channel.connect.expired (how a one-time connect link ended; data.connect names the link by linkId; it names its hotel and is in the event log); platform.incident.opened, .updated and .resolved (ZimmerStack's staff recorded an incident that touches your hotels; data.incident, with properties naming YOUR hotels it touches); support.ticket.replied and support.ticket.closed (ZimmerStack answered or closed your support ticket; data.ticket and data.message; company endpoints only). The incident and ticket events are about your account: they carry NO top-level property and NO sequence, are not in the event log, and Recover since does not replay them (zs.status.get() and zs.supportTickets.get(ticketId) are the reads). Narrow them with isConnectEvent(event), isIncidentEvent(event) and isSupportTicketEvent(event), and check the last two before any code that reads event.property.\n- Events: channel.booking.created, channel.booking.modified, channel.booking.cancelled (an OTA booking arrived, changed, was cancelled); direct.booking.created, direct.booking.modified, direct.booking.cancelled (a guest booked on the hotel's own website through ZimmerStack's booking engine, the hotel recorded that the guest did not arrive or undid that, or the booking was cancelled: topic website-bookings; an endpoint gets each only when it lists that type); channel.sync.alert and channel.sync.recovered (a channel problem began: a refused value, a disconnect, prices or room counts that stopped going out, a setting changed, named in data.sync.event; and ended); channel.drift.detected and channel.drift.healed (a nightly read found the channel manager holding something other than what you sent, data.drift.cells names the nights; then found it agreeing again: an endpoint gets them only when it lists the type); zimmerstack.ping (a test).\n- Envelope: { id, type, apiVersion, occurredAt, mode: \"live\" | \"test\", sequence, property: { id, name, currency, timezone }, data: { booking } (or { sync }, { drift }), changes, previous }.\n- sequence is the event's place in its hotel's ordered log, one higher than the hotel's last. The webhook is the nudge; the log is the truth (topic event-log): keep the last sequence you applied and read zs.events.all({ after }) from it, on every delivery, on a schedule and after a restart. A Test button's sample has no sequence.\n- data.booking.version counts that booking's events (1, 2, 3 …): a higher version is a later state, whatever order deliveries arrived in.\n- Signature (Standard Webhooks): headers webhook-id, webhook-timestamp, webhook-signature. The signature is \"v1,\" + base64(HMAC-SHA256(secret, id + \".\" + timestamp + \".\" + rawBody)); the secret is whsec_ + base64. During a rotation the header carries two, space-separated.\n- Verify the RAW body before parsing it, compare in constant time, and refuse a timestamp more than five minutes old. With this package: const event = await verifyWebhook(rawBody, headers, secret); it throws ZimmerStackWebhookError otherwise.\n- Deliveries are at-least-once and may arrive out of order: dedupe on event.id, order on occurredAt. Answer 2xx within seconds and do slow work afterwards.\n- GET /events (zs.events.all({ after })) replays every event in order; GET /channel-bookings (zs.channelBookings.all({ since })) and GET /direct-bookings (zs.directBookings.all({ since })) give each booking's latest state, for a first load or after the log's retention. They are not polling loops.\n- isSyncEvent(event) and isDriftEvent(event) narrow the channel events (data.sync, data.drift).\n- A partner's company key with the scope webhooks:manage manages its own endpoints by API (topic webhook-endpoints): zs.webhookEndpoints.*.\n- isWebsiteBookingEvent(event) says an event is a website booking (direct.booking.*); isOtaBookingEvent(event) says it is an OTA booking (channel.booking.*). The booking object is the same in both.\n- direct.booking.modified is a no-show or its undo, not a cancellation: status stays CONFIRMED, the payment is untouched, and data.booking.stayStatus says NOSHOW (free the room) or UPCOMING again (hold it). changes and previous are set on it, as on channel.booking.modified.\n",
|
|
6135
|
-
"the-package": "@zimmerstack/connect 0.9.0: npm install @zimmerstack/connect. Node 20 or newer, on a server only, zero dependencies.\n\nconst zs = new ZimmerStack(); // reads ZIMMERSTACK_CONNECT_KEY; make one per process and reuse it\n\nEvery operation has a method: each operation's lookup names it (\"With the package\"). On top of those:\n- zs.grid.load(from, to): the whole rate grid for a window, ready for a screen. Rows are room types with their rate plans, columns are nights; prices in MAJOR units. Three reads (four the first time; the catalog is kept ten minutes).\n- zs.grid.save(edits): what a person changed, as single nights { availability?, rates?, restrictions? }. Folds nights into ranges, fills in the currency, splits a large save, sends one request per resource in turn. Returns the accepted answers, each with a batchId.\n- zs.batches.wait(batchId): asks every 15 seconds at the fastest, for at most five minutes; returns the last status (\"landed\", \"failed\", or still \"pending\").\n- zs.channelBookings.all({ since }): an async iterator over every OTA booking changed since then, following the cursor.\n- zs.directBookings.all({ since }): the same for the bookings guests made on the hotel's own website (scope direct-bookings:read). Read it before a full availability push.\n- zs.roomTypes.list(), zs.roomTypes.save(roomType), zs.roomTypes.delete(idOrRef) and zs.ratePlans.list(), zs.ratePlans.save(ratePlan), zs.ratePlans.delete(idOrRef): a hotel's room types and rate plans one at a time. save creates one, or changes it when that ref was sent before, and answers with its id. delete takes ZimmerStack's id (a number) or your own ref (a string), deletes for good, and a room type takes its rate plans with it. Scope catalog:write.\n- zs.properties.create(hotel) and zs.properties.delete(propertyId, { confirm }) (also zs.properties.remove): a software partner's company key adds a hotel and removes one it added, for good. Scope properties:write, a company key only. confirm is the hotel's exact name. With a test key they make and delete a sandbox.\n- zs.forProperty(propertyId): a software vendor's company key acting on one hotel. Each hotel has its own queue of writes and its own pace; what all the hotels share (the company's budget) is paced for all of them.\n- zs.limits.get(): every budget this key sits under (the key's, its hotel's, the company's), with its window, its quota, what is left and when it refills, and the budgets over an hour and a day. Any key; reading uses up nothing.\n- zs.events.all({ after }): an async iterator over the hotel's ordered event log from the sequence you saved to its end; each event carries its sequence, which is your new place. onGap tells you when the log no longer holds what follows your place. zs.events.list({ after }) is one page.\n- zs.requests.list({ status: \"errors\" }) and zs.requests.all(query): this key's own requests of the last 7 days (time, route, status, error code, address, request id; never a body).\n- zs.webhookEndpoints.list(), .create(body), .get(id), .update(id, body), .pause(id), .resume(id), .rotateSecret(id), .test(id, { eventType }), .recover(id, since), .delete(id) and zs.webhookEndpoints.deliveries.list(id, query), .get(id, deliveryId), .redeliver(id, deliveryId): a software partner's company key manages its own company webhook endpoints. Scope webhooks:manage. The signing secret is in the answer of create and rotateSecret only.\n- zs.sandbox.bookings.noShow(bookingId, { undo }) and zs.sandbox.syncEvents.create({ type, event }): with the three booking simulations, a real event of every type on a sandbox.\n- zs.availability.dryRun(updates), zs.rates.dryRun(updates), zs.restrictions.dryRun(updates): what the same set would do, with nothing written. The answer is a WritePreview (dryRun: true, verdict, wouldChange, unchanged, held, wouldReject, notices), never a WriteAccepted, so a dry run cannot be mistaken for a write. It spends the minute budgets like the write it previews.\n- noticesOf(answers), warningsOf(answers), findNotice(answers, code), noticesOmittedFrom(answers), noticeMeaning(code), isWritePreview(answer): the notices of a write's answer or a preview (what the write did NOT do), warnings first, each once across a split write. NOTICES lists every code with its level and meaning.\n- zs.availability.close(body) and zs.availability.reopen(body): close one room type on a range of nights everywhere (count 0 and stop-sell on every one of its rate plans), and undo exactly that. Read notReached in the answer. zs.availability.closeDryRun(body) and zs.availability.reopenDryRun(body) say what each would do. The real ones refuse a body that carries dryRun.\n- zs.explain.night({ roomTypeId, date, ratePlanId }): one night's whole story from ZimmerStack's record: what was last sent, what the record holds and who set it, what the channel manager was last seen holding, the sends and how they ended, summary in plain sentences. Scope ari:read.\n- zs.sandbox.faults.get(), zs.sandbox.faults.set(body), zs.sandbox.faults.clear(): make the sandbox's pretend channel refuse, throttle or go down, and end it. Prices and stay rules only.\n- zs.readiness.get() and zs.readiness.goLive(): the four readiness checks of a hotel that is not live yet, and the switch that makes your software its source of truth. Pass { beforeGoLive: true } on a call to send values ahead: prices and stay rules are stored and wait. Room counts are not sent ahead: until the hotel is live a count that lowers what is on sale goes out at once and one that raises it is refused in rejected, so send the room counts again right after going live.\n- zs.connectLinks.create(body), zs.connectLinks.list(query), zs.connectLinks.get(linkId), zs.connectLinks.revoke(linkId): one-time links with which a hotel's own person connects one booking site on ZimmerStack's hosted page. Scope channels:connect, a company key, a live key only. The url is in the create's answer only.\n- zs.hotelKeys.list(propertyId), zs.hotelKeys.create(propertyId, body), zs.hotelKeys.rotate(propertyId, keyId), zs.hotelKeys.revoke(propertyId, keyId, { reason }): the keys a software partner made on a hotel it added. Scope keys:manage, a company key. The key is in the answer of create and rotate only.\n- shownOnce(answer) and withoutShownOnce(answer): the value an answer shows once (a hotel key, a connect link's url, a webhook secret), or a ZimmerStackShownOnceError whose nextStep names the way back when the answer is a replay and the value is null; and a copy of the answer that is safe to log.\n- zs.billing.get(), zs.billing.invoices(), zs.billing.nextInvoice(): a software partner's bills, quota, money paid ahead and at-cost records, read only. Scope billing:read, a company key.\n- zs.supportTickets.create(body), zs.supportTickets.list(query), zs.supportTickets.all(query), zs.supportTickets.get(ticketId), zs.supportTickets.reply(ticketId, message), zs.supportTickets.close(ticketId): support tickets by API. Scope support:write, a company key. SUPPORT_SEVERITIES lists the three levels with their first-reply times.\n- zs.status.get(): the components and the incidents that touch this key's hotels. Any key.\n- diagnose(options) and formatDoctorReport(report): the doctor's checks from your own code (a health page, a deploy check). The command: npx @zimmerstack/connect doctor. It reads ZimmerStack's own status first, a hotel's readiness when it is not live, and one night when you name it (--room-type <id> --night <YYYY-MM-DD>; in code, the night option).\n- checkKey(value): is this string a ZimmerStack key, by its own checksum, without sending it. Returns { ok, mode, format | problem, message }; the message never contains the key.\n- Money on strings, never floats: toAmount(value, decimals), addAmounts(a, b, decimals), subtractAmounts(a, b, decimals), multiplyAmount(amount, factor, decimals), compareAmounts(a, b), formatAmount(amount, { currency, decimals, locale }); amountFromMinorUnits(units, decimals) and amountToMinorUnits(amount, decimals) for a ledger of whole cents or paise; amountFromHundredths(rateMinor, decimals) for the API's …Minor fields. decimals comes from GET /property, GET /catalog or GET /rates.\n- zs.request(\"GET /sync\"): any operation by its contract name, typed.\n- Pure helpers: eachDate(from, to), addDays(date, n), toRanges(cells), chunk(updates), buildGrid(parts), channelPrice(rate, steps).\n- verifyWebhook(rawBody, headers, secret): returns the event or throws ZimmerStackWebhookError.\n- isWebsiteBookingEvent(event), isOtaBookingEvent(event): tell the two booking families apart; BOOKING_EVENT_TYPES lists every type of both. isSyncEvent(event), isDriftEvent(event), isConnectEvent(event): the channel events. isIncidentEvent(event), isSupportTicketEvent(event): the two families about your account, which carry no property.\n- MODIFIER_TAKES_EFFECT: the sentence to show where a person saves a channel's modifier. LIMITS, ERROR_CODES, SCOPES: the contract's own.\n\nA refusal is a ZimmerStackError: code (stable; branch on it), message (for a person; show it), status, retryable (false = fix the request, never resend), retryAfterSeconds, scope (which budget), details, operation.\n\nOptions: apiKey, propertyId, timeoutMs (30 s), maxRetries (3), maxWaitSeconds (120; any call may pass its own), onEvent (every answer, wait and retry, for logs; never the key), fetch (a stand-in for tests), allowLiveWritesInTests.\n\nWhat it keeps by itself, so do not re-implement it or wrap its calls in a retry loop:\n- Server only: it refuses a browser and React Native, sends the key to ZimmerStack only, never follows a redirect with it and never prints it.\n- Reads every budget in the RateLimit headers and waits before one runs out. One hotel's writes go one at a time, in order (each hotel of a company key has its own queue and its own pace); at most four requests at once.\n- Sends a 429 again after its Retry-After (four attempts, the same idempotency key). Sends a 5xx or a network failure again only for a read or a write that carries an idempotency key. Throws anything else at once.\n- A wait over two minutes (an hour's or a day's budget) is handed back as a retryable error with retryAfterSeconds and freesAt, unless the call passed a longer maxWaitSeconds: then it is held, and onEvent is told when it lands. zs.limits.get() answers every budget with what is left.\n- A write the server keeps no idempotency record for is not resent when its outcome is unknown.\n- Splits a write at 1,000 updates or 5,000 cells.\n- After API_KEY_INVALID, API_KEY_REVOKED or API_KEY_EXPIRED it stops calling.\n- A zsk_live_ key under a test runner may read but not write.\n"
|
|
7380
|
+
"the-package": "@zimmerstack/connect 0.9.1: npm install @zimmerstack/connect. Node 20 or newer, on a server only, zero dependencies.\n\nconst zs = new ZimmerStack(); // reads ZIMMERSTACK_CONNECT_KEY; make one per process and reuse it\n\nEvery operation has a method: each operation's lookup names it (\"With the package\"). On top of those:\n- zs.grid.load(from, to): the whole rate grid for a window, ready for a screen. Rows are room types with their rate plans, columns are nights; prices in MAJOR units. Three reads (four the first time; the catalog is kept ten minutes).\n- zs.grid.save(edits): what a person changed, as single nights { availability?, rates?, restrictions? }. Folds nights into ranges, fills in the currency, splits a large save, sends one request per resource in turn. Returns the accepted answers, each with a batchId.\n- zs.batches.wait(batchId): asks every 15 seconds at the fastest, for at most five minutes; returns the last status (\"landed\", \"failed\", or still \"pending\").\n- zs.channelBookings.all({ since }): an async iterator over every OTA booking changed since then, following the cursor.\n- zs.directBookings.all({ since }): the same for the bookings guests made on the hotel's own website (scope direct-bookings:read). Read it before a full availability push.\n- zs.roomTypes.list(), zs.roomTypes.save(roomType), zs.roomTypes.delete(idOrRef) and zs.ratePlans.list(), zs.ratePlans.save(ratePlan), zs.ratePlans.delete(idOrRef): a hotel's room types and rate plans one at a time. save creates one, or changes it when that ref was sent before, and answers with its id. delete takes ZimmerStack's id (a number) or your own ref (a string), deletes for good, and a room type takes its rate plans with it. Scope catalog:write.\n- zs.properties.create(hotel) and zs.properties.delete(propertyId, { confirm }) (also zs.properties.remove): a software partner's company key adds a hotel and removes one it added, for good. Scope properties:write, a company key only. confirm is the hotel's exact name. With a test key they make and delete a sandbox.\n- zs.properties.update(propertyId, changes): the same key changes the name or the address (line1, city, state, postalCode) of a hotel it added; only what is sent changes. Never the country, currency, time zone, owner or tax id. The answer's changed lists the fields that moved. With a test key it changes a sandbox.\n- zs.forProperty(propertyId): a software vendor's company key acting on one hotel. Each hotel has its own queue of writes and its own pace; what all the hotels share (the company's budget) is paced for all of them.\n- zs.limits.get(): every budget this key sits under (the key's, its hotel's, the company's), with its window, its quota, what is left and when it refills, and the budgets over an hour and a day. Any key; reading uses up nothing.\n- zs.events.all({ after }): an async iterator over the hotel's ordered event log from the sequence you saved to its end; each event carries its sequence, which is your new place. onGap tells you when the log no longer holds what follows your place. zs.events.list({ after }) is one page.\n- zs.requests.list({ status: \"errors\" }) and zs.requests.all(query): this key's own requests of the last 7 days (time, route, status, error code, address, request id; never a body).\n- zs.webhookEndpoints.list(), .create(body), .get(id), .update(id, body), .pause(id), .resume(id), .rotateSecret(id), .test(id, { eventType }), .recover(id, since), .delete(id) and zs.webhookEndpoints.deliveries.list(id, query), .get(id, deliveryId), .redeliver(id, deliveryId): a software partner's company key manages its own company webhook endpoints. Scope webhooks:manage. The signing secret is in the answer of create and rotateSecret only.\n- zs.sandbox.bookings.noShow(bookingId, { undo }) and zs.sandbox.syncEvents.create({ type, event }): with the three booking simulations, a real event of every type on a sandbox.\n- zs.availability.dryRun(updates), zs.rates.dryRun(updates), zs.restrictions.dryRun(updates): what the same set would do, with nothing written. The answer is a WritePreview (dryRun: true, verdict, wouldChange, unchanged, held, wouldReject, notices), never a WriteAccepted, so a dry run cannot be mistaken for a write. It spends the minute budgets like the write it previews.\n- noticesOf(answers), warningsOf(answers), findNotice(answers, code), noticesOmittedFrom(answers), noticeMeaning(code), isWritePreview(answer): the notices of a write's answer or a preview (what the write did NOT do), warnings first, each once across a split write. NOTICES lists every code with its level and meaning.\n- zs.availability.close(body) and zs.availability.reopen(body): close one room type on a range of nights everywhere (count 0 and stop-sell on every one of its rate plans), and undo exactly that. Read notReached in the answer. zs.availability.closeDryRun(body) and zs.availability.reopenDryRun(body) say what each would do. The real ones refuse a body that carries dryRun.\n- zs.explain.night({ roomTypeId, date, ratePlanId }): one night's whole story from ZimmerStack's record: what was last sent, what the record holds and who set it, what the channel manager was last seen holding, the sends and how they ended, summary in plain sentences. Scope ari:read.\n- zs.sandbox.faults.get(), zs.sandbox.faults.set(body), zs.sandbox.faults.clear(): make the sandbox's pretend channel refuse, throttle or go down, and end it. Prices and stay rules only.\n- zs.readiness.get() and zs.readiness.goLive(): the four readiness checks of a hotel that is not live yet, and the switch that makes your software its source of truth. Pass { beforeGoLive: true } on a call to send values ahead: prices and stay rules are stored and wait. Room counts are not sent ahead: until the hotel is live a count that lowers what is on sale goes out at once and one that raises it is refused in rejected, so send the room counts again right after going live.\n- zs.connectLinks.create(body), zs.connectLinks.list(query), zs.connectLinks.get(linkId), zs.connectLinks.revoke(linkId): one-time links with which a hotel's own person connects one booking site on ZimmerStack's hosted page. Scope channels:connect, a company key, a live key only. The url is in the create's answer only.\n- zs.hotelKeys.list(propertyId), zs.hotelKeys.create(propertyId, body), zs.hotelKeys.rotate(propertyId, keyId), zs.hotelKeys.revoke(propertyId, keyId, { reason }): the keys a software partner made on a hotel it added. Scope keys:manage, a company key. The key is in the answer of create and rotate only.\n- shownOnce(answer) and withoutShownOnce(answer): the value an answer shows once (a hotel key, a connect link's url, a webhook secret), or a ZimmerStackShownOnceError whose nextStep names the way back when the answer is a replay and the value is null; and a copy of the answer that is safe to log.\n- zs.billing.get(), zs.billing.invoices(), zs.billing.nextInvoice(): a software partner's bills, quota, money paid ahead and at-cost records, read only. Scope billing:read, a company key.\n- zs.supportTickets.create(body), zs.supportTickets.list(query), zs.supportTickets.all(query), zs.supportTickets.get(ticketId), zs.supportTickets.reply(ticketId, message), zs.supportTickets.close(ticketId): support tickets by API. Scope support:write, a company key. SUPPORT_SEVERITIES lists the three levels with their first-reply times.\n- zs.status.get(): the components and the incidents that touch this key's hotels. Any key.\n- diagnose(options) and formatDoctorReport(report): the doctor's checks from your own code (a health page, a deploy check). The command: npx @zimmerstack/connect doctor. It reads ZimmerStack's own status first, a hotel's readiness when it is not live, and one night when you name it (--room-type <id> --night <YYYY-MM-DD>; in code, the night option).\n- checkKey(value): is this string a ZimmerStack key, by its own checksum, without sending it. Returns { ok, mode, format | problem, message }; the message never contains the key.\n- Money on strings, never floats: toAmount(value, decimals), addAmounts(a, b, decimals), subtractAmounts(a, b, decimals), multiplyAmount(amount, factor, decimals), compareAmounts(a, b), formatAmount(amount, { currency, decimals, locale }); amountFromMinorUnits(units, decimals) and amountToMinorUnits(amount, decimals) for a ledger of whole cents or paise; amountFromHundredths(rateMinor, decimals) for the API's …Minor fields. decimals comes from GET /property, GET /catalog or GET /rates.\n- zs.request(\"GET /sync\"): any operation by its contract name, typed.\n- Pure helpers: eachDate(from, to), addDays(date, n), toRanges(cells), chunk(updates), buildGrid(parts), channelPrice(rate, steps).\n- verifyWebhook(rawBody, headers, secret): returns the event or throws ZimmerStackWebhookError.\n- isWebsiteBookingEvent(event), isOtaBookingEvent(event): tell the two booking families apart; BOOKING_EVENT_TYPES lists every type of both. isSyncEvent(event), isDriftEvent(event), isConnectEvent(event): the channel events. isIncidentEvent(event), isSupportTicketEvent(event): the two families about your account, which carry no property.\n- MODIFIER_TAKES_EFFECT: the sentence to show where a person saves a channel's modifier. LIMITS, ERROR_CODES, SCOPES: the contract's own.\n\nA refusal is a ZimmerStackError: code (stable; branch on it), message (for a person; show it), status, retryable (false = fix the request, never resend), retryAfterSeconds, scope (which budget), details, operation.\n\nOptions: apiKey, propertyId, timeoutMs (30 s), maxRetries (3), maxWaitSeconds (120; any call may pass its own), onEvent (every answer, wait and retry, for logs; never the key), fetch (a stand-in for tests), allowLiveWritesInTests.\n\nWhat it keeps by itself, so do not re-implement it or wrap its calls in a retry loop:\n- Server only: it refuses a browser and React Native, sends the key to ZimmerStack only, never follows a redirect with it and never prints it.\n- Reads every budget in the RateLimit headers and waits before one runs out. One hotel's writes go one at a time, in order (each hotel of a company key has its own queue and its own pace); at most four requests at once.\n- Sends a 429 again after its Retry-After (four attempts, the same idempotency key). Sends a 5xx or a network failure again only for a read or a write that carries an idempotency key. Throws anything else at once.\n- A wait over two minutes (an hour's or a day's budget) is handed back as a retryable error with retryAfterSeconds and freesAt, unless the call passed a longer maxWaitSeconds: then it is held, and onEvent is told when it lands. zs.limits.get() answers every budget with what is left.\n- A write the server keeps no idempotency record for is not resent when its outcome is unknown.\n- Splits a write at 1,000 updates or 5,000 cells.\n- After API_KEY_INVALID, API_KEY_REVOKED or API_KEY_EXPIRED it stops calling.\n- A zsk_live_ key under a test runner may read but not write.\n"
|
|
6136
7381
|
}
|
|
6137
7382
|
};
|