We developed Babbage, our AI-powered suite of health-tracking APIs for great platforms. Babbage is a powerful health assessment tool designed to analyze vital signs and provide valuable insights into an individual’s well-being. Whether you need a quick check of key health metrics or a detailed analysis, this API has you covered. With support for both file uploads and video URLs, users can conveniently integrate health analysis into their applications.
Comprehensive Vital Signs Analysis: Assess a wide range of vital signs, including heart rate, blood pressure, body temperature, body fat, readiness index, and VO2 max.
Flexible Input Options: Users can submit either an uploaded file or a video URL for analysis, allowing for diverse use cases and user preferences.
Intelligent Metric Calculation: The API intelligently calculates metrics based on the provided input, offering a holistic view of an individual’s health.
The Checkup API supports a variety of health metrics aimed at providing a comprehensive analysis of an individual’s well-being. Here’s an overview of the supported metrics and a brief explanation of how each is calculated:
To ensure accurate and reliable health metric analysis, users are advised to follow specific guidelines when providing input data, whether it be in the form of facial videos or full-body images.
POST /analysis
This endpoint analyzes vital signs based on the provided input, which can be either an uploaded file or a video URL. For uploaded files, the maximum size is 10MB
. For files larger than this, please use a video URL.
Parameter | Description | Values |
---|---|---|
file |
The uploaded file for analysis. (Optional, mutually exclusive with video_url ) |
- |
video_url |
The URL of the video for analysis. (Optional, mutually exclusive with file ) |
- |
filename |
The name of the file (if using file upload). | - |
Parameter | Description | Values | Example Value |
---|---|---|---|
metrics |
A string representing the metrics to be analyzed. Use “* ” for all available metrics. Options include: HR (Heart Rate), BP (Blood Pressure), RI (Readiness Index), VO2 (VO2-max), BT (Body Temperature), BF (Body Fat) |
HR , BP , RI , VO2 , BT , BF , * |
HR,BP |
sex |
Gender of the individual. (Optional, Accepted Values: male or female - case-insensitive) |
male , female |
male |
height |
Height of the individual in meters. (Optional) | numeric |
1.75 |
age |
Age of the individual. (Optional) | numeric |
30 |
readiness_history |
A JSON dump string representing a list of historical user readiness indices. Each item must contain mandatory fields. See below for more details. | JSON object |
See below |
readiness_history
The readiness_history
parameter is a critical component of the Checkup API, enabling users to incorporate a historical record of the user’s readiness indices for a more thorough health analysis. Users are required to store this history for use in subsequent API calls. Each item in the readiness_history
list is presented as a dictionary with the following key-value pairs:
type
: Type of assessment, always set to 'readiness'
.artefact
: Artefact value from the assessment.artefact_level
: Artefact level from the assessment.create_timestamp
: Timestamp of the assessment creation.mean_hr_bpm
: Mean heart rate in beats per minute.mean_rr_ms
: Mean RR interval in milliseconds.pns_index
: PNS (Parasympathetic Nervous System) index.readiness
: Readiness index.rmssd_ms
: RMSSD (Root Mean Square of Successive Differences) in milliseconds.sd1_ms
: SD1 (Standard Deviation 1) in milliseconds.sd2_ms
: SD2 (Standard Deviation 2) in milliseconds.sdnn_ms
: SDNN (Standard Deviation of NN intervals) in milliseconds.sns_index
: SNS (Sympathetic Nervous System) index.stress_index
: Stress index.The readiness_history
parameter provides valuable context by incorporating past assessments into the current health analysis, contributing to a more nuanced understanding of an individual’s well-being.
# Example readiness history item
{
"type": "readiness",
"artefact": 0.0,
"artefact_level": "GOOD",
"create_timestamp": "2023-12-06T02:41:50.725535+00:00",
"mean_hr_bpm": 83.52910467240929,
"mean_rr_ms": 718.3125,
"pns_index": 3.2919038482055702,
"readiness": 62.5,
"respiratory_rate": null,
"rmssd_ms": 193.74641380131075,
"sd1_ms": 141.81213214984373,
"sd2_ms": 185.3059222762331,
"sdnn_ms": 162.37692855992265,
"sns_index": 0.4832850685037345,
"stress_index": 5.998611734126247
}
Status Code | Response Body | Example Value | Description |
---|---|---|---|
200 OK |
data : The analyzed results. |
See Example JSON Below | |
400 Bad Request |
message : Error message |
“Invalid request. Missing required parameter ‘metrics’.” | |
500 Internal Server Error |
message : Error message |
“Internal Server Error. Please try again later.” |
{
"status_code": 200,
"data": {
"body_temperature": 36.7,
"heart_rate": 83.52910467240929,
"systolic_blood_pressure": 118.33201599121094,
"diastolic_blood_pressure": 83.448081970214844,
"readiness_index": 62.5,
"readiness_detail": {
"artefact": 0.0,
"artefact_level": "GOOD",
"create_timestamp": "2023-12-06T02:41:50.725535+00:00",
"mean_hr_bpm": 83.52910467240929,
"mean_rr_ms": 718.3125,
"pns_index": 3.2919038482055702,
"readiness": 62.5,
"respiratory_rate": null,
"rmssd_ms": 193.74641380131075,
"sd1_ms": 141.81213214984373,
"sd2_ms": 185.3059222762331,
"sdnn_ms": 162.37692855992265,
"sns_index": 0.4832850685037345,
"stress_index": 5.998611734126247
},
"vo2_max": 49.30697233098408
}
}
Ensuring a minimum video duration of 5 to 10 seconds to capture an adequate sample of cardiac activity.
# Video url
curl -X POST -F "video_url=https://example.com/video.mp4" -F "filename=video.mp4" -F "metrics=HR" https://checkup-api.p.rapidapi.com/analysis
# Uploaded file
curl -X POST -F "@file=/path/to/your/local/file.mp4" -F "metrics=HR" https://checkup-api.p.rapidapi.com/analysis
# Response
{"status_code": 200, "data": {"heart_rate": 76}}
Notes:
https://example.com/video.mp4
with the actual URL of the video containing facial data./path/to/your/local/file.mp4
with the actual local video file if you use uploaded file as input.-F "metrics=HR"
specifies that the API should predict heart rate.Ensuring a minimum video duration of 5 to 10 seconds to capture an adequate sample of cardiac activity.
# Video url
curl -X POST -F "video_url=https://example.com/video.mp4" \
-F "filename=video.mp4" \
-F "metrics=BP" \
https://checkup-api.p.rapidapi.com/analysis
# Uploaded file
curl -X POST -F "@file=/path/to/your/local/file.mp4" \
-F "metrics=BP" \
https://checkup-api.p.rapidapi.com/analysis
# Response
{"status_code": 200, "data": {"systolic_blood_pressure": 118.33201599121094,"diastolic_blood_pressure": 83.448081970214844}}
Notes:
https://example.com/video.mp4
with the actual URL of the video./path/to/your/local/file.mp4
with the actual local video file if you use uploaded file as input.-F "metrics=BP"
indicates that the API should predict blood pressure.A minimum video duration of 30 seconds is recommended to ensure a comprehensive assessment.
# Video url
curl -X POST -F "video_url=https://example.com/video.mp4" \
-F "filename=video.mp4" \
-F "metrics=RI" \
-F 'readiness_history=[
{
"type": "readiness",
"artefact": 0.0,
"artefact_level": "GOOD",
"create_timestamp": "2023-12-06T02:41:50.725535+00:00",
"mean_hr_bpm": 83.52910467240929,
"mean_rr_ms": 718.3125,
"pns_index": 3.2919038482055702,
"readiness": 62.5,
"respiratory_rate": null,
"rmssd_ms": 193.74641380131075,
"sd1_ms": 141.81213214984373,
"sd2_ms": 185.3059222762331,
"sdnn_ms": 162.37692855992265,
"sns_index": 0.4832850685037345,
"stress_index": 5.998611734126247
},
...
]' \
https://checkup-api.p.rapidapi.com/analysis
# Uploaded file
curl -X POST -F "@file=/path/to/your/local/file.mp4" \
-F "metrics=RI" \
-F 'readiness_history=[]' \
https://checkup-api.p.rapidapi.com/analysis
# Response
{
"status_code": 200,
"data": {
"readiness_index": 62.5,
"readiness_detail": {
"artefact": 0.0,
"artefact_level": "GOOD",
"create_timestamp": "2023-12-06T02:41:50.725535+00:00",
"mean_hr_bpm": 83.52910467240929,
"mean_rr_ms": 718.3125,
"pns_index": 3.2919038482055702,
"readiness": 62.5,
"respiratory_rate": null,
"rmssd_ms": 193.74641380131075,
"sd1_ms": 141.81213214984373,
"sd2_ms": 185.3059222762331,
"sdnn_ms": 162.37692855992265,
"sns_index": 0.4832850685037345,
"stress_index": 5.998611734126247
}
}
}
Notes:
https://example.com/video.mp4
with the actual URL of the video./path/to/your/local/file.mp4
with the actual local video file if you use uploaded file as input.-F "metrics=RI"
specifies that the API should predict the readiness index.# Video url
curl -X POST -F "video_url=https://example.com/video.mp4" \
-F "filename=video.mp4" \
-F "metrics=BT" \
https://checkup-api.p.rapidapi.com/analysis
# Uploaded file
curl -X POST -F "@file=/path/to/your/local/file.mp4" \
-F "metrics=BT" \
https://checkup-api.p.rapidapi.com/analysis
# Response
{"status_code": 200, "data": {"body_temperature": 37.0"}}
Notes:
https://example.com/video.mp4
with the actual URL of the video./path/to/your/local/file.mp4
with the actual local video file if you use uploaded file as input.-F "metrics=BT"
specifies that the API should predict the body temperature.You will have to provide user’s sex and age to the API.
# Video url
curl -X POST -F "video_url=https://example.com/video.mp4" \
-F "filename=video.mp4" \
-F "metrics=VO2" \
-F "sex=male" \
-F "age=28" \
https://checkup-api.p.rapidapi.com/analysis
# Uploaded file
curl -X POST -F "@file=/path/to/your/local/file.mp4" \
-F "metrics=VO2" \
-F "sex=male" \
-F "age=28" \
https://checkup-api.p.rapidapi.com/analysis
# Response
{"status_code": 200, "data": {"vo2_max": 40.1"}}
Notes:
https://example.com/video.mp4
with the actual URL of the video./path/to/your/local/file.mp4
with the actual local video file if you use uploaded file as input.-F "metrics=VO2"
indicates that the API should predict VO2-max.# Video url
curl -X POST -F "video_url=https://example.com/video.mp4" \
-F "filename=video.mp4" \
-F "metrics=BF" \
-F "sex=male" \
-F "age=28" \
-F "height=1.8" \
https://checkup-api.p.rapidapi.com/analysis
# Uploaded file
curl -X POST -F "@file=/path/to/your/local/file.mp4" \
-F "metrics=BF" \
-F "sex=male" \
-F "age=28" \
-F "height=1.8" \
https://checkup-api.p.rapidapi.com/analysis
# Response
{"status_code": 200, "data": {"body_fat": 10.2"}}
Notes:
https://example.com/body.jpg
with the actual URL of the image./path/to/your/local/file.mp4
with the actual local video file if you use uploaded file as input.-F "metrics=BF"
indicates that the API should predict body fat.