---
title: "How an activity compared with its plan, if it had one"
method: GET
path: "/activities/{activityId}/adherence"
tags: ["Training"]
---

# How an activity compared with its plan, if it had one

`GET /activities/{activityId}/adherence`

## Request

- Base URL: `https://bodylab.lol/api/v1`
- URL: `https://bodylab.lol/api/v1/activities/{activityId}/adherence`
- Auth: HTTP bearer

## Path parameters

- `activityId` string, required: Opaque identifier.

## Headers

- `X-Client-Platform` string
- `X-Client-Version` string

## Response `200`

OK

- object
  - `adherence` object, nullable, required
    - `matchKind` string, required: How the activity was matched to its plan. Known values: explicit, inferred. Treat unknown values as "other".
    - `workoutType` string, nullable, required
    - `metric` string, required: What the plan targeted. Known values: power, heart_rate. Treat unknown values as "other".
    - `prescribedWorkSeconds` number, required
    - `actualWorkSeconds` number, required
    - `repsPrescribed` integer, required
    - `repsCompleted` integer, required
    - `average` number, nullable, required
    - `easySeconds` number, required
    - `totalSeconds` number, required
    - `blocks` object[], required
      - `label` string, required
      - `repeat` integer, required
      - `targetLow` number, nullable, required
      - `targetHigh` number, nullable, required
      - `prescribedSeconds` number, required
      - `deliveredSeconds` number, nullable, required
      - `direction` string, required
      - `repsCompleted` integer, nullable, required
      - `repDurations` number[], required
    - `series` array[], required: [secondsFromStart, value] samples.
      - unknown[]
        - unknown
    - `plan` object[], required
      - `label` string, required
      - `repeat` integer, required
      - `work` object, required
        - `minutes` number
        - `zone` integer: Heart-rate zone, 1–5.
        - `hrLow` number, nullable
        - `hrHigh` number, nullable
        - `powerLow` number, nullable
        - `powerHigh` number, nullable
        - `speedLowMs` number, nullable: The slow end of this block's pace, as a speed in metres per second. Null with speedHighMs set means a ceiling only ("no faster than"); null with both null means no pace. Show it as pace in the athlete's units; each edge already sits on a whole five seconds of pace.
        - `speedHighMs` number, nullable: The fast end of this block's pace, metres per second, or null for no pace. Pace comes from the athlete's critical speed and only on road, track and treadmill runs; heart rate stays the limit.
      - `recovery` object, nullable, required
        - `minutes` number
        - `zone` integer: Heart-rate zone, 1–5.
        - `hrLow` number, nullable
        - `hrHigh` number, nullable
        - `powerLow` number, nullable
        - `powerHigh` number, nullable
        - `speedLowMs` number, nullable: The slow end of this block's pace, as a speed in metres per second. Null with speedHighMs set means a ceiling only ("no faster than"); null with both null means no pace. Show it as pace in the athlete's units; each edge already sits on a whole five seconds of pace.
        - `speedHighMs` number, nullable: The fast end of this block's pace, metres per second, or null for no pace. Pace comes from the athlete's critical speed and only on road, track and treadmill runs; heart rate stays the limit.

## Other responses

- `401`: Error: UNAUTHORIZED.

---

[API](https://skmtc.dev/bodylab/apis/body-lab-api.md) · [All operations](https://skmtc.dev/bodylab/apis/body-lab-api/llms.txt) · [OpenAPI document](https://skmtc.dev/bodylab/apis/body-lab-api/revisions/544c201eaf88?raw)
