API reference · v1
BedsChain Data API
One permanent ID for every hotel (the BCH ID), the hotel's details, and the code each supplier uses for it. Connect your supplier contracts to one hotel list, keep your content up to date, and match your own hotel list to ours.
- Subscribe. Choose a plan with the BedsChain team; you receive an API key.
- Whitelist your server. Call
GET /ipfrom your server and send us the address; keys work only from whitelisted addresses. - Check your key. Call
GET /accountto see your plan, countries and suppliers. - Load the hotels. Page through
GET /hotels(or download everything with/export). - Stay current. Call
GET /hotels/updated-sincedaily and refresh only what changed.
https://unify.bedschain.com/api/v1for Postman, Swagger or code generators.
Authentication
Send your API key in the X-API-Key header of every request, over HTTPS. Keys start with bcu_. Keep the key on your server, never in a browser or mobile app. If a key leaks, ask us to revoke it and issue a new one; a revoked key stops working within a minute.
curl https://unify.bedschain.com/api/v1/account \
-H "X-API-Key: $BEDSCHAIN_API_KEY"IP whitelisting. Requests are accepted only from your whitelisted server addresses (single addresses or ranges). Until one is whitelisted, every call answers 403 ip_not_whitelisted with the address we saw. GET /ip shows it.
Responses are JSON in UTF-8 (the full download is JSON Lines). Dates and times are ISO 8601 in UTC.
Plans
Your plan decides what the API returns. Supplier codes are shown only for the suppliers named in your subscription, which can also be limited to certain countries.
| Plan | Hotel details | Supplier codes | Match your list | Full download | Hotels |
|---|---|---|---|---|---|
| Hotel Mapping | – | ✓ | – | – | All |
| Hotel Content | ✓ | – | – | – | All |
| Complete | ✓ | ✓ | ✓ up to 50,000 | ✓ | All |
| Trial (7 days) | ✓ | ✓ | ✓ up to 500 | – | Approved only |
Identifiers of third-party mapping providers and suppliers' own data feeds are never part of the API.
Limits and errors
Each plan allows a number of requests per minute and per month (see /account). Over a limit the API answers 429 with a Retry-After header in seconds. Lists return at most 1,000 items per page; pass page from 0 until you have total items.
{ "error": { "code": "not_in_plan", "message": "Supplier codes is not part of the Hotel Content plan." } }| Status | Code | Meaning |
|---|---|---|
| 400 | bad_request | A parameter or file is wrong; the message says which. |
| 401 | missing_api_key / invalid_api_key | No key, an unknown or revoked key, or no active subscription. |
| 403 | ip_not_whitelisted | The request came from an address not whitelisted for your account. |
| 403 | not_in_plan / supplier_not_in_subscription | Your plan or subscription does not include this. |
| 404 | not_found | No such hotel or list in your subscription. |
| 429 | rate_limited | Per-minute or monthly limit reached; wait the seconds in Retry-After. |
BCH IDs and merges
A BCH ID (for example BCH-00100001-8) never changes and is never reused; its last digit is a check digit. When two BCH IDs turn out to be the same hotel, one is merged into the other: the old ID keeps answering with "status": "Merged" and mergedInto, and appears in /hotels/updated-since. Values marked "verified": false come from suppliers and have not yet been confirmed by BedsChain.
Account
Your IP address
GET/ip
The address BedsChain sees your requests coming from. Send it to us to have it whitelisted; no key is needed for this call.
Plans: Everyone
curl "https://unify.bedschain.com/api/v1/ip" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{ "ip": "203.0.113.7" }Your subscription
GET/account
Your plan, subscription dates, countries and suppliers, what your plan includes, and your limits. Call it first to check your key.
Plans: All plans
curl "https://unify.bedschain.com/api/v1/account" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"customer": "Acme Travel",
"plan": { "code": "complete", "name": "Complete" },
"subscription": { "startsOn": "2026-10-12", "endsOn": null, "countries": ["AE"], "suppliers": ["SUPPLIER_A", "SUPPLIER_B"] },
"features": { "hotelContent": true, "supplierCodes": true, "inventoryMapping": true, "bulkDownload": true, "publishedHotelsOnly": false },
"limits": { "requestsPerMinute": 300, "requestsPerMonth": 1000000, "maxInventoryHotels": 50000 }
}Locations
Countries
GET/countries
Countries in your subscription and how many hotels each has.
Plans: All plans
curl "https://unify.bedschain.com/api/v1/countries" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"[ { "iso2": "AE", "name": "United Arab Emirates", "hotels": 1250 } ]Cities
GET/cities
Cities of one country with their hotel counts. City IDs are permanent; use them to filter hotels.
Plans: All plans
| Parameter | In | Description |
|---|---|---|
countryrequiredstring | query | ISO 3166 alpha-2 country codee.g. AE |
curl "https://unify.bedschain.com/api/v1/cities?country=AE" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"[ { "id": "CITY-292223", "name": "Dubai", "division": "Dubai", "latitude": 25.07725, "longitude": 55.30927, "hotels": 820 } ]Hotels
List and search hotels
GET/hotels
A page of hotels ordered by BedsChain hotel ID (BCH ID). Hotel details come with the Hotel Content and Complete plans; supplier codes with Hotel Mapping and Complete, for the suppliers in your subscription. Descriptions and photos are included where BedsChain may pass them on; facilities use BedsChain's own list.
Plans: All plans
| Parameter | In | Description |
|---|---|---|
countrystring | query | ISO country codee.g. AE |
cityIdstring | query | City ID from /citiese.g. CITY-292223 |
namestring | query | Part of the hotel namee.g. marina |
updatedSincedate-time | query | Only hotels changed since then (UTC)e.g. 2026-10-01 |
verifiedboolean | query | true: only hotels verified by BedsChain (a person checked name, city, map position and every supplier link; any later change ends it)e.g. true |
pageinteger | query | Page number, from 0e.g. 0 |
limitinteger | query | Hotels per page, up to 1,000 (default 100)e.g. 100 |
curl "https://unify.bedschain.com/api/v1/hotels?country=AE&cityId=CITY-292223&limit=100&page=0" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"page": 0,
"limit": 100,
"total": 820,
"hotels": [
{
"bchId": "BCH-00100001-8",
"status": "Active",
"mergedInto": null,
"country": "AE",
"updatedAt": "2026-10-12T13:01:22Z",
"verified": true,
"verifiedAt": "2026-10-15T09:40:00Z",
"name": "Marina Palace",
"propertyType": "Hotel",
"address": { "street": "Dubai Marina", "postalCode": null },
"city": { "id": "CITY-292223", "name": "Dubai" },
"area": { "id": "AREA-AE-DUBAI-MARINA", "name": "Dubai Marina" },
"location": { "latitude": 25.0801, "longitude": 55.1402, "verified": false },
"starRating": { "value": 5, "verified": false },
"phones": ["+971 4 555 0101"],
"websites": [],
"description": "Set on Dubai Marina, the hotel offers …",
"images": ["https://images.example/marina-palace/1.jpg"],
"facilities": ["Fitness centre", "Outdoor pool", "Restaurant", "Wi-Fi"],
"quality": { "score": 75, "status": "Incomplete" },
"supplierCodes": [
{ "supplier": "SUPPLIER_A", "code": "A12345" },
{ "supplier": "SUPPLIER_B", "code": "B-77821" }
]
}
]
}One hotel
GET/hotels/{bchId}
One hotel by BCH ID, in the same shape as the list. If the hotel turned out to be a duplicate and was merged, it answers with "status": "Merged" and mergedInto: use that BCH ID from then on.
Plans: All plans
| Parameter | In | Description |
|---|---|---|
bchIdrequiredstring | path | BedsChain hotel IDe.g. BCH-00100001-8 |
curl "https://unify.bedschain.com/api/v1/hotels/BCH-00100001-8" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"bchId": "BCH-00100001-8",
"status": "Active",
"mergedInto": null,
"country": "AE",
"updatedAt": "2026-10-12T13:01:22Z",
"verified": true,
"verifiedAt": "2026-10-15T09:40:00Z",
"name": "Marina Palace",
"propertyType": "Hotel",
"address": { "street": "Dubai Marina", "postalCode": null },
"city": { "id": "CITY-292223", "name": "Dubai" },
"area": { "id": "AREA-AE-DUBAI-MARINA", "name": "Dubai Marina" },
"location": { "latitude": 25.0801, "longitude": 55.1402, "verified": false },
"starRating": { "value": 5, "verified": false },
"phones": ["+971 4 555 0101"],
"websites": [],
"description": "Set on Dubai Marina, the hotel offers …",
"images": ["https://images.example/marina-palace/1.jpg"],
"facilities": ["Fitness centre", "Outdoor pool", "Restaurant", "Wi-Fi"],
"quality": { "score": 75, "status": "Incomplete" },
"supplierCodes": [
{ "supplier": "SUPPLIER_A", "code": "A12345" },
{ "supplier": "SUPPLIER_B", "code": "B-77821" }
]
}What changed
GET/hotels/updated-since
BCH IDs whose details, supplier codes or status changed since a moment, merged hotels included. Store the time of each call and pass it next time to refresh only what changed.
Plans: All plans
| Parameter | In | Description |
|---|---|---|
sincerequireddate-time | query | UTC date or date-timee.g. 2026-10-01T00:00:00Z |
pageinteger | query | Page number, from 0e.g. 0 |
limitinteger | query | IDs per page, up to 1,000e.g. 1000 |
curl "https://unify.bedschain.com/api/v1/hotels/updated-since?since=2026-10-01T00:00:00Z" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{ "since": "2026-10-01T00:00:00+00:00", "page": 0, "limit": 1000, "total": 2, "ids": ["BCH-00100001-8", "BCH-00100002-6"] }Full download
GET/export
Every hotel in your subscription as JSON Lines: one hotel per line, in the list shape. Use it for the first load, then /hotels/updated-since for changes.
Plans: Complete
curl "https://unify.bedschain.com/api/v1/export" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{"bchId":"BCH-00100001-8","status":"Active","name":"Marina Palace", … }
{"bchId":"BCH-00100002-6","status":"Active","name":"Creek Hotel", … }Supplier codes
Supplier codes to BCH IDs
GET/mappings/{supplier}
Every hotel code of one supplier in your subscription with its BCH ID. Two supplier codes with the same BCH ID are the same hotel, which is how you connect your supplier contracts to one hotel list.
Plans: Hotel Mapping, Complete, Trial
| Parameter | In | Description |
|---|---|---|
supplierrequiredstring | path | A supplier code as listed in your subscription (GET /account)e.g. SUPPLIER_A |
codestring | query | Look up one supplier hotel codee.g. A12345 |
pageinteger | query | Page number, from 0e.g. 0 |
limitinteger | query | Codes per page, up to 1,000e.g. 1000 |
curl "https://unify.bedschain.com/api/v1/mappings/SUPPLIER_A?code=A12345" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"supplier": "SUPPLIER_A",
"page": 0,
"limit": 1000,
"total": 1,
"mappings": [ { "supplierHotelCode": "A12345", "bchId": "BCH-00100001-8", "supplierStatus": "Active", "updatedAt": "2026-10-12T09:41:07Z" } ]
}Mapping changes feed
GET/mappings/changes
Every supplier code whose mapping changed, oldest first, so you can keep your own mapping table in step without downloading everything again. Added: the code now points to a BCH ID. Moved: it now points to another BCH ID (for example after two hotels were merged; previousBchId says which). Removed: it no longer points to one. Start with since, then pass the resumeKey from each answer until hasMore is false; store the last resumeKey for next time.
Plans: Hotel Mapping, Complete, Trial
| Parameter | In | Description |
|---|---|---|
sincedate-time | query | Changes from this moment (needed on the first call)e.g. 2026-10-01T00:00:00Z |
resumeKeystring | query | From the previous answer, to continue where it stopped |
supplierstring | query | Only one supplier in your subscriptione.g. SUPPLIER_A |
limitinteger | query | Changes per call, up to 1,000e.g. 1000 |
curl "https://unify.bedschain.com/api/v1/mappings/changes?since=2026-10-01T00:00:00Z" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"since": "2026-10-01T00:00:00+00:00",
"count": 2,
"hasMore": false,
"resumeKey": "NjM4OTUxMjk2MDAwMDAwMDAwfE1BUC1CQ0gtMDAwMDAwMTJ8Mg",
"changes": [
{ "change": "Added", "supplier": "SUPPLIER_A", "supplierHotelCode": "A12345", "bchId": "BCH-00100001-8", "previousBchId": null, "reason": null, "changedAt": "2026-10-12T09:41:07Z" },
{ "change": "Moved", "supplier": "SUPPLIER_B", "supplierHotelCode": "B-77821", "bchId": "BCH-00100001-8", "previousBchId": "BCH-00100044-1", "reason": "Merged", "changedAt": "2026-10-13T08:02:55Z" }
]
}Look up many codes
POST/mappings/lookup
Up to 1,000 supplier hotel codes in one call, for example the hotels in today's bookings. Each comes back with its BCH ID, in the order you sent them. status is Mapped, NotMapped, NotInSubscription, or SwitchedOff (you switched that supplier off for the hotel, its city or country in the portal).
Plans: Hotel Mapping, Complete, Trial
| Parameter | In | Description |
|---|---|---|
bodyrequiredapplication/json | body | {"codes": [{"supplier", "code"}]} |
curl -X POST "https://unify.bedschain.com/api/v1/mappings/lookup" \
-H "X-API-Key: $BEDSCHAIN_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @hotels.csv{ "codes": [ { "supplier": "SUPPLIER_A", "code": "A12345" }, { "supplier": "SUPPLIER_B", "code": "B-00000" } ] }{
"results": [
{ "supplier": "SUPPLIER_A", "supplierHotelCode": "A12345", "bchId": "BCH-00100001-8", "status": "Mapped", "supplierStatus": "Active" },
{ "supplier": "SUPPLIER_B", "supplierHotelCode": "B-00000", "bchId": null, "status": "NotMapped", "supplierStatus": null }
]
}History of one code
GET/mappings/{supplier}/{code}/history
Every version of one supplier hotel's mapping: which BCH ID it pointed to, its status and when it changed. Useful when a booking was made against an older mapping.
Plans: Hotel Mapping, Complete, Trial
| Parameter | In | Description |
|---|---|---|
supplierrequiredstring | path | A supplier in your subscriptione.g. SUPPLIER_A |
coderequiredstring | path | The supplier's hotel codee.g. A12345 |
curl "https://unify.bedschain.com/api/v1/mappings/SUPPLIER_A/A12345/history" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"supplier": "SUPPLIER_A",
"supplierHotelCode": "A12345",
"supplierStatus": "Active",
"firstSeenAt": "2026-10-10T06:00:00Z",
"lastSeenAt": "2026-10-13T06:00:00Z",
"history": [ { "version": 1, "bchId": "BCH-00100001-8", "status": "Mapped", "confidence": 98.5, "reason": null, "changedAt": "2026-10-10T06:12:40Z" } ]
}Your hotel list
Match your hotel list
POST/inventories
Send your own hotel list as CSV or JSON; it is matched to BCH IDs straight away. hotel_code and name are required; country, latitude/longitude, address, city and stars make matches far better. Each hotel comes back Mapped (the same hotel), Review (probably the same: please check) or Unmapped.
Plans: Complete, Trial
| Parameter | In | Description |
|---|---|---|
namestring | query | A name for the liste.g. My hotels |
bodyrequiredtext/csv or application/json | body | Header row: hotel_code, name, address, city, country, latitude, longitude, stars |
curl -X POST "https://unify.bedschain.com/api/v1/inventories?name=My%20hotels" \
-H "X-API-Key: $BEDSCHAIN_API_KEY" \
-H "Content-Type: text/csv" \
--data-binary @hotels.csvhotel_code,name,address,city,country,latitude,longitude,stars
A1,Marina Palace,Dubai Marina,Dubai,AE,25.0801,55.1402,5
A2,Nowhere Inn,,,AE,24.0,54.0,{ "id": "6f2c1e0a-6a51-4c5e-9d0e-2b1f8f0d7a11", "name": "My hotels", "status": "Completed", "createdAt": "2026-10-12T14:02:11Z", "hotels": 2, "mapped": 1, "review": 0, "unmapped": 1 }Your lists
GET/inventories
The hotel lists you have sent, newest first.
Plans: Complete, Trial
curl "https://unify.bedschain.com/api/v1/inventories" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"[ { "id": "6f2c1e0a-…", "name": "My hotels", "status": "Completed", "hotels": 2, "mapped": 1, "review": 0, "unmapped": 1 } ]Match results
GET/inventories/{id}
Each hotel of a list with its BCH ID, confidence (0 to 100) and the reason.
Plans: Complete, Trial
| Parameter | In | Description |
|---|---|---|
idrequireduuid | path | List ID |
resultstring | query | Mapped, Review or Unmappede.g. Mapped |
pageinteger | query | Page number, from 0e.g. 0 |
limitinteger | query | Hotels per page, up to 1,000e.g. 1000 |
curl "https://unify.bedschain.com/api/v1/inventories/6f2c1e0a-6a51-4c5e-9d0e-2b1f8f0d7a11?result=Mapped" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"inventory": { "id": "6f2c1e0a-…", "name": "My hotels", "hotels": 2, "mapped": 1, "review": 0, "unmapped": 1 },
"page": 0,
"limit": 1000,
"total": 1,
"hotels": [ { "hotelCode": "A1", "name": "Marina Palace", "result": "Mapped", "confidence": 95, "reason": "Same name, 14 m apart.", "bchId": "BCH-00100001-8", "bchName": "Marina Palace" } ]
}Delete a list
DELETE/inventories/{id}
Removes a list and its results. Answers 204 No Content.
Plans: Complete, Trial
| Parameter | In | Description |
|---|---|---|
idrequireduuid | path | List ID |
curl -X DELETE "https://unify.bedschain.com/api/v1/inventories/6f2c1e0a-6a51-4c5e-9d0e-2b1f8f0d7a11" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"(no content)Match one hotel now
POST/match
Match a single hotel (or up to 50) straight away, without creating a list: for example when a new hotel appears in your system. Same rules and answers as list matching.
Plans: Complete, Trial
| Parameter | In | Description |
|---|---|---|
bodyrequiredapplication/json | body | One hotel, or {"hotels": [...]}: name (required), hotelCode, address, city, country, latitude, longitude, stars |
curl -X POST "https://unify.bedschain.com/api/v1/match" \
-H "X-API-Key: $BEDSCHAIN_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @hotels.csv{ "hotelCode": "A1", "name": "Marina Palace", "country": "AE", "latitude": 25.0801, "longitude": 55.1402 }{ "results": [ { "hotelCode": "A1", "name": "Marina Palace", "result": "Mapped", "bchId": "BCH-00100001-8", "confidence": 95, "reason": "Same name, 14 m apart." } ] }Coverage & reference
Coverage statistics
GET/statistics
For each supplier in your subscription: how many of its hotels are mapped to a BCH ID, how many are being checked by our team, and how many are not mapped yet, in total and per country.
Plans: All plans
curl "https://unify.bedschain.com/api/v1/statistics" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"generatedAt": "2026-10-13T20:00:00Z",
"masterHotels": 2092,
"suppliers": [
{ "supplier": "SUPPLIER_A", "supplierHotels": 1250, "mapped": 1190, "inReview": 41, "notMapped": 19, "mappedPercent": 95.2,
"byCountry": [ { "country": "AE", "supplierHotels": 1250, "mapped": 1190, "inReview": 41, "notMapped": 19 } ] }
]
}Reference lists
GET/reference
The fixed lists hotel fields use: property types, BedsChain facilities with their group, brands, and the problems you can report with POST /feedback.
Plans: All plans
curl "https://unify.bedschain.com/api/v1/reference" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"{
"propertyTypes": ["Apartment", "Hotel", "Resort"],
"facilities": [ { "key": "outdoor-pool", "name": "Outdoor pool", "group": "Leisure" } ],
"brands": [ { "id": "BRD-000001", "name": "Example Brand" } ],
"problems": ["WrongMapping", "Duplicate", "WrongDetails", "Closed", "Other"]
}Feedback
Report a problem
POST/feedback
Tell us when a mapping is wrong (for example a guest was sent to a different hotel), two BCH IDs are the same hotel, details are wrong, or a hotel has closed. Our team checks every report; follow it with GET /feedback. Give bchId, or supplier and supplierHotelCode.
Plans: All plans
| Parameter | In | Description |
|---|---|---|
bodyrequiredapplication/json | body | problem (WrongMapping, Duplicate, WrongDetails, Closed or Other), bchId, supplier, supplierHotelCode, otherBchId, bookingReference, message |
curl -X POST "https://unify.bedschain.com/api/v1/feedback" \
-H "X-API-Key: $BEDSCHAIN_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @hotels.csv{ "problem": "WrongMapping", "supplier": "SUPPLIER_A", "supplierHotelCode": "A12345", "bookingReference": "BK-77", "message": "The guest arrived at a different hotel." }{ "id": "0b7d3c1e-2f4a-4d7b-8b8e-6a1f0c9e2d31", "status": "Open" }Your reports
GET/feedback
Your reports, newest first, with their status (Open, Resolved or Rejected) and what our team did.
Plans: All plans
curl "https://unify.bedschain.com/api/v1/feedback" \
-H "X-API-Key: $BEDSCHAIN_API_KEY"[ { "id": "0b7d3c1e-…", "problem": "WrongMapping", "supplier": "SUPPLIER_A", "supplierHotelCode": "A12345", "status": "Resolved", "resolution": "Mapping corrected.", "createdAt": "2026-10-13T10:12:00Z", "resolvedAt": "2026-10-13T11:40:00Z" } ]