POST

Reservations.Add

Create a room reservation. This uses the existing reservation workflow because it handles availability rules, payments, channel booking ids, custom fields, room blocks, automation, and calendar side effects.

Permissions

  • User must be logged in with a valid bearer token.
  • Returned or changed records are limited by the user permissions, team access, folder access, and account settings.

Action

  • Creates a Reservations record or sends the requested data after validation.

Push Service

No push is sent because this function only reads data or returns helper information.

Automation

No automation is run for this function.

Special Instructions

  • Send the bearer token on protected calls with Authorization: Bearer YOUR TOKEN.
  • Send parameters as POST body fields exactly as documented.
  • Send date/time values in UTC Y-m-d H:i:s format when a date or datetime field is used.

Required Parameters

NameTypeSampleExplanation
room_id
post
int3710Room id to reserve.
cust_id
post
int123Customer id for the reservation.
start_date
post
date|datetime2026-07-20Reservation start date. Send UI dates as UTC-compatible Y-m-d or Y-m-d H:i:s. Send UTC date/time as Y-m-d H:i:s, for example 2026-07-20 10:00:00. The SDK converts user local Date/local datetime input to UTC before posting.
end_date
post
date|datetime2026-07-22Reservation end date. Send UTC date/time as Y-m-d H:i:s, for example 2026-07-20 10:00:00. The SDK converts user local Date/local datetime input to UTC before posting.
date
post
month2026-07Calendar month for the reservation, usually the start date month in Y-m.
days
post
int2Number of booked days/nights. Must be more than zero.
book_type
post
stringnightlyRoom booking type, such as nightly or daily.
total_price
post
number500Reservation total price.

Optional Parameters

NameTypeSampleWhat it gives
notes
post
stringLate check-inReservation notes.
paid_status
post
int0Payment state: 0 not paid, 1 paid, 2 partly paid. Paid/partly paid reservations require payment_method.
payment_method
post
stringcashPayment method for paid/partly paid reservations.
payment_note
post
stringPaid at deskPayment note preserved with the reservation.
discount
post
number0Reservation discount percentage/value used by the existing workflow.
room_display_name
post
stringDaniel bookingDisplay title shown on the room calendar.
room_row_id
post
int0Specific occupancy row when a room supports more than one concurrent booking.
block_this_time_room
post
int0Set to 1 to block time instead of attaching a customer reservation.
channel
post
stringdirectBooking source/channel such as direct, airbnb, or booking.
channel_booking_id
post
stringABC123External channel booking id for sync/idempotency.
channel_listing_id
post
stringlisting-1External listing id.
channel_event_uid
post
stringical-event-1External calendar event UID.

Authentication

Send the bearer token returned by Login in the request header.

Authorization: Bearer YOUR TOKEN

Sample Request

{
    "url": "\/app\/Reservations.Add",
    "method": "POST",
    "headers": {
        "Authorization": "Bearer YOUR TOKEN"
    },
    "body": {
        "room_id": "3710",
        "cust_id": "123",
        "start_date": "2026-07-20",
        "end_date": "2026-07-22",
        "date": "2026-07",
        "days": "2",
        "book_type": "nightly",
        "total_price": "500"
    },
    "url_user": "https:\/\/{user}.bull36.com\/app\/Reservations.Add",
    "url_domain": "https:\/\/{domain}\/app\/Reservations.Add"
}

Endpoint

POST /app/Reservations.Add
POST https://{user}.bull36.com/app/Reservations.Add
POST https://{domain}/app/Reservations.Add

Sample Output

{
    "success": 1,
    "message": "Room book successfully",
    "id": "88"
}

JavaScript Example

const token = 'YOUR TOKEN';
const body = new URLSearchParams({
  room_id: '3710',
  cust_id: '123',
  start_date: '2026-07-20',
  end_date: '2026-07-22',
  date: '2026-07',
  days: '2',
  book_type: 'nightly',
  total_price: '500'
});

const res = await fetch('/app/Reservations.Add', {
  method: 'POST',
  headers: { Authorization: 'Bearer ' + token },
  body
});

const data = await res.json();
console.log(data);

Error Example

{
    "success": 0,
    "message": "Please add days"
}