Public search and booking
GET /api/book/pool/search is the public, unauthenticated search behind the PoolSearch booking widget. Use it to build your own front end over all pool resorts and liveaboards. It answers 404 when the Pool Inventory module is off.
Search
| Parameter | Meaning |
|---|---|
type | Resort or Vessel. |
from, to | Stay or trip window, YYYY-MM-DD, end-exclusive. |
pax | Number of guests. |
flex | 0–3 days of flexibility. |
share, gender | share=true and gender=male|female to look for one shared bed. |
country | Country as a 2- or 3-letter ISO code (ID or IDN) or its English name. An unknown value matches nothing. |
city, port | Resort city, or trip departure port name. |
priceMax | Highest full price (per night, or per person per trip). |
bash
curl "https://YOUR-DOMAIN/api/book/pool/search?type=Vessel&from=2027-03-12&to=2027-03-19&pax=1&country=ID"json
{
"results": [
{
"asset": { "id": "…", "name": "MV Laut Senja", "type": "Vessel", "sub": "Labuan Bajo" },
"schedule": { "id": "…", "name": "Komodo North–South", "from": "2027-03-12", "to": "2027-03-19", "nights": 7 },
"inRelease": false,
"releaseFrom": "2027-01-26",
"lines": [
{
"roomType": "…", "name": "Lower Quad", "poolRoom": "…", "maxPax": 4,
"shareable": true, "freeUnits": 0, "shareMale": false, "shareFemale": true,
"lastSpot": "female", "boards": [], "soloPrice": null,
"price": { "price": 1890, "currency": "EUR" }, "priceBasis": "pp_trip", "sellable": true
}
]
}
]
}What the public response guarantees:
- Only active, priced, bookable lines outside the release period. Drafts, hidden room types and assets not open for customer booking never appear.
freeUnitsis capped at 5 — never the real allocation. Use it for "Only N left".- Shared beds are booleans:
shareMale,shareFemale. A line with no whole cabin left but a bed for one gender is still returned (freeUnits: 0). - No
alternatives, no sold or pax counts, no supplier data. - Resort lines:
priceBasis: "night",stayTotalfor one unit,boards(board names), optionalsinglePrice(the 1-guest night price, only when it differs from the default-occupancy price — see Staff API), and astayon the result — withflex, the shifted dates that have space. - Vessel lines: price per person per trip;
soloPrice= the full price for one guest alone;specialPriceandspecialNamewhen a supplier discount applies. - At most 50 results. The route allows about 30 requests per minute per client; more get
429. - One search looks at no more than 200 resorts or liveaboards, taken alphabetically by name. Resort results are listed alphabetically too, so a big inventory still gives you the first part of the full list. To reach the others, narrow the search with
country,cityorport.
Booking a result
Book through the public booking API, POST /api/book/booking/create, with one room line per unit on the line's poolRoom:
json
{
"type": "Vessel",
"vessel": "<vesselId>", "schedule": "<scheduleId>", "tour": "<tourId>", "price": "<priceListId>",
"date": { "from": "2027-03-12T00:00:00.000Z", "to": "2027-03-19T00:00:00.000Z" },
"room": [
{ "room": "<poolRoom>", "locked": false, "gender": "f",
"date": { "from": "…", "to": "…" },
"customer": [ { "firstName": "Ana", "lastName": "Example", "email": "ana@example.com", "gender": "f" } ] }
],
"customer": { "firstName": "Ana", "lastName": "Example", "email": "ana@example.com", "gender": "f" },
"noOfPax": 1, "acceptTerms": true
}- Trips: take
tourandpricefrom the trip's entry in the public schedules list (GET /api/book/schedules). Resorts sendresortinstead ofvessel/schedule/tour/price, with the result'sstaydates. - Whole room or cabin:
locked: true, up tomaxPaxguests per line; book ⌈pax ÷ maxPax⌉ lines. - Shared bed:
locked: false, one guest per line, gendermorfon the guest. - The same body sent to the booking price endpoint returns the quote.
- The booking state and agency follow the company's online-booking settings.
Availability is checked again when the booking is created. Public callers get the bare code, never counts:
| Code | Meaning |
|---|---|
QTY_EXCEEDS_FREE | Taken in the meantime. Search again. |
PRICE_MISSING, RELEASE_PERIOD | No longer bookable online. |
GENDER_REQUIRED_FOR_SHARED | A shared-bed guest has no gender. |
ROOM_NOT_AVAILABLE | Not a pool room of this asset, or the asset isn't bookable. |
INVENTORY_BUSY (409) | Another booking was saving at the same moment. Retry. |
Related
- Staff endpoints
- Embed the widget — the ready-made PoolSearch widget does all of this for you.
- User guide: The public widget
