Synchronize swimming data

Swimming

iOS: IDOSyncDataType.swim

Android: IDOSyncDataType.SWIM

When function table supportSyncMultiActivityNew is enabled, swim data is delivered via the merge callback; see Sync Multi-Activity Merge (IDOSyncDataType.activityMerge / ACTIVITYMERGE).

json field received by App:

Field name Field type Field description
year int data date year
month int data date month
day int data date day
hour int data date hour
minute int data date minute
second int data date seconds
version int protocol version number
type int Type 0 is invalid,
1 is for indoor swimming,
2 is for open water swimming
calories int calories
Unit: Kcal
distance int distance
Unit: meters
confirm_distance int user confirmation distance
Unit: meters
duration int duration
Unit :seconds
trips int number of swimming trips
average_swolf int average stroke efficiency
total_strokes_number int total number of strokes
swimming_posture int main stroke
0 : Medley
1: Freestyle
2: Breaststroke
3: Backstroke
4: Butterfly
pool_distance int Pool distance
Unit: meters
avg_speed int Average pace
Sec/100 meters How many seconds does it take to reach 100 meters
Unit: seconds
version=1 is valid, otherwise the field is 0
avg_frequency Int Average stroke Water frequency
Unit: times/minute
Version=1 is valid, otherwise the field is 0
time_zone int Time zone offset scaled by 100; e.g. timezone 8 returns 800, 5.5 returns 550
Valid only when supportSyncHealthDataWithTimeZone function table flag is on
items Collection Swimming data details, swolf & strokesNumber
& duration & swimmingPosture
& distance & frequency
& speed & stop_time
& Collection of difference_time
Field name Field type Field description
swolf int Stroke efficiency
swimming_posture int Stroke
0: Medley
1: Freestyle
2: Breaststroke
3: Backstroke
4: Butterfly
strokes_number int Number of strokes
duration int time
Unit: seconds
distance int Distance
Unit: meters
frequency int frequency
Unit: times/ Points
version=1 is valid, otherwise the field is 0

items items — Swim lap details

Field name Field type Field description
swolf int Stroke efficiency
swimming_posture int Stroke
0: Medley
1: Freestyle
2: Breaststroke
3: Backstroke
4: Butterfly
strokes_number int Number of strokes
duration int time
Unit: seconds
distance int Distance
Unit: meters
frequency int frequency
Unit: times/ Points
version=1 is valid, otherwise the field is 0
speed int Pace
seconds/how many seconds it took to reach 100 meters
Unit: seconds
version=1 is valid, otherwise the field is 0
stop_time int End Time
Unit: seconds
version=1 is valid, otherwise the field is 0
difference_time int Rest time between two trips
Unit: seconds
version=1 is valid , otherwise the field is 0
interval_item Collection Interval training array
Collection of stage_type & repeat_num & stage_data_type_item

interval_item items — Interval training step

Field name Field type Field description
stage_type int Current training step type
repeat_num int Current number of repetitions
stage_data_type_item Collection Training data of the current step
Collection of stage_support_type & stage_data_value

stage_data_type_item items

Field name Field type Field description
stage_support_type int Training data type of the current step
stage_data_value int Time: s
Distance: m
Calories: kcal
Pace: s/km
Speed: km/h × 100

stage_type values

stage_type value
None (invalid) 0x00
Warm up 0x01
Training 0x02
Rest 0x03
Relax 0x04

stage_support_type values

stage_support_type value
None (invalid) 0x00
Duration 0x01
Average heart rate 0x02
Distance 0x03
Calories 0x04
Average pace 0x05
Average speed 0x06

Example

{
    "average_swolf": 113,
    "avg_frequency": 42,
    "avg_speed": 146,
    "calories": 63,
    "confirm_distance": 250,
    "day": 18,
    "distance": 250,
    "duration": 367,
    "hour": 10,
    "items": [{
        "difference_time": 0,
        "distance": 25,
        "duration": 45,
        "frequency": 30,
        "speed": 180,
        "stop_time": 45,
        "strokes_number": 23,
        "swimming_posture": 1,
        "swolf": 136
    }],
    "minute": 3,
    "month": 4,
    "pool_distance": 25,
    "pool_distance_decimal": 0,
    "second": 6,
    "swimming_posture": 4,
    "total_strokes_number": 235,
    "trips": 10,
    "type": 1,
    "time_zone": 800,
    "version": 2,
    "year": 2024,
    "interval_item":[
     {
      "repeat_num": 4,
      "stage_data_num": 2,
      "stage_data_type_item": [{
       "stage_data_value": 15,
       "stage_support_type": 1
      },
       {
        "stage_data_value": 30,
        "stage_support_type": 3
       }
      ],
      "stage_type": 2
     }
    ]
}
Copyright © 2023-2024 IDO. All rights reserved. all right reserved,powered by Gitbook修改日期: 2026-10-20 07:53:20

results matching ""

    No results matching ""