Skip to content

Before using these functions, you will need a developer account and an access token. You can contact us about creating a developer account here. To get an access token, review the authentication and access tokens guide.

Once an appointment is booked for a provider, there is a variety of actions that you can take on the appointment.

Confirm the Appointment

When an appointment is booked, the status of the appointment is pending_booking. In order for the appointment to be carried out, you need to confirm the appointment.

curl -i -X POST \
  https://api-developer-sandbox.zocdoc.com/v1/appointments/confirm \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "appointment_id": "d04b049a-41b1-4aba-9268-d8973cf72cdd"
  }'

Cancel the Appointment

Note

If the appointment was booked with a Zocdoc user credential, only that user will have access to view or modify the appointment. If the appointment was booked with a machine-to-machine credential, the appointment can be viewed and modified by any of the developer's machine-to-machine credentials.

curl -i -X POST \
  https://api-developer-sandbox.zocdoc.com/v1/appointments/cancel \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "appointment_id": "d04b049a-41b1-4aba-9268-d8973cf72cdd",
    "cancellation_reason": "string",
    "cancellation_reason_type": "patient_no_longer_needs_appointment"
  }'

Reschedule the Appointment

You can modify the appointment time and request the reschedule of an appointment in pending_booking, confirmed, pending_reschedule, or rescheduled status.

Note

If the appointment was booked with a Zocdoc user credential, only that user will have access to view or modify the appointment. If the appointment was booked with a machine-to-machine credential, the appointment can be viewed and modified by any of the developer's machine-to-machine credentials.

curl -i -X POST \
  https://api-developer-sandbox.zocdoc.com/v1/appointments/reschedule \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "appointment_id": "63f995c2-49c4-40c8-a93a-140fb32e913b",
    "start_time": "2022-04-27T09:00:00-04:00"
  }'