---
title: "Book Appointment Slot"
method: POST
path: "/dr/v1/appointment"
tags: ["Appointment API"]
---

# Book Appointment Slot

`POST /dr/v1/appointment`

This API is used to book an appointment slot for a patient based on the available slots retrieved from the `get appointment slots` API.

## Headers

- `auth` string, required

## Request body

- union — The request body should contain either partner-specific fields or non-partner-specific fields for clinic and doctor identification.
  - object
    - `partner_appointment_id` string
    - `token` integer — A unique number given to each patient to indicate their position in the queue.
    - `appointment_details` object, required
      - `mode` 'INCLINIC' | 'PHONE' | 'VIDEO'
      - `start_time` integer, required — Start time of the appointment in epoch
      - `end_time` integer — End time of the appointment in epoch
      - `custom_attributes` object — `Custom attributes` and `value` for each custom attribute are a fixed set of enum defined by our partner at the time of onboarding. `Labels` and `Tags` are `special type` of custom attributes which exist by default for every partner and are visible in appointment queue. key-value pair within labels and tags can be defined by each repective partner. Position of other custom attributes in appointment queue need to configured by partner.
      - `video_connect` object — Configuration of video connect. To be used only when mode is `VIDEO`
        - `vendor` '100ms'
        - `url` string
    - `patient_details` union
      - object
        - `designation` 'Mr.' | 'Ms.' | 'Mrs.' | 'Miss.' | 'Kumar.' | 'Shri.' | 'Smt.' | 'Dr.' | 'Master.' | 'Baby.' | 'Mohd.' | 'B/O' — Title or designation of the patient
        - `first_name` string — First name of the patient
        - `partner_patient_id` string — Identifier for the partner’s patient.
        - `middle_name` string — Middle name of the patient (if any)
        - `last_name` string — Last name of the patient
        - `mobile` string — Mobile number of the patient, including country code
        - `gender` 'M' | 'F' | 'O' — Gender of the patient (e.g., 'M' for male, 'F' for female, 'O' for others)
        - `address` object — Address details of the patient
          - `city` string
          - `pincode` integer
        - `dob` string, date, required — Date of birth of the patient (YYYY-MM-DD)
      - object
        - `designation` 'Mr.' | 'Ms.' | 'Mrs.' | 'Miss.' | 'Kumar.' | 'Shri.' | 'Smt.' | 'Dr.' | 'Master.' | 'Baby.' | 'Mohd.' | 'B/O' — Title or designation of the patient
        - `first_name` string — First name of the patient
        - `partner_patient_id` string — Identifier for the partner’s patient.
        - `middle_name` string — Middle name of the patient (if any)
        - `last_name` string — Last name of the patient
        - `mobile` string — Mobile number of the patient, including country code
        - `gender` 'M' | 'F' | 'O' — Gender of the patient (e.g., 'M' for male, 'F' for female, 'O' for others)
        - `address` object — Address details of the patient
          - `city` string
          - `pincode` integer
        - `age` integer, required — Age in years
    - `partner_meta` object — This field is a set of `key-value pair` very specific to our partner and not visible in appointment queue. These key-value pairs are just stored at our end and echoed back in appointment related apis. We dont use it for any computation.
    - `display_meta` object — - This field is a set of `key-value pair`. - The value corresponding to a key must be string, int, or float. - Keys in `display_meta` must not exceed 30 characters. - The value for a key must not exceed 50 characters. - These key-value pairs will be shown on the appointment card. - For key names, it is recommended to use underscores (`_`) instead of spaces. During display, underscores will be replaced with spaces, and the following letter will be capitalized automatically. - Example: `"vendor_patient_id": "P41025551968206"` will be shown as `"Vendor Patient Id": "P41025551968206"`
    - `notes` string — - Optional field used to save notes attached to the created appointment. - It can be provided as a plain string or as HTML for better formatting, using tags such as `<p>`, `<li>`, and `<b>` (bold).
    - `partner_clinic_id` string, required — Identifier for the partner’s clinic. Please ensure the clinic is registered on the hub
    - `partner_doctor_id` string, required — Identifier for the partner’s doctor. Please ensure the doctor is registered on the hub
    - `partner_patient_id` string, required — Identifier for the partner’s patient. Please ensure the patient is registered beforehand using the "Add Patient" API.
  - object
    - `partner_appointment_id` string
    - `token` integer — A unique number given to each patient to indicate their position in the queue.
    - `appointment_details` object, required
      - `mode` 'INCLINIC' | 'PHONE' | 'VIDEO'
      - `start_time` integer, required — Start time of the appointment in epoch
      - `end_time` integer — End time of the appointment in epoch
      - `custom_attributes` object — `Custom attributes` and `value` for each custom attribute are a fixed set of enum defined by our partner at the time of onboarding. `Labels` and `Tags` are `special type` of custom attributes which exist by default for every partner and are visible in appointment queue. key-value pair within labels and tags can be defined by each repective partner. Position of other custom attributes in appointment queue need to configured by partner.
      - `video_connect` object — Configuration of video connect. To be used only when mode is `VIDEO`
        - `vendor` '100ms'
        - `url` string
    - `patient_details` union
      - object
        - `designation` 'Mr.' | 'Ms.' | 'Mrs.' | 'Miss.' | 'Kumar.' | 'Shri.' | 'Smt.' | 'Dr.' | 'Master.' | 'Baby.' | 'Mohd.' | 'B/O' — Title or designation of the patient
        - `first_name` string — First name of the patient
        - `partner_patient_id` string — Identifier for the partner’s patient.
        - `middle_name` string — Middle name of the patient (if any)
        - `last_name` string — Last name of the patient
        - `mobile` string — Mobile number of the patient, including country code
        - `gender` 'M' | 'F' | 'O' — Gender of the patient (e.g., 'M' for male, 'F' for female, 'O' for others)
        - `address` object — Address details of the patient
          - `city` string
          - `pincode` integer
        - `dob` string, date, required — Date of birth of the patient (YYYY-MM-DD)
      - object
        - `designation` 'Mr.' | 'Ms.' | 'Mrs.' | 'Miss.' | 'Kumar.' | 'Shri.' | 'Smt.' | 'Dr.' | 'Master.' | 'Baby.' | 'Mohd.' | 'B/O' — Title or designation of the patient
        - `first_name` string — First name of the patient
        - `partner_patient_id` string — Identifier for the partner’s patient.
        - `middle_name` string — Middle name of the patient (if any)
        - `last_name` string — Last name of the patient
        - `mobile` string — Mobile number of the patient, including country code
        - `gender` 'M' | 'F' | 'O' — Gender of the patient (e.g., 'M' for male, 'F' for female, 'O' for others)
        - `address` object — Address details of the patient
          - `city` string
          - `pincode` integer
        - `age` integer, required — Age in years
    - `partner_meta` object — This field is a set of `key-value pair` very specific to our partner and not visible in appointment queue. These key-value pairs are just stored at our end and echoed back in appointment related apis. We dont use it for any computation.
    - `display_meta` object — - This field is a set of `key-value pair`. - The value corresponding to a key must be string, int, or float. - Keys in `display_meta` must not exceed 30 characters. - The value for a key must not exceed 50 characters. - These key-value pairs will be shown on the appointment card. - For key names, it is recommended to use underscores (`_`) instead of spaces. During display, underscores will be replaced with spaces, and the following letter will be capitalized automatically. - Example: `"vendor_patient_id": "P41025551968206"` will be shown as `"Vendor Patient Id": "P41025551968206"`
    - `notes` string — - Optional field used to save notes attached to the created appointment. - It can be provided as a plain string or as HTML for better formatting, using tags such as `<p>`, `<li>`, and `<b>` (bold).
    - `clinic_id` string, required — Identifier for the clinic in Eka.
    - `doctor_id` string, required — Identifier for the doctor in Eka.
    - `patient_id` string, required — Identifier for the patient in Eka.

## Response `201`

OK

- object
  - `appointment_id` string

## Other responses

- `400` — Bad Request

---

[API](https://skmtc.net/eka/apis/eka-developer-apis.md) · [All operations](https://skmtc.net/eka/apis/eka-developer-apis/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/eka/eka-developer-apis/revisions/9ea23456f722/schema)
