Skip to main content
PATCH
/
appointments
/
v1
/
{appointment_id}
/
reschedule
Reschedule Appointment
curl --request PATCH \
  --url https://api.eka.care/appointments/v1/{appointment_id}/reschedule \
  --header 'Content-Type: application/json' \
  --header 'auth: <auth>' \
  --data '
{
  "start_time": 1730189586,
  "end_time": 1730193186,
  "partner_appointment_id": "api-3f9c2b18-7e44-4a51-9"
}
'
{
  "appointment_id": "api-3f9c2b18-7e44-4a51-9c2d-1b6f0a8e5d23",
  "patient_id": "patient-oid-123",
  "doctor_id": "doctor-oid-456",
  "clinic_id": "clinic-789",
  "status": "BK",
  "mode": "IN_CLINIC",
  "start_time": 1730189586,
  "end_time": 1730193186,
  "created_at": 1730185000,
  "prev_aids": [
    "api-1a2b3c4d-5e6f-7a8b-9c0d-1e2f3a4b5c6d"
  ]
}

Headers

auth
string
required

Path Parameters

appointment_id
string
required

The id (aid) of the existing appointment to reschedule. When partner_appointment_id is supplied, this is treated as the partner appointment id.

Body

application/json
start_time
integer
required

New start time of the appointment as a Unix epoch in seconds.

Example:

1730189586

end_time
integer
required

New end time of the appointment as a Unix epoch in seconds. Must be after start_time.

Example:

1730193186

partner_appointment_id
string

Optional partner-provided appointment id. When omitted, the server generates the new appointment id and the appointment_id path param is used as-is. When supplied, the new id is derived with the help of this field and the appointment_id path param is treated as a partner appointment id.

Response

OK — the newly created (rescheduled) appointment.

appointment_id
string

Id of the newly created appointment.

patient_id
string
doctor_id
string | null
clinic_id
string
status
string
mode
string
start_time
integer

Start time as a Unix epoch in seconds.

end_time
integer

End time as a Unix epoch in seconds.

created_at
integer

Creation time as a Unix epoch in seconds.

prev_aids
string[]

Ids of the previous rescheduled appointment(s).

next_aid
string

Id of the next appointment this one was rescheduled to. Present only on previous appointments.