Skip to main content
Glama

set_activity_exercise_sets

Destructive

Replace all exercise sets on a strength or rep-counting activity with Garmin-compatible per-set data, or keep watch-recorded timing while correcting exercises, reps, and weights.

Instructions

Replace the exercise sets on a strength (or other rep-counting) activity.

    Writes Garmin's structured per-set data, the same grid the Garmin Connect
    "Edit sets" screen saves, so the sets feed Garmin's exercise history,
    volume and muscle-map charts. This OVERWRITES every existing set,
    including watch-detected sets and their recorded timing; to keep some,
    read them with get_activity_exercise_sets and include them in the list.

    When the watch already recorded the right sets but misidentified the
    exercises, pass keep_timing=True: the existing sets keep their start
    times, durations and rest periods, and only the exercise, reps and
    weight are replaced, in order. The number of sets must match the
    activity's recorded active sets, and duration_seconds/rest_seconds are
    ignored.

    Exercises must use Garmin's own keys. category is an exercise category
    (e.g. DEADLIFT, BENCH_PRESS, PULL_UP, SQUAT) and exercise_name an
    exercise within it (e.g. BARBELL_DEADLIFT, ROMANIAN_DEADLIFT). Garmin
    rejects anything else with "Invalid Category" or "Invalid Sub-Category",
    and rejects the whole request, so a typo leaves the activity unchanged.
    Valid keys, grouped by category, are in
    https://connect.garmin.com/web-data/exercises/Exercises.json

    Args:
        activity_id: ID of the activity to update
        sets: Active sets in the order performed. Each is a dict with:
            category (required): Garmin exercise category key
            exercise_name: Garmin exercise key within the category; omit to
                record just the category
            reps: Repetition count; omit for timed exercises
            weight_kg or weight_lb: Load lifted; omit for bodyweight
            duration_seconds: Time under work for the set
            rest_seconds: Rest after this set, recorded as a REST set
        keep_timing: Keep the recorded set timing and rest periods,
            replacing only exercise, reps and weight (default False)
    

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "activity_id": "<activity_id>",
      "sets": "<sets>"
    },
    "name": "set_activity_exercise_sets"
  }
}

Input Schema

NameRequiredDescriptionDefault
setsYes
activity_idYes
keep_timingNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond the annotations by naming exactly what is destroyed ('every existing set, including watch-detected sets and their recorded timing'), the failure mode ('a typo leaves the activity unchanged' because Garmin rejects the whole request), and the constraint that keep_timing requires a set count matching the activity's recorded active sets while ignoring duration_seconds/rest_seconds. It is fully consistent with destructiveHint=true and idempotentHint=false.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the destructive warning before the mechanics, and the docstring-style Args block is information-dense rather than padding. It runs long, and the exercise-key URL plus category examples consume several lines, but no sentence is genuinely disposable.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a destructive three-parameter mutation with no output schema, the definition covers preconditions, overwrite scope, rejection behavior, and per-field semantics thoroughly. The only gap is that it never indicates what the call returns or how to confirm success, which is a minor omission for an overwrite-and-check-yourself tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, so the description must carry the parameter burden and it does: every field of the nested sets dict is documented with required/omit semantics (category required, exercise_name omit to record just the category, reps omitted for timed sets, weight omitted for bodyweight), plus keep_timing's behavior and default. This is meaning the schema does not provide at all.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb and resource: 'Replace the exercise sets on a strength (or other rep-counting) activity', and immediately scopes what it writes ('Garmin's structured per-set data, the same grid the Garmin Connect "Edit sets" screen saves'). It is unambiguously distinct from the sibling get_activity_exercise_sets, which it names.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit conditional guidance rather than just context: use keep_timing=True when the watch already recorded the right sets but misidentified exercises, and first read with get_activity_exercise_sets if you want to retain any existing sets. It also states the alternative is destructive overwrite by default.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools