---
title: "Create appointment (beta)"
method: POST
path: "/appointments"
tags: ["Appointments"]
---

# Create appointment (beta)

`POST /appointments`

## Request

- Base URL: `https://nexhealth.info`
- URL: `https://nexhealth.info/appointments`
- Auth: API key in header `Authorization`

> 🚧 Beta
>
> Send `Nex-Api-Version: v3.1.0` to use this endpoint. It is still changing, and access is limited to approved partner institutions. Contact NexHealth before you build on it.

> **Changed from v3.0.0:** Removes query param `notify_patient`; adds request fields `appt.patient.bio.address_line_1`, `appt.patient.bio.address_line_2`, `appt.patient.bio.cell_phone_number`, `appt.patient.bio.city` (+6 more); and other schema changes.

This endpoint books an appointment for the given patient with the given provider at the specified location. When `is_guardian` is true, the booking is made by a guardian and a patient object with the dependent's details must be provided.

## Query parameters

- `subdomain` string, required
- `location_id` integer, required

## Headers

- `Nex-Api-Version` string, required

## Request body

- PostAppointments: Create appointment
  - `appointments_per_timeslot` integer
  - `appt` object, required: Appointment detail object
    - `patient_id` integer: ID of an existing patient. Omit and supply the `patient` object instead to create a new patient.
    - `provider_id` integer, required: Provider ID
    - `operatory_id` integer: Required if bookings are mapped to operatories for this location
    - `start_time` string, date-time, required: Appointment start time. Must be a parseable date/time string, recommended format is YYYY-MM-DDThh:mm:ss+0000
    - `end_time` string, date-time: Appointment end time. Must be a parseable date/time string. Recommended format is YYYY-MM-DDThh:mm:ss+0000.
    - `appointment_type_id` integer: The appointment type for this appointment
    - `note` string: A note that will be written to the EHR. 128 character limit.
    - `patient` object: Patient details. Supply this (without a patient_id) to create a new patient for the appointment.
      - `first_name` string, required: Patients first name
      - `last_name` string, required: Patients last name
      - `middle_name` string: Patient middle name
      - `email` string: Patient email
      - `bio` object, required: Patient Bio
        - `date_of_birth` string, date, required: Patient date of birth. Must be a parseable date string, recommended formats is YYYY-MM-DD
        - `gender` 'Male' | 'Female' | 'Other': Patient gender. Gender will be default to Female if not provided
        - `phone_number` string: Patient phone number
        - `cell_phone_number` string: Patient cell phone number
        - `home_phone_number` string: Patient home phone number
        - `address_line_1` string: Patient street address
        - `address_line_2` string: Patient street address line 2
        - `city` string: Patient city
        - `state` string: Patient state
        - `zip_code` string: Patient zip code
    - `descriptor_ids` integer[]: Associate descriptors with this appointment, which will also be synchronized on insertion

## Response `201`

Successful

- APIV31EntitiesAppointmentResponseResponse: API_V31_Entities_AppointmentResponse_Response model
  - `code` boolean: Indicates the success or failure of the request
  - `description` string: Additional context on the request to help with debugging.
  - `error` string[]: Any errors that occur during the execution of the request.
  - `data` APIV31EntitiesAppointmentResponse
    - `appt` APIV31EntitiesAppointmentWithoutIncludes
      - `id` integer: Appointment ID
      - `patient_id` integer: Appointment patient ID
      - `provider_id` integer: Provider ID
      - `provider_name` string: Provider name
      - `start_time` string, date-time: Appointment scheduled start time in UTC
      - `confirmed` boolean: Appointment confirmation status
      - `patient_missed` boolean: Did the patient no show? Not supported by all integrations
      - `created_at` string, date-time: Appointment created time in UTC
      - `updated_at` string, date-time: Appointment last updation time in UTC
      - `note` string: Appointment note
      - `end_time` string, date-time: Appointment scheduled end time in UTC
      - `unavailable` boolean: Is this appointment a scheduling block (blocks off the schedule)
      - `cancelled` boolean: Is this appointment cancelled?
      - `timezone` string: Appointment timezone
      - `institution_id` integer: Institution ID
      - `appointment_type_id` integer: Nexhealth appointment_type ID, 0 if not set
      - `checkin_at` string, date-time: Time the patient checked in at in UTC. Not supported by all integrations
      - `location_id` integer: Appointment location ID
      - `foreign_id` string: Identifier NexHealth uses to uniquely match this record to its counterpart in the integrated EHR. How it is derived differs between EHRs and may change; treat it as an opaque string and do not parse it.
      - `foreign_id_type` string: Unique identifier for the integrated system itself
      - `misc` object: Miscellaneous information for the appointment
      - `patient_confirmed` integer: Is this appointment confirmed by the patient (as opposed to the office)?
      - `created_by_user_id` integer: ID of the user who booked the appointment
      - `patient_confirmed_at` string, date-time: Time of patient_confirmation in UTC
      - `cancelled_at` string, date-time: Time of appointment cancellation in UTC. Note this will not be reset if the appointment is uncancelled
      - `confirmed_at` string, date-time: Time of appointment confirmation by the office in UTC
      - `sooner_if_possible` boolean: Does patient want an earlier time?
      - `operatory_id` integer: Operatory ID for the appointment
      - `checked_out` boolean: Has the patient checked out? Not supported by all integrations
      - `checked_out_at` string, date-time: Time of check out in UTC
      - `is_past_patient` boolean: Does this patient have prior appointments?
      - `timezone_offset` string: Timezone offset string
  - `count` integer: Number of total objects, in case of collection.

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found
- `500`: Internal Server Error

---

[API](https://skmtc.dev/nexhealth/apis/nexhealth-api-v3-1-0-beta.md) - [All operations](https://skmtc.dev/nexhealth/apis/nexhealth-api-v3-1-0-beta/llms.txt) - [OpenAPI document](https://skmtc.dev/nexhealth/apis/nexhealth-api-v3-1-0-beta/revisions/93cb4af790a5?raw)
