Bỏ qua để đến nội dung

Get Room Types List

API cho đối tácAdd-on
GET
/properties/{tenant_id}/room_types

Returns all active room types including their availability (quantity) for specific check-in and check-out dates. Unlike /room_types/search endpoint, this returns ALL room types including those with quantity = 0.

Scope Required: properties:read

Query Parameters:

  • checkin_date (required): Check-in date in YYYY-MM-DD format
  • checkout_date (required): Check-out date in YYYY-MM-DD format
  • room_type_id (optional): Specific room type code (UUID) to check (if not provided, returns all room types)

Important Notes:

  • Maximum stay period: 30 days
  • checkin_date and checkout_date must be different dates (checkout must be strictly after checkin)
  • Returns ALL active room types including those with 0 available rooms
  • Does NOT filter by occupancy (adults/children/infants)
  • Availability calculation considers:
    • Existing bookings (confirmed, checked-in)
    • Room maintenance schedules
    • Out-of-order rooms
  • Rate plans returned are “direct rate plans” only (not derived/seasonal)
  • Rate plans include days_breakdown with daily rates (uses restrictions data first, then default_rates)
  • Rate plans include estimated_total_price (sum of daily rates)
  • Rate plans include has_breakfast (boolean flag whether breakfast is included in the rate)
tenant_id
required
string
room_type_id
string | null format: uuid
Example
550e8400-e29b-41d4-a716-446655440000
checkin_date
required
string format: date
Example
2025-11-19
checkout_date
required
string format: date
Example
2025-11-21
object
success
required
boolean
data
required
Array<object>
object
room_types
required
object
id
required
string
title
required
string
quantity
required
integer
occ_adults
required
integer
occ_children
required
integer
occ_infants
required
integer
rate_plans
required
Array<object>
object
id
required
string
title
required
string
currency
required
string
sell_mode
required
string
has_breakfast
required
boolean
days_breakdown
required
Array<object>
object
day
required
string
price
required
number
estimated_total_price
required
number

Validation error

object
message
required

Errors overview.

string
errors
required

A detailed description of each field that failed validation.

object
key
additional properties
Array<string>
Bài này có giúp được bạn không?