Skip to main content

ROOK (2.0.1)

Download OpenAPI specification:Download

Intro

ROOK is a set of services that simplifies the collection, processing, and delivering of Users' HealthData from various data sources.

Testing

You can use the following constants to test the API and receive default responses:

  • client_uuid = Your "client_uuid" for testing you can use: 'demoClientUUID'
  • client secret = Your "client secret" for testing you can use: 'demoClientSecret'
  • user_id = Your "user_id" for testing you can use: 'demoUserId'
  • date = Your "date" for testing you can use: '2022-10-28'

ROOK > Connect > User

[User][Data Sources][Authorizers]

Retrieves the array of authorizers corresponding to the data sources enabled for each client. Includes the data source's description, its logo, the authorization URL personalized for each user_id, and the user's current authorization status.

Authorizations:
basicAuth
path Parameters
client_uuid
required
string <uuid> (schema_client_uuid)
Example: demoClientUUID

A unique identifier for each client, in UUID4 format. Provided by ROOK upon signing service agreements.

user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

query Parameters
redirect_url
string <uri> [ 1 .. 50 ] characters ^https://.+
Example: redirect_url=https://example.com

(Optional): Designates a custom URL to which the user is redirected after a successful authentication or linking process. In its absence, the redirection will be to ROOK's connections page (or the default configured) to continue the post-authentication flow.

Responses

Response samples

Content type
application/json
{}

[User][Data Sources][Authorized]

Provides a list of authorized data sources for the specified user.

IMPORTANT NOTE: Google Fit will be removed from the Authorized endpoint on November 4, 2024. Please do not use it in your implementation, as Google is deprecating Google Fit. For more information, visit Google Fit deprecation notice.

Authorizations:
basicAuth
path Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

Responses

Response samples

Content type
application/json
{
  • "user_id": "demoUserId",
  • "sources": {
    }
}

[User][Information]

Fetches user information for the given user ID and date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "metadata": {
    },
  • "data_structure": "user_info",
  • "user_information": {
    }
}

[User][Information]

User information receives and processes user information from users

Authorizations:
basicAuth
Request Body schema: application/json

body

datetime
string <date-time> (datetime_iso8601)

Date and time in ISO 8601 format (YYYY-MM-DDTHH:MM:SS.sssZ).

user_id
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
date_of_birth_string
string <date>
height_cm_int
integer
weight_kg_float
number <float>
bmi_float
number <float>
sex_string
string

Responses

Request samples

Content type
application/json
{
  • "datetime": "2023-12-29T21:07:14.402999Z",
  • "user_id": "demoUserId",
  • "date_of_birth_string": "2024-04-21",
  • "height_cm_int": 0,
  • "weight_kg_float": 0,
  • "bmi_float": 0,
  • "sex_string": "male"
}

Response samples

Content type
application/json
{
  • "message": "added"
}

[User][Data Sources][Revoke]

Revokes user authorization for the specified data source.

Authorizations:
basicAuth
path Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

Request Body schema: application/json

body

data_source
string

Must be one of Garmin, Oura, Apple Health, Health Connect, Android, Polar, Fitbit, Withings, Whoop.

Responses

Request samples

Content type
application/json
{
  • "data_source": "Polar"
}

Response samples

Content type
application/json
{
  • "message": "Authorization for the specified user data source has been successfully revoked"
}

ROOK > Connect > Webhooks

[Client][Webhooks][Resend Notification]

Endpoint to resend rejected notifications

Authorizations:
basicAuth
Request Body schema: application/json

body

start
string <date>
finish
string <date>

Responses

Request samples

Content type
application/json
{
  • "start": "2024-04-20",
  • "finish": "2024-04-21"
}

Response samples

Content type
application/json
{
  • "message": "Success",
  • "total_docs_to_resend": 29
}

ROOK > Connect > Physical Health

[Physical][Summary]

Fetches a summary of the user's physical health data for a specified date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "data_structure": "physical_summary",
  • "physical_health": {
    }
}

[Physical][Events][Activity]

Retrieves activity event data for the specified user over a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "activity_event",
  • "physical_health": {
    }
}

[Physical][Events][Heart Rate]

Fetches heart rate event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "heart_rate_event",
  • "physical_health": {
    }
}

[Physical][Events][Oxygenation]

Retrieves oxygenation event data for a specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "oxygenation_event",
  • "physical_health": {
    }
}

[Physical][Events][Stress]

Retrieves stress event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "stress_event",
  • "physical_health": {
    }
}

ROOK > Connect > Sleep Health

[Sleep][Summary]

Retrieves a summary of the user's sleep health data for a specified date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "data_structure": "sleep_summary",
  • "sleep_health": {
    }
}

ROOK > Connect > Body Health

[Body][Summary]

Retrieves a summary of the user's body health data for a specified date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "data_structure": "body_summary",
  • "body_health": {
    }
}

[Body][Events][Body Metrics]

Retrieves body metrics event data for a specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "body_metrics_event",
  • "body_health": {
    }
}

[Body][Events][Heart Rate]

Retrieves heart rate event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "heart_rate_event",
  • "body_health": {
    }
}

[Body][Events][Oxygenation]

Retrieves oxygenation event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "oxygenation_event",
  • "body_health": {
    }
}

[Body][Events][Nutrition]

Retrieves nutrition event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "nutrition_event",
  • "body_health": {
    }
}

[Body][Events][Mood]

Retrieves mood event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "mood_event",
  • "body_health": {
    }
}

[Body][Events][Hydration]

Retrieves hydration event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "hydration_event",
  • "body_health": {
    }
}

[Body][Events][Blood Glucose]

Retrieves blood glucose event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "blood_glucose_event",
  • "body_health": {
    }
}

[Body][Events][Blood Pressure]

Retrieves blood pressure event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "blood_pressure_event",
  • "body_health": {
    }
}

[Body][Events][Temperature]

Retrieves body temperature event data for the specified user on a given date.

Authorizations:
basicAuth
query Parameters
user_id
required
string (schema_user_id) ^[a-zA-Z0-9\-]{1,50}$
Example: user_id=demoUserId

Unique identifier for the user. Can include numerals, UUID4, strings, or other identifiers. Length must be between 1 to 50 characters.

date
required
string <date>
Example: date=2023-01-01

Date in YYYY-MM-DD format.

Responses

Response samples

Content type
application/json
{
  • "client_uuid": "demoClientUUID",
  • "user_id": "demoUserId",
  • "version": 2,
  • "document_version": 1,
  • "auto_detected": false,
  • "data_structure": "temperature_event",
  • "body_health": {
    }
}