Book an appointment with multiple services and/or multiple customers
POST/api/v2/branches/:branchPublicId/dates/:date/times/:time/book
Book an appointment with multiple services and/or multiple customers.
Example:
curl -X POST -H "Content-Type: application/json" -d '{
"title": "Meeting A",
"customers": [
{"publicId":"e86b8db371eda62b5bcef33556450969aaa0f46a7a5f8ecbe45757d7f4798d18"},
{"publicId":"64c90fbc11b35ccebec0305480d4acaa6a793dae38c11711fa9d4d59071fc12f"}
],
"services": [
{"publicId":"4c2fe2853f1f4b429b928faabc8b35e6c6a3154ff883163f4149676e4a84df00"},
{"publicId":"df20bd853e13c5b71715f3f332ec304839637ac8b34cdd3c20c9820f01377dd9"}
]}'
"http://localhost:8080/calendar-backend/public/api/v2/branches/6f27497fb5cc458ff05242ebb3a11872cd17e501eff275074439b0d1f3d8d43e/dates/2016-09-08/times/14:00/book"
If the setting to enable custom slot length is enabled in the calendar configuration, it is possible to override the calculated appointment duration (which is normally based on service times and no of customers). To do this add a matrix parameter "customSlotLength" to the request, which specifies the booking time in minutes. Simply add e.g. ";customSlotLength=60" to the URL in the example above. The REST endpoint will throw an error if an attempt is made to use customSlotLength without the setting being enabled.
Request
Responses
- 201
A Json object of com.qmatic.qp.calendar.rest.dto.AppointmentDTO