Hostavi™

Hostavi API

Read and manage your Hostavi properties, calendar, reservations, guest messages, reviews and cleanings, and get webhooks when they change.

Access. Available on the Business plan while the subscription is active (not on Essentials, Pro or the trial). The account owner creates keys in Settings > API & webhooks (2-step verification required).

Permissions. Each key has a permission per area: properties (read only), calendar, reservations, guest_messages, reviews, cleanings. Each is read or write (write includes read); an area not given is refused with insufficient_permission.

Limits. 120 requests a minute per key. Bodies up to 100 KB. Lists come in pages of up to 100 with next_cursor.

Data. JSON with snake_case fields; dates as YYYY-MM-DD, within 10 years of today; times in UTC (ISO 8601); amounts in cents with their currency. Text can't hold control characters (notes may hold line breaks and tabs). A key only ever sees its account's own properties; anything else answers 404.

Writes go through the same rules as the app (channel sync, cleanings, door codes). Send an Idempotency-Key header to retry safely (a key whose first request died is free again after 10 minutes).

Base URL https://www.hostavi.app/api/v1 · Machine-readable description: openapi.json (OpenAPI 3.1, for code generators and AI agents) · Keys: Settings > API & webhooks

Quick start

Send the key in the Authorization header:

curl https://www.hostavi.app/api/v1/reservations?updated_since=2026-10-01T00:00:00Z \
  -H "Authorization: Bearer hvk_live_…"

Writes take JSON. Add an Idempotency-Key so a retry after a network error never books twice:

curl -X POST https://www.hostavi.app/api/v1/reservations \
  -H "Authorization: Bearer hvk_live_…" \
  -H "Idempotency-Key: 7c2e6b1a-booking-42" \
  -H "Content-Type: application/json" \
  -d '{"property_id":"…","guest_name":"Ana Silva","guests":2,"check_in":"2030-06-01","check_out":"2030-06-04"}'

Lists come in pages: pass the answer's next_cursor as cursor until it's null.

Connect an AI agent (MCP)

Claude Code, Cursor, Codex and any other MCP client can work with your Hostavi account through Hostavi's MCP server. Nothing to install: add the address with an API key. The agent sees one tool per endpoint below, limited to the key's permissions (a read-only key gets no tools that change anything). Changes go through the same rules as the API.

Claude Code:

claude mcp add --transport http hostavi https://www.hostavi.app/api/mcp \
  --header "Authorization: Bearer hvk_live_…"

Cursor, Codex and other clients that read an mcp.json-style file:

{
  "mcpServers": {
    "hostavi": {
      "url": "https://www.hostavi.app/api/mcp",
      "headers": { "Authorization": "Bearer hvk_live_…" }
    }
  }
}

Give the agent its own key with only the permissions it needs, and keep an eye on what it does: replies and price changes reach guests and channels for real. Guest-written text reaches the agent as data; a good agent treats it as such, but review what it proposes before it acts.

Errors

Every error has the same shape, with a stable code to branch on:

{ "error": { "code": "insufficient_permission", "message": "This API key needs the reservations write permission." } }

Codes: invalid_api_key, insufficient_permission, plan_required, subscription_inactive, account_unavailable, rate_limited, not_found, invalid_request, conflict, payload_too_large, idempotency_key_reused, request_in_progress, internal_error, unavailable. A 5xx, a 429 or unavailable can be retried (with the same Idempotency-Key): those answers are never stored under it.

Endpoints

Properties

get/propertiesproperties: read

List your properties

Parameters

limitinteger · query1-100, default 50. min 1, max 100
cursorstring · queryFrom the previous page's next_cursor.

200 A page of properties. { data: Property[], next_cursor: string or null }

get/properties/{propertyId}properties: read

Get a property

Parameters

propertyId*string (uuid) · path

200 The property. { data: Property }

Calendar and prices

get/properties/{propertyId}/calendarcalendar: read

Get the calendar

Each night's price (in the property's currency), restrictions and availability, as sent to the channels. At most 366 days, within 10 years of today.

Parameters

propertyId*string (uuid) · path
from*string (date) · queryFirst night.
to*string (date) · queryLast night (inclusive).

200 One entry per night. { data: CalendarDay[] }

put/properties/{propertyId}/calendarcalendar: write

Set day prices and restrictions

Sets a day price on every night of the range (Price Parity's day overrides) and sends it to the connected channels. Fields left out keep each night's own value; null clears a stay restriction. Nights without any price need price.

Parameters

propertyId*string (uuid) · path

Body

from*string (date)
to*string (date)Inclusive.
priceintegerMinor units (cents) of the property's pricing currency. min 1
currencystringMust be the property's pricing currency (its currency) if given.
min_stayinteger or null
min_stay_throughinteger or null
max_stayinteger or null
stop_sellboolean
closed_to_arrivalboolean
closed_to_departureboolean

200 The nights of the range, after the change. { data: CalendarDay[] }

Reservations

get/reservationsreservations: read

List reservations and blocks

Sorted by check-in; with updated_since, by last change (to sync what changed).

Parameters

property_idstring (uuid) · queryOnly this property.
status"confirmed" | "blocked" | "cancelled" · queryOnly this status.
check_in_fromstring (date) · queryCheck-in on or after.
check_in_tostring (date) · queryCheck-in on or before.
updated_sincestring (date-time) · queryChanged at or after (with a time zone).
limitinteger · query1-100, default 50. min 1, max 100
cursorstring · queryFrom the previous page's next_cursor.

200 A page of reservations. { data: Reservation[], next_cursor: string or null }

post/reservationsreservations: write

Create a manual reservation or block

Like adding one in the Calendar: closes the nights on the connected channels, creates the cleaning and the door code where set up.

Body

property_id*string (uuid)
type"reservation" | "block"Default reservation.
check_in*string (date)
check_out*string (date)
guest_namestring or nullRequired for a reservation; not allowed for a block.
guestsinteger or null
notesstring or null

201 The new reservation. { data: Reservation }

get/reservations/{reservationId}reservations: read

Get a reservation

Parameters

reservationId*string (uuid) · path

200 The reservation. { data: Reservation }

patch/reservations/{reservationId}reservations: write

Change a reservation

Only the fields sent change. A channel booking's dates belong to the channel (409); an anonymised booking's guest_name and notes stay removed (409).

Parameters

reservationId*string (uuid) · path

Body

check_instring (date)
check_outstring (date)
guest_namestring or nullRequired for a reservation; not allowed for a block.
guestsinteger or null
notesstring or null

200 The reservation after the change. { data: Reservation }

post/reservations/{reservationId}/cancelreservations: write

Cancel a manual reservation or block

Channel bookings are cancelled on the channel; direct bookings in Hostavi, because a refund is involved (both 409). Cancelling one already cancelled answers it unchanged. Still possible while the property is being removed.

Parameters

reservationId*string (uuid) · path

200 The cancelled reservation. { data: Reservation }

Guest messages

get/guest-message-threadsguest_messages: read

List guest conversations

Parameters

property_idstring (uuid) · queryOnly this property.
updated_sincestring (date-time) · queryChanged at or after.
limitinteger · query1-100, default 50. min 1, max 100
cursorstring · queryFrom the previous page's next_cursor.

200 A page of conversations. Reading through the API doesn't mark them read. { data: GuestThread[], next_cursor: string or null }

get/guest-message-threads/{threadId}/messagesguest_messages: read

List a conversation's messages

Oldest first.

Parameters

threadId*string (uuid) · path
limitinteger · query1-100, default 50. min 1, max 100
cursorstring · queryFrom the previous page's next_cursor.

200 A page of messages. { data: GuestMessage[], next_cursor: string or null }

post/guest-message-threads/{threadId}/messagesguest_messages: write

Reply to a guest

Sent through the channel, translated into the guest's language unless translate is false (like the app). Refused for anonymised conversations and inquiries (409). 30 replies a minute per account. 202 means the channel took it but Hostavi's copy arrives with the next sync.

Parameters

threadId*string (uuid) · path

Body

body*stringup to 2000 characters
translatebooleanDefault true.

201 The message as stored. { data: GuestMessage }

Reviews

get/reviewsreviews: read

List reviews

Parameters

property_idstring (uuid) · queryOnly this property.
updated_sincestring (date-time) · queryChanged at or after.
limitinteger · query1-100, default 50. min 1, max 100
cursorstring · queryFrom the previous page's next_cursor.

200 A page of reviews. A review the guest never wrote, once its window has closed, is left out, so a page can hold fewer than limit: follow next_cursor. { data: Review[], next_cursor: string or null }

post/reviews/{reviewId}/replyreviews: write

Reply to a review

Posted on the channel, where it's public. A review can be answered once (409 after).

Parameters

reviewId*string (uuid) · path

Body

reply*stringup to 2000 characters

200 The review with its reply. { data: Review }

Cleanings

get/cleaningscleanings: read

List cleanings

Parameters

property_idstring (uuid) · queryOnly this property.
status"scheduled" | "pending_review" | "completed" | "cancelled" · queryOnly this status.
date_fromstring (date) · queryOn or after.
date_tostring (date) · queryOn or before.
limitinteger · query1-100, default 50. min 1, max 100
cursorstring · queryFrom the previous page's next_cursor.

200 A page of cleanings. { data: Cleaning[], next_cursor: string or null }

get/cleanings/{cleaningId}cleanings: read

Get a cleaning

Parameters

cleaningId*string (uuid) · path

200 The cleaning. { data: Cleaning }

patch/cleanings/{cleaningId}cleanings: write

Change a cleaning

Only while it's still to do (scheduled). The assignee must be an active cleaner or co-host on the property (see /team); the people concerned are told, like in Turnover.

Parameters

cleaningId*string (uuid) · path

Body

assigned_user_idstring (uuid) or null
datestring (date)
timestring or nullHH:MM
notesstring or null

200 The cleaning after the change. { data: Cleaning }

post/cleanings/{cleaningId}/completecleanings: write

Approve a cleaning waiting for review

Only a cleaning in pending_review: marking a scheduled one done is the cleaner's (409).

Parameters

cleaningId*string (uuid) · path

200 The completed cleaning. { data: Cleaning }

post/cleanings/{cleaningId}/cancelcleanings: write

Cancel a cleaning

Only a scheduled one; its cleaner is told.

Parameters

cleaningId*string (uuid) · path

200 The cancelled cleaning. { data: Cleaning }

post/cleanings/{cleaningId}/restorecleanings: write

Restore a cancelled cleaning

Refused when its stay was cancelled or the booking already has an open cleaning (409).

Parameters

cleaningId*string (uuid) · path

200 The restored cleaning. { data: Cleaning }

get/teamcleanings: read

Who can be assigned cleanings

Active cleaners and co-hosts of a property. No emails.

Parameters

property_id*string (uuid) · queryThe property.

200 The team. { data: TeamMember[] }

Objects

Money

amount*integerMinor units (cents).
currency*stringISO 4217, upper case.

Property

id*string (uuid)
name*string
address*string or null
location*{ latitude: number, longitude: number } or null
max_guests*integer or null
bedrooms*integer or null
bathrooms*number or null
check_in_time*string or nullLocal time HH:MM at the property.
check_out_time*string or nullLocal time HH:MM at the property.
parent_property_id*string or nullFor a room: the id of the whole place it is part of. A booking of the whole place closes its rooms, and a booking of a room closes the whole place.
currency*stringISO 4217, upper case. What the property's prices are in, on its calendar and on the channels. Set when the property is created; a room has its place's.
created_at*string (date-time)

Reservation

id*string (uuid)
property_id*string (uuid)
type*"reservation" | "block"A block has no guest.
source*"airbnb" | "booking" | "expedia" | "agoda" | "tripcom" | "vrbo" | "manual" | "direct_booking"Where it came from.
status*"confirmed" | "blocked" | "cancelled"
check_in*string (date)
check_out*string (date)The departure day (the last night is the day before).
guest*{ name, email, phone, country, language } or null
guests*{ total, adults, children, infants } or null
price*Money or null
extra_fees*Money or null
channel_commission*Money or null
channel_reservation_code*string or null
notes*string or null
created_at*string (date-time)
updated_at*string (date-time)
cancelled_at*string (date-time) or null
links*ReservationLink[]Links connected tools saved on the booking (online check-in, deposit).

CalendarDay

date*string (date)
price*Money or null
available*booleanBookable: priced, not stop-sold, no confirmed stay or block on the night.
restrictions*{ min_stay, min_stay_through, max_stay, stop_sell, closed_to_arrival, closed_to_departure }
reservation_id*string (uuid) or nullThe stay or block covering the night.

GuestThread

id*string (uuid)
property_id*string (uuid)
reservation_id*string (uuid) or null
channel*string
guest_name*string or null
last_message_at*string (date-time) or null
unread*booleanA guest message arrived after the host last read the conversation.
closed*boolean
anonymised*booleanGuest data was removed; replies are refused.
inquiry*booleanA question before booking; the channel takes no replies through Hostavi.
created_at*string (date-time)
updated_at*string (date-time)

GuestMessage

id*string (uuid)
thread_id*string (uuid)
sender*"guest" | "host" | "system"
body*string or null
translated_body*string or null
translated_locale*string or null
attachments*{ name: string or null, type: string or null, size: integer or null }[]Described only; files aren't served by the API.
created_at*string (date-time)

Review

id*string (uuid)
property_id*string (uuid)
reservation_id*string (uuid) or null
channel*string
guest_name*string or null
overall_score*number or nullOut of 10. Null until the guest's score has arrived.
scores*{ category: string, score: number }[]
content*string or null
reply*string or null
replied*boolean
received_at*string (date-time) or null
created_at*string (date-time)
updated_at*string (date-time)

Cleaning

id*string (uuid)
property_id*string (uuid)
reservation_id*string (uuid) or null
status*"scheduled" | "pending_review" | "completed" | "cancelled"
date*string (date)
time*string or nullHH:MM
assigned_to*{ id: string (uuid), name: string or null } or null
notes*string or null
completed_at*string (date-time) or null
created_at*string (date-time)

TeamMember

id*string (uuid)
name*string or null
role*"cleaner" | "co_host"

Webhooks

Add up to 5 https addresses in Settings > API & webhooks and choose their events. Hostavi sends a POST with { id, type, created_at, data }, where data is the object as the API returns it. Answer 2xx within 10 seconds; anything else is retried for about 24 hours, and an address failing for 3 days is switched off (you get an email). The same event can arrive twice: use webhook-id to ignore repeats.

Requests are signed with the Standard Webhooks scheme: check the signature with any Standard Webhooks library, or by hand:

import { createHmac, timingSafeEqual } from "crypto";

// secret: the address's signing secret (whsec_…); rawBody: the request body as received.
function isFromHostavi(rawBody, headers, secret) {
  const id = headers["webhook-id"], timestamp = headers["webhook-timestamp"];
  if (Math.abs(Date.now() / 1000 - Number(timestamp)) > 300) return false; // too old
  const key = Buffer.from(secret.slice("whsec_".length), "base64");
  const expected = createHmac("sha256", key).update(`${id}.${timestamp}.${rawBody}`).digest();
  return headers["webhook-signature"].split(" ").some((entry) => {
    const given = Buffer.from(entry.split(",")[1] ?? "", "base64");
    return given.length === expected.length && timingSafeEqual(given, expected);
  });
}
reservation.createdReservationA reservation or block was added, from any channel, the app or the API.
reservation.updatedReservationA reservation's dates, guest, guests, notes or price changed, or a connected tool saved, changed or removed one of its links (its updated_at moves too).
reservation.cancelledReservationA reservation was cancelled.
message.receivedGuestMessage + { property_id: string (uuid) }A guest sent a message.
review.receivedReviewA guest left a review.
review.updatedReviewA review was completed (score first, text later) or answered.
cleaning.createdCleaningA cleaning was created.
cleaning.updatedCleaningA cleaning was assigned, moved, completed or cancelled.
calendar.updated{ property_id, from, to, all_dates }Prices or restrictions changed; one notice per batch of changes.
Hostavi API | Hostavi