We use essential cookies for the website to function, as well as analytics cookies for analyzing and creating statistics of the website performance. To agree to the use of analytics cookies, click "Accept All". You can manage your preferences at any time by clicking "Cookie Settings" on the footer. More Information.

Only Essential Cookies
Accept All
ReferencesHealth KitBasic Capabilities API ReferenceRESTData Model

Data Model

ActivityRecord

Expand

Parameter

Type

Mandatory

Description

Restrictions

appInfo

AppInfo

Yes

AppInfo of the app that created the exercise record.

-

id

String

Yes

ID generated by the client for an exercise record.

It is unique across all exercise records owned by the user.

If no ID is specified, it will be created from the start time and name.

modifyTime

Long

Yes

The last time the exercise record was modified. The unit is milliseconds.

-

name

String

Yes

User-defined name of the exercise record. For example, the name can be cycling on Sunday.

-

startTime

Long

Yes

Start time (inclusive) of the exercise record. The unit is milliseconds.

-

endTime

Long

Yes

End time of an exercise record. The unit is milliseconds.

If it is not specified, the exercise record is considered as still being in progress.

The end time must be later than the start time.

timeZone

String

Yes

Time zone information.

Example: +0800

activeTime

Long

No

Active time of the exercise record. The unit is milliseconds.

The start/end time identifies the complete duration of the exercise record. However, the active time of the exercise record can be shorter.

activitySummary

ActivitySummary

Yes

Summary of the exercise record.

For details, see the data model.

activityType

Integer

Yes

Exercise type corresponding to the exercise record. For details about the supported exercise types, please refer to Workout Type Constants.

-

deviceInfo

DeviceInfo

No

Description of the hardware device that integrates various sensors, such as a watch, a band, or any other wearable devices.

-

cursor

String

No

ID for the paginated query. It will be contained only when the query result is to be displayed on more than one page.

-

desc

String

No

Description of the exercise record.

-

subDataRelation

List<SamplePointRelation>

No

Subdata mapping.

-

details

List<SampleSet>

No

Exercise record details.

-

metadata

String

No

Extended metadata, which is a character string in JSON format.

-

sourceType

Integer

No

Data source type.

0: unknown (default)

1: generated from a workout

2: manually entered by a user

3: course records

4: connectable devices

5: automatically identified

-

abnormal

Integer

No

Flag indicating abnormal exercise records.

0: no

1: yes

Exercise records will be marked as abnormal when important data is missing or cheating occurs.

duplicate

Integer

No

Flag indicating duplicate exercise records.

0: no

1: yes

If there are two exercise records in the same time segment, one of them will be marked as a duplicate record.

ActivitySummary

Expand

Parameter

Type

Mandatory

Description

Restrictions

dataSummary

List<SamplePoint>

No

List of sampling points of the statistical data type.

It can only be a statistical type.

It is recommended that you specify this field.

paceSummary

PaceSummary

No

Pace information.

-

activityFeature

SamplePoint

No

Exercise record feature data points.

-

sectionSummary

List<SampleSection>

No

List of sampling points for exercise record segment statistics.

-

performanceSummary

PerformanceSummary

No

Training performance data.

-

PaceSummary

Expand

Parameter

Type

Mandatory

Description

Restrictions

avgPace

Double

Yes

Average pace.

The unit is second/km.

NOTE

The unit for the rower workout is second per 500 meters.

bestPace

Double

Yes

Optimal pace.

The unit is second/km.

NOTE

The unit for the rower workout is second per 500 meters.

paceMap

Map<String,Double>

No

Pace map in the metric system.

This field indicates the pace information per kilometer. The unit is second/km. For example:

"1.0":407.945

"2.0":473.98846

"2.170":473.98846

NOTE

For the last part of distance, if it is less than one kilometer, the pace will be converted in proportion and then be stored.

partTimeMap

Map<String,Double>

No

Segmented time map in the metric system.

Segmental data (key: kilometer; value: second)

When km is used, the distance value is accurate to the fourth decimal place.

Value is the time taken to cover the current distance.

  • 1.0:3.0
  • 2.0:6.0
  • 3.0:9.0
  • 21.0975:7020.0
  • 42.195:18000.0

Where, 21.0975 and 42.195 are the distances of the half Marathon and full Marathon, respectively. Except for these two types of race, the first decimal place is 0.

PerformanceSummary

Expand

Parameter

Type

Mandatory

Description

Restrictions

aerobicTrainingStress

Double

No

Aerobic training stress.

1.0 ≤ Aerobic training stress ≤ 5.0

anaerobicTrainingStress

Double

No

Anaerobic training stress.

1.0 ≤ Anaerobic training stress ≤ 5.0

recoveryTime

Integer

No

Recovery time.

Recovery time > 0, in min

vo2Max

Integer

No

Maximum oxygen uptake.

Maximum oxygen uptake > 0, in ml/kg/min

loadPeak

Integer

No

Training load.

Training load > 0

paceZoneStatistics

Map<String, Integer>

No

Pace zone statistics. Key: zone ID; value: statistical value, in seconds.

-

heartRateZoneStatistics

Map<String, Integer>

No

Heart rate zone statistics. Key: zone ID; value: statistical value, in seconds.

-

runningAbility

Double

No

Single RAI.

-

aerobicLoadPeak

Integer

No

Aerobic load.

-

anaerobicLoadPeak

Integer

No

Anaerobic load.

-

AppInfo

Expand

Parameter

Type

Mandatory

Description

appName

String

Either appName or appPackageName must be specified.

App name. Length range: 1 to 1000 characters

NOTICE

For the access of GPRS devices, add the prefix com.huawei.health.cloud.device before the app name. Example: com.huawei.health.cloud.device.appName

appPackageName

String

Package name of the app. Length range: 1 to 300 characters

If both appPackageName and clientId are set, make sure that they are matching.

appVersion

String

No

App version. Length range: 1 to 1000 characters

clientId

String

No

App ID. The value is a string of 2 to 128 digits.

desc

String

No

URL that links to the app. Length range: 1 to 1000 characters

DataCollector

Expand

Parameter

Type

Mandatory

Description

appInfo

AppInfo

Yes

App information of the data collector.

collectorDataType

DataType

Yes

Data type definition.

collectorType

String

Yes

Type of the data collector as a constant. The value can be:

  • derived: derived data type
  • raw: raw data type

collectorId

String

No

-

collectorName

String

No

Internal ID. The name is used to identify a data collector created for a certain data type by the user.

deviceInfo

DeviceInfo

No

Description of the hardware device that integrates various sensors, such as a watch, a band, or any other wearable devices.

name

String

No

Data collector's name to display in your app.

lastUpdateTime

Long

No

Last data update time, when the sampling data is uploaded to or deleted from the data collector.

DataType

Expand

Parameter

Type

Mandatory

Description

Restrictions

field

List<DataTypeField>

Yes

A dimension of the data type.

For details, please refer to DataTypeField data model.

NOTE
  • For public data types, this field is written by Health Service Kit.
  • For customized data types, provide field values.

name

String

Yes

Unique, namespace name of the data type.

Length range: 1 to 300 characters

Huawei provides a group of shared, visible health data types starting with com.huawei. as the namespace. Customized data types are also supported, but the name of a customized data type cannot start with com.huawei.

DataType.Field

Expand

Parameter

Type

Mandatory

Description

Restrictions

format

String

Yes

Supported formats of each field in the data type.

The following formats are supported:

  • float
  • integer
  • map
  • string
  • long

name

String

Yes

Name of the data field.

Length range: 1 to 1000 characters

There mustn't be duplicate fields with a DataType. If a public data type among the data types provided by Huawei is used, the value of field must be the same as the one that has been defined.

desc

String

No

Description.

Length range: 1 to 1000 characters

optional

Boolean

No

Indicates whether the value for this field is mandatory.

  • true: optional
  • false: mandatory

If the value is not specified, the value for this field is false by default.

-

DelAuthRecord

Expand

Parameter

Type

Mandatory

Description

clientId

String

Yes

App ID.

deauthorizedTime

Long

Yes

UTC timestamp when the authorization is canceled. The unit is milliseconds.

packageName

String

Yes

App name.

DeviceInfo

Expand

Parameter

Type

Mandatory

Description

Restrictions

devType

String

Yes

Device type.

The following types are supported:

  • Phone
  • Smart watch
  • Smart band
  • Smart earphone
  • Scales (body fat scale)
  • Blood glucose monitor
  • Blood pressure monitor
  • ECG equipment
  • Heart rate monitor
  • Thermometers
  • Oximeter
  • Treadmill
  • Elliptical machine
  • Exercise bike (spinning)
  • Rowing machine
  • Walking machine
  • Rope skipping (jump rope)
  • Third watch (third-party watch)
  • Ventilator
  • Unknown

manufacturer

String

Yes

Manufacturer of the product.

Length range: 1 to 300 characters

modelNum

String

Yes

Model of the device.

Length range: 1 to 300 characters

uniqueId

String

Yes

UDID of a Huawei or non-Huawei device.

Length range: 1 to 300 characters

version

String

No

Hardware/software version of the device.

Length range: 1 to 1000 characters

prodId

String

No

Huawei all-scenario product ID of an ecosystem device.

Length range: 1 to 6 characters

NOTICE

The prodId field is mandatory for GPRS devices.

devId

String

No

Huawei all-scenario device ID of an ecosystem device.

Length range: 1 to 40 characters

deviceCode

Long

No

Device code generated after binding.

-

bindStatus

Integer

No

Device binding status.

Value:

  • 1: The device is not bound.
  • 2: The device is not bound by its owner (conflict).
  • 3: The device is bound by its owner.

Group

Expand

Parameter

Type

Mandatory

Description

Restrictions

sampleSet

List<SampleSet>

Yes

Each PolymerizeWith in the request has a sampling dataset.

-

endTime

Long

No

End time (inclusive) of the data group. The unit is milliseconds.

-

startTime

Long

No

Start time (inclusive) of the data group. The unit is milliseconds.

-

GroupByTime

Expand

Parameter

Type

Mandatory

Description

Restrictions

duration

Long

These parameters are mutually exclusive. Only one parameter can be specified.

Accurate time duration for polymerized data to be grouped into the result group. The unit is milliseconds.

A time range that does not contain data will be included in the response, but the sample dataset will empty.

The value must be greater than 0.

groupPeriod

GroupByTimeGroupPeriod

Grouping period.

The value must be greater than 0.

GroupByTimeGroupPeriod

Expand

Parameter

Type

Mandatory

Description

Restrictions

timeZone

String

Yes

Time zone.

Example: +0800

unit

String

Yes

Time unit.

The value can be:

  • day
  • month (by 30 days)
  • week

value

Integer

Yes

Period for polymerizing data. It is used together with unit.

-

PolymerizeWith

Expand

Parameter

Type

Mandatory

Description

Restrictions

dataCollectorId

String

Only one parameter takes effect at any given time.

ID of the data collector for which data is polymerized.

-

dataTypeName

String

Type of the data to be polymerized. All data of this type will be polymerized.

Length range: 1 to 300 characters

SampleConfig

Expand

Parameter

Type

Mandatory

Description

Restrictions

type

String

Yes

Configuration type.

Currently, only the 9002 configuration type is available.

id

String

Yes

Configuration ID.

Currently, only the following IDs can be queried: 900200006 (step count), 900200007 (active calories), 900200008 (workout duration), and 900200009 (active hours).

scopeApp

String

No

App to which the configuration belongs.

-

scopeDeviceType

String

No

Device to which the configuration belongs.

-

configData

String

No

Configuration content.

-

modifyTime

Long

No

Time when the configuration is last modified.

-

SamplePoint

Expand

Parameter

Type

Mandatory

Description

Restrictions

dataTypeName

String

Yes

Data type name.

-

endTime

Long

Yes

End time, in nanoseconds.

-

startTime

Long

Yes

Start time, in nanoseconds.

-

value

List<SamplePointValue>

Yes

Data value. The data sequence and type must be the same as the dataType definition in DataCollector.

-

modifyTime

Long

No

The last time when this sample point was modified, in milliseconds.

Visible only when querying the data changes.

originalDataCollectorId

String

No

ID of the raw data collector. Valid only when the SamplePoint is included in the SampleSet of the derived dataCollector.

-

metadata

String

No

Extended metadata, which is a character string in JSON format.

-

NOTE
  1. A SamplePoint can be contained in multiple SampleSet objects.
  2. The usage of metadata in different data types is as follows:
    • dataTypeName=com.huawei.continuous.steps.delta (step count)

      Extended field: motion_type (step counting motion status). The values are as follows:

      • RUN (running)
      • WALK (walking)
      • STAIRS (stairs climbing)
      • UNKNOWN (unknown)

      Example: "metadata": "{\"motion_type\":\"WALK\"}"

    • dataTypeName=com.huawei.instantaneous.blood_glucose (blood glucose)

      Extended field: mIsConfirmed (indicating the user confirmation status). The values are as follows:

      • true (confirmed)
      • false (not confirmed)

      Example: "metadata": "{\"mIsConfirmed\":true}"

SamplePoint.Value

Expand

Parameter

Type

Mandatory

Description

Restrictions

fieldName

String

Yes

Field name.

-

floatValue

Double

No

Float.

Only one field takes effect at a time.

integerValue

Integer

No

Integer.

longValue

Long

No

Long integer.

mapValue

List<SamplePointMap>

No

Map.

stringValue

String

No

String. The string length should be as short as possible. Data streams with large string values and high data frequency may be reduced in sampling.

SamplePoint.Value.Map

Expand

Parameter

Type

Mandatory

Description

Restrictions

key

String

Yes

Key.

-

value

SamplePointMapVal

Yes

Value of the SamplePointMapVal type.

-

SamplePoint.Value.Map.Value

Expand

Parameter

Type

Mandatory

Description

Restrictions

floatValue

Double

No

Float value corresponding to the sampling point of the Map type.

Only one field takes effect at a time.

integerValue

Integer

No

Integer value corresponding to the sampling point of the Map type.

longValue

Long

No

Long integer value corresponding to the sampling point of the Map type.

stringValue

String

No

String value corresponding to the sampling point of the Map type. The string length should be as short as possible. Data streams with large string values and high data frequency may be reduced in sampling.

SampleSection

Expand

Parameter

Type

Mandatory

Description

Restrictions

sectionNum

Integer

Yes

Segment index.

-

sectionTime

Long

Yes

Exercise duration of a segment, in seconds.

-

startTime

Long

Yes

Segment start time, in milliseconds.

The segment start time is later than or equal to the exercise record start time.

endTime

Long

Yes

Segment end time, in milliseconds.

The segment end time must be later than the segment start time and earlier than or equal to the exercise record end time.

sectionDataList

List<SamplePoint>

Yes

List of sampling points for exercise record segment statistics.

-

SampleSet

Expand

Parameter

Type

Mandatory

Description

Restrictions

dataCollectorId

String

Yes

ID of the data collector.

-

endTime

Long

Yes

Maximum end time among all sampling points, in nanoseconds.

-

samplePoints

List<SamplePoint>

Yes

SamplePoint list.

Complete data will apply if the SampleSet is small.

Partial data will apply if the queried SampleSet is large or the SampleSet is incrementally updated during patching.

startTime

Long

Yes

Minimum start time among all sampling points, in nanoseconds.

-

timeZone

String

Yes

Time zone information.

Example: +0800

cursor

String

No

Pagination marker for querying the SampleSet using the GET method. It will be contained only when the query result is to be displayed on more than one page.

-

NOTE

A SampleSet is the container for a group of SamplePoint objects and does not contain any information by itself.

A SamplePoint can be contained in multiple SampleSet objects.

ScopeLangItem

Expand

Parameter

Type

Mandatory

Description

Restrictions

url2Desc

Map<String, String>

Yes

Map representation of ScopeUrl and Scope.

-

authTime

String

Yes

Time when the authorization is granted.

-

appName

Long

Yes

App name.

-

appIconPath

String

Yes

Path to the app icon image.

-

Subscription

Expand

Parameter

Type

Mandatory

Description

Restrictions

appId

String

Yes

App ID.

-

eventType

String

Yes

Events that are monitored or subscribed to, which consist of event types and subtypes.

-

type

String

Yes

Event type.

-

subType

String

Yes

Event subtype.

-

subscriptionMode

int

Yes

Subscription mode.

0: HTTP subscription mode

1: PUSH subscription mode (not supported currently)

2: device-side subscription mode (PendingIntent)

subscriberId

String

Yes

Subscriber ID.

-

subscriptionId

String

Yes

Subscription record ID.

-

openId

String

Yes

OpenID in the form of user-appId.

-

goalInfo

GoalInfo

No

Goal information in scenario subscription.

This parameter is returned only when eventType is set to SCENARIO_GOAL_EVENT$ACHIEVE.

EventType

Expand

Parameter

Type

Mandatory

Description

Restrictions

type

String

Yes

Subscribed event type.

-

subType

String

Yes

Subscribed event subtype.

-

eventType

String

Yes

Subscribed event type ID.

The value is the concatenation of the value of type, the character $, and the value of subType. For details, please refer to Event Subscription.

goalInfo

GoalInfo

No

Goal information in scenario subscription.

This parameter is valid only when eventType is set to SCENARIO_GOAL_EVENT$ACHIEVE.

Event

Expand

Parameter

Type

Mandatory

Description

Restrictions

eventId

String

No

Event ID (generated on the cloud).

-

name

String

Yes

Event name. The value length range is (0, 64].

-

holdingTime

Long

Yes

Timestamp when an event is held.

The value must be later than the current timestamp.

timeZone

String

Yes

Time zone information. Example: +0800

-

city

String

Yes

City where an event is held. The value length range is (0, 128].

-

type

int

Yes

Main event type.

0: running event

-

subType

int

Yes

Subevent type.

0: marathon

-

totalDistance

Float

Yes

Full distance, in kilometers.

-

userChosenGroupType

int

Yes

Category selected by a user when signing up for an event.

0: user-defined event

1: full marathon

2: half marathon

-

userChosenDistance

Float

No

Distance of an event. The default value is the full distance, in kilometers.

-

modifyTime

Long

No

Event update time (generated on the cloud).

-

createTime

Long

No

Event creation time (generated on the cloud).

-

appInfo

AppInfo

Yes

Information about your app.

  

GoalInfo

Expand

Parameter

Type

Mandatory

Description

Restrictions

createTime

Long

No

System timestamp when a goal is created.

The unit is milliseconds.

startDay

Integer

Yes

Goal start date.

The start date must be later than the current date.

recurrence

Recurrence

Yes

Period.

-

goals

List<Goal>

Yes

Goal list.

-

Recurrence

Expand

Parameter

Type

Mandatory

Description

Restrictions

count

int

Yes

Number of periods.

-

unit

int

Yes

Period unit.

1: day

2: week

3: month

expectedAchievedCount

Integer

No

Expected achievement times in the entire period.

-

Goal

Expand

Parameter

Type

Mandatory

Description

Restrictions

goalType

int

Yes

Goal type.

The options are as follows:

1: metric goal

2: duration goal

metricGoal

MetricGoal

No

Metric goal.

Subject to the value of goalType. You can set either of them for different goals.

durationGoal

DurationGoal

No

Duration goal.

MetricGoal

Expand

Parameter

Type

Mandatory

Description

Restrictions

value

double

Yes

Goal value.

-

fieldName

String

Yes

Field name.

-

dataType

String

Yes

Metric goal statistical data type.

-

healthRecordType

String

No

Target health record type.

When this parameter is not empty, it indicates the statistical goal of {dataType} of a health record type.

activityTypes

List<Integer>

No

Target workout type list.

When this parameter is not empty, it indicates the statistical goal of {dataType} of a workout type.

DurationGoal

Expand

Parameter

Type

Mandatory

Description

Restrictions

duration

long

Yes

Goal duration.

Unit: minute

dataType

String

Yes

Duration goal statistical data type.

-

healthRecordType

String

No

Target health record type.

When this parameter is not empty, it indicates the statistical goal of {dataType} of a health record type.

activityTypes

List<Integer>

No

Target workout type list.

When this parameter is not empty, it indicates the statistical goal of {dataType} of a workout type.

AchieveRecord

Expand

Parameter

Type

Mandatory

Description

Restrictions

openId

String

Yes

OpenID that uniquely identifies a user.

-

appId

String

Yes

Third-party app ID.

-

subscriptionId

String

Yes

Subscription record ID.

-

periodIndex

int

Yes

Index of a single period.

-

periodStartDay

int

Yes

Start date of a period.

Format: YYYYMMDD

periodEndDay

int

Yes

End date of a period.

Format: YYYYMMDD

goalAchieve

List<GoalAchieve>

Yes

Goal achievement record list.

-

GoalAchieve

Expand

Parameter

Type

Mandatory

Description

Restrictions

goalType

int

Yes

Goal type.

The options are as follows:

1: metric goal

2: duration goal

3: frequency goal

metricGoal

MetricGoal

No

Metric goal.

Subject to the value of goalType. You can set either of them for different goals.

durationGoal

DurationGoal

No

Duration goal.

achievedResult

String

Yes

Actual record value.

-

achievedFlag

Boolean

Yes

Flag indicating whether the goal is achieved.

-

MetaData

Expand

Parameter

Type

Mandatory

Description

Restrictions

metaKey

String

Yes

Metadata key.

The following metaKey parameters are supported:

  • startTime: indicates the start time of the data change (deletion or update).
  • endTime: indicates the end time of the data change (deletion or update).
  • activityType: indicates the activity type of the deleted or updated activity record.
  • datatype: indicates the atomic sampling data type.
  • timeZone: indicates the time zone.
  • recordDay: indicates the date of an exercise record.
  • goalInfo: indicates the original goal information created by a user.
  • goalStatus: indicates the achievement status of goals created by a user in each period.
  • actualAchievedCount: indicates the total number of times that a user achieves goals.

Applies to user exercise record events and sampling dataset events. For details, please refer to Subscribing to Data.

metaValue

String

Yes

Metadata value.

-

HealthRecord

Expand

Parameter

Type

Mandatory

Description

Restrictions

id

String

No

Unique ID.

-

dataTypeName

String

Yes

Data type name.

-

endTime

Long

Yes

End time, in nanoseconds.

-

startTime

Long

Yes

Start time, in nanoseconds.

-

value

List<SamplePointValue>

Yes

Data value. The data sequence and type must be the same as the dataType definition in DataCollector.

-

modifyTime

Long

No

The last time when this sample point was modified. The unit is milliseconds.

Visible only when querying the data changes.

originalDataCollectorId

String

No

ID of the raw data collector. Valid only when the SamplePoint is included in the SampleSet of the derived dataCollector.

-

metadata

String

No

Extended metadata, which is a character string in JSON format.

-

subDataRelation

List<SamplePointRelation>

No

Subdata mapping.

-

subData

Map<String,SampleSet>

No

Sub-data.

-

NOTE

The data type of subDataRelation is associated with that of healthRecord. For details, please refer to the API for Uploading Health Records.

HealthRecords

Expand

Parameter

Type

Mandatory

Description

Restrictions

healthRecords

List<HealthRecord>

Yes

Unique ID.

-

timeZone

String

Yes

Time zone information. Example: +0800

-

cursor

String

No

ID for the paginated query.

-

SamplePointRelation

Expand

Parameter

Type

Mandatory

Description

Restrictions

dataTypeName

String

Yes

Data type name.

-

endTime

Long

Yes

End time, in nanoseconds.

-

startTime

Long

Yes

Start time, in nanoseconds.

-

dataCollectorId

String

Yes

ID of the raw data collector.

-

DeviceBindResp

Expand

Parameter

Type

Mandatory

Description

Restrictions

deviceCode

Long

Yes

Device binding code.

-

dataCollectors

List<DataCollector>

Yes

Data collector list.

-

Workout

Expand

Parameter

Type

Mandatory

Description

Restrictions

workoutId

String

No

Course ID.

Generated on the cloud. The value ranges from 0 to 255.

name

String

Yes

Activity name.

The value needs to be synchronized when there is an update.

description

String

No

Description.

The value ranges from 0 to 255.

createTime

Long

No

Creation time (generated on the cloud).

-

modifyTime

Long

No

Update time (generated on the cloud).

-

actionCombine

List<ActionCombine>

Yes

Training steps.

-

ActionCombine

Expand

Parameter

Type

Mandatory

Description

Restrictions

repeatTimes

int

Yes

Number of times that a training step needs to be repeated.

The value ranges from 1 to 100000.

actionList

List<RunAction>

Yes

Running training action details.

The value ranges from 0 to 100.

RunAction

Expand

Parameter

Type

Mandatory

Description

Restrictions

name

String

Yes

Action name.

The options are as follows:

1: "Warm up"

2: "Run"

3: "Walk"

4: "Have a rest"

5: "Relax"

describe

String

No

Description.

The value ranges from 0 to 255.

target

Target

No

Training goal.

-

strength

Strength

No

Strength goal.

-

Target

Expand

Parameter

Type

Mandatory

Description

Restrictions

name

String

Yes

Goal type.

The options are as follows:

1: "distance"

2: "time"

3: "calorie"

value

double

Yes

Description.

For details about the value range, please refer to name.

name

Expand

Parameter

Unit

Min. Value

Max. Value

distance

metre

50

100950

time

second

1

86399

calorie

kcal

50

5000

Strength

Expand

Parameter

Type

Mandatory

Description

Restrictions

name

String

Yes

Goal type.

The options are as follows:

1: "heart rate"

2: "Pace"

3: "steps rate"

valueH

double

Yes

Maximum value.

For details about the value range, please refer to name.

valueL

double

Yes

Minimum value.

For details about the value range, please refer to name.

name

Expand

Parameter

Unit

Min. Value

Max. Value

heart rate

bpm

38

213

pace

ms/km

60000

959000

steps rate

steps/min

100

300

HealthTrend

Expand

Parameter

Type

Mandatory

Description

Restrictions

dataType

String

Yes

Trend statistical data type.

Value range:

  • com.huawei.continuous.steps.delta: step count
  • com.huawei.continuous.calories.burnt: calories
  • com.huawei.instantaneous.resting_heart_rate: resting heart rate
  • com.huawei.instantaneous.spo2: SpO2
  • com.huawei.instantaneous.stress: stress
  • com.huawei.continuous.sleep.fragment: sleep
  • com.huawei.continuous.exercise_intensity.v2: moderate to high-intensity exercise
  • com.huawei.active_hours: hours active

item

String

Yes

Trend statistics items.

Value range:

  • Step: step count
  • Calorie: calories
  • RestingHeartRate: resting heart rate
  • SpO2: SpO2
  • Stress: stress
  • AllSleepTime: sleep duration
  • ExerciseIntensity: moderate to high-intensity exercise duration
  • ActiveHour: hours active

trendPeriod

int

Yes

Trend statistics period.

The options are as follows:

1: last 30 days (one month)

2: last 26 weeks (half a year)

startDate

int

Yes

Trend statistics start date.

-

endDate

int

Yes

Trend statistics end date.

-

statistical

boolean

Yes

Whether trend statistics is available within a period.

The options are as follows:

true: yes

false: no (due to insufficient data)

daysNeed

int

No

Number of days after which trend statistics is available.

-

trendConclusion

int

No

Trend changes.

The options are as follows:

1: ascending

2: descending

3: unchanged

trendResult

int

No

Trend change impact.

The options are as follows:

1: positive

2: negative

3: unknown

trendSplitPosition

long

No

Trend change point.

-

format

int

No

Data format.

The options are as follows:

1: integer

2: floating point

frontValue

String

No

Statistics before trend change.

-

backValue

String

No

Statistics after trend change.

-

diffValue

String

No

Difference before and after the trend change point.

-

trendDescText

String

No

Trend analysis.

-

statValues

List<PeriodStatistic>

No

Average health data in each period.

-

PeriodStatistic

Expand

Parameter

Type

Mandatory

Description

startDate

int

Yes

Start date of a period.

avgValue

String

No

Average value in a period.

minValue

String

No

Minimum value in a period.

maxValue

String

No

Maximum value in a period.

valueQuality

Float

No

Data confidence.

AthleticPerformance

Expand

Parameter

Type

Mandatory

Description

runningAbility

Double

Yes

Running ability index. The value ranges from 20 to 90.

condition

Double

Yes

Condition index. The value range is as follows:

  • > 6: haven't exercised for a long time
  • (3, 6]: energized
  • (0.5, 3]: in good condition
  • (-2, 0.5]: ready for training
  • (-6, -2]: a little tired
  • (-10, -6]: tired
  • (-13, -10]: very tired
  • ≤ –13: must take a rest

fitness

Double

Yes

Fitness index. The value ranges from 0 to 80.

fatigue

Double

Yes

Fatigue index. The value ranges from 0 to 160.

PredictedTimes

Expand

Parameter

Type

Mandatory

Description

km1

Integer

Yes

Estimated completion time, in seconds/1.6 km. The value ranges from 214 to 780.

km3

Integer

Yes

Estimated completion time, in seconds/3 km. The value ranges from 426 to 1524.

km5

Integer

Yes

Estimated completion time, in seconds/5 km. The value ranges from 740 to 2750.

km10

Integer

Yes

Estimated completion time, in seconds/10 km. The value ranges from 1541 to 5696.

halfMarathon

Integer

Yes

Estimated completion time, in seconds/half marathon. The value ranges from 3388 to 12641.

marathon

Integer

Yes

Estimated completion time, in seconds/full marathon. The value ranges from 7107 to 26334.

SportReports

Expand

Parameter

Type

Description

activityType

String

Workout type.

personalBest

List<BestSportReports>

Best personal score.

accumulate

List<AccumulatedSportReports>

Cumulative best personal score.

AccumulatedSportReports

Expand

Parameter

Type

Description

name

String

Achievement name.

value

float

Best personal record.

startDate

Long

Start date.

endDate

Long

End date.

BestSportReports

Expand

Parameter

Type

Description

name

String

Achievement name.

value

float

Best personal record.

startTime

Long

Start date.

endTime

Long

End date.

recordDay

Long

Date when the best record was achieved.

Search in References
Enter a keyword.