Skip to content

Availability

Fenêtre de terminal
curl -X PUT https://localoge.com/api/v1/channel/availability \
-H "Authorization: Bearer $LOCALOGE_KEY" \
-H "Content-Type: application/json" \
-d '{
"property_id": "PROP-4821",
"availability": [
{ "date": "2026-09-01", "available": false },
{ "date": "2026-09-02", "available": false },
{ "date": "2026-09-03", "available": true }
]
}'
{
"success": true,
"data": {
"property_id": "PROP-4821",
"applied": 2,
"skipped": [{ "date": "2026-09-03", "reason": "BOOKED" }]
}
}

Up to 1000 dates per request. There is also PUT /properties/{external_property_id}/availability, with the same body minus property_id: use whichever suits you, both do the same thing.

This is the part of the response that matters. It lists the nights we did not change, and why.

reason Meaning
BOOKED The night is sold on Localoge. It cannot be changed.
HOST_BLOCKED The host closed this night themselves on Localoge AND took control of this property back (“Connected tools” screen).
ADMIN_LOCKED Night locked by Localoge. Rare, and never without a reason.
EXTERNAL_BLOCKED Night closed by another source: an iCal calendar linked directly to Localoge (Airbnb, Booking…) or another software. You can only reopen your own closures.

Your calendar is the source of truth. As with other channel managers, available: true also reopens a night the host closed on Localoge; the response names them in reopened_host_blocks. The one exception: a host who took control of this property back (“Connected tools” screen) keeps their closures, and you receive HOST_BLOCKED.

A night can be closed by you and by an iCal calendar the host linked to Localoge. It stays closed as long as either source holds it:

  • you reopen a night you had closed, which the host also blocked on Airbnb: it stays closed by Airbnb, your closure is removed (counted in applied);
  • the Airbnb event disappears while you also held the night: it stays closed by you;
  • you close a night already closed by an iCal calendar: your closure is added (applied).

A reservation (BOOKED), a closure by a host who took control back (HOST_BLOCKED) and a Localoge lock (ADMIN_LOCKED) always come before closures from a feed. Removing an iCal calendar from the listing never erases your closures.

In batches and by ranges: PUT /availability/batch

Section titled “In batches and by ranges: PUT /availability/batch”

For a whole portfolio, send up to 50 properties per call, with date ranges (date_from and date_to, both included) and, if needed, single dates that win over ranges:

Fenêtre de terminal
curl -X PUT https://localoge.com/api/v1/channel/availability/batch \
-H "Authorization: Bearer $LOCALOGE_KEY" \
-H "Content-Type: application/json" \
-d '{
"properties": [
{ "property_id": "PROP-4821", "ranges": [{ "date_from": "2026-12-20", "date_to": "2027-01-03", "available": false }] },
{ "property_id": "PROP-4822", "ranges": [{ "date_from": "2026-12-01", "date_to": "2026-12-31", "available": true }],
"availability": [{ "date": "2026-12-24", "available": false }] }
]
}'
{ "success": true, "data": { "results": [
{ "property_id": "PROP-4821", "ok": true, "applied": 15, "skipped": [] },
{ "property_id": "PROP-4822", "ok": false, "error": { "code": "PROPERTY_NOT_FOUND", "message": "unknown property, or not yours" } }
] } }
  • Limits: 50 properties per call, each at most once; 1000 days per property, ranges expanded; 200 ranges per property. Beyond: 400 INVALID_PAYLOAD, nothing is written.
  • One result per property, in the order sent. An unknown property does not stop the others: it gets ok: false and its code, the others are applied.
  • Same rules as PUT /availability: a sold night is never touched, each source only reopens its own closures, skipped gives the reason.
  • Idempotent: sending the same batch again leaves the same state (applied: 0). One call counts as one request against the rate limit.
  • PUT /availability and PUT /properties/{id}/availability do not change.
Fenêtre de terminal
curl "https://localoge.com/api/v1/channel/properties/PROP-4821/calendar?from=2026-09-01&to=2026-09-30" \
-H "Authorization: Bearer $LOCALOGE_KEY"

Returns blocked nights with their reason, prices and restrictions. This is your reconciliation tool when the two calendars disagree.

Calendar writes (PUT /availability, PUT /rates and their /batch versions) carry no version: there is no If-Match and no counter to compare. If two requests touch the same night, the last one received wins, even if it was issued earlier on your side.

What we advise:

  • One writer per listing: send all changes for a listing through a single queue, in the order they happened, and send the next one only after the previous response.
  • After an outage, a doubt, or two concurrent sends, read our calendar back (GET /properties/{id}/calendar) and compare it to yours before resending.
  • Watch GET /events: a closure set by the host or a Localoge booking appears there; only your calendar reopens it, and only if the host has not taken control back (see HOST_BLOCKED, reopened_host_blocks and skipped).
  • Identical sends have no effect: resending the last known state is always safe.

Push your changes as they happen, not on a timer. A full catch-up sync once a day is enough to cover anything that might have been lost.