Skip to main content

Manage Bookings

Bookings are a core entity in the Bookla Platform. They can be created manually by administrators or programmatically by authorized clients. Each booking is associated with a service, resource, start time, duration, and other relevant metadata.

Booking Statuses

Bookings can have the following statuses:

  • pending: Awaiting approval or payment
  • confirmed: Booking is approved and confirmed
  • finished: Service has been provided and booking is complete
  • cancelled: Booking cancelled by the client
  • no_show: Client failed to appear for the booking
  • rejected: Booking rejected by the merchant
  • failed: Booking failed, typically due to payment issues

Booking API endpoints

Creating a Booking

To create a booking, follow these steps:

  1. Query available time slots for the desired service:

    • Use the Get Available Times endpoint (client API)
    • Or the Get Available Times endpoint (merchant API)
  2. Select an available time slot and create the booking:

    • Use the Request Booking endpoint (client API)
    • Or the Create Booking endpoint (merchant API)

Rescheduling

To reschedule a booking, use the dedicated move endpoint instead of the edit endpoint. The move operation recalculates the price according to applicable price rules:

Move Booking API endpoint

Editing

For modifications other than rescheduling, use the edit endpoint: Edit Booking API endpoint

Best Practices

  • Always check for available time slots before creating a booking to ensure accuracy and prevent conflicts.
  • Use the move endpoint for rescheduling to ensure proper price recalculation.
  • Implement proper error handling to manage booking failures gracefully.