Skip to content
This page is available in Markdown format. Markdown is recommended for AI consumption. See /api/hotels/get-hotel-rates/index.md for this page, or/llms.txt for the full documentation index.

List a hotel's rooms & rates

Returns the Book-on-Wego rooms & rates for a hotel (cheapest-first): room name, board, refundability, price, and each rate's composed booking reference id. searchId must name a hotel-scoped search (one created with hotelId); a city or geo search is a 409.

View as MarkdownView this page as plain text
Carries onwardrateId
Settlesimmediately
Id expiresyes · 404 means search again

GET /v1/hotels/{hotelId}/rates

Returns the Book-on-Wego rooms & rates for a hotel (cheapest-first): room name, board, refundability, price, and each rate’s composed booking reference id. searchId must name a hotel-scoped search (one created with hotelId); a city or geo search is a 409.

Operation ID: getHotelRates

Parameters

Name In Type Required Constraints Description
hotelId path integer yes 1..9007199254740991 The hotel’s numeric id (a positive integer), as carried by hotel search results (results[].hotelId) and embedded in a rate id.
searchId query string yes pattern ^[A-Za-z0-9._:~=-]{1,256}$ The search the hotel was found in (from createHotelSearch); rates are priced within that search context. Required.
currency query string no pattern ^[A-Z]{3}$; default "USD" Pricing currency as a 3-letter ISO 4217 code (e.g. AED). Defaults to USD.
locale query string no length 1..35; default "en" Response language tag (e.g. en, ar). Defaults to en.

Responses

Status Description
200 Cheapest-first Book-on-Wego rates.
400 Invalid request parameters.
401 Missing or invalid bearer token.
404 Unknown hotel, or unknown/expired search.
409 The searchId names a city or geo search, which never holds a hotel’s full rate list. Create a hotel-scoped search (createHotelSearch with hotelId) and read its rates.
429 Rate limit exceeded; retry after the Retry-After seconds.
502 The upstream hotels service returned an invalid response.
503 The hotels service is unavailable (upstream_unavailable) or rate-limited upstream (upstream_rate_limited); retry after the Retry-After seconds.

200 body

Field Type Always present Description
hotelId number yes The hotel these rates are for.
searchId string yes The search these rates were priced within.
currencyCode string yes The currency every rate price on this read was computed in – the same value as metadata.currencyCode, which carries currencyCodeSource beside it. Read it before you show a number: a price computed in the wrong currency renders as a perfectly normal price.
searchComplete boolean yes Advisory: true means upstream reports it finished aggregating rates for this search. It is not a guarantee that the list on this page is final, so do not block on it.
stay object no What upstream priced: the dates and occupancy every price on this read covers. Present when upstream states them.
checkIn string yes Check-in date priced upstream, YYYY-MM-DD.
checkOut string yes Check-out date priced upstream, YYYY-MM-DD.
nights integer yes Nights between checkIn and checkOut. price.total covers this many nights of price.amountPerNight.
occupancy object yes The occupancy priced upstream for this search (ages resolved, incl. fallback).
rates object[] yes Bookable rates for the hotel in this search.
id string yes Composed booking reference (opaque passthrough); pass it to GET /v1/hotels/{hotelId}/rates/{rateId}/booking-link.
roomName string yes Room type name, e.g. Deluxe King.
board string no Board basis, normalized to lower_snake_case (e.g. room_only, breakfast_included). Absent when the provider states none.
refundable boolean yes True when this rate carries a refundable or free-cancellation code. Authoritative on this endpoint, unlike the results card’s refundable witness.
cancellationPolicy string no Coarse policy derived from the refundability codes: free_cancellation or non_refundable.
price object yes A rate’s pricing. Every amount covers the whole booking, all rooms in the search, so quote these figures as they stand. Upstream rounds per booking, so total is the exact stay figure and amountPerNight is one night of it. All amounts exclude totalLocalTax, which wego.com adds to the displayed price.
roomsLeft number no Rooms remaining at this rate, when the provider reports scarcity; absent otherwise.
images string[] no Room image URLs, when the provider supplies them.
metadata object yes What this read resolved currency and locale to, and how each was decided.
currencyCode string yes The currency this read ASKED upstream for, and the one every price on it is meant to be in. Read it beside currencyCodeSource before you show a number: a price computed in the wrong currency renders as a perfectly normal price, with no error and no odd shape to notice, so the response states which one rather than leaving it to be inferred. Where the operation also publishes a top-level currencyCode, that field reports the currency the prices actually came back in; the two agree unless upstream declined to reprice.
currencyCodeSource explicit | default yes How the API resolved currencyCode: explicit (the caller sent currency – including a value equal to the default) or default (USD, no currency sent). A default here is the one signal that the request never carried the currency you meant.
locale string yes The language tag this read asked upstream for – what any localized text on it was resolved in (room and board names, airline and airport names, review prose).
localeSource explicit | default yes How the API resolved locale: explicit (the caller sent locale – including a value equal to the default) or default (en, no locale sent). A default here explains text that came back in a language the caller did not ask for.

Example

curl -s -H "Authorization: Bearer $TOKEN" \
  "https://api.wego.com/v1/hotels/$HOTEL_ID/rates?searchId=$SEARCH_ID"

FORM WG-REF · SEQ 004821The API and the ways in to it are early and may change.

Navigation

Type to search…

↑↓ navigate↵ selectEsc close