Mapping a planned event to the Garmin workout id found in the activity FIT (training_file)

Hi,

I plan workouts through the API (events with category WORKOUT) and they are synced to Garmin Connect. Runs are structured workouts; strength sessions are sent as text only (type WeightTraining, description, empty workout_doc, no steps).

Two questions:

  1. When an athlete starts a planned workout from the watch, the original FIT file of the activity contains a training_file message (type = workout) with a serial number, which looks like the Garmin workout id. This number stays the same when the event is renamed or moved to another day, so it would be a reliable way to know which planned event was actually started. Is there any way to get this Garmin workout id for a planned event through the API (a field on the event, or another endpoint)? I could not find it on the event object.
  2. Run activities get paired with their planned event (paired_event_id), but strength activities never do, even when the session was started from the watch on the planned day and it was the only one that day. Is this expected for workouts without steps? Is there something I should send (a single open step, a duration, a target) so that they get paired like runs?

Thanks a lot for your help.

Automatic pairing is not based on any id.
An activity gets paired to a workout if all of the below

  • both are on the same day
  • have the same activity type
  • the Load calculated from the activity is within +/- 50% from the planned load.

Are you referring to the original fit file downloaded from Garmin Connect, or the one downloaded from Intervals?
These used to be equal, but no longer are because Garmin filters some info on the API forwarded one.