Create a patient
Body
Object containing the patient details
-
patientNumber null | string
The identifier used by the hospital staff to correlate patients with their data.
Minimum length is
1
. -
age integer | null
The number of years that have passed since the patient's date of birth.
Minimum value is
0
. -
name string | null
All the name parts, i.e. first name, middle name, and last name.
Minimum length is
1
. -
gender null | string
Values are
MALE
,FEMALE
, orOTHER
. -
patientCategory string | null
Values are
GENERAL
,INPATIENT
, orOUTPATIENT
. -
phoneNumber string | null
Patient phone number
Minimum length is
1
. -
residentialAddress string | null
Patient residential address
Minimum length is
1
.
POST /patients
curl \
-X POST https://example.com/api/patients \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name":"John Doe","gender":"MALE","patientCategory":"GENERAL","phoneNumber":"01234567890","residentialAddress":"Guesthouse"}'
Request examples
Complete registration
{
"name": "John Doe",
"gender": "MALE",
"patientCategory": "GENERAL",
"phoneNumber": "01234567890",
"residentialAddress": "Guesthouse"
}
{
"summary": "Empty details",
"value": {}
}
Request examples
{
"patientNumber": "23-72362",
"age": 23,
"name": "John Doe",
"gender": "MALE",
"patientCategory": "GENERAL",
"phoneNumber": "+1234567890",
"residentialAddress": "Guesthouse"
}
Response examples (200)
{
"_id": "string",
"patientNumber": "23-72362",
"age": 23,
"name": "John Doe",
"gender": "MALE",
"patientCategory": "GENERAL",
"phoneNumber": "+1234567890",
"residentialAddress": "Guesthouse"
}
Response examples (200)
{
"_id": "string",
"patientNumber": "23-72362",
"age": 23,
"name": "John Doe",
"gender": "MALE",
"patientCategory": "GENERAL",
"phoneNumber": "+1234567890",
"residentialAddress": "Guesthouse"
}