Enums
Every enumeration the hotel API uses, from booking statuses and meal plan types to hotel categories, languages and passenger data fields, with the rules for handling values you don't recognise.
The values below come from the OpenAPI spec. New values do appear over time, for example in ServiceStatus and TripType, so parse every enum leniently and route unknown values to a person instead of failing.
ServiceStatus
The status of a service (one booked hotel) and of a whole booking. The spec lists 21 values, but only seven are documented as booking and service outcomes.
| Status | Meaning |
|---|---|
BOOKED | Confirmed by the supplier. |
RQ | On request: the supplier hasn't confirmed yet. |
PENDING_BOOK | Still in the booking process. |
PRICE_ERROR | Booked, but the supplier's closing price differed beyond the price tolerance. |
BOOK_ERROR | Error while booking or closing the service. |
NOT_BOOKED | The supplier did not confirm. |
CANCELED | Cancelled. |
The other 14 values are not documented as outcomes. Treat any of them, and any value not on this page, as "needs attention": don't crash, and never treat it as success.
NOT_QUOTED, QUOTED, LOAD_CANCELLATION_POLICIES_ERROR, CONFIRMATION_ERROR, CONFIRMED, PREBOOKED, PAID, NEED_QUOTE, CANCEL_ERROR, LOCKED, PENDING_UPDATE, WITH_PROPOSALS, WAITING_SUPPLIER, WAITING_ACCEPTANCE
const OUTCOMES = ['BOOKED', 'RQ', 'PENDING_BOOK', 'PRICE_ERROR', 'BOOK_ERROR', 'NOT_BOOKED', 'CANCELED'] as const;
type Outcome = (typeof OUTCOMES)[number] | 'NEEDS_ATTENTION';
export const toOutcome = (status: string): Outcome =>
(OUTCOMES as readonly string[]).includes(status) ? (status as Outcome) : 'NEEDS_ATTENTION';What to do for each outcome is in Book and Booking statuses.
MealPlanType
ROOM_ONLY, BED_AND_BREAKFAST, HALF_BOARD, FULL_BOARD, ALL_INCLUSIVE
Mixed plans collapse to the nearest type: "1 bed and breakfast + 1 half board" comes back as HALF_BOARD. Use type to group and filter, and show the meal plan's description to guests. See Meal plans.
CancellationPolicyType
The type of currentCancellationType in quote responses.
| Value | Meaning |
|---|---|
REFUNDABLE | Free cancellation until the deadline. |
PARTIALLY_REFUNDABLE | Partially refundable. |
NON_REFUNDABLE | Not refundable. |
UNKNOWN | Unknown. Read the policy steps. |
The full policy is always the list of CancellationPolicyVO steps. Only Confirm's policies are authoritative.
WarningType
PRICE_CHANGE, CANCELLATION_POLICIES_CHANGE
Returned in warnings[] by Confirm and Prebook. Show the change to the guest and get their consent again before you continue. A refundable offer may have become non-refundable.
HotelCategory
Four scales.
| Codes | Scale |
|---|---|
S1 to S6 | Stars |
L1 to L5 | Keys |
H1 to H5 | Suns |
IN | None, or indeterminate |
Datasheets return the code as a string ("S4"). The booking flow returns an object with the code and a name, for example { "code": "S4", "name": "4 STARS" }. Normalise both into one type.
AccomodationType
The spec spells the enum name AccomodationType (sic). The field is accommodationType.
HOTEL, APARTMENT
The FAQ writes the values as "Hotel or Apartement", so compare them case-insensitively.
AccommodationSubtype
33 values, for finer filters than accommodationType.
HOTEL, MOTELS, RESORTS, BED_AND_BR, RYOKANS, INNS, RIADS, ECONOMY_H, HEALTH_RESORTS, CAPSULE_HOTELS, LOVE_HOTELS, HOSTEL, LUXURY_TENTS, STUDENT_AC, APARTHOTELS, OTHER, APARTMENT, GUEST_AC, RESIDENCES, FARM_STAYS, HOLIDAY_PARKS, VILLAS, CAMPSITES, BOATS, GUEST_HOUSES, HOLIDAY_HOMES, LODGES, HOMESTAYS, COUNTRY_HOUSES, CHALETS, CONDOS, COTTAGES, GITES
Image ClassificationType
What an image in a datasheet shows (images[].classification.type). The spec writes the values with spaces and hyphens. The docs samples write them in upper case with underscores, for example POOL, AERIAL_VIEW and HALLWAY_OR_STAIRCASE.
Normalise both sides before you compare: upper-case, replace every run of non-alphanumeric characters with _, then drop _OR_. The right-hand column shows the result.
| Spec value | Normalised |
|---|---|
Aerial View | AERIAL_VIEW |
Bathroom | BATHROOM |
Beach | BEACH |
Building | BUILDING |
Business Center | BUSINESS_CENTER |
Cleanliness badge | CLEANLINESS_BADGE |
Garden | GARDEN |
Hallway-Staircase | HALLWAY_STAIRCASE |
Kitchen | KITCHEN |
Living Area | LIVING_AREA |
Lobby-Reception | LOBBY_RECEPTION |
Meeting Facility | MEETING_FACILITY |
Parking | PARKING |
Pool | POOL |
Restaurant-Bar | RESTAURANT_BAR |
Room | ROOM |
Spa-Sauna | SPA_SAUNA |
Sports Facility | SPORTS_FACILITY |
Terrace | TERRACE |
Food | FOOD |
Waterpark | WATERPARK |
export const normaliseClassification = (s: string) =>
s.toUpperCase().replace(/[^A-Z0-9]+/g, '_').replace(/_OR_/g, '_');
// 'Hallway-Staircase' and 'HALLWAY_OR_STAIRCASE' both become 'HALLWAY_STAIRCASE'Language
40 values. Quote takes it as language; static content takes it as lang.
EN, EN_IE, EN_US, ES, IT, FR, PT, PT_BR, AR, RO, EL, FI, DE, NL, SV, ZH, ZH_TW, RU, HU, FA, PL, CA, BG, JA, MS, NO, TR, SK, SL, CS, HR, AZ, HE, DA, TH, SQ, KA, SR, UZ, EU
TripType
ONLY_HOTEL
Send ONLY_HOTEL on Quote. The field is optional there and defaults to ONLY_HOTEL.
Trips read through getBookings also carry a tripType. The platform has other values for products these docs don't cover, and new values appear over time, so don't fail on one you don't know.
CourtesyTitle
MISTER, MRS, MS
Sent as courtesyTitle when Confirm's requiredField asks for TITLE.
AcademyTitle
Dr, Prof, ProfDr
Sent as academyTitle. The values are in mixed case.
DocumentType
IDENTITY_CARD, NIE, PASSPORT
Sent as documentType, always together with documentNumber. When requiredField asks for PASSPORT, the type must be PASSPORT.
RequiredPassengerData
The values in Confirm's requiredField lists (contactPerson, otherPersons, roomHolders), and the PersonVO field to send for each. requestedAge is always mandatory, even when it isn't listed.
| Value | Send in the person | |
|---|---|---|
FIRST_NAME | name | |
LAST_NAME | lastName | |
TITLE | courtesyTitle | |
ACADEMY_TITLE | academyTitle | |
BIRTH_DATE | birthDate, consistent with requestedAge at the end of the trip | |
COUNTRY | countryId | |
PHONE | phoneCountryCode and phone | |
DOCUMENT | documentNumber and documentType | |
PASSPORT | documentNumber, with documentType set to PASSPORT | |
DOCUMENT_EXPIRY_DATE | passportExpirationDate, after the end of the trip | |
ADDRESS | address (street, city, postCode) | |
EMAIL | email | |
BILLING_DOCUMENT | billingNumber | |
SOCIAL_INSURANCE_NUMBER | socialInsuranceNumber | |
DOCUMENT_DATE_OF_ISSUE | No hotel mapping documented | |
EMERGENCY_CONTACT | No hotel mapping documented | |
SEAT_SELECTION | No hotel mapping documented | |
FREQUENT_TRAVELLER_NUMBER | No hotel mapping documented | |
INVOICE_DATA | No hotel mapping documented |
If one of the last five appears for a hotel, ask your Nava account manager. For a DOCUMENT that isn't a passport, IDENTITY_CARD or NIE is probably the right type.
PriceType
RETAIL, RETAIL_OVER, NET, NET_BASE, NET_RETAIL
Appears on booked services, as priceType in hotelservice[]. See Reading bookings.
ServiceType
HOTEL
The {serviceType} path segment of the generic cancel and cancellation fee endpoints. Send HOTEL. The platform has other service types for products these docs don't cover.
CancellationType
PROVIDER, MANUAL
Sent as cancellationType to the generic cancel endpoint, and listed in supportedCancellationTypes by the generic cancellation fee. The spec doesn't describe them. PROVIDER most likely cancels at the supplier, and MANUAL records a cancellation handled outside the platform.