A gap-night rule adjusts a short run of available nights between known reserved or blocked nights. The gap must also be bookable: lowering the rate cannot fix a minimum stay or check-in restriction that prevents the stay.
Illustrative calendar: June 12–17, 2026. Calculation date June 13; $200 per night after model effects.
Try each calendar scenario. A “gap” is a continuous stretch of known available nights with known unavailable boundaries. A missing date is not a boundary. A matching gap length alone is also not enough: the stay must be bookable.
| Situation | One-night gap on June 13 | Two-night gap on June 15–16 |
|---|---|---|
| Minimum stay is two nights | Too short; no gap adjustment | Can qualify |
| Custom rule excludes weekends | Saturday excluded | Monday and Tuesday still eligible |
| June 17 is unknown | Unaffected; both boundaries known | Right boundary unknown; no gap adjustment |
For the original -15% one-night / -8% two-to-three-night policy, the standalone prices are $170 and $184 respectively. In the “no adjustment” cases, $200 is retained before other rules and limits, not guaranteed as the final API price.
A blocked night can bound a gap, but it cannot anchor an adjacent-day reservation search. A nonzero gap adjustment prevents the adjacent rule from also adjusting that same date. If the gap is ineligible or its band has a zero adjustment, a separately eligible adjacent rule can still run.
The JSON below is an addition to this complete Calendar Prices request. Merge fields into one request; do not send a rule fragment by itself.
{
"location": {
"latitude": 25.7907,
"longitude": -80.13
},
"currency": "USD",
"base_price": 200
}
All worked prices use USD and assume a $200 price after model effects, with no other adjustments unless stated. They demonstrate arithmetic, not live forecasts.
Gap-day, adjacent-day, and occupancy-pacing rules need calendar.
Each row requires a unique date and a status: available, reserved, or
blocked. For this historical illustration, assume today is June 13, 2026:
{
"calendar": [
{"date": "2026-06-12", "status": "reserved", "reservation_id": "booking-a"},
{"date": "2026-06-13", "status": "available", "price": 240, "min_stay": 1,
"check_in_allowed": true, "check_out_allowed": true},
{"date": "2026-06-14", "status": "reserved", "reservation_id": "booking-b"},
{"date": "2026-06-15", "status": "available"},
{"date": "2026-06-16", "status": "available"},
{"date": "2026-06-17", "status": "reserved", "reservation_id": "booking-c"}
]
}
This creates a one-night gap on June 13 and a two-night gap on June 15–16. Use your current dates in a real request. Send up to 1,000 rows; order does not matter. Missing dates mean unknown, not available.
Optional min_stay (1–365), check_in_allowed, and check_out_allowed
help test whether a gap is bookable when no corresponding custom stay rule
is set; defaults are one night and both permissions true. price must be
positive in the request currency but does not affect calculations.
reservation_id must be nonblank and is allowed only on reserved or blocked
rows; it is not currently used by pricing rules.
| Date | June 12 | June 13 | June 14 | June 15 | June 16 | June 17 |
|---|---|---|---|---|---|---|
| Status | Reserved | Available | Reserved | Available | Available | Reserved |
| Gap | Boundary | 1 night | Boundary | 2 nights | 2 nights | Boundary |
Add this rule alongside the calendar above:
{
"pricing_rules": {
"gap_day": {
"mode": "custom",
"settings": [
{"min_days": 1, "max_days": 1, "adjustment_percent": -15},
{"min_days": 2, "max_days": 3, "adjustment_percent": -8}
],
"apply_on_weekends": true
}
}
}
June 13 receives −15% (200 → 170); each night of June 15–16 receives −8% (200 → 184). A gap needs known reserved or blocked nights on both sides and must be bookable under the effective stay restrictions. A two-night minimum would make the one-night gap ineligible.
Gap bands are inclusive, ascending, non-overlapping, and within 1–30 nights.
Uncovered lengths receive no adjustment. apply_on_weekends is required in
custom mode; false excludes Friday and Saturday nights, including June 13.
A two-night gap with a three-night minimum is not eligible. Likewise, disallowing the required check-in or checkout can prevent a gap stay. Custom stay rules take precedence over the corresponding calendar-row restrictions; without them, the supplied row restrictions apply.
If an available run began before today, its gap length counts only the remaining nights from today onward. Each night qualifies only if at least one allowed stay within the gap can include it. The minimum stay is evaluated on that stay's check-in date, and checkout permission on its departure date.
For custom mode with apply_on_weekends: false, Friday and Saturday dates are excluded from adjustment. This is the engine's weekend definition, not a locale-dependent setting.
Check the evidence in this order:
Stay ahead of the curve
Join our newsletter for exclusive insights and updates. No spam ever.