post https://app.officernd.com/api/{version}/organizations/{orgSlug}/user/bookings/checkout
The bookings checkout endpoint allows you to create a booking request with a set of parameters.
This can be used to trigger a purchase flow and generate a fee and invoice for a booking.
The checkout flow simulates the flow that members have to go through when booking a resource in the members portal or the public calendar.
Booking Request
Property | Type | Required | Description |
---|---|---|---|
start | date | true | Start datetime of the booking request. |
end | date | true | End datetime of the booking request. |
team | id | false | Reference to the company (required if no member). |
member | id | false | Reference to the member (required if no team). |
extras | object | false | Dictionary with keys the IDs of the extras to add to the booking and values - the quantity of the extra. |
source | string | false | The origin/source of the bookings. |
summary | string | false | Booking title/summary. |
description | string | false | Long description of the booking. |
tentative | boolean | false | True if the booking is not confirmed. Tentative bookings are not charged. |
free | boolean | false | True if the booking is marked as free. If a booking is marked as free, no fees will be added for it. |
size | number* | false | The resource size to be used. |
count | number | true | The count of bookings of this type to be made. |
rate | id | false | The resource rate to be used to lookup available resources. |
resourceId | id | false | The _id of the resource which will be booked. |
resourceType | id | false | The resource type to be used to lookup available resources. |
office | id | false | The office to be used to lookup available resources. |
number*: You can use a query instead of a value, for example { size: { $gte: 2 } }
, meaning the size must be at least 2
Note
In order to use the requests in this collection you need to authenticate to the API with your username and password by using this request.