Create patient
This endpoint creates a new patient or returns an existing patient if return_existing_if_match is true. Responds with 201 when a new patient is created, or with 200 and the existing patient when return_existing_if_match is true and a patient with matching information already exists.
Authorization
Authorization In: header
Query Parameters
Used to scope the request to the specified institution
Used to scope the request to the specified location
int32Header Parameters
The NexHealth API version
"v3.0.0"Request Body
application/json
Create patient
If true, return existing patient with matching information (200 OK) instead of raising an error. If false, raise an error when a patient with matching information already exists (400 Bad Request). Matching is based on date of birth and name.
falseResponse Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/patients?subdomain=string&location_id=0" \ -H "Nex-Api-Version: v3.0.0" \ -H "Content-Type: application/json" \ -d '{ "provider": { "provider_id": 12 }, "patient": { "first_name": "John", "last_name": "Smith", "email": "john.smith@example.com", "bio": { "date_of_birth": "1964-05-03", "phone_number": "5163042196" } } }'{ "code": false, "description": "Description", "error": [ "Error message" ], "data": { "user": { "id": 415, "email": "Amy.Ramos@nexhealth.com", "first_name": "John", "middle_name": "Anthony", "last_name": "Smith", "name": "John Smith", "created_at": "2020-06-05T20:16:57.007Z", "updated_at": "2020-06-05T20:16:57.007Z", "institution_id": 105, "foreign_id": "100437", "foreign_id_type": "--DataSource-", "bio": { "city": "New York", "state": "NY", "gender": "Female", "zip_code": "20814", "new_patient": false, "non_patient": true, "phone_number": "5163042196", "date_of_birth": "1964-05-03", "address_line_1": "", "address_line_2": "", "street_address": "", "cell_phone_number": "", "home_phone_number": "", "work_phone_number": "" }, "inactive": false, "last_sync_time": "2024-04-12T10:30:00Z", "guarantor_id": 472, "billing_type": "Standard Billing - finance charges", "chart_id": "017407", "preferred_language": "es", "preferred_locale": "es", "location_ids": [ 101, 102, 103 ] } }, "count": 2}