Appointments

View appointments

GET
/appointments

This endpoint returns the appointments starting within the requested time window, narrowed down by the optional filters configured. At least one of location_id or foreign_id must be provided.

Authorization

Authorization
Authorization<token>

In: header

Query Parameters

subdomain*string

Used to scope the request to the specified institution

location_id?integer

Used to scope the request to the specified location

Formatint32
sort?string

Optional comma-separated string of fields to sort on. Include a leading dash for descending order.

Available fields:

  • updated_at
  • -updated_at
start*string

A parseable date string defining the earliest returned records. Recommended format is YYYY-MM-DDThh:mm:ss+0000

Formatdate-time
end*string

A parseable date string defining the last returned records. Recommended format is YYYY-MM-DDThh:mm:ss+0000

Formatdate-time
timezone?string

IANA time zone name, such as America/New_York. Validated only: start and end are absolute instants, so it does not change which appointments are returned

cancelled?boolean

Filter by cancelled status.

unavailable?boolean

true returns only scheduling blocks (unavailable appointments that block time on the schedule), false only real appointments

nex_only?boolean

true returns only appointments booked through NexHealth

updated_since?string

Query appointments whose records have updated since the specified datetime in ISO8601 format. Must be a parseable date/time, recommended formats are YYYY-MM-DD or YYYY-MM-DDT00:00:00+0000

Formatdate-time
appointment_type_id?integer

Get appointments for a specific appointment type

Formatint32
foreign_id?string

Unique appointment ID from the EHR

created_by?integer

Query appointments that were created by a specific user

Formatint32
start_cursor?string

First item of the current page. Starts empty

end_cursor?string

Last item of the current page. Starts empty

per_page?integer

Number of results to return per page. Maximum allowed amount is 1000.

Formatint32
Default5
patient_ids[]?array<>

Get appointments for specific patients (up to 25 IDs)

provider_ids[]?array<>

Query appointments that are booked with the specified providers only

operatory_ids[]?array<>

Query appointments that are booked in the specified operatories only

Header Parameters

Nex-Api-Version*string

The NexHealth API version

Default"v3.0.0"

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/appointments?subdomain=string&location_id=1&start=2024-04-01T00%3A00%3A00Z&end=2024-04-30T23%3A59%3A59Z&timezone=America%2FNew_York&cancelled=false&unavailable=false&nex_only=false&updated_since=2024-04-12T10%3A30%3A00Z&appointment_type_id=27&foreign_id=94&created_by=197&patient_ids%5B%5D=2897&provider_ids%5B%5D=104&operatory_ids%5B%5D=181" \  -H "Nex-Api-Version: v3.0.0"
{  "code": false,  "description": "Description",  "error": [    "Error message"  ],  "data": [    {      "id": 1822,      "patient_id": 2897,      "provider_id": 104,      "provider_name": "Dr. John Smith",      "start_time": "2020-06-05T20:16:57.007Z",      "confirmed": true,      "patient_missed": false,      "created_at": "2020-06-05T20:16:57.007Z",      "updated_at": "2020-06-05T20:16:57.007Z",      "note": "Patient has been having a cough for 3 days",      "end_time": "2020-06-05T20:16:57.007Z",      "unavailable": false,      "cancelled": false,      "timezone": "America/New_York",      "institution_id": 1,      "appointment_type_id": 27,      "checkin_at": "2020-06-05T20:16:57.007Z",      "location_id": 1,      "foreign_id": "94",      "foreign_id_type": "msg-dentrix-DataSource-100",      "misc": {        "is_booked_on_nexhealth": true      },      "last_sync_time": "2020-06-05T20:16:57.007Z",      "patient_confirmed": false,      "created_by_user_id": 197,      "is_guardian": false,      "patient_confirmed_at": "2020-06-05T20:16:57.007Z",      "cancelled_at": "2020-06-05T20:16:57.007Z",      "is_new_clients_patient": false,      "confirmed_at": "2020-06-05T20:16:57.007Z",      "sooner_if_possible": false,      "operatory_id": 181,      "checked_out": false,      "checked_out_at": "2020-06-05T20:16:57.007Z",      "referrer": "http://mypractice.com/book",      "is_past_patient": true,      "timezone_offset": "-4:00"    }  ],  "page_info": {    "has_previous_page": false,    "has_next_page": false,    "start_cursor": "AAAAA",    "end_cursor": "BBBBBB"  }}