Get Biometrics Data
/biometrics
curl --request GET \
--url https://api.sandbox.metriport.com/biometrics \
--header 'x-api-key: <x-api-key>'
Query Params
The Metriport user ID to create a session token for.
Day for which to pull the data. Formatted YYYY-MM-DD
.
For simplicity, all queries assume the UTC timezone for the specified date
starting at 00:00 to 23:59 - unless otherwise specified by the timezoneId
parameter.
Timezone ID to use for the specified date. If not specified, the UTC timezone is used.
For example this can be valid timezones like America/Los_Angeles
or Europe/Kiev
.
Valid timezones can be found at https://en.wikipedia.org/wiki/List_of_tz_database_time_zones.
Support for this parameter is under development, and currently only supported for the Google Fit provider.
Response
An array of biometrics objects for each of the user’s connected providers
For simplicity, all queries assume the UTC timezone for the specified date starting at 00:00 to 23:59.
import { MetriportDevicesApi } from "@metriport/api-sdk";
const metriport = new MetriportDevicesApi("YOUR_API_KEY");
const response = await metriport.getBiometricsData(
"metriportUserId",
"date"
);
[
{
"metadata": {
"date": "2022-12-21",
"source": "oura"
},
"heart_rate": {
"avg_bpm": 70,
"max_bpm": 220,
"min_bpm": 45,
"resting_bpm": 45,
"samples_bpm": [
{
"time": "2022-12-13T06:15:40Z",
"value": 140
}
]
},
"hrv": {
"rmssd": {
"avg_millis": 540,
"samples_millis": [
{
"time": "2022-12-13T06:15:40Z",
"value": 140
}
]
},
"sdnn": {
"avg_millis": 340,
"samples_millis": [
{
"time": "2022-12-13T06:15:40Z",
"value": 140
}
]
}
},
"respiration": {
"avg_breaths_per_minute": 44,
"spo2": {
"avg_pct": 97,
"std_dev": 2,
"max_pct": 99,
"min_pct": 95
},
"vo2_max": 390,
"peak_flow_L_min": 464,
"forced_volume_L": 3.67
},
"perfusion_index_pct": 97,
"blood_glucose": {
"avg_mg_dL": 132,
"samples_mg_dL": [
{
"time": "2022-12-13T06:15:40Z",
"value": 123
}
]
},
"blood_pressure": {
"diastolic_mm_Hg": {
"samples": [
{
"time": "2022-12-13T06:15:40Z",
"value": 123
}
]
},
"systolic_mm_Hg": {
"samples": [
{
"time": "2022-12-13T06:15:40Z",
"value": 123
}
]
}
},
"temperature": {
"core": {
"samples_celcius": [
{
"time": "2022-12-13T06:15:40Z",
"value": 36
}
]
},
"delta_celcius": 23,
"skin": {
"samples_celcius": [
{
"time": "2022-12-13T06:15:40Z",
"value": 36
}
]
}
}
}
]
curl --request GET \
--url https://api.sandbox.metriport.com/biometrics \
--header 'x-api-key: <x-api-key>'
import { MetriportDevicesApi } from "@metriport/api-sdk";
const metriport = new MetriportDevicesApi("YOUR_API_KEY");
const response = await metriport.getBiometricsData(
"metriportUserId",
"date"
);