Get the set calories/distance/medium and high exercise duration Main interface
Function table: getSupportGetMainSportGoalV3
Parameter description:
Field name | Field type | Field description |
---|---|---|
timeGoalType | int | 0: Invalid 1: Daily goal 2: Weekly goal The firmware needs to open the function table getSupportSetGetTimeGoalTypeV2 |
Example
Swift
Cmds.getMainSportGoal(timeGoalType: 1).send { rs in
if case .success(let obj) = rs {
// Success
// obj is IDOMainSportGoalModel
}else {
// Failed
}
}
Kotlin
Cmds.getMainSportGoal(timeGoalType: 1).send {
if (it.error.code == 0) {
// Success
// it.res is IDOMainSportGoalModel
}else {
// Failed
}
}