Skip to main content
Not served yet. This page describes the final contract, version 1.0.0. Until the sandbox opens with the first test key, try it against a mock of the contract (Testing).
Prices follow the party. Each night of a rate carries the price for every number of adults the property takes, what each child adds by age band and what an infant adds, all as the guest pays them, so the price of any stay is a sum and you compute no rule. Every amount is VAT included, with your markup applied to the nightly prices and never to fees.

Rate plans

A property has one or more rate_plans, each a way to sell it with its own nightly prices and rules:
  • meal_plan: none, breakfast, half_board, full_board or all_inclusive. Open enum: accept a value you do not know.
  • cancellation: refundable, free_until_days_before, penalty, penalty_percent, and a text Gridbeds generates from those fields. The fields are what binds.
  • child_age_bands: the age bands the plan prices children by.
  • lower_price_reasons: why a guest may pay less than the price you add up.
Gridbeds applies no reduction for the length of a stay or for booking early or late. A cheaper rate for a longer or an earlier stay is a rate plan of its own, with its own nightly prices and rules (min_stay, closed_to_arrival): offer every plan whose rules admit the stay, as the property’s own site does, and the cheapest of them is the lowest price Gridbeds offers for it.

A night’s prices

Each rate of a night, in rates of an availability response, prices the whole party:
  • Children by age. child_age_bands lists the plan’s bands in ascending order, never overlapping, each {age_from, age_to} in whole years from 0 to 17, both inclusive. When it is not empty, ask the guest for each child’s age: a child whose age falls in no band cannot be booked. When it is empty, the plan prices children without their age, by child_price.
  • Infants. capacity.max_infants is how many infants the property takes beside max_guests, in a cot and using no bed. An infant is a guest the booking declares as one, conventionally under 2; the property sets no age limit for it in version 1.

The price of a stay

For a party on one rate plan, the price of a stay is:
1

Every night of the stay

For each night from arrival up to departure (exclusive): the night’s prices_by_occupancy entry for the number of adults, plus for each child the child_prices entry of its age band (or child_price when the plan names no bands), plus infant_price for each infant.
2

The fees paid with the booking

Then each fee with included_in_price: false and payable_at: booking: once for per: stay, once per night for per: night and once per guest and night for per: guest_night. In version 1 that is the cleaning fee, once per stay.
That sum is the price of the stay the guest books on the property’s own site, VAT included, however much of it the rate plan takes as a deposit. Nothing else is added and nothing is taken off. What is paid at the property is shown beside it. A fee with payable_at: property (in version 1 the tourist tax, city_tax) is paid to the property during the stay and is not part of that price: the property’s own site shows it beside the price, and so should you. A fee with included_in_price: true is already in the nightly prices: show it, and add nothing. Charges a property posts to a stay on its own account during it (parking, a resort fee, breakfast billed by the night) are not published in version 1; they are not part of the price on the property’s own site either, and are settled at the property.

When the property’s own quote differs

The property’s own quote can differ from your sum in four ways, and in no other: One more difference holds until the property’s site asks for each child’s age and for infants: the redirect carries only the number of adults and of children (booking.url_template), so a party with children on a plan that prices them by age band is priced there without their ages, and a party’s infants are not priced there at all. lower_price_reasons is always present, and empty when no guest pays less. Its one value today is promo_code: the property has a promo code a guest can still redeem on its own site. It is listed only when booking.method is redirect, because only a guest sent to the property’s site can type one. Say that the final price may be lower, and read a reason you do not know the same way. A change to it is a property.updated with a higher version.

Fees

fees lists the charges beside the nightly prices. Version 1 publishes cleaning and city_tax, each at most once, and neither carries your markup. Every member of a fee is always present; one that does not apply is null. A cleaning fee always has basis: fixed, an amount, per: stay and payable_at: booking:
Read basis first. A fee whose basis you do not know is shown as payable at the property when payable_at is property, and is never added to the price of a stay.

The tourist tax

The tourist tax is never left out. Some municipalities levy it as a fixed amount per guest and night, others as a percentage of the accommodation price, and the amounts change by local decision. Every property says which of three things is true in city_tax_status: A property without a city_tax fee is therefore never a statement that there is no tax, unless its city_tax_status is none. Read a status you do not know as undeclared. A change is a property.updated with a higher version. A city_tax is paid at the property (payable_at: property) and is never added to the price of a stay. It states what is known and no more:
  • basis: fixed, with an amount per taxable guest and night (per: guest_night). The tax of a stay is amount × taxable guests × nights, the nights capped at max_nights, rounded once to the currency’s minor unit. The taxable guests are the adults and the children, or the adults alone when exempts_children is true, and never the infants. That is the most the property charges: any further exemption it applies only lowers it. amount is the rate in force on the property’s today; a stay that begins after a new rate takes effect is charged the new one.
  • basis: percent, with percent_bp: a percentage of the accommodation price named by percent_of, for the whole stay (per: stay), or for its first max_nights nights when that is set. The base is the accommodation price at the property’s own rates, without your markup and without fees, excluding or including VAT; the prices you receive include VAT and your markup, so the base cannot be derived from them exactly. Gridbeds does not compute the amount and neither should you: show the percentage as a local tax paid at the property. Exemptions from a percentage are not modelled: exempts_children is null, and the property applies its own. Read a percent_of you do not know as “the accommodation price”.
  • A value that is not known is null, and the fee is still there. basis: fixed with amount: null, or basis: percent with percent_bp: null, says that the tax exists and how it is charged, but not how much. basis: null, with per, amount and percent_bp null, says only that a tourist tax applies. Show such a fee as a local tax payable at the property, never as zero.
The least a city_tax can say: