Book a visit
/care/v1/booking/create/documentbooking:writeBAA requiredBooks one of the open times of a service for a patient. The patient must have an active connection with your company that allows bookings. Insurance cannot be used for a booking made through this API.
The order of calls is: connect the patient, save a card, book. A visit charges nothing when it
is booked; the visit, a late-cancellation fee and a no-show fee are charged later to the
patient's default card, so a patient with no default card cannot be booked. Save one first
with POST /care/v1/patient/{patient_id}/payment-method/setup/create/document and its confirm
route.
Booking the same patient, specialist and start again returns the first booking, so a retry is
safe. A new booking raises one booking.created event; a repeat raises none.
Needs the booking:write scope.
Request body
client_notestringnullableA note for the specialist, at most 2000 characters. It cannot contain
$,{or}.Max length 2000 · Pattern ^[^${}]*$
service_idstringrequiredThe ID of the service.
Min length 1 · Max length 200
specialist_idstring (uuid)requiredThe ID of the specialist.
start_timestring (date-time)requiredThe start of the open time you chose, with a UTC offset. Take it from the open times of the service.
timezonestringrequiredThe patient's IANA timezone, for example
America/Toronto.Min length 1 · Max length 64
userstring (uuid)requiredThe ID of the patient the visit is for. The patient must have an active connection with your company that allows bookings.
Response 201
booking_idstringrequiredThe ID of the booking.
booking_namestringrequiredThe name of the booking.
client_notestringnullableThe note for the specialist. Only when you read one booking.
created_atstring (date-time)requiredWhen your company booked the visit.
end_datestring (date-time)requiredWhen the visit ends, in UTC.
has_reportbooleanrequiredWhether a report exists for the visit.
is_insurance_selectedbooleanrequiredWhether insurance was selected. Always
falsefor a booking made through this API.service_snapshotBookingServicerequiredThe service, as of the booking.
Show child attributesHide child attributes
accepted_insurance_providersarray of stringThe insurance providers accepted for the service.
is_insurance_acceptedbooleanrequiredWhether insurance was accepted for the service.
service_currencystringrequiredThe currency of the price.
service_descriptionstringnullableThe description of the service.
service_duration_in_minutesintegerrequiredThe length of the visit in minutes.
service_idstringrequiredThe ID of the service.
service_image_urlstringnullableThe URL of an image of the service.
service_mode_of_deliveryenumrequiredHow the visit is delivered:
In PersonorVirtual.In PersonVirtual
service_namestringrequiredThe name of the service.
service_price_in_centsintegerrequiredThe price in cents, as it was when the visit was booked.
specialiststringrequiredThe ID of the specialist.
specialist_snapshotBookingSpecialistrequiredThe specialist, as of the booking.
Show child attributesHide child attributes
first_namestringrequiredThe first name.
last_namestringrequiredThe last name.
profile_picture_urlstringnullableThe URL of the photo.
specialist_idstringrequiredThe ID of the specialist.
specialist_typeenumrequiredThe kind of specialist.
DietitianCertified Nutrition SpecialistPhysical Trainer
start_datestring (date-time)requiredWhen the visit starts, in UTC.
statusenumrequiredThe status of the booking:
booked,meeting_rescheduled,meeting_completed,meeting_cancelledorno_show.bookedmeeting_rescheduledmeeting_completedmeeting_cancelledno_show
timezonestringrequiredThe IANA timezone the visit was booked in.
updated_atstring (date-time)requiredWhen the record of the visit last changed.
userstringrequiredThe ID of the patient.
Errors
Every error has this shape. Branch on code, not on message. request_id equals the X-Request-Id response header.
{
"error": {
"code": "not_found",
"message": "The object does not exist.",
"request_id": "req_0123456789abcdef0123456789abcdef"
}
}| Status | Code | Meaning |
|---|---|---|
401 | invalid_api_key | The API key is missing or not valid. |
403 | company_archived | This company is archived. |
403 | company_not_live | The company must be live to use prod keys. |
403 | company_suspended | This company is suspended. |
403 | connection_scope_not_granted | When the patient did not allow bookings |
403 | scope_not_granted | This API key does not have the booking:write scope. |
404 | not_found | When the patient has no connection with your company that allows care |
409 | agreements_not_signed | When the patient has not signed the agreements a visit needs |
409 | connection_not_active | When the connection is pending or was revoked |
409 | not_licensed_here | When the specialist cannot serve the booking yet |
409 | payment_method_required | When the patient has no card saved to their account. Nothing is booked |
409 | service_not_bookable | When the service cannot be booked online, or the specialist or the service does not exist |
409 | slot_taken | When the time is no longer open |
422 | validation_error | body.user: Field required |
429 | rate_limited | Too many requests. Wait before calling again. |
500 | internal_error | Something went wrong on our side. Please try again later. |
502 | upstream_error | A Nurish'd service could not complete the request. |
503 | upstream_unavailable | A Nurish'd service is unavailable. Please try again later. |
504 | upstream_timeout | A Nurish'd service did not answer in time. Please try again. |