Page Summary
-
BatchAvailabilityLookup is used to check the availability of a specific time slot with details like merchant ID, service ID, staff ID, duration, and start time.
-
The BatchAvailabilityLookup response indicates if the requested slot is available and confirms the mode of confirmation.
-
CreateBooking is used to make a new booking with user information, payment details, and the slot information.
-
The CreateBooking response confirms the booking with a booking ID and status.
-
UpdateBooking allows for modifying an existing booking, such as changing its status to "CANCELED".
BatchAvailabilityLookup (slot click)
Request
{ "merchant_id" : "1234", "slot_time" : [ { "availability_tag" : "5042328", "duration_sec" : "4500", "resource_ids" : { "staff_id" : "276191" }, "service_id" : "5678", "start_sec" : "1606359600" } ] }
Response
{ "slot_time_availability" : [ { "available" : true, "slot_time" : { "availability_tag" : "5042328", "confirmation_mode" : "CONFIRMATION_MODE_SYNCHRONOUS", "duration_sec" : "4500", "resource_ids" : { "staff_id" : "276191" }, "service_id" : "5678", "start_sec" : "1606359600" } } ] }
CreateBooking
Request
{ "idempotency_token" : "13490670332760737439", "payment_information" : { "prepayment_status" : "PREPAYMENT_NOT_PROVIDED" }, "slot" : { "availability_tag" : "5042328", "confirmation_mode" : "CONFIRMATION_MODE_SYNCHRONOUS", "duration_sec" : "4500", "merchant_id" : "1234", "resources" : { "staff_id" : "276191" }, "service_id" : "5678", "start_sec" : "1606359600" }, "user_information" : { "email" : "john.smith@gmail.com", "family_name" : "Smith", "given_name" : "John", "telephone" : "+12091111111", "user_id" : "1111111111111111111" } }
Response
{ "booking" : { "booking_id" : "890", "payment_information" : { "prepayment_status" : "PREPAYMENT_NOT_PROVIDED" }, "slot" : { "availability_tag" : "5042328", "confirmation_mode" : "CONFIRMATION_MODE_SYNCHRONOUS", "duration_sec" : "4500", "merchant_id" : "1234", "resources" : { "staff_id" : "276191" }, "service_id" : "5678", "start_sec" : "1606359600" }, "status" : "CONFIRMED", "user_information" : { "email" : "john.smith@gmail.com", "family_name" : "Smith", "given_name" : "John", "telephone" : "+12091111111", "user_id" : "1111111111111111111" } } }
UpdateBooking
Request
{ "booking" : { "booking_id" : "890", "status" : "CANCELED" } }
Response
{ "booking" : { "booking_id" : "890", "status" : "CANCELED" } }