Booking Endpoints
Booking Endpoints
Create, manage, and retrieve golf course bookings. Standard bookings support up to 4 players. For larger groups, use the Group Bookings endpoints.
Create a Booking
Code
Creates a new golf course booking.
Request Body
Code
Required Fields
| Field | Type | Description |
|---|---|---|
courseId | string | Course document ID |
date | string | Booking date (YYYY-MM-DD) |
teeTime | string | Requested tee time (HH |
players | integer | Number of players (1-4) |
leadPlayer | object | Lead player details (firstName, lastName, email required) |
Response
Code
For online courses, the booking is confirmed immediately. For offline courses, the booking enters a pending state until confirmed by the golf course.
List Agency Bookings
Code
Returns all bookings for the authenticated agency.
Query Parameters
| Parameter | Type | Description |
|---|---|---|
page | integer | Page number (default: 1) |
pageSize | integer | Items per page (default: 20, max: 100) |
status | string | Filter by status (confirmed, pending, cancelled) |
startDate | string | Filter bookings on or after this date (YYYY-MM-DD) |
endDate | string | Filter bookings on or before this date (YYYY-MM-DD) |
Response
Code
Get Booking Details
Code
Returns details of a specific booking.
| Parameter | Type | Description |
|---|---|---|
id | string | Booking ID |
Returns the same structure as the create booking response.
Update a Booking
Code
Updates an existing booking. Only certain fields can be modified.
Request Body
Code
Modifiable Fields
| Field | Description |
|---|---|
players | Number of players |
specialRequests | Special requests or notes |
agencyBookingReference | Your internal reference |
Cancel a Booking
Code
Cancels an existing booking. Cancellation fees may apply depending on the course's cancellation policy. Use GET /courses/{id}/terms to check the cancellation policy before cancelling.
Response
Code
Cancellation policies vary by course. Check GET /courses/{id}/terms for the applicable cancellation tiers and refund percentages.