List Patients
curl --request GET \
--url https://api.sandbox.metriport.com/medical/v1/patient \
--header 'x-api-key: <api-key>'import requests
url = "https://api.sandbox.metriport.com/medical/v1/patient"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.sandbox.metriport.com/medical/v1/patient', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.metriport.com/medical/v1/patient",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.metriport.com/medical/v1/patient"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.sandbox.metriport.com/medical/v1/patient")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.metriport.com/medical/v1/patient")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_bodyimport { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const facilityId = "018a80c4-292a-7486-a1234-9uiu76yhe234";
const filters = "john doe";
const { patients } = await metriport.listPatients(facilityId, filters);
Patient
List Patients
Lists all Patients receiving care.
GET
/
medical
/
v1
/
patient
List Patients
curl --request GET \
--url https://api.sandbox.metriport.com/medical/v1/patient \
--header 'x-api-key: <api-key>'import requests
url = "https://api.sandbox.metriport.com/medical/v1/patient"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.sandbox.metriport.com/medical/v1/patient', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sandbox.metriport.com/medical/v1/patient",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.sandbox.metriport.com/medical/v1/patient"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.sandbox.metriport.com/medical/v1/patient")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sandbox.metriport.com/medical/v1/patient")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_bodyimport { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const facilityId = "018a80c4-292a-7486-a1234-9uiu76yhe234";
const filters = "john doe";
const { patients } = await metriport.listPatients(facilityId, filters);
This is a paginated endpoint. For more information see pagination.
Query Params
The ID of the Facility where the patient is receiving care, optional. If not provided, Patients
from all Facilities will be returned.
How to filter patients. It uses Metriport’s filter/search criteria
based on the main properties of a Patient: first name, last name, date of birth, ID, external ID,
facility ID, facility name, and additional identifiers.One can combine fields as needed, for example:
john or doewill return all patients with the first and/or last name equal tojohnordoe.john -doewill return all patients with the first and/or last name equal tojohnbut without anydoeeither on first or last names.john 2000will return all patients with the first and/or last name equal tojohnand born in the year2000.2000-02-03will return all patients born on2020-02-03.ABCD1234will return all patients with that external ID.
YYYY-MM-DD), but partial values are accepted (YYYY,
YYYY-MM)Response
All Patients receiving care at the specified Facility, or all Patients if no Facility is specified.Show Patient properties
Show Patient properties
The ID assigned to this Patient. This ID will be used to uniquely identify this Patient in medical
documents.
The ID of the Patient on your internal system to associate to a Patient in Metriport.
A map containing additional external identifiers. If the patient is created or mapped in Metriport through one of
our EHR apps - this property will be populated with the ID from the EHR, and included
within the webhook payloads.
Show AdditionalIdentifiers properties
Show AdditionalIdentifiers properties
Athena patient ID. If more than one patient in Athena maps to a Metriport patient, they
will all be included.
Canvas patient ID. If more than one patient in Canvas maps to a Metriport patient, they
will all be included.
Elation Patient ID. If more than one patient in Elation maps to a Metriport patient, they
will all be included.
The Patient's first name(s).
The Patient's last name(s).
The Patient's date of birth (DOB), formatted
YYYY-MM-DD as per ISO 8601.The Patient's gender at birth, can be one of
M or F or O or U. Use O (other) when the patient's gender is known but it is not M or F, i.e intersex or hermaphroditic.
Use U (unknown) when the patient's gender is not known.An array of the Patient's personal IDs, such as a driver's license. May be empty.
Array of the IDs of the Facilities where the Patient is receiving care.
import { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const facilityId = "018a80c4-292a-7486-a1234-9uiu76yhe234";
const filters = "john doe";
const { patients } = await metriport.listPatients(facilityId, filters);
{
"meta": {
"itemsOnPage": 2
},
"patients": [
{
"id": "018a80c4-292a-7486-a1234-76yuhe23yu14",
"externalId": "123456789",
"additionalIds": {
"athenahealth": ["43210"],
"canvas": ["1234567890"],
"elation": ["0987654321"]
},
"facilityIds": ["018a80c4-292a-7486-a1234-9uiu76yhe234"],
"firstName": "Jose",
"lastName": "Juarez",
"dob": "1951-05-05",
"genderAtBirth": "M",
"personalIdentifiers": [
{
"type": "driversLicense",
"state": "CA",
"value": "51227265"
}
],
"address": [
{
"zip": "12345",
"city": "San Diego",
"state": "CA",
"country": "USA",
"addressLine1": "Guadalajara St",
}
],
"contact": [
{
"phone": "1234567899",
"email": "jose@domain.com"
}
],
},
{
"id": "018a80c4-292a-7486-a1234-5ert32uij123",
"externalId": "123456777",
"facilityIds": ["018a80c4-292a-7486-a1234-9uiu76yhe234"],
"firstName": "Josita",
"lastName": "Juarez,Diaz",
"dob": "1949-06-09",
"genderAtBirth": "F",
"address": [
{
"zip": "12345",
"city": "San Diego",
"state": "CA",
"country": "USA",
"addressLine1": "Guadalajara St"
}
]
}
]
}
⌘I

