curl --request GET \
--url https://api.sandbox.metriport.com/medical/v1/cohort/{id}/patient \
--header 'x-api-key: <api-key>'import { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const cohortId = "00000000-0000-0000-0000-000000000000";
const cohortPatients = await metriport.listPatientsInCohort(cohortId);
Returns a paginated list of all patients that are members of the specified cohort.
curl --request GET \
--url https://api.sandbox.metriport.com/medical/v1/cohort/{id}/patient \
--header 'x-api-key: <api-key>'import { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const cohortId = "00000000-0000-0000-0000-000000000000";
const cohortPatients = await metriport.listPatientsInCohort(cohortId);
Show Patient properties
Show AdditionalIdentifiers properties
YYYY-MM-DD as per ISO 8601.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.Show Pagination properties
import { MetriportMedicalApi } from "@metriport/api-sdk";
const metriport = new MetriportMedicalApi("YOUR_API_KEY");
const cohortId = "00000000-0000-0000-0000-000000000000";
const cohortPatients = await metriport.listPatientsInCohort(cohortId);
{
"patients": [
{
"id": "11111111-1111-1111-1111-111111111111",
"eTag": "1",
"firstName": "John",
"lastName": "Doe",
"dob": "1990-01-01",
"genderAtBirth": "M",
"address": [
{
"addressLine1": "123 Fake Street",
"city": "Fake City",
"state": "NY",
"zip": "12345",
"country": "USA"
}
],
"personalIdentifiers": [
{
"type": "drivers_license",
"value": "FAKE123456789",
"state": "NY"
}
],
"facilityIds": ["22222222-2222-2222-2222-222222222222"]
},
{
"id": "33333333-3333-3333-3333-333333333333",
"eTag": "1",
"firstName": "Jane",
"lastName": "Smith",
"dob": "1985-05-15",
"genderAtBirth": "F",
"address": [
{
"addressLine1": "456 Example Avenue",
"city": "Sample Town",
"state": "CA",
"zip": "54321",
"country": "USA"
}
],
"personalIdentifiers": [
{
"type": "drivers_license",
"value": "FAKE987654321",
"state": "CA"
}
],
"facilityIds": ["44444444-4444-4444-4444-444444444444"]
}
],
"meta": {
"itemsOnPage": 2,
"itemsInTotal": 2
}
}