{
"basePath": "",
"baseUrl": "https://health.googleapis.com/",
"batchPath": "batch",
"canonicalName": "Google Health API",
"description": "The Google Health API lets you view and manage health and fitness metrics and measurement data.",
"discoveryVersion": "v1",
"documentationLink": "https://developers.google.com/health",
"fullyEncodeReservedExpansion": true,
"icons": {
"x16": "http://www.google.com/images/icons/product/search-16.gif",
"x32": "http://www.google.com/images/icons/product/search-32.gif"
},
"id": "health:v4",
"kind": "discovery#restDescription",
"mtlsRootUrl": "https://health.mtls.googleapis.com/",
"name": "health",
"ownerDomain": "google.com",
"ownerName": "Google",
"parameters": {
"$.xgafv": {
"description": "V1 error format.",
"enum": [
"1",
"2"
],
"enumDescriptions": [
"v1 error format",
"v2 error format"
],
"location": "query",
"type": "string"
},
"access_token": {
"description": "OAuth access token.",
"location": "query",
"type": "string"
},
"alt": {
"default": "json",
"description": "Data format for response.",
"enum": [
"json",
"media",
"proto"
],
"enumDescriptions": [
"Responses with Content-Type of application/json",
"Media download with context-dependent Content-Type",
"Responses with Content-Type of application/x-protobuf"
],
"location": "query",
"type": "string"
},
"callback": {
"description": "JSONP",
"location": "query",
"type": "string"
},
"fields": {
"description": "Selector specifying which fields to include in a partial response.",
"location": "query",
"type": "string"
},
"key": {
"description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.",
"location": "query",
"type": "string"
},
"oauth_token": {
"description": "OAuth 2.0 token for the current user.",
"location": "query",
"type": "string"
},
"prettyPrint": {
"default": "true",
"description": "Returns response with indentations and line breaks.",
"location": "query",
"type": "boolean"
},
"quotaUser": {
"description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.",
"location": "query",
"type": "string"
},
"uploadType": {
"description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\").",
"location": "query",
"type": "string"
},
"upload_protocol": {
"description": "Upload protocol for media (e.g. \"raw\", \"multipart\").",
"location": "query",
"type": "string"
}
},
"protocol": "rest",
"resources": {
"users": {
"methods": {
"getIdentity": {
"description": "Gets the user's identity. It includes the legacy Fitbit user ID and the Google user ID and it can be used by migrating clients to map identifiers between the two systems.",
"flatPath": "v4/users/{usersId}/identity",
"httpMethod": "GET",
"id": "health.users.getIdentity",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "Required. The resource name of the Identity. Format: `users/me/identity`",
"location": "path",
"pattern": "^users/[^/]+/identity$",
"required": true,
"type": "string"
}
},
"path": "v4/{+name}",
"response": {
"$ref": "Identity"
}
},
"getProfile": {
"description": "Returns user Profile details.",
"flatPath": "v4/users/{usersId}/profile",
"httpMethod": "GET",
"id": "health.users.getProfile",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "Required. The name of the Profile. Format: `users/me/profile`.",
"location": "path",
"pattern": "^users/[^/]+/profile$",
"required": true,
"type": "string"
}
},
"path": "v4/{+name}",
"response": {
"$ref": "Profile"
}
},
"getSettings": {
"description": "Returns user settings details.",
"flatPath": "v4/users/{usersId}/settings",
"httpMethod": "GET",
"id": "health.users.getSettings",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "Required. The name of the Settings. Format: `users/me/settings`.",
"location": "path",
"pattern": "^users/[^/]+/settings$",
"required": true,
"type": "string"
}
},
"path": "v4/{+name}",
"response": {
"$ref": "Settings"
}
},
"updateProfile": {
"description": "Updates the user's profile details.",
"flatPath": "v4/users/{usersId}/profile",
"httpMethod": "PATCH",
"id": "health.users.updateProfile",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "Identifier. The resource name of this Profile resource. Format: `users/{user}/profile` Example: `users/1234567890/profile` or `users/me/profile` The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal `me` can also be used to refer to the authenticated user.",
"location": "path",
"pattern": "^users/[^/]+/profile$",
"required": true,
"type": "string"
},
"updateMask": {
"description": "Optional. The list of fields to be updated.",
"format": "google-fieldmask",
"location": "query",
"type": "string"
}
},
"path": "v4/{+name}",
"request": {
"$ref": "Profile"
},
"response": {
"$ref": "Profile"
}
},
"updateSettings": {
"description": "Updates the user's settings details.",
"flatPath": "v4/users/{usersId}/settings",
"httpMethod": "PATCH",
"id": "health.users.updateSettings",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "Identifier. The resource name of this Settings resource. Format: `users/{user}/settings` Example: `users/1234567890/settings` or `users/me/settings` The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal `me` can also be used to refer to the authenticated user.",
"location": "path",
"pattern": "^users/[^/]+/settings$",
"required": true,
"type": "string"
},
"updateMask": {
"description": "Optional. The list of fields to be updated.",
"format": "google-fieldmask",
"location": "query",
"type": "string"
}
},
"path": "v4/{+name}",
"request": {
"$ref": "Settings"
},
"response": {
"$ref": "Settings"
}
}
},
"resources": {
"dataTypes": {
"resources": {
"dataPoints": {
"methods": {
"batchDelete": {
"description": "Delete a batch of identifyable data points.",
"flatPath": "v4/users/{usersId}/dataTypes/{dataTypesId}/dataPoints:batchDelete",
"httpMethod": "POST",
"id": "health.users.dataTypes.dataPoints.batchDelete",
"parameterOrder": [
"parent"
],
"parameters": {
"parent": {
"description": "Optional. Parent (data type) for the Data Point collection Format: `users/me/dataTypes/{data_type}`, e.g.: - `users/me/dataTypes/steps` - `users/me/dataTypes/-` For a list of the supported data types see the DataPoint data union field. Deleting data points across multiple data type collections is supported following https://aip.dev/159. If this is set, the parent of all of the data points specified in `names` must match this field.",
"location": "path",
"pattern": "^users/[^/]+/dataTypes/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v4/{+parent}/dataPoints:batchDelete",
"request": {
"$ref": "BatchDeleteDataPointsRequest"
},
"response": {
"$ref": "Operation"
}
},
"create": {
"description": "Creates a single identifiable data point.",
"flatPath": "v4/users/{usersId}/dataTypes/{dataTypesId}/dataPoints",
"httpMethod": "POST",
"id": "health.users.dataTypes.dataPoints.create",
"parameterOrder": [
"parent"
],
"parameters": {
"parent": {
"description": "Required. The parent resource name where the data point will be created. Format: `users/{user}/dataTypes/{data_type}`",
"location": "path",
"pattern": "^users/[^/]+/dataTypes/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v4/{+parent}/dataPoints",
"request": {
"$ref": "DataPoint"
},
"response": {
"$ref": "Operation"
}
},
"dailyRollUp": {
"description": "Roll up data points over civil time intervals for supported data types.",
"flatPath": "v4/users/{usersId}/dataTypes/{dataTypesId}/dataPoints:dailyRollUp",
"httpMethod": "POST",
"id": "health.users.dataTypes.dataPoints.dailyRollUp",
"parameterOrder": [
"parent"
],
"parameters": {
"parent": {
"description": "Required. Parent data type of the Data Point collection. Format: `users/{user}/dataTypes/{data_type}`, e.g.: - `users/me/dataTypes/steps` - `users/me/dataTypes/distance` For a list of the supported data types see the DailyRollupDataPoint value union field.",
"location": "path",
"pattern": "^users/[^/]+/dataTypes/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v4/{+parent}/dataPoints:dailyRollUp",
"request": {
"$ref": "DailyRollUpDataPointsRequest"
},
"response": {
"$ref": "DailyRollUpDataPointsResponse"
}
},
"exportExerciseTcx": {
"description": "Exports exercise data in TCX format. Note: While the Authorization section below states that any one of the listed scopes is accepted, this specific method requires the user to provide both one of the `activity_and_fitness` scopes (`normal` or `readonly`) AND one of the `location` scopes (`normal` or `readonly`) in their access token to succeed.",
"flatPath": "v4/users/{usersId}/dataTypes/{dataTypesId}/dataPoints/{dataPointsId}:exportExerciseTcx",
"httpMethod": "GET",
"id": "health.users.dataTypes.dataPoints.exportExerciseTcx",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "Required. The resource name of the exercise data point to export. Format: `users/{user}/dataTypes/exercise/dataPoints/{data_point}` Example: `users/me/dataTypes/exercise/dataPoints/2026443605080188808` The `{user}` is the alias `\"me\"` currently. Future versions may support user IDs. The `{data_point}` ID maps to the exercise ID, which is a long integer.",
"location": "path",
"pattern": "^users/[^/]+/dataTypes/[^/]+/dataPoints/[^/]+$",
"required": true,
"type": "string"
},
"partialData": {
"description": "Optional. Indicates whether to include the TCX data points when the GPS data is not available. If not specified, defaults to `false` and partial data will not be included.",
"location": "query",
"type": "boolean"
}
},
"path": "v4/{+name}:exportExerciseTcx",
"response": {
"$ref": "ExportExerciseTcxResponse"
},
"supportsMediaDownload": true,
"useMediaDownloadService": true
},
"list": {
"description": "Query user health and fitness data points.",
"flatPath": "v4/users/{usersId}/dataTypes/{dataTypesId}/dataPoints",
"httpMethod": "GET",
"id": "health.users.dataTypes.dataPoints.list",
"parameterOrder": [
"parent"
],
"parameters": {
"filter": {
"description": "Optional. Filter expression following https://google.aip.dev/160. A time range (either physical or civil) can be specified. The supported filter fields are: - Interval start time: - Pattern: `{interval_data_type}.interval.start_time` - Supported comparison operators: `>=`, `<` - Timestamp literal expected in RFC-3339 format - Supported logical operators: `AND` - Example: - `steps.interval.start_time >= \"2023-11-24T00:00:00Z\" AND steps.interval.start_time < \"2023-11-25T00:00:00Z\"` - `distance.interval.start_time >= \"2024-08-14T12:34:56Z\"` - Interval civil start time: - Pattern: `{interval_data_type}.interval.civil_start_time` - Supported comparison operators: `>=`, `<` - Date with optional time literal expected in ISO 8601 `YYYY-MM-DD[THH:mm:ss]` format - Supported logical operators: `AND` - Example: - `steps.interval.civil_start_time >= \"2023-11-24\" AND steps.interval.civil_start_time < \"2023-11-25\"` - `distance.interval.civil_start_time >= \"2024-08-14T12:34:56\"` - Sample observation physical time: - Pattern: `{sample_data_type}.sample_time.physical_time` - Supported comparison operators: `>=`, `<` - Timestamp literal expected in RFC-3339 format - Supported logical operators: `AND` - Example: - `weight.sample_time.physical_time >= \"2023-11-24T00:00:00Z\" AND weight.sample_time.physical_time < \"2023-11-25T00:00:00Z\"` - `weight.sample_time.physical_time >= \"2024-08-14T12:34:56Z\"` - Sample observation civil time: - Pattern: `{sample_data_type}.sample_time.civil_time` - Supported comparison operators: `>=`, `<` - Date with optional time literal expected in ISO 8601 `YYYY-MM-DD[THH:mm:ss]` format - Supported logical operators: `AND` - Example: - `weight.sample_time.civil_time >= \"2023-11-24\" AND weight.sample_time.civil_time < \"2023-11-25\"` - `weight.sample_time.civil_time >= \"2024-08-14T12:34:56\"` - Daily summary date: - Pattern: `{daily_summary_data_type}.date` - Supported comparison operators: `>=`, `<` - Date literal expected in ISO 8601 `YYYY-MM-DD` format - Supported logical operators: `AND` - Example: - `daily_resting_heart_rate.date >= \"2024-08-14\"` - `daily_heart_rate_variability.date < \"2024-08-15\"` - Session civil start time (**Excluding Sleep**): - Pattern: `{session_data_type}.interval.civil_start_time` - Supported comparison operators: `>=`, `<` - Date with optional time literal expected in ISO 8601 `YYYY-MM-DD[THH:mm:ss]` format - Supported logical operators: `AND` - Example: - `exercise.interval.civil_start_time >= \"2023-11-24\" AND exercise.interval.civil_start_time < \"2023-11-25\"` - `exercise.interval.civil_start_time >= \"2024-08-14T12:34:56\"` - Session end time (**Sleep specific**): - Pattern: `sleep.interval.end_time` - Supported comparison operators: `>=`, `<` - Timestamp literal expected in RFC-3339 format - Supported logical operators: `AND`, `OR` - Example: - `sleep.interval.end_time >= \"2023-11-24T00:00:00Z\" AND sleep.interval.end_time < \"2023-11-25T00:00:00Z\"` - Session civil end time (**Sleep specific**): - Pattern: `sleep.interval.civil_end_time` - Supported comparison operators: `>=`, `<` - Date with optional time literal expected in ISO 8601 `YYYY-MM-DD[THH:mm:ss]` format - Supported logical operators: `AND`, `OR` - Example: - `sleep.interval.civil_end_time >= \"2023-11-24\" AND sleep.interval.civil_end_time < \"2023-11-25\"` Data points in the response will be ordered by the interval start time in descending order.",
"location": "query",
"type": "string"
},
"pageSize": {
"description": "Optional. The maximum number of data points to return. If unspecified, at most 1440 data points will be returned. The maximum page size is 10000; values above that will be truncated accordingly. For `exercise` and `sleep` the default page size is 25. The maximum page size for `exercise` and `sleep` is 25.",
"format": "int32",
"location": "query",
"type": "integer"
},
"pageToken": {
"description": "Optional. The `next_page_token` from a previous request, if any.",
"location": "query",
"type": "string"
},
"parent": {
"description": "Required. Parent data type of the Data Point collection. Format: `users/me/dataTypes/{data_type}`, e.g.: - `users/me/dataTypes/steps` - `users/me/dataTypes/weight` For a list of the supported data types see the DataPoint data union field.",
"location": "path",
"pattern": "^users/[^/]+/dataTypes/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v4/{+parent}/dataPoints",
"response": {
"$ref": "ListDataPointsResponse"
}
},
"patch": {
"description": "Updates a single identifiable data point. If a data point with the specified `name` is not found, the request will fail.",
"flatPath": "v4/users/{usersId}/dataTypes/{dataTypesId}/dataPoints/{dataPointsId}",
"httpMethod": "PATCH",
"id": "health.users.dataTypes.dataPoints.patch",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "Identifier. Data point name, only supported for the subset of identifiable data types. For the majority of the data types, individual data points do not need to be identified and this field would be empty. Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` Example: `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` The `{user}` ID is a system-generated identifier, as described in Identity.health_user_id. The `{data_type}` ID corresponds to the kebab-case version of the field names in the DataPoint data union field, e.g. `total-calories` for the `total_calories` field. The `{data_point}` ID can be client-provided or system-generated. If client-provided, it must be a string of 4-63 characters, containing only lowercase letters, numbers, and hyphens.",
"location": "path",
"pattern": "^users/[^/]+/dataTypes/[^/]+/dataPoints/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v4/{+name}",
"request": {
"$ref": "DataPoint"
},
"response": {
"$ref": "Operation"
}
},
"reconcile": {
"description": "Reconcile data points from multiple data sources into a single data stream.",
"flatPath": "v4/users/{usersId}/dataTypes/{dataTypesId}/dataPoints:reconcile",
"httpMethod": "GET",
"id": "health.users.dataTypes.dataPoints.reconcile",
"parameterOrder": [
"parent"
],
"parameters": {
"dataSourceFamily": {
"description": "Optional. The data source family name to reconcile. If empty, data points from all data sources will be reconciled. Format: `users/me/dataSourceFamilies/{data_source_family}` The supported values are: - `users/me/dataSourceFamilies/all-sources` - default value - `users/me/dataSourceFamilies/google-wearables` - tracker devices - `users/me/dataSourceFamilies/google-sources` - Google first party sources",
"location": "query",
"type": "string"
},
"filter": {
"description": "Optional. Filter expression based on https://aip.dev/160. A time range, either physical or civil, can be specified. See the ListDataPointsRequest.filter for the supported fields and syntax.",
"location": "query",
"type": "string"
},
"pageSize": {
"description": "Optional. The maximum number of data points to return. If unspecified, at most 1440 data points will be returned. The maximum page size is 10000; values above that will be truncated accordingly. For `exercise` and `sleep` the default page size is 25. The maximum page size for `exercise` and `sleep` is 25.",
"format": "int32",
"location": "query",
"type": "integer"
},
"pageToken": {
"description": "Optional. The `next_page_token` from a previous request, if any.",
"location": "query",
"type": "string"
},
"parent": {
"description": "Required. Parent data type of the Data Point collection. Format: `users/me/dataTypes/{data_type}`, e.g.: - `users/me/dataTypes/steps` - `users/me/dataTypes/heart-rate` For a list of the supported data types see the DataPoint data union field.",
"location": "path",
"pattern": "^users/[^/]+/dataTypes/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v4/{+parent}/dataPoints:reconcile",
"response": {
"$ref": "ReconcileDataPointsResponse"
}
},
"rollUp": {
"description": "Roll up data points over physical time intervals for supported data types.",
"flatPath": "v4/users/{usersId}/dataTypes/{dataTypesId}/dataPoints:rollUp",
"httpMethod": "POST",
"id": "health.users.dataTypes.dataPoints.rollUp",
"parameterOrder": [
"parent"
],
"parameters": {
"parent": {
"description": "Required. Parent data type of the Data Point collection. Format: `users/{user}/dataTypes/{data_type}`, e.g.: - `users/me/dataTypes/steps` - `users/me/dataTypes/distance` For a list of the supported data types see the RollupDataPoint value union field.",
"location": "path",
"pattern": "^users/[^/]+/dataTypes/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v4/{+parent}/dataPoints:rollUp",
"request": {
"$ref": "RollUpDataPointsRequest"
},
"response": {
"$ref": "RollUpDataPointsResponse"
}
}
}
}
}
}
}
}
},
"revision": "20260405",
"rootUrl": "https://health.googleapis.com/",
"schemas": {
"ActiveMinutes": {
"description": "Record of active minutes in a given time interval.",
"id": "ActiveMinutes",
"properties": {
"activeMinutesByActivityLevel": {
"description": "Required. Active minutes by activity level. At most one record per activity level is allowed.",
"items": {
"$ref": "ActiveMinutesByActivityLevel"
},
"type": "array"
},
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval."
}
},
"type": "object"
},
"ActiveMinutesByActivityLevel": {
"description": "Active minutes at a given activity level.",
"id": "ActiveMinutesByActivityLevel",
"properties": {
"activeMinutes": {
"description": "Required. Number of whole minutes spent in activity.",
"format": "int64",
"type": "string"
},
"activityLevel": {
"description": "Required. The level of activity.",
"enum": [
"ACTIVITY_LEVEL_UNSPECIFIED",
"LIGHT",
"MODERATE",
"VIGOROUS"
],
"enumDescriptions": [
"Activity level is unspecified.",
"Light activity level.",
"Moderate activity level.",
"Vigorous activity level."
],
"type": "string"
}
},
"type": "object"
},
"ActiveMinutesRollupByActivityLevel": {
"description": "Active minutes by activity level.",
"id": "ActiveMinutesRollupByActivityLevel",
"properties": {
"activeMinutesSum": {
"description": "Number of whole minutes spent in activity.",
"format": "int64",
"type": "string"
},
"activityLevel": {
"description": "The level of activity.",
"enum": [
"ACTIVITY_LEVEL_UNSPECIFIED",
"LIGHT",
"MODERATE",
"VIGOROUS"
],
"enumDescriptions": [
"Activity level is unspecified.",
"Light activity level.",
"Moderate activity level.",
"Vigorous activity level."
],
"type": "string"
}
},
"type": "object"
},
"ActiveMinutesRollupValue": {
"description": "Represents the result of the rollup of the active minutes data type.",
"id": "ActiveMinutesRollupValue",
"properties": {
"activeMinutesRollupByActivityLevel": {
"description": "Active minutes by activity level. At most one record per activity level is allowed.",
"items": {
"$ref": "ActiveMinutesRollupByActivityLevel"
},
"type": "array"
}
},
"type": "object"
},
"ActiveZoneMinutes": {
"description": "Record of active zone minutes in a given time interval.",
"id": "ActiveZoneMinutes",
"properties": {
"activeZoneMinutes": {
"description": "Required. Number of Active Zone Minutes earned in the given time interval. Note: active_zone_minutes equals to 1 for low intensity (fat burn) zones or 2 for high intensity zones (cardio, peak).",
"format": "int64",
"type": "string"
},
"heartRateZone": {
"description": "Required. Heart rate zone in which the active zone minutes have been earned, in the given time interval.",
"enum": [
"HEART_RATE_ZONE_UNSPECIFIED",
"FAT_BURN",
"CARDIO",
"PEAK"
],
"enumDescriptions": [
"Unspecified heart rate zone.",
"The fat burn heart rate zone.",
"The cardio heart rate zone.",
"The peak heart rate zone."
],
"type": "string"
},
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval."
}
},
"type": "object"
},
"ActiveZoneMinutesRollupValue": {
"description": "Represents the result of the rollup of the active zone minutes data type.",
"id": "ActiveZoneMinutesRollupValue",
"properties": {
"sumInCardioHeartZone": {
"description": "Active zone minutes in `HeartRateZone.CARDIO`.",
"format": "int64",
"type": "string"
},
"sumInFatBurnHeartZone": {
"description": "Active zone minutes in `HeartRateZone.FAT_BURN`.",
"format": "int64",
"type": "string"
},
"sumInPeakHeartZone": {
"description": "Active zone minutes in `HeartRateZone.PEAK`.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"ActivityLevel": {
"description": "Internal type to capture activity level during a certain time interval.",
"id": "ActivityLevel",
"properties": {
"activityLevelType": {
"description": "Required. Activity level type in the given time interval.",
"enum": [
"ACTIVITY_LEVEL_TYPE_UNSPECIFIED",
"SEDENTARY",
"LIGHTLY_ACTIVE",
"MODERATELY_ACTIVE",
"VERY_ACTIVE"
],
"enumDescriptions": [
"Unspecified activity level type.",
"Sedentary activity level.",
"Lightly active activity level.",
"Moderately active activity level.",
"Very active activity level."
],
"type": "string"
},
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval."
}
},
"type": "object"
},
"ActivityLevelRollupByActivityLevelType": {
"description": "Represents the total duration in a specific activity level type.",
"id": "ActivityLevelRollupByActivityLevelType",
"properties": {
"activityLevelType": {
"description": "Activity level type.",
"enum": [
"ACTIVITY_LEVEL_TYPE_UNSPECIFIED",
"SEDENTARY",
"LIGHTLY_ACTIVE",
"MODERATELY_ACTIVE",
"VERY_ACTIVE"
],
"enumDescriptions": [
"Unspecified activity level type.",
"Sedentary activity level.",
"Lightly active activity level.",
"Moderately active activity level.",
"Very active activity level."
],
"type": "string"
},
"totalDuration": {
"description": "Total duration in the activity level type.",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"ActivityLevelRollupValue": {
"description": "Represents the result of the rollup of the activity level data type.",
"id": "ActivityLevelRollupValue",
"properties": {
"activityLevelRollupsByActivityLevelType": {
"description": "List of total durations in each activity level type.",
"items": {
"$ref": "ActivityLevelRollupByActivityLevelType"
},
"type": "array"
}
},
"type": "object"
},
"Altitude": {
"description": "Captures the altitude gain (i.e. deltas), and not level above sea, for a user in millimeters.",
"id": "Altitude",
"properties": {
"gainMillimeters": {
"description": "Required. Altitude gain in millimeters over the observed interval.",
"format": "int64",
"type": "string"
},
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval."
}
},
"type": "object"
},
"AltitudeRollupValue": {
"description": "Represents the result of the rollup of the user's altitude.",
"id": "AltitudeRollupValue",
"properties": {
"gainMillimetersSum": {
"description": "Sum of the altitude gain in millimeters.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"Application": {
"description": "Optional metadata for the application that provided this data.",
"id": "Application",
"properties": {
"googleWebClientId": {
"description": "Output only. The Google OAuth 2.0 client ID of the web application or service that recorded the data. This is the client ID used during the Google OAuth flow to obtain user credentials. This field is system-populated when the data is uploaded from Google Web API.",
"readOnly": true,
"type": "string"
},
"packageName": {
"description": "Output only. A unique identifier for the mobile application that was the source of the data. This is typically the application's package name on Android (e.g., `com.google.fitbit`) or the bundle ID on iOS. This field is informational and helps trace data origin. This field is system-populated when the data is uploaded from the Fitbit mobile application, Health Connect or Health Kit.",
"readOnly": true,
"type": "string"
},
"webClientId": {
"description": "Output only. The client ID of the application that recorded the data. This ID is a legacy Fitbit API client ID, which is different from a Google OAuth client ID. Example format: `ABC123`. This field is system-populated and used for tracing data from legacy Fitbit API integrations. This field is system-populated when the data is uploaded from a legacy Fitbit API integration.",
"readOnly": true,
"type": "string"
}
},
"type": "object"
},
"BatchDeleteDataPointsRequest": {
"description": "Request to delete a batch of identifiable data points.",
"id": "BatchDeleteDataPointsRequest",
"properties": {
"names": {
"description": "Required. The names of the DataPoints to delete. A maximum of 10000 data points can be deleted in a single request.",
"items": {
"type": "string"
},
"type": "array"
}
},
"type": "object"
},
"BodyFat": {
"description": "Body fat measurement.",
"id": "BodyFat",
"properties": {
"percentage": {
"description": "Required. Body fat percentage, in range [0, 100].",
"format": "double",
"type": "number"
},
"sampleTime": {
"$ref": "ObservationSampleTime",
"description": "Required. The time at which body fat was measured."
}
},
"type": "object"
},
"BodyFatRollupValue": {
"description": "Represents the result of the rollup of the body fat data type.",
"id": "BodyFatRollupValue",
"properties": {
"bodyFatPercentageAvg": {
"description": "Average body fat percentage.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"CaloriesInHeartRateZoneRollupValue": {
"description": "Represents the result of the rollup of the calories in heart rate zone data type.",
"id": "CaloriesInHeartRateZoneRollupValue",
"properties": {
"caloriesInHeartRateZones": {
"description": "List of calories burned in each heart rate zone.",
"items": {
"$ref": "CaloriesInHeartRateZoneValue"
},
"type": "array"
}
},
"type": "object"
},
"CaloriesInHeartRateZoneValue": {
"description": "Represents the amount of kilocalories burned in a specific heart rate zone.",
"id": "CaloriesInHeartRateZoneValue",
"properties": {
"heartRateZone": {
"description": "The heart rate zone.",
"enum": [
"HEART_RATE_ZONE_TYPE_UNSPECIFIED",
"LIGHT",
"MODERATE",
"VIGOROUS",
"PEAK"
],
"enumDescriptions": [
"Unspecified heart rate zone.",
"The light heart rate zone.",
"The moderate heart rate zone.",
"The vigorous heart rate zone.",
"The peak heart rate zone."
],
"type": "string"
},
"kcal": {
"description": "The amount of kilocalories burned in the specified heart rate zone.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"CivilDateTime": {
"description": "Civil time representation similar to google.type.DateTime, but ensures that neither the timezone nor the UTC offset can be set to avoid confusion between civil and physical time queries.",
"id": "CivilDateTime",
"properties": {
"date": {
"$ref": "Date",
"description": "Required. Calendar date."
},
"time": {
"$ref": "TimeOfDay",
"description": "Optional. Time of day. Defaults to the start of the day, at midnight if omitted."
}
},
"type": "object"
},
"CivilTimeInterval": {
"description": "Counterpart of google.type.Interval, but using CivilDateTime.",
"id": "CivilTimeInterval",
"properties": {
"end": {
"$ref": "CivilDateTime",
"description": "Required. The exclusive end of the range."
},
"start": {
"$ref": "CivilDateTime",
"description": "Required. The inclusive start of the range."
}
},
"type": "object"
},
"DailyHeartRateVariability": {
"description": "Represents the daily heart rate variability data type. At least one of the following fields must be set: - `average_heart_rate_variability_milliseconds` - `non_rem_heart_rate_beats_per_minute` - `entropy` - `deep_sleep_root_mean_square_of_successive_differences_milliseconds`",
"id": "DailyHeartRateVariability",
"properties": {
"averageHeartRateVariabilityMilliseconds": {
"description": "Optional. A user's average heart rate variability calculated using the root mean square of successive differences (RMSSD) in times between heartbeats.",
"format": "double",
"type": "number"
},
"date": {
"$ref": "Date",
"description": "Required. Date (in the user's timezone) of heart rate variability measurement."
},
"deepSleepRootMeanSquareOfSuccessiveDifferencesMilliseconds": {
"description": "Optional. The root mean square of successive differences (RMSSD) value during deep sleep.",
"format": "double",
"type": "number"
},
"entropy": {
"description": "Optional. The Shanon entropy of heartbeat intervals. Entropy quantifies randomness or disorder in a system. High entropy indicates high HRV. Entropy is measured from the histogram of time interval between successive heart beats values measured during sleep.",
"format": "double",
"type": "number"
},
"nonRemHeartRateBeatsPerMinute": {
"description": "Optional. Non-REM heart rate",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"DailyHeartRateZones": {
"description": "User's heart rate zone thresholds based on the Karvonen algorithm for a specific day.",
"id": "DailyHeartRateZones",
"properties": {
"date": {
"$ref": "Date",
"description": "Required. Date (in user's timezone) of the heart rate zones record."
},
"heartRateZones": {
"description": "Required. The heart rate zones.",
"items": {
"$ref": "HeartRateZone"
},
"type": "array"
}
},
"type": "object"
},
"DailyOxygenSaturation": {
"description": "A daily oxygen saturation (SpO2) record. Represents the user's daily oxygen saturation summary, typically calculated during sleep.",
"id": "DailyOxygenSaturation",
"properties": {
"averagePercentage": {
"description": "Required. The average value of the oxygen saturation samples during the sleep.",
"format": "double",
"type": "number"
},
"date": {
"$ref": "Date",
"description": "Required. Date (in user's timezone) of the daily oxygen saturation record."
},
"lowerBoundPercentage": {
"description": "Required. The lower bound of the confidence interval of oxygen saturation samples during sleep.",
"format": "double",
"type": "number"
},
"standardDeviationPercentage": {
"description": "Optional. Standard deviation of the daily oxygen saturation averages from the past 7-30 days.",
"format": "double",
"type": "number"
},
"upperBoundPercentage": {
"description": "Required. The upper bound of the confidence interval of oxygen saturation samples during sleep.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"DailyRespiratoryRate": {
"description": "A daily average respiratory rate (breaths per minute) for a day of the year. One data point per day calculated for the main sleep.",
"id": "DailyRespiratoryRate",
"properties": {
"breathsPerMinute": {
"description": "Required. The average number of breaths taken per minute.",
"format": "double",
"type": "number"
},
"date": {
"$ref": "Date",
"description": "Required. The date on which the respiratory rate was measured."
}
},
"type": "object"
},
"DailyRestingHeartRate": {
"description": "Measures the daily resting heart rate for a user, calculated using the all day heart rate measurements.",
"id": "DailyRestingHeartRate",
"properties": {
"beatsPerMinute": {
"description": "Required. The resting heart rate value in beats per minute.",
"format": "int64",
"type": "string"
},
"dailyRestingHeartRateMetadata": {
"$ref": "DailyRestingHeartRateMetadata",
"description": "Optional. Metadata for the daily resting heart rate."
},
"date": {
"$ref": "Date",
"description": "Required. Date (in the user's timezone) of the resting heart rate measurement."
}
},
"type": "object"
},
"DailyRestingHeartRateMetadata": {
"description": "Metadata for the daily resting heart rate.",
"id": "DailyRestingHeartRateMetadata",
"properties": {
"calculationMethod": {
"description": "Required. The method used to calculate the resting heart rate.",
"enum": [
"CALCULATION_METHOD_UNSPECIFIED",
"WITH_SLEEP",
"ONLY_WITH_AWAKE_DATA"
],
"enumDescriptions": [
"The calculation method is unspecified.",
"The resting heart rate is calculated using the sleep data.",
"The resting heart rate is calculated using only awake data."
],
"type": "string"
}
},
"type": "object"
},
"DailyRollUpDataPointsRequest": {
"description": "Request to roll up data points by civil time intervals.",
"id": "DailyRollUpDataPointsRequest",
"properties": {
"dataSourceFamily": {
"description": "Optional. The data source family name to roll up. If empty, data points from all available data sources will be rolled up. Format: `users/me/dataSourceFamilies/{data_source_family}` The supported values are: - `users/me/dataSourceFamilies/all-sources` - default value - `users/me/dataSourceFamilies/google-wearables` - tracker devices - `users/me/dataSourceFamilies/google-sources` - Google first party sources",
"type": "string"
},
"pageSize": {
"description": "Optional. The maximum number of data points to return. If unspecified, at most 1440 data points will be returned. The maximum page size is 10000; values above that will be truncated accordingly.",
"format": "int32",
"type": "integer"
},
"pageToken": {
"description": "Optional. The `next_page_token` from a previous request, if any. All other request fields need to be the same as in the initial request when the page token is specified.",
"type": "string"
},
"range": {
"$ref": "CivilTimeInterval",
"description": "Required. Closed-open range of data points that will be rolled up. The start time must be aligned with the aggregation window. The maximum range for `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes` and `total-calories` is 14 days. The maximum range for all other data types is 90 days."
},
"windowSizeDays": {
"description": "Optional. Aggregation window size, in number of days. Defaults to 1 if not specified.",
"format": "int32",
"type": "integer"
}
},
"type": "object"
},
"DailyRollUpDataPointsResponse": {
"description": "Response containing the list of rolled up data points.",
"id": "DailyRollUpDataPointsResponse",
"properties": {
"rollupDataPoints": {
"description": "Values for each aggregation time window.",
"items": {
"$ref": "DailyRollupDataPoint"
},
"type": "array"
}
},
"type": "object"
},
"DailyRollupDataPoint": {
"description": "Value of a daily rollup for a single civil time interval (aggregation window)",
"id": "DailyRollupDataPoint",
"properties": {
"activeMinutes": {
"$ref": "ActiveMinutesRollupValue",
"description": "Returned by default when rolling up data points from the `active-minutes` data type, or when requested explicitly using the `active-minutes` rollup type identifier."
},
"activeZoneMinutes": {
"$ref": "ActiveZoneMinutesRollupValue",
"description": "Returned by default when rolling up data points from the `active-zone-minutes` data type, or when requested explicitly using the `active-zone-minutes` rollup type identifier."
},
"activityLevel": {
"$ref": "ActivityLevelRollupValue",
"description": "Returned by default when rolling up data points from the `activity-level` data type, or when requested explicitly using the `activity-level` rollup type identifier."
},
"altitude": {
"$ref": "AltitudeRollupValue",
"description": "Returned by default when rolling up data points from the `altitude` data type, or when requested explicitly using the `altitude` rollup type identifier."
},
"bodyFat": {
"$ref": "BodyFatRollupValue",
"description": "Returned by default when rolling up data points from the `body-fat` data type, or when requested explicitly using the `body-fat` rollup type identifier."
},
"caloriesInHeartRateZone": {
"$ref": "CaloriesInHeartRateZoneRollupValue",
"description": "Returned by default when rolling up data points from the `calories-in-heart-rate-zone` data type, or when requested explicitly using the `calories-in-heart-rate-zone` rollup type identifier."
},
"civilEndTime": {
"$ref": "CivilDateTime",
"description": "End time of the window this value aggregates over"
},
"civilStartTime": {
"$ref": "CivilDateTime",
"description": "Start time of the window this value aggregates over"
},
"distance": {
"$ref": "DistanceRollupValue",
"description": "Returned by default when rolling up data points from the `distance` data type, or when requested explicitly using the `distance` rollup type identifier."
},
"floors": {
"$ref": "FloorsRollupValue",
"description": "Returned by default when rolling up data points from the `floors` data type, or when requested explicitly using the `floors` rollup type identifier."
},
"heartRate": {
"$ref": "HeartRateRollupValue",
"description": "Returned by default when rolling up data points from the `heart-rate` data type, or when requested explicitly using the `heart-rate` rollup type identifier."
},
"heartRateVariabilityPersonalRange": {
"$ref": "HeartRateVariabilityPersonalRangeRollupValue",
"description": "Returned by default when rolling up data points from the `daily-heart-rate-variability` data type, or when requested explicitly using the `heart-rate-variability-personal-range` rollup type identifier."
},
"hydrationLog": {
"$ref": "HydrationLogRollupValue",
"description": "Returned by default when rolling up data points from the `hydration-log` data type, or when requested explicitly using the `hydration-log` rollup type identifier."
},
"restingHeartRatePersonalRange": {
"$ref": "RestingHeartRatePersonalRangeRollupValue",
"description": "Returned by default when rolling up data points from the `daily-resting-heart-rate` data type, or when requested explicitly using the `resting-heart-rate-personal-range` rollup type identifier."
},
"runVo2Max": {
"$ref": "RunVO2MaxRollupValue",
"description": "Returned by default when rolling up data points from the `run-vo2-max` data type, or when requested explicitly using the `run-vo2-max` rollup type identifier."
},
"sedentaryPeriod": {
"$ref": "SedentaryPeriodRollupValue",
"description": "Returned by default when rolling up data points from the `sedentary-period` data type, or when requested explicitly using the `sedentary-period` rollup type identifier."
},
"steps": {
"$ref": "StepsRollupValue",
"description": "Returned by default when rolling up data points from the `steps` data type, or when requested explicitly using the `steps` rollup type identifier."
},
"timeInHeartRateZone": {
"$ref": "TimeInHeartRateZoneRollupValue",
"description": "Returned by default when rolling up data points from the `time-in-heart-rate-zone` data type, or when requested explicitly using the `time-in-heart-rate-zone` rollup type identifier."
},
"totalCalories": {
"$ref": "TotalCaloriesRollupValue",
"description": "Returned by default when rolling up data points from the `total-calories` data type, or when requested explicitly using the `total-calories` rollup type identifier."
},
"weight": {
"$ref": "WeightRollupValue",
"description": "Returned by default when rolling up data points from the `weight` data type, or when requested explicitly using the `weight` rollup type identifier."
}
},
"type": "object"
},
"DailySleepTemperatureDerivations": {
"description": "Provides derived sleep temperature values, calculated from skin or internal device temperature readings during sleep.",
"id": "DailySleepTemperatureDerivations",
"properties": {
"baselineTemperatureCelsius": {
"description": "Optional. The user's baseline skin temperature. It is the median of the user's nightly skin temperature over the past 30 days.",
"format": "double",
"type": "number"
},
"date": {
"$ref": "Date",
"description": "Required. Date for which the sleep temperature derivations are calculated."
},
"nightlyTemperatureCelsius": {
"description": "Required. The user's nightly skin temperature. It is the mean of skin temperature samples taken from the user\u2019s sleep.",
"format": "double",
"type": "number"
},
"relativeNightlyStddev30dCelsius": {
"description": "Optional. The standard deviation of the user\u2019s relative nightly skin temperature (temperature - baseline) over the past 30 days.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"DailyVO2Max": {
"description": "Contains a daily summary of the user's VO2 max (cardio fitness score), which is the maximum rate of oxygen the body can use during exercise.",
"id": "DailyVO2Max",
"properties": {
"cardioFitnessLevel": {
"description": "Optional. Represents the user's cardio fitness level based on their VO2 max.",
"enum": [
"CARDIO_FITNESS_LEVEL_UNSPECIFIED",
"POOR",
"FAIR",
"AVERAGE",
"GOOD",
"VERY_GOOD",
"EXCELLENT"
],
"enumDescriptions": [
"Unspecified cardio fitness level.",
"Poor cardio fitness level.",
"Fair cardio fitness level.",
"Average cardio fitness level.",
"Good cardio fitness level.",
"Very good cardio fitness level.",
"Excellent cardio fitness level."
],
"type": "string"
},
"date": {
"$ref": "Date",
"description": "Required. The date for which the Daily VO2 max was measured."
},
"estimated": {
"description": "Optional. An estimated field is added to indicate when the confidence has decreased sufficiently to consider the value an estimation.",
"type": "boolean"
},
"vo2Max": {
"description": "Required. Daily VO2 max value measured as in ml consumed oxygen / kg of body weight / min.",
"format": "double",
"type": "number"
},
"vo2MaxCovariance": {
"description": "Optional. The covariance of the VO2 max value.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"DataPoint": {
"description": "A computed or recorded metric.",
"id": "DataPoint",
"properties": {
"activeMinutes": {
"$ref": "ActiveMinutes",
"description": "Optional. Data for points in the `active-minutes` interval data type collection."
},
"activeZoneMinutes": {
"$ref": "ActiveZoneMinutes",
"description": "Optional. Data for points in the `active-zone-minutes` interval data type collection, measured in minutes."
},
"activityLevel": {
"$ref": "ActivityLevel",
"description": "Optional. Data for points in the `activity-level` daily data type collection."
},
"altitude": {
"$ref": "Altitude",
"description": "Optional. Data for points in the `altitude` interval data type collection."
},
"bodyFat": {
"$ref": "BodyFat",
"description": "Optional. Data for points in the `body-fat` sample data type collection."
},
"dailyHeartRateVariability": {
"$ref": "DailyHeartRateVariability",
"description": "Optional. Data for points in the `daily-heart-rate-variability` daily data type collection."
},
"dailyHeartRateZones": {
"$ref": "DailyHeartRateZones",
"description": "Optional. Data for points in the `daily-heart-rate-zones` daily data type collection."
},
"dailyOxygenSaturation": {
"$ref": "DailyOxygenSaturation",
"description": "Optional. Data for points in the `daily-oxygen-saturation` daily data type collection."
},
"dailyRespiratoryRate": {
"$ref": "DailyRespiratoryRate",
"description": "Optional. Data for points in the `daily-respiratory-rate` daily data type collection."
},
"dailyRestingHeartRate": {
"$ref": "DailyRestingHeartRate",
"description": "Optional. Data for points in the `daily-resting-heart-rate` daily data type collection."
},
"dailySleepTemperatureDerivations": {
"$ref": "DailySleepTemperatureDerivations",
"description": "Optional. Data for points in the `daily-sleep-temperature-derivations` daily data type collection."
},
"dailyVo2Max": {
"$ref": "DailyVO2Max",
"description": "Optional. Data for points in the `daily-vo2-max` daily data type collection."
},
"dataSource": {
"$ref": "DataSource",
"description": "Optional. Data source information for the metric"
},
"distance": {
"$ref": "Distance",
"description": "Optional. Data for points in the `distance` interval data type collection."
},
"exercise": {
"$ref": "Exercise",
"description": "Optional. Data for points in the `exercise` session data type collection."
},
"floors": {
"$ref": "Floors",
"description": "Optional. Data for points in the `floors` interval data type collection."
},
"heartRate": {
"$ref": "HeartRate",
"description": "Optional. Data for points in the `heart-rate` sample data type collection."
},
"heartRateVariability": {
"$ref": "HeartRateVariability",
"description": "Optional. Data for points in the `heart-rate-variability` sample data type collection."
},
"hydrationLog": {
"$ref": "HydrationLog",
"description": "Optional. Data for points in the `hydration-log` session data type collection."
},
"name": {
"description": "Identifier. Data point name, only supported for the subset of identifiable data types. For the majority of the data types, individual data points do not need to be identified and this field would be empty. Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` Example: `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` The `{user}` ID is a system-generated identifier, as described in Identity.health_user_id. The `{data_type}` ID corresponds to the kebab-case version of the field names in the DataPoint data union field, e.g. `total-calories` for the `total_calories` field. The `{data_point}` ID can be client-provided or system-generated. If client-provided, it must be a string of 4-63 characters, containing only lowercase letters, numbers, and hyphens.",
"type": "string"
},
"oxygenSaturation": {
"$ref": "OxygenSaturation",
"description": "Optional. Data for points in the `oxygen-saturation` sample data type collection."
},
"respiratoryRateSleepSummary": {
"$ref": "RespiratoryRateSleepSummary",
"description": "Optional. Data for points in the `respiratory-rate-sleep-summary` sample data type collection."
},
"runVo2Max": {
"$ref": "RunVO2Max",
"description": "Optional. Data for points in the `run-vo2-max` sample data type collection."
},
"sedentaryPeriod": {
"$ref": "SedentaryPeriod",
"description": "Optional. Data for points in the `sedentary-period` interval data type collection."
},
"sleep": {
"$ref": "Sleep",
"description": "Optional. Data for points in the `sleep` session data type collection."
},
"steps": {
"$ref": "Steps",
"description": "Optional. Data for points in the `steps` interval data type collection."
},
"timeInHeartRateZone": {
"$ref": "TimeInHeartRateZone",
"description": "Optional. Data for points in the `time-in-heart-rate-zone` interval data type collection."
},
"vo2Max": {
"$ref": "VO2Max",
"description": "Optional. Data for points in the `vo2-max` sample data type collection."
},
"weight": {
"$ref": "Weight",
"description": "Optional. Data for points in the `weight` sample data type collection."
}
},
"type": "object"
},
"DataSource": {
"description": "Data Source definition to track the origin of data. Each health data point, regardless of the complexity or data model (whether a simple step count or a detailed sleep session) must retain information about its source of origin (e.g. the device or app that collected it).",
"id": "DataSource",
"properties": {
"application": {
"$ref": "Application",
"description": "Output only. Captures metadata for the application that provided this data.",
"readOnly": true
},
"device": {
"$ref": "Device",
"description": "Optional. Captures metadata for raw data points originating from devices. We expect this data source to be used for data points written on device sync."
},
"platform": {
"description": "Output only. Captures the platform that uploaded the data.",
"enum": [
"PLATFORM_UNSPECIFIED",
"FITBIT",
"HEALTH_CONNECT",
"HEALTH_KIT",
"FIT",
"FITBIT_WEB_API",
"NEST",
"GOOGLE_WEB_API",
"GOOGLE_PARTNER_INTEGRATION"
],
"enumDescriptions": [
"The platform is unspecified.",
"The data was uploaded from Fitbit.",
"The data was uploaded from Health Connect.",
"The data was uploaded from Health Kit.",
"The data was uploaded from Google Fit.",
"The data was uploaded from Fitbit legacy Web API.",
"The data was uploaded from Nest devices.",
"The data was uploaded from Google Health API.",
"The data was uploaded from Google Partner Integrations."
],
"readOnly": true,
"type": "string"
},
"recordingMethod": {
"description": "Optional. Captures how the data was recorded.",
"enum": [
"RECORDING_METHOD_UNSPECIFIED",
"MANUAL",
"PASSIVELY_MEASURED",
"DERIVED",
"ACTIVELY_MEASURED",
"UNKNOWN"
],
"enumDescriptions": [
"The recording method is unspecified.",
"The data was manually entered by the user.",
"The data was passively measured by a device.",
"The data was derived from other data, e.g., by an algorithm in the backend.",
"The data was actively measured by a device.",
"The recording method is unknown. This is set when the data is uploaded from a third party app that does not provide this information."
],
"type": "string"
}
},
"type": "object"
},
"Date": {
"description": "Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp",
"id": "Date",
"properties": {
"day": {
"description": "Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.",
"format": "int32",
"type": "integer"
},
"month": {
"description": "Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.",
"format": "int32",
"type": "integer"
},
"year": {
"description": "Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.",
"format": "int32",
"type": "integer"
}
},
"type": "object"
},
"DateTime": {
"description": "Represents civil time (or occasionally physical time). This type can represent a civil time in one of a few possible ways: * When utc_offset is set and time_zone is unset: a civil time on a calendar day with a particular offset from UTC. * When time_zone is set and utc_offset is unset: a civil time on a calendar day in a particular time zone. * When neither time_zone nor utc_offset is set: a civil time on a calendar day in local time. The date is relative to the Proleptic Gregorian Calendar. If year, month, or day are 0, the DateTime is considered not to have a specific year, month, or day respectively. This type may also be used to represent a physical time if all the date and time fields are set and either case of the `time_offset` oneof is set. Consider using `Timestamp` message for physical time instead. If your use case also would like to store the user's timezone, that can be done in another field. This type is more flexible than some applications may want. Make sure to document and validate your application's limitations.",
"id": "DateTime",
"properties": {
"day": {
"description": "Optional. Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if specifying a datetime without a day.",
"format": "int32",
"type": "integer"
},
"hours": {
"description": "Optional. Hours of day in 24 hour format. Should be from 0 to 23, defaults to 0 (midnight). An API may choose to allow the value \"24:00:00\" for scenarios like business closing time.",
"format": "int32",
"type": "integer"
},
"minutes": {
"description": "Optional. Minutes of hour of day. Must be from 0 to 59, defaults to 0.",
"format": "int32",
"type": "integer"
},
"month": {
"description": "Optional. Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a month.",
"format": "int32",
"type": "integer"
},
"nanos": {
"description": "Optional. Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults to 0.",
"format": "int32",
"type": "integer"
},
"seconds": {
"description": "Optional. Seconds of minutes of the time. Must normally be from 0 to 59, defaults to 0. An API may allow the value 60 if it allows leap-seconds.",
"format": "int32",
"type": "integer"
},
"timeZone": {
"$ref": "TimeZone",
"description": "Time zone."
},
"utcOffset": {
"description": "UTC offset. Must be whole seconds, between -18 hours and +18 hours. For example, a UTC offset of -4:00 would be represented as { seconds: -14400 }.",
"format": "google-duration",
"type": "string"
},
"year": {
"description": "Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without a year.",
"format": "int32",
"type": "integer"
}
},
"type": "object"
},
"Device": {
"description": "Captures metadata about the device that recorded the measurement.",
"id": "Device",
"properties": {
"displayName": {
"description": "Optional. An optional name for the device.",
"type": "string"
},
"formFactor": {
"description": "Optional. Captures the form factor of the device.",
"enum": [
"FORM_FACTOR_UNSPECIFIED",
"FITNESS_BAND",
"WATCH",
"PHONE",
"RING",
"CHEST_STRAP",
"SCALE",
"TABLET",
"HEAD_MOUNTED",
"SMART_DISPLAY"
],
"enumDescriptions": [
"The form factor is unspecified.",
"The device is a fitness band.",
"The device is a watch.",
"The device is a phone.",
"The device is a ring.",
"The device is a chest strap.",
"The device is a scale.",
"The device is a tablet.",
"The device is a head mounted device.",
"The device is a smart display."
],
"type": "string"
},
"manufacturer": {
"description": "Optional. An optional manufacturer of the device.",
"type": "string"
}
},
"type": "object"
},
"Distance": {
"description": "Distance traveled over an interval of time.",
"id": "Distance",
"properties": {
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval."
},
"millimeters": {
"description": "Required. Distance in millimeters over the observed interval.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"DistanceRollupValue": {
"description": "Result of the rollup of the user's distance.",
"id": "DistanceRollupValue",
"properties": {
"millimetersSum": {
"description": "Sum of the distance in millimeters.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"Exercise": {
"description": "An exercise that stores information about a physical activity.",
"id": "Exercise",
"properties": {
"activeDuration": {
"description": "Optional. Duration excluding pauses.",
"format": "google-duration",
"type": "string"
},
"createTime": {
"description": "Output only. Represents the timestamp of the creation of the exercise.",
"format": "google-datetime",
"readOnly": true,
"type": "string"
},
"displayName": {
"description": "Required. Exercise display name.",
"type": "string"
},
"exerciseEvents": {
"description": "Optional. Exercise events that happen during an exercise, such as pause & restarts.",
"items": {
"$ref": "ExerciseEvent"
},
"type": "array"
},
"exerciseMetadata": {
"$ref": "ExerciseMetadata",
"description": "Optional. Additional exercise metadata."
},
"exerciseType": {
"description": "Required. The type of activity performed during an exercise.",
"enum": [
"EXERCISE_TYPE_UNSPECIFIED",
"RUNNING",
"WALKING",
"BIKING",
"SWIMMING",
"HIKING",
"YOGA",
"PILATES",
"WORKOUT",
"HIIT",
"WEIGHTLIFTING",
"STRENGTH_TRAINING",
"OTHER"
],
"enumDescriptions": [
"Exercise type is unspecified.",
"Running type.",
"Walking type.",
"Biking type.",
"Swimming type.",
"Hiking type.",
"Yoga type.",
"Pilates type.",
"Workout type.",
"HIIT type.",
"Weightlifting type.",
"Strength training type.",
"Other type."
],
"type": "string"
},
"interval": {
"$ref": "SessionTimeInterval",
"description": "Required. Observed exercise interval"
},
"metricsSummary": {
"$ref": "MetricsSummary",
"description": "Required. Summary metrics for this exercise ( )"
},
"notes": {
"description": "Optional. Standard free-form notes captured at manual logging.",
"type": "string"
},
"splitSummaries": {
"description": "Optional. Laps or splits recorded within an exercise. Laps could be split based on distance or other criteria (duration, etc.) Laps should not be overlapping with each other.",
"items": {
"$ref": "SplitSummary"
},
"type": "array"
},
"splits": {
"description": "Optional. The default split is 1 km or 1 mile. - if the movement distance is less than the default, then there are no splits - if the movement distance is greater than or equal to the default, then we have splits",
"items": {
"$ref": "SplitSummary"
},
"type": "array"
},
"updateTime": {
"description": "Output only. This is the timestamp of the last update to the exercise.",
"format": "google-datetime",
"readOnly": true,
"type": "string"
}
},
"type": "object"
},
"ExerciseEvent": {
"description": "Represents instantaneous events that happen during an exercise, such as start, stop, pause, split.",
"id": "ExerciseEvent",
"properties": {
"eventTime": {
"description": "Required. Exercise event time",
"format": "google-datetime",
"type": "string"
},
"eventUtcOffset": {
"description": "Required. Exercise event time offset from UTC",
"format": "google-duration",
"type": "string"
},
"exerciseEventType": {
"description": "Required. The type of the event, such as start, stop, pause, resume.",
"enum": [
"EXERCISE_EVENT_TYPE_UNSPECIFIED",
"START",
"STOP",
"PAUSE",
"RESUME",
"AUTO_PAUSE",
"AUTO_RESUME"
],
"enumDescriptions": [
"Exercise event type is unspecified.",
"Exercise start event.",
"Exercise stop event.",
"Exercise pause event.",
"Exercise resume event.",
"Exercise auto-pause event.",
"Exercise auto-resume event."
],
"type": "string"
}
},
"type": "object"
},
"ExerciseMetadata": {
"description": "Additional exercise metadata.",
"id": "ExerciseMetadata",
"properties": {
"hasGps": {
"description": "Optional. Whether the exercise had GPS tracking.",
"type": "boolean"
},
"poolLengthMillimeters": {
"description": "Optional. Pool length in millimeters. Only present in the swimming exercises.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"ExportExerciseTcxResponse": {
"description": "Represents a Response for exporting exercise data in TCX format.",
"id": "ExportExerciseTcxResponse",
"properties": {
"tcxData": {
"description": "Contains the exported TCX data.",
"type": "string"
}
},
"type": "object"
},
"Floors": {
"description": "Gained elevation measured in floors over the time interval",
"id": "Floors",
"properties": {
"count": {
"description": "Required. Number of floors in the recorded interval",
"format": "int64",
"type": "string"
},
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval"
}
},
"type": "object"
},
"FloorsRollupValue": {
"description": "Represents the result of the rollup of the user's floors.",
"id": "FloorsRollupValue",
"properties": {
"countSum": {
"description": "Sum of the floors count.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"GoogleDevicesandservicesHealthV4DataType": {
"description": "Represents a type of health data a user can have data points recorded for. It matches the parent resource of collection containing data points of the given type. Clients currently do not need to interact with this resource directly.",
"id": "GoogleDevicesandservicesHealthV4DataType",
"properties": {
"name": {
"description": "Identifier. The resource name of the data type. Format: `users/{user}/dataTypes/{data_type}` See DataPoint.name for examples and possible values.",
"type": "string"
}
},
"type": "object"
},
"HeartRate": {
"description": "A heart rate measurement.",
"id": "HeartRate",
"properties": {
"beatsPerMinute": {
"description": "Required. The heart rate value in beats per minute.",
"format": "int64",
"type": "string"
},
"metadata": {
"$ref": "HeartRateMetadata",
"description": "Optional. Metadata about the heart rate sample."
},
"sampleTime": {
"$ref": "ObservationSampleTime",
"description": "Required. Observation time"
}
},
"type": "object"
},
"HeartRateMetadata": {
"description": "Heart rate metadata.",
"id": "HeartRateMetadata",
"properties": {
"motionContext": {
"description": "Optional. Indicates the user\u2019s level of activity when the heart rate sample was measured",
"enum": [
"MOTION_CONTEXT_UNSPECIFIED",
"ACTIVE",
"SEDENTARY"
],
"enumDescriptions": [
"The default value when no data is available.",
"The user is active.",
"The user is inactive."
],
"type": "string"
},
"sensorLocation": {
"description": "Optional. Indicates the location of the sensor that measured the heart rate.",
"enum": [
"SENSOR_LOCATION_UNSPECIFIED",
"CHEST",
"WRIST",
"FINGER",
"HAND",
"EAR_LOBE",
"FOOT"
],
"enumDescriptions": [
"The default value when no data is available.",
"Chest sensor.",
"Wrist sensor.",
"Finger sensor.",
"Hand sensor.",
"Ear lobe sensor.",
"Foot sensor."
],
"type": "string"
}
},
"type": "object"
},
"HeartRateRollupValue": {
"description": "Represents the result of the rollup of the heart rate data type.",
"id": "HeartRateRollupValue",
"properties": {
"beatsPerMinuteAvg": {
"description": "The average heart rate value in the interval.",
"format": "double",
"type": "number"
},
"beatsPerMinuteMax": {
"description": "The maximum heart rate value in the interval.",
"format": "double",
"type": "number"
},
"beatsPerMinuteMin": {
"description": "The minimum heart rate value in the interval.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"HeartRateVariability": {
"description": "Captures user's heart rate variability (HRV) as measured by the root mean square of successive differences (RMSSD) between normal heartbeats or by standard deviation of the inter-beat intervals (SDNN).",
"id": "HeartRateVariability",
"properties": {
"rootMeanSquareOfSuccessiveDifferencesMilliseconds": {
"description": "Optional. The root mean square of successive differences between normal heartbeats. This is a measure of heart rate variability used by Fitbit.",
"format": "double",
"type": "number"
},
"sampleTime": {
"$ref": "ObservationSampleTime",
"description": "Required. The time of the heart rate variability measurement."
},
"standardDeviationMilliseconds": {
"description": "Optional. The standard deviation of the heart rate variability measurement.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"HeartRateVariabilityPersonalRangeRollupValue": {
"description": "Represents the result of the rollup of the user's daily heart rate variability personal range.",
"id": "HeartRateVariabilityPersonalRangeRollupValue",
"properties": {
"averageHeartRateVariabilityMillisecondsMax": {
"description": "The upper bound of the user's average heart rate variability personal range.",
"format": "double",
"type": "number"
},
"averageHeartRateVariabilityMillisecondsMin": {
"description": "The lower bound of the user's average heart rate variability personal range.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"HeartRateZone": {
"description": "The heart rate zone.",
"id": "HeartRateZone",
"properties": {
"heartRateZoneType": {
"description": "Required. The heart rate zone type.",
"enum": [
"HEART_RATE_ZONE_TYPE_UNSPECIFIED",
"LIGHT",
"MODERATE",
"VIGOROUS",
"PEAK"
],
"enumDescriptions": [
"Unspecified heart rate zone.",
"The light heart rate zone.",
"The moderate heart rate zone.",
"The vigorous heart rate zone.",
"The peak heart rate zone."
],
"type": "string"
},
"maxBeatsPerMinute": {
"description": "Required. Maximum heart rate for this zone in beats per minute.",
"format": "int64",
"type": "string"
},
"minBeatsPerMinute": {
"description": "Required. Minimum heart rate for this zone in beats per minute.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"HydrationLog": {
"description": "Holds information about a user logged hydration.",
"id": "HydrationLog",
"properties": {
"amountConsumed": {
"$ref": "VolumeQuantity",
"description": "Required. Amount of liquid (ex. water) consumed."
},
"interval": {
"$ref": "SessionTimeInterval",
"description": "Required. Observed interval."
}
},
"type": "object"
},
"HydrationLogRollupValue": {
"description": "Represents the result of the rollup of the hydration log data type.",
"id": "HydrationLogRollupValue",
"properties": {
"amountConsumed": {
"$ref": "VolumeQuantityRollup",
"description": "Rollup for amount consumed."
}
},
"type": "object"
},
"Identity": {
"description": "Represents details about the Google user's identity.",
"id": "Identity",
"properties": {
"healthUserId": {
"description": "Output only. The Google User Identifier in the Google Health APIs. It matches the `{user}` resource ID segment in the resource name paths, e.g. `users/{user}/dataTypes/steps`. Valid values are strings of 1-63 characters, and valid characters are lowercase and uppercase letters, numbers, and hyphens.",
"readOnly": true,
"type": "string"
},
"legacyUserId": {
"description": "Output only. The legacy Fitbit User identifier. This is the Fitbit ID used in the legacy Fitbit APIs (v1-v3). It can be referenced by clients migrating from the legacy Fitbit APIs to map their existing identifiers to the new Google user ID. It **must not** be used for any other purpose. It is not of any use for new clients using only the Google Health APIs. Valid values are strings of 1-63 characters, and valid characters are lowercase and uppercase letters, numbers, and hyphens.",
"readOnly": true,
"type": "string"
},
"name": {
"description": "Identifier. The resource name of this Identity resource. Format: `users/me/identity`",
"type": "string"
}
},
"type": "object"
},
"Interval": {
"description": "Represents a time interval, encoded as a Timestamp start (inclusive) and a Timestamp end (exclusive). The start must be less than or equal to the end. When the start equals the end, the interval is empty (matches no time). When both start and end are unspecified, the interval matches any time.",
"id": "Interval",
"properties": {
"endTime": {
"description": "Optional. Exclusive end of the interval. If specified, a Timestamp matching this interval will have to be before the end.",
"format": "google-datetime",
"type": "string"
},
"startTime": {
"description": "Optional. Inclusive start of the interval. If specified, a Timestamp matching this interval will have to be the same or after the start.",
"format": "google-datetime",
"type": "string"
}
},
"type": "object"
},
"ListDataPointsResponse": {
"description": "Response containing raw data points matching the query",
"id": "ListDataPointsResponse",
"properties": {
"dataPoints": {
"description": "Data points matching the query",
"items": {
"$ref": "DataPoint"
},
"type": "array"
},
"nextPageToken": {
"description": "Next page token, empty if the response is complete",
"type": "string"
}
},
"type": "object"
},
"MetricsSummary": {
"description": "Summary metrics for an exercise.",
"id": "MetricsSummary",
"properties": {
"activeZoneMinutes": {
"description": "Optional. Total active zone minutes for the exercise.",
"format": "int64",
"type": "string"
},
"averageHeartRateBeatsPerMinute": {
"description": "Optional. Average heart rate during the exercise.",
"format": "int64",
"type": "string"
},
"averagePaceSecondsPerMeter": {
"description": "Optional. Average pace in seconds per meter.",
"format": "double",
"type": "number"
},
"averageSpeedMillimetersPerSecond": {
"description": "Optional. Average speed in millimeters per second.",
"format": "double",
"type": "number"
},
"caloriesKcal": {
"description": "Optional. Total calories burned by the user during the exercise.",
"format": "double",
"type": "number"
},
"distanceMillimeters": {
"description": "Optional. Total distance covered by the user during the exercise.",
"format": "double",
"type": "number"
},
"elevationGainMillimeters": {
"description": "Optional. Total elevation gain during the exercise.",
"format": "double",
"type": "number"
},
"heartRateZoneDurations": {
"$ref": "TimeInHeartRateZones",
"description": "Optional. Time spent in each heart rate zone."
},
"mobilityMetrics": {
"$ref": "MobilityMetrics",
"description": "Optional. Mobility workouts specific metrics. Only present in the advanced running exercises."
},
"runVo2Max": {
"description": "Optional. Run VO2 max value for the exercise. Only present in the running exercises at the top level as in the summary of the whole exercise.",
"format": "double",
"type": "number"
},
"steps": {
"description": "Optional. Total steps taken during the exercise.",
"format": "int64",
"type": "string"
},
"totalSwimLengths": {
"description": "Optional. Number of full pool lengths completed during the exercise. Only present in the swimming exercises at the top level as in the summary of the whole exercise.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"MobilityMetrics": {
"description": "Mobility workouts specific metrics",
"id": "MobilityMetrics",
"properties": {
"avgCadenceStepsPerMinute": {
"description": "Optional. Cadence is a measure of the frequency of your foot strikes. Steps / min in real time during workout.",
"format": "double",
"type": "number"
},
"avgGroundContactTimeDuration": {
"description": "Optional. The ground contact time for a particular stride is the amount of time for which the foot was in contact with the ground on that stride",
"format": "google-duration",
"type": "string"
},
"avgStrideLengthMillimeters": {
"description": "Optional. Stride length is a measure of the distance covered by a single stride",
"format": "int64",
"type": "string"
},
"avgVerticalOscillationMillimeters": {
"description": "Optional. Distance off the ground your center of mass moves with each stride while running",
"format": "int64",
"type": "string"
},
"avgVerticalRatio": {
"description": "Optional. Vertical oscillation/stride length between [5.0, 11.0].",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"ObservationSampleTime": {
"description": "Represents a sample time of an observed data point.",
"id": "ObservationSampleTime",
"properties": {
"civilTime": {
"$ref": "CivilDateTime",
"description": "Output only. The civil time in the timezone the subject is in at the time of the observation.",
"readOnly": true
},
"physicalTime": {
"description": "Required. The time of the observation.",
"format": "google-datetime",
"type": "string"
},
"utcOffset": {
"description": "Required. The offset of the user's local time during the observation relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"ObservationTimeInterval": {
"description": "Represents a time interval of an observed data point.",
"id": "ObservationTimeInterval",
"properties": {
"civilEndTime": {
"$ref": "CivilDateTime",
"description": "Output only. Observed interval end time in civil time in the timezone the subject is in at the end of the observed interval",
"readOnly": true
},
"civilStartTime": {
"$ref": "CivilDateTime",
"description": "Output only. Observed interval start time in civil time in the timezone the subject is in at the start of the observed interval",
"readOnly": true
},
"endTime": {
"description": "Required. Observed interval end time.",
"format": "google-datetime",
"type": "string"
},
"endUtcOffset": {
"description": "Required. The offset of the user's local time at the end of the observation relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
},
"startTime": {
"description": "Required. Observed interval start time.",
"format": "google-datetime",
"type": "string"
},
"startUtcOffset": {
"description": "Required. The offset of the user's local time at the start of the observation relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"Operation": {
"description": "This resource represents a long-running operation that is the result of a network API call.",
"id": "Operation",
"properties": {
"done": {
"description": "If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.",
"type": "boolean"
},
"error": {
"$ref": "Status",
"description": "The error result of the operation in case of failure or cancellation."
},
"metadata": {
"additionalProperties": {
"description": "Properties of the object. Contains field @type with type URL.",
"type": "any"
},
"description": "Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.",
"type": "object"
},
"name": {
"description": "The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.",
"type": "string"
},
"response": {
"additionalProperties": {
"description": "Properties of the object. Contains field @type with type URL.",
"type": "any"
},
"description": "The normal, successful response of the operation. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.",
"type": "object"
}
},
"type": "object"
},
"OutOfBedSegment": {
"description": "A time interval to represent an out-of-bed segment.",
"id": "OutOfBedSegment",
"properties": {
"endTime": {
"description": "Required. Segment end time.",
"format": "google-datetime",
"type": "string"
},
"endUtcOffset": {
"description": "Required. The offset of the user's local time at the end of the segment relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
},
"startTime": {
"description": "Required. Segment tart time.",
"format": "google-datetime",
"type": "string"
},
"startUtcOffset": {
"description": "Required. The offset of the user's local time at the start of the segment relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"OxygenSaturation": {
"description": "Captures the user's instantaneous oxygen saturation percentage (SpO2).",
"id": "OxygenSaturation",
"properties": {
"percentage": {
"description": "Required. The oxygen saturation percentage. Valid values are from 0 to 100.",
"format": "double",
"type": "number"
},
"sampleTime": {
"$ref": "ObservationSampleTime",
"description": "Required. The time at which oxygen saturation was measured."
}
},
"type": "object"
},
"Profile": {
"description": "Profile details.",
"id": "Profile",
"properties": {
"age": {
"description": "Optional. The age in years based on the user's birth date. Updates to this field are currently not supported.",
"format": "int32",
"type": "integer"
},
"autoRunningStrideLengthMm": {
"description": "Output only. The automatically calculated running stride length, in millimeters. The user must consent to one of the following access scopes to access this field: - `https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly` - `https://www.googleapis.com/auth/googlehealth.activity_and_fitness`",
"format": "int32",
"readOnly": true,
"type": "integer"
},
"autoWalkingStrideLengthMm": {
"description": "Output only. The automatically calculated walking stride length, in millimeters. The user must consent to one of the following access scopes to access this field: - `https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly` - `https://www.googleapis.com/auth/googlehealth.activity_and_fitness`",
"format": "int32",
"readOnly": true,
"type": "integer"
},
"membershipStartDate": {
"$ref": "Date",
"description": "Output only. The date the user created their account. Updates to this field are currently not supported.",
"readOnly": true
},
"name": {
"description": "Identifier. The resource name of this Profile resource. Format: `users/{user}/profile` Example: `users/1234567890/profile` or `users/me/profile` The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal `me` can also be used to refer to the authenticated user.",
"type": "string"
},
"userConfiguredRunningStrideLengthMm": {
"description": "Optional. The user's user configured running stride length, in millimeters. The user must consent to one of the following access scopes to access this field: - `https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly` - `https://www.googleapis.com/auth/googlehealth.activity_and_fitness`",
"format": "int32",
"type": "integer"
},
"userConfiguredWalkingStrideLengthMm": {
"description": "Optional. The user's user configured walking stride length, in millimeters. The user must consent to one of the following access scopes to access this field: - `https://www.googleapis.com/auth/googlehealth.activity_and_fitness.readonly` - `https://www.googleapis.com/auth/googlehealth.activity_and_fitness`",
"format": "int32",
"type": "integer"
}
},
"type": "object"
},
"ReconcileDataPointsResponse": {
"description": "Response containing the list of reconciled DataPoints.",
"id": "ReconcileDataPointsResponse",
"properties": {
"dataPoints": {
"description": "Data points matching the query",
"items": {
"$ref": "ReconciledDataPoint"
},
"type": "array"
},
"nextPageToken": {
"description": "Next page token, empty if the response is complete",
"type": "string"
}
},
"type": "object"
},
"ReconciledDataPoint": {
"description": "A reconciled computed or recorded metric.",
"id": "ReconciledDataPoint",
"properties": {
"activeMinutes": {
"$ref": "ActiveMinutes",
"description": "Data for points in the `active-minutes` interval data type collection."
},
"activeZoneMinutes": {
"$ref": "ActiveZoneMinutes",
"description": "Data for points in the `active-zone-minutes` interval data type collection, measured in minutes."
},
"activityLevel": {
"$ref": "ActivityLevel",
"description": "Data for points in the `activity-level` daily data type collection."
},
"altitude": {
"$ref": "Altitude",
"description": "Data for points in the `altitude` interval data type collection."
},
"bodyFat": {
"$ref": "BodyFat",
"description": "Data for points in the `body-fat` sample data type collection."
},
"dailyHeartRateVariability": {
"$ref": "DailyHeartRateVariability",
"description": "Data for points in the `daily-heart-rate-variability` daily data type collection."
},
"dailyHeartRateZones": {
"$ref": "DailyHeartRateZones",
"description": "Data for points in the `daily-heart-rate-zones` daily data type collection."
},
"dailyOxygenSaturation": {
"$ref": "DailyOxygenSaturation",
"description": "Data for points in the `daily-oxygen-saturation` daily data type collection."
},
"dailyRespiratoryRate": {
"$ref": "DailyRespiratoryRate",
"description": "Data for points in the `daily-respiratory-rate` daily data type collection."
},
"dailyRestingHeartRate": {
"$ref": "DailyRestingHeartRate",
"description": "Data for points in the `daily-resting-heart-rate` daily data type collection."
},
"dailySleepTemperatureDerivations": {
"$ref": "DailySleepTemperatureDerivations",
"description": "Data for points in the `daily-sleep-temperature-derivations` daily data type collection."
},
"dailyVo2Max": {
"$ref": "DailyVO2Max",
"description": "Data for points in the `daily-vo2-max` daily data type collection."
},
"dataPointName": {
"description": "Identifier. Data point name, only supported for the subset of identifiable data types. For the majority of the data types, individual data points do not need to be identified and this field would be empty. Format: `users/{user}/dataTypes/{data_type}/dataPoints/{data_point}` Example: `users/abcd1234/dataTypes/sleep/dataPoints/a1b2c3d4-e5f6-7890-1234-567890abcdef` The `{user}` ID is a system-generated identifier, as described in Identity.health_user_id. The `{data_type}` ID corresponds to the kebab-case version of the field names in the DataPoint data union field, e.g. `total-calories` for the `total_calories` field. The `{data_point}` ID can be client-provided or system-generated. If client-provided, it must be a string of 4-63 characters, containing only lowercase letters, numbers, and hyphens.",
"type": "string"
},
"distance": {
"$ref": "Distance",
"description": "Data for points in the `distance` interval data type collection."
},
"exercise": {
"$ref": "Exercise",
"description": "Data for points in the `exercise` session data type collection."
},
"floors": {
"$ref": "Floors",
"description": "Data for points in the `floors` interval data type collection."
},
"heartRate": {
"$ref": "HeartRate",
"description": "Data for points in the `heart-rate` sample data type collection."
},
"heartRateVariability": {
"$ref": "HeartRateVariability",
"description": "Data for points in the `heart-rate-variability` sample data type collection."
},
"hydrationLog": {
"$ref": "HydrationLog",
"description": "Data for points in the `hydration-log` session data type collection."
},
"oxygenSaturation": {
"$ref": "OxygenSaturation",
"description": "Data for points in the `oxygen-saturation` sample data type collection."
},
"respiratoryRateSleepSummary": {
"$ref": "RespiratoryRateSleepSummary",
"description": "Data for points in the `respiratory-rate-sleep-summary` sample data type collection."
},
"runVo2Max": {
"$ref": "RunVO2Max",
"description": "Data for points in the `run-vo2-max` sample data type collection."
},
"sedentaryPeriod": {
"$ref": "SedentaryPeriod",
"description": "Data for points in the `sedentary-period` interval data type collection."
},
"sleep": {
"$ref": "Sleep",
"description": "Data for points in the `sleep` session data type collection."
},
"steps": {
"$ref": "Steps",
"description": "Data for points in the `steps` interval data type collection."
},
"timeInHeartRateZone": {
"$ref": "TimeInHeartRateZone",
"description": "Data for points in the `time-in-heart-rate-zone` interval data type collection."
},
"vo2Max": {
"$ref": "VO2Max",
"description": "Data for points in the `vo2-max` sample data type collection."
},
"weight": {
"$ref": "Weight",
"description": "Data for points in the `weight` sample data type collection."
}
},
"type": "object"
},
"RespiratoryRateSleepSummary": {
"description": "Records respiratory rate details during sleep. Can have multiple per day if the user sleeps multiple times.",
"id": "RespiratoryRateSleepSummary",
"properties": {
"deepSleepStats": {
"$ref": "RespiratoryRateSleepSummaryStatistics",
"description": "Optional. Respiratory rate statistics for deep sleep."
},
"fullSleepStats": {
"$ref": "RespiratoryRateSleepSummaryStatistics",
"description": "Required. Full respiratory rate statistics."
},
"lightSleepStats": {
"$ref": "RespiratoryRateSleepSummaryStatistics",
"description": "Optional. Respiratory rate statistics for light sleep."
},
"remSleepStats": {
"$ref": "RespiratoryRateSleepSummaryStatistics",
"description": "Optional. Respiratory rate statistics for REM sleep."
},
"sampleTime": {
"$ref": "ObservationSampleTime",
"description": "Required. The time at which respiratory rate was measured."
}
},
"type": "object"
},
"RespiratoryRateSleepSummaryStatistics": {
"description": "Respiratory rate statistics for a given sleep stage.",
"id": "RespiratoryRateSleepSummaryStatistics",
"properties": {
"breathsPerMinute": {
"description": "Required. Average breaths per minute.",
"format": "double",
"type": "number"
},
"signalToNoise": {
"description": "Optional. How trustworthy the data is for the computation.",
"format": "double",
"type": "number"
},
"standardDeviation": {
"description": "Optional. Standard deviation of the respiratory rate during sleep.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"RestingHeartRatePersonalRangeRollupValue": {
"description": "Represents the rollup value for the daily resting heart rate data type.",
"id": "RestingHeartRatePersonalRangeRollupValue",
"properties": {
"beatsPerMinuteMax": {
"description": "The upper bound of the user's daily resting heart rate personal range.",
"format": "double",
"type": "number"
},
"beatsPerMinuteMin": {
"description": "The lower bound of the user's daily resting heart rate personal range.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"RollUpDataPointsRequest": {
"description": "Request to roll up data points by physical time intervals.",
"id": "RollUpDataPointsRequest",
"properties": {
"dataSourceFamily": {
"description": "Optional. The data source family name to roll up. If empty, data points from all available data sources will be rolled up. Format: `users/me/dataSourceFamilies/{data_source_family}` The supported values are: - `users/me/dataSourceFamilies/all-sources` - default value - `users/me/dataSourceFamilies/google-wearables` - tracker devices - `users/me/dataSourceFamilies/google-sources` - Google first party sources",
"type": "string"
},
"pageSize": {
"description": "Optional. The maximum number of data points to return. If unspecified, at most 1440 data points will be returned. The maximum page size is 10000; values above that will be truncated accordingly.",
"format": "int32",
"type": "integer"
},
"pageToken": {
"description": "Optional. The next_page_token from a previous request, if any. All other request fields need to be the same as in the initial request when the page token is specified.",
"type": "string"
},
"range": {
"$ref": "Interval",
"description": "Required. Closed-open range of data points that will be rolled up. The maximum range for `calories-in-heart-rate-zone`, `heart-rate`, `active-minutes` and `total-calories` is 14 days. The maximum range for all other data types is 90 days."
},
"windowSize": {
"description": "Required. The size of the time window to group data points into before applying the aggregation functions.",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"RollUpDataPointsResponse": {
"description": "Response containing the list of rolled up data points.",
"id": "RollUpDataPointsResponse",
"properties": {
"nextPageToken": {
"description": "A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.",
"type": "string"
},
"rollupDataPoints": {
"description": "Values for each aggregation time window.",
"items": {
"$ref": "RollupDataPoint"
},
"type": "array"
}
},
"type": "object"
},
"RollupDataPoint": {
"description": "Value of a rollup for a single physical time interval (aggregation window)",
"id": "RollupDataPoint",
"properties": {
"activeMinutes": {
"$ref": "ActiveMinutesRollupValue",
"description": "Returned by default when rolling up data points from the `active-minutes` data type, or when requested explicitly using the `active-minutes` rollup type identifier."
},
"activeZoneMinutes": {
"$ref": "ActiveZoneMinutesRollupValue",
"description": "Returned by default when rolling up data points from the `active-zone-minutes` data type, or when requested explicitly using the `active-zone-minutes` rollup type identifier."
},
"activityLevel": {
"$ref": "ActivityLevelRollupValue",
"description": "Returned by default when rolling up data points from the `activity-level` data type, or when requested explicitly using the `activity-level` rollup type identifier."
},
"altitude": {
"$ref": "AltitudeRollupValue",
"description": "Returned by default when rolling up data points from the `altitude` data type, or when requested explicitly using the `altitude` rollup type identifier."
},
"bodyFat": {
"$ref": "BodyFatRollupValue",
"description": "Returned by default when rolling up data points from the `body-fat` data type, or when requested explicitly using the `body-fat` rollup type identifier."
},
"caloriesInHeartRateZone": {
"$ref": "CaloriesInHeartRateZoneRollupValue",
"description": "Returned by default when rolling up data points from the `calories-in-heart-rate-zone` data type, or when requested explicitly using the `calories-in-heart-rate-zone` rollup type identifier."
},
"distance": {
"$ref": "DistanceRollupValue",
"description": "Returned by default when rolling up data points from the `distance` data type, or when requested explicitly using the `distance` rollup type identifier."
},
"endTime": {
"description": "End time of the window this value aggregates over",
"format": "google-datetime",
"type": "string"
},
"floors": {
"$ref": "FloorsRollupValue",
"description": "Returned by default when rolling up data points from the `floors` data type, or when requested explicitly using the `floors` rollup type identifier."
},
"heartRate": {
"$ref": "HeartRateRollupValue",
"description": "Returned by default when rolling up data points from the `heart-rate` data type, or when requested explicitly using the `heart-rate` rollup type identifier."
},
"hydrationLog": {
"$ref": "HydrationLogRollupValue",
"description": "Returned by default when rolling up data points from the `hydration-log` data type, or when requested explicitly using the `hydration-log` rollup type identifier."
},
"runVo2Max": {
"$ref": "RunVO2MaxRollupValue",
"description": "Returned by default when rolling up data points from the `run-vo2-max` data type, or when requested explicitly using the `run-vo2-max` rollup type identifier."
},
"sedentaryPeriod": {
"$ref": "SedentaryPeriodRollupValue",
"description": "Returned by default when rolling up data points from the `sedentary-period` data type, or when requested explicitly using the `sedentary-period` rollup type identifier."
},
"startTime": {
"description": "Start time of the window this value aggregates over",
"format": "google-datetime",
"type": "string"
},
"steps": {
"$ref": "StepsRollupValue",
"description": "Returned by default when rolling up data points from the `steps` data type, or when requested explicitly using the `steps` rollup type identifier."
},
"timeInHeartRateZone": {
"$ref": "TimeInHeartRateZoneRollupValue",
"description": "Returned by default when rolling up data points from the `time-in-heart-rate-zone` data type, or when requested explicitly using the `time-in-heart-rate-zone` rollup type identifier."
},
"totalCalories": {
"$ref": "TotalCaloriesRollupValue",
"description": "Returned by default when rolling up data points from the `total-calories` data type, or when requested explicitly using the `total-calories` rollup type identifier."
},
"weight": {
"$ref": "WeightRollupValue",
"description": "Returned by default when rolling up data points from the `weight` data type, or when requested explicitly using the `weight` rollup type identifier."
}
},
"type": "object"
},
"RunVO2Max": {
"description": "VO2 max value calculated based on the user's running activity. Value stored in ml/kg/min.",
"id": "RunVO2Max",
"properties": {
"runVo2Max": {
"description": "Required. Run VO2 max value in ml/kg/min.",
"format": "double",
"type": "number"
},
"sampleTime": {
"$ref": "ObservationSampleTime",
"description": "Required. The time at which the metric was measured."
}
},
"type": "object"
},
"RunVO2MaxRollupValue": {
"description": "Represents the result of the rollup of the user's daily heart rate variability personal range.",
"id": "RunVO2MaxRollupValue",
"properties": {
"rateAvg": {
"description": "Average value of run VO2 max in the interval.",
"format": "double",
"type": "number"
},
"rateMax": {
"description": "Maximum value of run VO2 max in the interval.",
"format": "double",
"type": "number"
},
"rateMin": {
"description": "Minimum value of run VO2 max in the interval..",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"SedentaryPeriod": {
"description": "SedentaryPeriod SedentaryPeriod data represents the periods of time that the user was sedentary (i.e. not moving while wearing the device).",
"id": "SedentaryPeriod",
"properties": {
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval."
}
},
"type": "object"
},
"SedentaryPeriodRollupValue": {
"description": "Represents the result of the rollup of the user's sedentary periods.",
"id": "SedentaryPeriodRollupValue",
"properties": {
"durationSum": {
"description": "The total time user spent sedentary during the interval.",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"SessionTimeInterval": {
"description": "Represents a time interval of session data point, which bundles multiple observed metrics together.",
"id": "SessionTimeInterval",
"properties": {
"civilEndTime": {
"$ref": "CivilDateTime",
"description": "Output only. Session end time in civil time in the timezone the subject is in at the end of the session.",
"readOnly": true
},
"civilStartTime": {
"$ref": "CivilDateTime",
"description": "Output only. Session start time in civil time in the timezone the subject is in at the start of the session.",
"readOnly": true
},
"endTime": {
"description": "Required. The end time of the observed session.",
"format": "google-datetime",
"type": "string"
},
"endUtcOffset": {
"description": "Required. The offset of the user's local time at the end of the session relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
},
"startTime": {
"description": "Required. The start time of the observed session.",
"format": "google-datetime",
"type": "string"
},
"startUtcOffset": {
"description": "Required. The offset of the user's local time at the start of the session relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"Settings": {
"description": "Settings details.",
"id": "Settings",
"properties": {
"autoStrideEnabled": {
"description": "Optional. True if the user's stride length is determined automatically. Updates to this field are currently not supported.",
"type": "boolean"
},
"distanceUnit": {
"description": "Optional. The measurement unit defined in the user's account settings. Updates to this field are currently not supported.",
"enum": [
"DISTANCE_UNIT_UNSPECIFIED",
"DISTANCE_UNIT_MILES",
"DISTANCE_UNIT_KILOMETERS"
],
"enumDescriptions": [
"Distance unit is not specified.",
"Distance unit is miles.",
"Distance unit is kilometers."
],
"type": "string"
},
"glucoseUnit": {
"description": "Optional. The measurement unit defined in the user's account settings.",
"enum": [
"GLUCOSE_UNIT_UNSPECIFIED",
"GLUCOSE_UNIT_MG_DL",
"GLUCOSE_UNIT_MMOL_L"
],
"enumDescriptions": [
"Glucose unit is not specified.",
"Glucose unit is mg/dL.",
"Glucose unit is mmol/l."
],
"type": "string"
},
"heightUnit": {
"description": "Optional. The measurement unit defined in the user's account settings.",
"enum": [
"HEIGHT_UNIT_UNSPECIFIED",
"HEIGHT_UNIT_INCHES",
"HEIGHT_UNIT_CENTIMETERS"
],
"enumDescriptions": [
"Height unit is not specified.",
"Height unit is inches.",
"Height unit is cm."
],
"type": "string"
},
"languageLocale": {
"description": "Optional. The locale defined in the user's account settings. Updates to this field are currently not supported.",
"type": "string"
},
"name": {
"description": "Identifier. The resource name of this Settings resource. Format: `users/{user}/settings` Example: `users/1234567890/settings` or `users/me/settings` The {user} ID is a system-generated Google Health API user ID, a string of 1-63 characters consisting of lowercase and uppercase letters, numbers, and hyphens. The literal `me` can also be used to refer to the authenticated user.",
"type": "string"
},
"strideLengthRunningType": {
"description": "Optional. The stride length type defined in the user's account settings for running. Updates to this field are currently not supported.",
"enum": [
"STRIDE_LENGTH_TYPE_UNSPECIFIED",
"STRIDE_LENGTH_TYPE_DEFAULT",
"STRIDE_LENGTH_TYPE_MANUAL",
"STRIDE_LENGTH_TYPE_AUTO"
],
"enumDescriptions": [
"Stride length type is not specified.",
"Stride length type is computed based on the user's gender and height.",
"Stride length type is manually set by the user.",
"Stride length type is determined automatically."
],
"type": "string"
},
"strideLengthWalkingType": {
"description": "Optional. The stride length type defined in the user's account settings for walking. Updates to this field are currently not supported.",
"enum": [
"STRIDE_LENGTH_TYPE_UNSPECIFIED",
"STRIDE_LENGTH_TYPE_DEFAULT",
"STRIDE_LENGTH_TYPE_MANUAL",
"STRIDE_LENGTH_TYPE_AUTO"
],
"enumDescriptions": [
"Stride length type is not specified.",
"Stride length type is computed based on the user's gender and height.",
"Stride length type is manually set by the user.",
"Stride length type is determined automatically."
],
"type": "string"
},
"swimUnit": {
"description": "Optional. The measurement unit defined in the user's account settings.",
"enum": [
"SWIM_UNIT_UNSPECIFIED",
"SWIM_UNIT_METERS",
"SWIM_UNIT_YARDS"
],
"enumDescriptions": [
"Swim unit is not specified.",
"Swim unit is meters.",
"Swim unit is yards."
],
"type": "string"
},
"temperatureUnit": {
"description": "Optional. The measurement unit defined in the user's account settings.",
"enum": [
"TEMPERATURE_UNIT_UNSPECIFIED",
"TEMPERATURE_UNIT_CELSIUS",
"TEMPERATURE_UNIT_FAHRENHEIT"
],
"enumDescriptions": [
"Temperature unit is not specified.",
"Temperature unit is Celsius.",
"Temperature unit is Fahrenheit."
],
"type": "string"
},
"timeZone": {
"description": "Optional. The timezone defined in the user's account settings. This follows the IANA [Time Zone Database](https://www.iana.org/time-zones). Updates to this field are currently not supported.",
"type": "string"
},
"utcOffset": {
"description": "Optional. The user's timezone offset relative to UTC. Updates to this field are currently not supported.",
"format": "google-duration",
"type": "string"
},
"waterUnit": {
"description": "Optional. The measurement unit defined in the user's account settings.",
"enum": [
"WATER_UNIT_UNSPECIFIED",
"WATER_UNIT_ML",
"WATER_UNIT_FL_OZ",
"WATER_UNIT_CUP"
],
"enumDescriptions": [
"Water unit is not specified.",
"Water unit is milliliters.",
"Water unit is fluid ounces.",
"Water unit is cups."
],
"type": "string"
},
"weightUnit": {
"description": "Optional. The measurement unit defined in the user's account settings.",
"enum": [
"WEIGHT_UNIT_UNSPECIFIED",
"WEIGHT_UNIT_POUNDS",
"WEIGHT_UNIT_STONE",
"WEIGHT_UNIT_KILOGRAMS"
],
"enumDescriptions": [
"Weight unit is not specified.",
"Weight unit is pounds.",
"Weight unit is stones.",
"Weight unit is kilograms."
],
"type": "string"
}
},
"type": "object"
},
"Sleep": {
"description": "A sleep session possibly including stages.",
"id": "Sleep",
"properties": {
"createTime": {
"description": "Output only. Creation time of this sleep observation.",
"format": "google-datetime",
"readOnly": true,
"type": "string"
},
"interval": {
"$ref": "SessionTimeInterval",
"description": "Required. Observed sleep interval."
},
"metadata": {
"$ref": "SleepMetadata",
"description": "Optional. Sleep metadata: processing, main, manually edited, stages status."
},
"outOfBedSegments": {
"description": "Optional. \u201cOut of bed\u201d segments that can overlap with sleep stages.",
"items": {
"$ref": "OutOfBedSegment"
},
"type": "array"
},
"stages": {
"description": "Optional. List of non-overlapping contiguous sleep stage segments that cover the sleep period.",
"items": {
"$ref": "SleepStage"
},
"type": "array"
},
"summary": {
"$ref": "SleepSummary",
"description": "Output only. Sleep summary: metrics and stages summary.",
"readOnly": true
},
"type": {
"description": "Optional. SleepType: classic or stages.",
"enum": [
"SLEEP_TYPE_UNSPECIFIED",
"CLASSIC",
"STAGES"
],
"enumDescriptions": [
"Sleep type is unspecified.",
"Classic sleep is a sleep with 3 stages types: AWAKE, RESTLESS and ASLEEP.",
"On top of \"classic\" sleep stages an additional processing pass can calculate stages more precisely, overwriting the prior stages with AWAKE, LIGHT, REM and DEEP."
],
"type": "string"
},
"updateTime": {
"description": "Output only. Last update time of this sleep observation.",
"format": "google-datetime",
"readOnly": true,
"type": "string"
}
},
"type": "object"
},
"SleepMetadata": {
"description": "Additional information about how the sleep was processed.",
"id": "SleepMetadata",
"properties": {
"externalId": {
"description": "Optional. Sleep identifier relevant in the context of the data source.",
"type": "string"
},
"manuallyEdited": {
"description": "Output only. Some sleeps autodetected by algorithms can be manually edited by users.",
"readOnly": true,
"type": "boolean"
},
"nap": {
"description": "Output only. Naps are sleeps without stages and relatively short durations.",
"readOnly": true,
"type": "boolean"
},
"processed": {
"description": "Output only. Sleep and sleep stages algorithms finished processing.",
"readOnly": true,
"type": "boolean"
},
"stagesStatus": {
"description": "Output only. Sleep stages algorithm processing status.",
"enum": [
"STAGES_STATE_UNSPECIFIED",
"REJECTED_COVERAGE",
"REJECTED_MAX_GAP",
"REJECTED_START_GAP",
"REJECTED_END_GAP",
"REJECTED_NAP",
"REJECTED_SERVER",
"TIMEOUT",
"SUCCEEDED",
"PROCESSING_INTERNAL_ERROR"
],
"enumDescriptions": [
"Output only. Sleep stages status is unspecified.",
"Output only. Sleep stages cannot be computed due to low RR coverage.",
"Output only. Sleep stages cannot be computed due to the large middle gap (2h).",
"Output only. Sleep stages cannot be computed due to the large start gap (1h).",
"Output only. Sleep stages cannot be computed due to the large end gap (1h).",
"Output only. Sleep stages cannot be computed because the sleep log is a nap (has < 3h duration).",
"Output only. Sleep stages cannot be computed because input data is not available (PPGV2, wake magnitude, etc).",
"Output only. Sleep stages cannot be computed due to server timeout.",
"Output only. Sleep stages successfully computed.",
"Output only. Sleep stages cannot be computed due to server internal error."
],
"readOnly": true,
"type": "string"
}
},
"type": "object"
},
"SleepStage": {
"description": "Sleep stage segment.",
"id": "SleepStage",
"properties": {
"createTime": {
"description": "Output only. Creation time of this sleep stages segment.",
"format": "google-datetime",
"readOnly": true,
"type": "string"
},
"endTime": {
"description": "Required. Sleep stage end time.",
"format": "google-datetime",
"type": "string"
},
"endUtcOffset": {
"description": "Required. The offset of the user's local time at the end of the sleep stage relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
},
"startTime": {
"description": "Required. Sleep stage start time.",
"format": "google-datetime",
"type": "string"
},
"startUtcOffset": {
"description": "Required. The offset of the user's local time at the start of the sleep stage relative to the Coordinated Universal Time (UTC).",
"format": "google-duration",
"type": "string"
},
"type": {
"description": "Required. Sleep stage type: AWAKE, DEEP, REM, LIGHT etc.",
"enum": [
"SLEEP_STAGE_TYPE_UNSPECIFIED",
"AWAKE",
"LIGHT",
"DEEP",
"REM",
"ASLEEP",
"RESTLESS"
],
"enumDescriptions": [
"The default unset value.",
"Sleep stage AWAKE.",
"Sleep stage LIGHT.",
"Sleep stage DEEP.",
"Sleep stage REM.",
"Sleep stage ASLEEP.",
"Sleep stage RESTLESS."
],
"type": "string"
},
"updateTime": {
"description": "Output only. Last update time of this sleep stages segment.",
"format": "google-datetime",
"readOnly": true,
"type": "string"
}
},
"type": "object"
},
"SleepSummary": {
"description": " Sleep summary: metrics and stages summary.",
"id": "SleepSummary",
"properties": {
"minutesAfterWakeUp": {
"description": "Output only. Minutes after wake up calculated by restlessness algorithm.",
"format": "int64",
"readOnly": true,
"type": "string"
},
"minutesAsleep": {
"description": "Output only. Total number of minutes asleep. For classic sleep it is the sum of ASLEEP stages (excluding AWAKE and RESTLESS). For \"stages\" sleep it is the sum of LIGHT, REM and DEEP stages (excluding AWAKE).",
"format": "int64",
"readOnly": true,
"type": "string"
},
"minutesAwake": {
"description": "Output only. Total number of minutes awake. It is a sum of all AWAKE stages.",
"format": "int64",
"readOnly": true,
"type": "string"
},
"minutesInSleepPeriod": {
"description": "Output only. Delta between wake time and bedtime. It is the sum of all stages.",
"format": "int64",
"readOnly": true,
"type": "string"
},
"minutesToFallAsleep": {
"description": "Output only. Minutes to fall asleep calculated by restlessness algorithm.",
"format": "int64",
"readOnly": true,
"type": "string"
},
"stagesSummary": {
"description": "Output only. List of summaries (total duration and segment count) per each sleep stage type.",
"items": {
"$ref": "StageSummary"
},
"readOnly": true,
"type": "array"
}
},
"type": "object"
},
"SplitSummary": {
"description": "Represents splits or laps recorded within an exercise. Lap events partition a workout into segments based on criteria like distance, time, or calories.",
"id": "SplitSummary",
"properties": {
"activeDuration": {
"description": "Output only. Lap time excluding the pauses.",
"format": "google-duration",
"readOnly": true,
"type": "string"
},
"endTime": {
"description": "Required. Lap end time",
"format": "google-datetime",
"type": "string"
},
"endUtcOffset": {
"description": "Required. Lap end time offset from UTC",
"format": "google-duration",
"type": "string"
},
"metricsSummary": {
"$ref": "MetricsSummary",
"description": "Required. Summary metrics for this split."
},
"splitType": {
"description": "Required. Method used to split the exercise laps. Users may manually mark the lap as complete even if the tracking is automatic.",
"enum": [
"SPLIT_TYPE_UNSPECIFIED",
"MANUAL",
"DURATION",
"DISTANCE",
"CALORIES"
],
"enumDescriptions": [
"Split type is unspecified.",
"Manual split.",
"Split by duration.",
"Split by distance.",
"Split by calories."
],
"type": "string"
},
"startTime": {
"description": "Required. Lap start time",
"format": "google-datetime",
"type": "string"
},
"startUtcOffset": {
"description": "Required. Lap start time offset from UTC",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"StageSummary": {
"description": "Total duration and segment count for a stage.",
"id": "StageSummary",
"properties": {
"count": {
"description": "Output only. Number of sleep stages segments.",
"format": "int64",
"readOnly": true,
"type": "string"
},
"minutes": {
"description": "Output only. Total duration in minutes of a sleep stage.",
"format": "int64",
"readOnly": true,
"type": "string"
},
"type": {
"description": "Output only. Sleep stage type: AWAKE, DEEP, REM, LIGHT etc.",
"enum": [
"SLEEP_STAGE_TYPE_UNSPECIFIED",
"AWAKE",
"LIGHT",
"DEEP",
"REM",
"ASLEEP",
"RESTLESS"
],
"enumDescriptions": [
"The default unset value.",
"Sleep stage AWAKE.",
"Sleep stage LIGHT.",
"Sleep stage DEEP.",
"Sleep stage REM.",
"Sleep stage ASLEEP.",
"Sleep stage RESTLESS."
],
"readOnly": true,
"type": "string"
}
},
"type": "object"
},
"Status": {
"description": "The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors).",
"id": "Status",
"properties": {
"code": {
"description": "The status code, which should be an enum value of google.rpc.Code.",
"format": "int32",
"type": "integer"
},
"details": {
"description": "A list of messages that carry the error details. There is a common set of message types for APIs to use.",
"items": {
"additionalProperties": {
"description": "Properties of the object. Contains field @type with type URL.",
"type": "any"
},
"type": "object"
},
"type": "array"
},
"message": {
"description": "A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.",
"type": "string"
}
},
"type": "object"
},
"Steps": {
"description": "Step count over the time interval.",
"id": "Steps",
"properties": {
"count": {
"description": "Required. Number of steps in the recorded interval.",
"format": "int64",
"type": "string"
},
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval."
}
},
"type": "object"
},
"StepsRollupValue": {
"description": "Represents the result of the rollup of the steps data type.",
"id": "StepsRollupValue",
"properties": {
"countSum": {
"description": "Total number of steps in the interval.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"TimeInHeartRateZone": {
"description": "Time in heart rate zone record. It's an interval spent in specific heart rate zone.",
"id": "TimeInHeartRateZone",
"properties": {
"heartRateZoneType": {
"description": "Required. Heart rate zone type.",
"enum": [
"HEART_RATE_ZONE_TYPE_UNSPECIFIED",
"LIGHT",
"MODERATE",
"VIGOROUS",
"PEAK"
],
"enumDescriptions": [
"Unspecified heart rate zone.",
"The light heart rate zone.",
"The moderate heart rate zone.",
"The vigorous heart rate zone.",
"The peak heart rate zone."
],
"type": "string"
},
"interval": {
"$ref": "ObservationTimeInterval",
"description": "Required. Observed interval."
}
},
"type": "object"
},
"TimeInHeartRateZoneRollupValue": {
"description": "Represents the result of the rollup of the time in heart rate zone data type.",
"id": "TimeInHeartRateZoneRollupValue",
"properties": {
"timeInHeartRateZones": {
"description": "List of time spent in each heart rate zone.",
"items": {
"$ref": "TimeInHeartRateZoneValue"
},
"type": "array"
}
},
"type": "object"
},
"TimeInHeartRateZoneValue": {
"description": "Represents the total time spent in a specific heart rate zone.",
"id": "TimeInHeartRateZoneValue",
"properties": {
"duration": {
"description": "The total time spent in the specified heart rate zone.",
"format": "google-duration",
"type": "string"
},
"heartRateZone": {
"description": "The heart rate zone.",
"enum": [
"HEART_RATE_ZONE_TYPE_UNSPECIFIED",
"LIGHT",
"MODERATE",
"VIGOROUS",
"PEAK"
],
"enumDescriptions": [
"Unspecified heart rate zone.",
"The light heart rate zone.",
"The moderate heart rate zone.",
"The vigorous heart rate zone.",
"The peak heart rate zone."
],
"type": "string"
}
},
"type": "object"
},
"TimeInHeartRateZones": {
"description": "Time spent in each heart rate zone.",
"id": "TimeInHeartRateZones",
"properties": {
"lightTime": {
"description": "Optional. Time spent in light heart rate zone.",
"format": "google-duration",
"type": "string"
},
"moderateTime": {
"description": "Optional. Time spent in moderate heart rate zone.",
"format": "google-duration",
"type": "string"
},
"peakTime": {
"description": "Optional. Time spent in peak heart rate zone.",
"format": "google-duration",
"type": "string"
},
"vigorousTime": {
"description": "Optional. Time spent in vigorous heart rate zone.",
"format": "google-duration",
"type": "string"
}
},
"type": "object"
},
"TimeOfDay": {
"description": "Represents a time of day. The date and time zone are either not significant or are specified elsewhere. An API may choose to allow leap seconds. Related types are google.type.Date and `google.protobuf.Timestamp`.",
"id": "TimeOfDay",
"properties": {
"hours": {
"description": "Hours of a day in 24 hour format. Must be greater than or equal to 0 and typically must be less than or equal to 23. An API may choose to allow the value \"24:00:00\" for scenarios like business closing time.",
"format": "int32",
"type": "integer"
},
"minutes": {
"description": "Minutes of an hour. Must be greater than or equal to 0 and less than or equal to 59.",
"format": "int32",
"type": "integer"
},
"nanos": {
"description": "Fractions of seconds, in nanoseconds. Must be greater than or equal to 0 and less than or equal to 999,999,999.",
"format": "int32",
"type": "integer"
},
"seconds": {
"description": "Seconds of a minute. Must be greater than or equal to 0 and typically must be less than or equal to 59. An API may allow the value 60 if it allows leap-seconds.",
"format": "int32",
"type": "integer"
}
},
"type": "object"
},
"TimeZone": {
"description": "Represents a time zone from the [IANA Time Zone Database](https://www.iana.org/time-zones).",
"id": "TimeZone",
"properties": {
"id": {
"description": "IANA Time Zone Database time zone. For example \"America/New_York\".",
"type": "string"
},
"version": {
"description": "Optional. IANA Time Zone Database version number. For example \"2019a\".",
"type": "string"
}
},
"type": "object"
},
"TotalCaloriesRollupValue": {
"description": "Represents the result of the rollup of the user's total calories.",
"id": "TotalCaloriesRollupValue",
"properties": {
"kcalSum": {
"description": "Sum of the total calories in kilocalories.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"VO2Max": {
"description": "VO2 max measurement.",
"id": "VO2Max",
"properties": {
"measurementMethod": {
"description": "Optional. The method used to measure the VO2 max value.",
"enum": [
"MEASUREMENT_METHOD_UNSPECIFIED",
"FITBIT_RUN",
"GOOGLE_DEMOGRAPHIC",
"COOPER_TEST",
"HEART_RATE_RATIO",
"METABOLIC_CART",
"MULTISTAGE_FITNESS_TEST",
"ROCKPORT_FITNESS_TEST",
"MAX_EXERCISE",
"PREDICTION_SUB_MAX_EXERCISE",
"PREDICTION_NON_EXERCISE",
"OTHER"
],
"enumDescriptions": [
"Unspecified measurement method.",
"Fitbit specific, measures VO2 max rate during a run.",
"Google specific, measures VO2 max rate for a user based on their demographic data.",
"Run as far as possible for 12 minutes. Distance correlated with age and gender translates to a VO2 max value.",
"Maximum heart rate divided by the resting heart rate, with a multiplier applied. Does not require any exercise.",
"Measured by a medical device called metabolic cart.",
"Continuous 20m back-and-forth runs with increasing difficulty, until exhaustion.",
"Measured using walking exercise.",
"Healthkit specific, measures VO2 max rate by monitoring exercise to the user\u2019s physical limit. Similar to COOPER_TEST or MULTISTAGE_FITNESS_TEST.",
"Healthkit specific, estimates VO2 max rate based on low-intensity exercise. Similar to ROCKPORT_FITNESS_TEST.",
"Healthkit specific, estimates VO2 max rate without any exercise. Similar to HEART_RATE_RATIO.",
"Use when the method is not covered in this enum."
],
"type": "string"
},
"sampleTime": {
"$ref": "ObservationSampleTime",
"description": "Required. The time at which VO2 max was measured."
},
"vo2Max": {
"description": "Required. VO2 max value measured as in ml consumed oxygen / kg of body weight / min.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"VolumeQuantity": {
"description": "Represents the volume quantity.",
"id": "VolumeQuantity",
"properties": {
"milliliters": {
"description": "Required. Value representing the volume in milliliters.",
"format": "double",
"type": "number"
},
"userProvidedUnit": {
"description": "Optional. Value representing the user provided unit.",
"enum": [
"VOLUME_UNIT_UNSPECIFIED",
"CUP_IMPERIAL",
"CUP_US",
"FLUID_OUNCE_IMPERIAL",
"FLUID_OUNCE_US",
"LITER",
"MILLILITER",
"PINT_IMPERIAL",
"PINT_US"
],
"enumDescriptions": [
"Unspecified volume unit.",
"Cup (imperial)",
"Cup (US)",
"Fluid ounce (imperial)",
"Fluid ounce (US)",
"Liter",
"Milliliter",
"Pint (imperial)",
"Pint (US)"
],
"type": "string"
}
},
"type": "object"
},
"VolumeQuantityRollup": {
"description": "Rollup for volume quantity.",
"id": "VolumeQuantityRollup",
"properties": {
"millilitersSum": {
"description": "Required. The sum of volume in milliliters.",
"format": "double",
"type": "number"
},
"userProvidedUnitLast": {
"description": "Optional. The user provided unit on the last element.",
"enum": [
"VOLUME_UNIT_UNSPECIFIED",
"CUP_IMPERIAL",
"CUP_US",
"FLUID_OUNCE_IMPERIAL",
"FLUID_OUNCE_US",
"LITER",
"MILLILITER",
"PINT_IMPERIAL",
"PINT_US"
],
"enumDescriptions": [
"Unspecified volume unit.",
"Cup (imperial)",
"Cup (US)",
"Fluid ounce (imperial)",
"Fluid ounce (US)",
"Liter",
"Milliliter",
"Pint (imperial)",
"Pint (US)"
],
"type": "string"
}
},
"type": "object"
},
"Weight": {
"description": "Body weight measurement.",
"id": "Weight",
"properties": {
"notes": {
"description": "Optional. Standard free-form notes captured at manual logging.",
"type": "string"
},
"sampleTime": {
"$ref": "ObservationSampleTime",
"description": "Required. The time at which the weight was measured"
},
"weightGrams": {
"description": "Required. Weight of a user in grams.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"WeightRollupValue": {
"description": "Represents the result of the rollup of the weight data type.",
"id": "WeightRollupValue",
"properties": {
"weightGramsAvg": {
"description": "Average weight in grams.",
"format": "double",
"type": "number"
}
},
"type": "object"
}
},
"servicePath": "",
"title": "Google Health API",
"version": "v4",
"version_module": true
}