One-hotel path
Open in Postman(Postman = a free app for sending API requests by clicking, without writing code)
The of this path are ready in one Postman file. Each one has a short note. Almost every one shows an example answer.
What you need
- The Postman app, or Postman in your browser. Both are free: postman.com/downloads.
- A Postman account. It is free. Postman asks you to sign in before it opens a file like this one.
- Your . It starts with
zsk_test_. The hotel's owner makes it: step 1.
Open the file
- 1
Open Postman and sign in
Use the app or the browser version. - 2
Open Import
Look at the top of the left panel. In new versions of Postman, Import is a small button beside the +. Point at it and it says Use resources or import. Click it, then click the Import tab. In older versions there is a button named Import at the top left. - 3
Paste this link
Copy the link below, paste it into the box, and press Enter. Postman imports the file. If it shows an Import button first, click it.the one-hotel file https://api.zimmerstack.com/api/v1/public/connect-api/postman?reader=hotel - 4
Find it on the left
It is named ZimmerStack API - One hotel. Click its name.
Do you prefer a file? Download it, then drag the file onto the Import box in Postman.
Put your key in
Your key goes in one place only. You do this once.
- 1
Open the Variables tab
Click the name of the collection on the left. Then click Variables. - 2
Paste your test key
Find the rowapiKey. Paste your key in the column Value. Older versions of Postman have two columns: there, use Current value. Postman keeps a value you type on your own computer. It shows it to other people only if you press Share. Do not press Share. - 3
Save
If you see a Save button, click it, or press Ctrl+S (Cmd+S on a Mac). New versions of Postman save by themselves.
Your key works for one hotel. So no request in this file names the hotel, and there is no hotel id to type.
Send your first request
- 1
Open the folder “1. Start here: check your key”
It is the first folder in the list. - 2
Click “Check your key (and read the hotel)”
Then press the blue Send button. - 3
Read the answer
At the bottom you see 200 OK and the hotel your key is for. With a test key, that is the sandbox. - 4
Send the rest of this folder
Send “Get room types and rate plans”. After that, the other folders are ready to use.
To see an example answer without sending anything, open a request and click the small arrow beside its name. Almost every request has one saved.
What is inside
11 folders. Start at the top. After the first folder, open the one for what you want to build.
1. Start here: check your key
Send these two requests first, from top to bottom. They check that your key works. They also save your hotel's ids, so the other requests can use them.
- Check your key (and read the hotel)
- Get room types and rate plans
2. Get availability, rates and restrictions
Read what ZimmerStack holds now for the hotel. Availability = how many rooms are free. Rates = the price of each night. Restrictions = stay rules, like a minimum stay.
- Get availability (rooms free on each night)
- Get rates (the price of each night)
- Get restrictions (stay rules)
3. Update availability, rates and restrictions
Send your numbers. ZimmerStack saves them and sends them to every OTA of the hotel. An OTA is a website that sells hotel rooms, like Booking.com or MakeMyTrip. The answer is 202 Accepted and has a batchId. Use folder 4 to check that the update reached the OTAs.
- Update availability (how many rooms are free)
- Update rates (the price of each night)
- Update restrictions (stay rules)
4. Check that an update reached the OTAs
202 Accepted means ZimmerStack saved your update. It does not yet mean the OTAs have it. Ask here. Wait 15 seconds between two checks.
- Check one update (batch)
- Check everything (sync status)
5. Get OTA bookings (from Booking.com, MakeMyTrip and others)
Read the bookings that OTAs sent for this hotel. Your server can also receive each booking as a webhook: the hotel's owner adds your server's address in Admin, under Developers. Use these requests to catch up after your server was down.
- List OTA bookings
- Get one OTA booking
- List events in order
6. Get website bookings (from the hotel's own website)
Read the bookings guests made on the hotel's own website, when the hotel uses the ZimmerStack booking engine. Lower the rooms free in your own software for each one, before you send availability again.
- List website bookings
- Get one website booking
- Cancel a website booking and refund it
7. Create bookings from your own website
For a hotel that runs the ZimmerStack PMS and sells rooms on its own website or app. Your website sends each booking here, and it appears in the PMS like a booking made at the front desk. The OTAs show one room fewer within seconds. Your key needs the scopes bookings:write and bookings:read.
- Create a booking
- Get the booking you created
- List your bookings
- Cancel your booking
8. Sandbox: practise what happens when a guest books
A real booking comes when a guest books on an OTA like Booking.com. You cannot make a real guest book only to test your software. So here the sandbox pretends. Each request makes one thing happen that happens to a real hotel: a guest books, changes the booking, cancels it, an OTA has a problem, a guest does not arrive. After each request, look at two things: the rooms free, and the webhook your server receives. It is the same webhook as for a real hotel. This folder works with a test key only, and nothing in it reaches an OTA.
- A guest books on an OTA (make a test booking)
- See that one room fewer is free
- List your test bookings
- The guest changes the booking
- The guest cancels the booking
- An OTA has a problem (sync alert)
- The OTA's problem is over
- A guest books on the hotel's own website
- The website guest does not arrive (no-show)
9. Create room types and rate plans
Use this when your software owns the hotel's room types and rate plans. You name each one with your own id (ref). This folder creates one room type and one rate plan of its own, then deletes only those two. A delete names what it deletes by ZimmerStack's id, or by your own ref with ref: in front. This folder shows both: it deletes its rate plan by your ref, and its room type by ZimmerStack's id. The same requests work on your own room types and rate plans. Your key needs the scope catalog:write.
- Create or change room types
- Create or change rate plans
- Get room types and rate plans again
- Delete a rate plan
- Delete a room type
10. Set a price modifier on an OTA (channel modifier)
You always send one price for each night. You cannot send one OTA its own price, and you cannot choose which OTAs get a price. A modifier is a rule on one OTA: every price that goes to that OTA is raised or lowered by it, for example by 10%. Your key needs the scope channel-modifiers:write. The last two requests of this folder are a full sync: ZimmerStack sends one OTA, or every OTA of the hotel, everything it holds again. They need the scope ari:write.
- List the OTAs of this hotel (channels)
- Set the price modifier of one OTA (+10%)
- Send the prices again
- Remove the price modifier
- Send everything to one OTA again (full sync)
- Send everything to every OTA again (full sync)
11. More: limits, errors and testing before you send
Things you need after the basics work: how fast you may send, what an error looks like, and how to test an update without saving it (dry run).
- Get your limits (how many requests you may send)
- See the rate limit headers
- List your own recent requests
- Send the same update twice safely (idempotency key)
- See the error for a wrong key (401)
- See the error for a date too far ahead (400)
- Test a restrictions update without saving it (dry run)
- Test an availability update without saving it (dry run)
- Stop selling a room type everywhere (dry run)
- Start selling the room type again (dry run)
- Explain one night
- Sandbox: make the next update fail on purpose
- Sandbox: see the failure you set
- Sandbox: go back to normal
- Get the full API description (OpenAPI)
- Check if ZimmerStack has a problem (status)
If it does not work
- 401 on every request. The key is missing or not saved. Open the Variables tab again, check the row
apiKey, and save. - 403 SCOPE_MISSING. Your key is not allowed to send this request. The answer names the it needs. Ask the owner to add it to your key.
- 403 SANDBOX_ONLY. This request makes test data. It works with a test key only, on the sandbox.
- The link opens as text in your browser, or downloads a file. That is normal. Paste the link into Postman's Import box, not into the browser.
Words on this page
- Postman
- A free app for sending API requests by clicking, without writing code.
- Request
- One message your software sends to the API.
- Test key
- A key that starts with zsk_test_. It works only on a sandbox, so it can never change a real hotel.
- Sandbox
- Your test hotel. It works like a real hotel, but no OTA can see it and it costs nothing.
- PMS
- Property management system: the software a hotel uses at its front desk for bookings, guests and bills.
- Live key
- A key that starts with zsk_live_. It works on real hotels.
- Scope
- One permission of a key. For example ari:write lets the key update availability, rates and restrictions.
Do you build software for many hotels? That file comes with the partner path.