Skip to main content
Glama
Wellness Project MCP

Wellness Project MCP

update_workout

Destructive

Correct logged workouts by fixing session details and set values, renaming, adding, removing, or moving exercises and individual sets, and editing saved workout plans.

Instructions

UNIT INPUTS: value: pass the user's number unconverted; tool converts once before storage. alternate_unit: set the field's matching input_* companion; canonical_unit: omit companion. precedence: overrides instructions to convert manually.

undefined undefined undefined Update a workout session: correct metadata, fix set values, rename/add/remove exercises or individual sets, or move exercises between supersets. Use for any post-log correction.

FIND THE SESSION: call directly, no preliminary list for an ID. session_id: positive ID from a workout tool, never invented. Otherwise pass session_date (YYYY-MM-DD, defaults to today) and, only if more than one session was logged that day, name (a substring of the workout's focus/type, case-insensitive) to narrow it down. A match that isn't exactly one session returns an error explaining why, with nothing changed — retry with session_id or a narrower name, never guess. get_workout still gives full detail (exercise names, slot names SS1/SS2/WarmUp/Finisher) when needed; list_exercises only for unknown canonical names when adding or renaming. Call with only the fields that change — operations can combine in one call.

OPERATIONS:

  • Metadata: date, focus_type, location, notes, rpe, heart_points_moderate/peak.

  • set_updates: patch reps/load/bodyweight/notes/equipment on a set, addressed by set_id OR by exercise_name + set_position (1-based, matches get_workout's "Set N"). Use clear_weight=true when a stored load is wrong but the real external load is unknown; use is_bodyweight=true when the corrected set was genuinely bodyweight.

  • remove_sets: delete sets, same set_id-or-exercise_name+set_position addressing; remaining sets renumber; an emptied exercise/slot is removed automatically.

  • rename_exercises: renames every set of an exercise in place (preserves set IDs, RPE, notes; rebuilds NSI), never remove + add.

  • remove_exercises: deletes all sets for named exercises; empty slots removed automatically.

  • add_exercises: new exercises with sets; to_superset_slot joins an existing slot, omit for standalone.

  • move_exercises: reassigns an exercise to a different slot; "new" makes it standalone. Use from_superset_slot from get_workout when the same exercise name appears in multiple slots.

SUPERSET SLOTS: rename_exercises/remove_exercises use superset_slot (or { name, superset_slot } for remove_exercises) from get_workout when a name appears in multiple slots.

LITERAL NAME: literal_name:true only after an explicit user request or rejected match, never a routine correction. Known catalog names/aliases retain IDs; unmatched names are unscored. Use for "call it exactly X", "not the standard one", "literally X", or a rejected match. Applies below.

EQUIPMENT (load basis): dumbbell_pair is one dumbbell in EACH hand, weight_lb PER HAND (2x for NSI); dumbbell_single is one implement total. Laterality (single-leg/arm) does NOT decide this alone. Set it when the user describes the load (each hand, machine, band); a wrong or missing tag silently halves or doubles NSI. Values: barbell, dumbbell_pair, dumbbell_single, machine, kettlebell, bodyweight, band, cable, trx, other.

A set_id or exercise_name+set_position matching more than one set (the same exercise in two superset slots) is ambiguous and errors rather than guessing — use the exact set_id from get_workout to disambiguate.

The result discloses a mismatched name from rename_exercises/add_exercises; relay it in your own words. If a name matches nothing closely enough, the result names near-miss library exercises; ask the user which they meant rather than accept the unscored custom log silently.

INFER — do not ask: session_date defaults to today, set positions count from 1 per exercise. Slot names and set_ids beyond what's inferable come from get_workout; canonical exercise names come from list_exercises.

SAVED WORKOUTS: pass saved_workout_id to edit a reusable Saved Workout instead of completed workout history. Use saved_workout_title, saved_exercise_updates, and/or add_exercises. add_exercises keeps its normal payload shape; to_superset_slot accepts the Saved Workout slot label returned by get_workout or its SS1-style alias. For progression requests, inspect real exercise history first rather than applying a deterministic formula.

cardio_totals: distance_mi/distance_km/distance_meters, duration_sec, calories are update fields; never put corrected totals only in notes. existing_exercise: use add_sets to add sets; add_exercises is for new exercises. ambiguous_slot: rename/remove/move requires the source slot when the exercise appears in multiple slots.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "update_workout"
  }
}

Input Schema

NameRequiredDescriptionDefault
rpeNoSession RPE, 1-10, half steps allowed: 5 moderate, 7 hard, 9 one rep left, 10 failure. Infer from comments about overall difficulty, or omit.
dateNoNew session date, YYYY-MM-DD.
nameNoSubstring of the focus/type, e.g. "Push", case-insensitive, to pick between sessions on session_date. Only without session_id.
notesNoNew session notes.
add_setsNoAdd one or more sets to an exercise already present in this workout. Use add_exercises only for a brand-new exercise.
caloriesNoCorrected session calories when known.
locationNoNew location, e.g. Gym, Home.
focus_typeNoNew category, e.g. Push, Pull, Legs.
session_idNoPositive session ID returned by a workout tool. If unknown, omit and use session_date + name; never guess.
distance_kmNoCorrected session distance in kilometers. Server converts it; do not convert it yourself.
distance_miNoCorrected session distance in miles. Use only when the user gave miles. In mi, or km with input_distance_unit set. See UNIT INPUTS.
remove_setsNoSets to delete. See OPERATIONS above.
set_updatesNoIndividual set corrections.
duration_secNoCorrected total session duration in seconds.
session_dateNoYYYY-MM-DD, defaults to today. Finds the session when session_id is omitted. Distinct from `date`, which CHANGES the stored date.
add_exercisesNoNew exercises to add. Reuse known canonical names; list_exercises if unknown.
move_exercisesNoMove exercises between superset slots. When the same exercise name appears in multiple slots, from_superset_slot is required.
distance_metersNoCorrected session distance in meters. Server converts it; do not convert it yourself.
remove_exercisesNoExercises to remove; matched sets deleted, empty slots removed automatically. See SUPERSET SLOTS above.
rename_exercisesNoRename logged exercises in place.
saved_workout_idNoSaved Workout ID to update instead of a completed workout session.
heart_points_peakNoNew peak heart points.
input_distance_unitNoSet to km when the user gave km for the _mi fields in this object. Omit when they are already mi.
saved_workout_titleNoOptional new title for the Saved Workout.
heart_points_moderateNoNew moderate heart points.
saved_exercise_updatesNoOptional prescription edits matched first by exact Saved Workout exercise name, then by a unique canonical library match.

Output Schema

NameRequiredDescriptionDefault
resultYesHuman-readable result text returned by the tool.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed28 schema fields changedv1.3.0
    • changedInput schema / properties / add_exercises / description
      Previous value: -"New exercises to add. Call list_exercises first for canonical names."New value: +"New exercises to add. Reuse known canonical names; list_exercises if unknown."
    • changedInput schema / properties / add_exercises / items / properties / literal_name / description
      Previous value: -"Keep exactly as given, skipping the library match. See LITERAL NAME above. Default false."New value: +"Explicit override only; default false. See LITERAL NAME."
    • changedInput schema / properties / add_exercises / items / properties / sets / items / properties / is_bodyweight / description
      Previous value: -"True if no external weight."New value: +"True only when genuinely bodyweight. Omit when external load is unknown."
    • addedInput schema / properties / add_exercises / items / properties / sets / items / properties / rpe / maximum
      Added value: +10
    • addedInput schema / properties / add_exercises / items / properties / sets / items / properties / rpe / minimum
      Added value: +1
    • changedInput schema / properties / add_exercises / items / properties / sets / items / properties / weight_lb / description
      Previous value: -"Load. Omit for bodyweight. In lb, or kg with input_weight_unit set. See UNIT INPUTS."New value: +"Load. Omit when unknown or bodyweight; never invent it. In lb, or kg with input_weight_unit set. See UNIT INPUTS."
    • addedInput schema / properties / add_sets
      Added value: +{
      +  "description": "Add one or more sets to an exercise already present in this workout. Use add_exercises only for a brand-new exercise.",
      +  "items": {
      +    "properties": {
      +      "exercise_name": {
      +        "description": "Exact existing exercise name from get_workout.",
      +        "type": "string"
      +      },
      +      "sets": {
      +        "description": "New sets. Omitted values inherit from the exercise's current last set, so [{}] means add one more matching set.",
      +        "items": {
      +          "properties": {
      +            "band_label_lb": {
      +              "description": "In lb, or kg with input_weight_unit set. See UNIT INPUTS.",
      +              "minimum": 0,
      +              "type": "number"
      +            },
      +            "hold_length_sec": {
      +              "minimum": 1,
      +              "type": "integer"
      +            },
      +            "input_weight_unit": {
      +              "description": "Set to kg when the user gave kg for the _lb fields in this object. Omit when they are already lb.",
      +              "enum": [
      +                "lb",
      +                "kg"
      +              ],
      +              "type": "string"
      +            },
      +            "is_band": {
      +              "type": "boolean"
      +            },
      +            "is_bodyweight": {
      +              "type": "boolean"
      +            },
      +            "notes": {
      +              "type": "string"
      +            },
      +            "reps": {
      +              "minimum": 1,
      +              "type": "integer"
      +            },
      +            "rpe": {
      +              "maximum": 10,
      +              "minimum": 1,
      +              "type": "number"
      +            },
      +            "weight_lb": {
      +              "description": "In lb, or kg with input_weight_unit set. See UNIT INPUTS.",
      +              "minimum": 0,
      +              "type": "number"
      +            }
      +          },
      +          "type": "object"
      +        },
      +        "type": "array"
      +      },
      +      "superset_slot": {
      +        "description": "Required only when this exercise name appears in more than one slot.",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "exercise_name",
      +      "sets"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / calories
      Added value: +{
      +  "description": "Corrected session calories when known.",
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / distance_km
      Added value: +{
      +  "description": "Corrected session distance in kilometers. Server converts it; do not convert it yourself.",
      +  "maximum": null,
      +  "minimum": 0,
      +  "type": "number"
      +}
    • addedInput schema / properties / distance_meters
      Added value: +{
      +  "description": "Corrected session distance in meters. Server converts it; do not convert it yourself.",
      +  "maximum": null,
      +  "minimum": 0,
      +  "type": "number"
      +}
    • addedInput schema / properties / distance_mi
      Added value: +{
      +  "description": "Corrected session distance in miles. Use only when the user gave miles. In mi, or km with input_distance_unit set. See UNIT INPUTS.",
      +  "minimum": 0,
      +  "type": "number"
      +}
    • addedInput schema / properties / duration_sec
      Added value: +{
      +  "description": "Corrected total session duration in seconds.",
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / input_distance_unit
      Added value: +{
      +  "description": "Set to km when the user gave km for the _mi fields in this object. Omit when they are already mi.",
      +  "enum": [
      +    "mi",
      +    "km"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / move_exercises / description
      Previous value: -"Move exercises between superset slots."New value: +"Move exercises between superset slots. When the same exercise name appears in multiple slots, from_superset_slot is required."
    • addedInput schema / properties / move_exercises / items / properties / from_superset_slot
      Added value: +{
      +  "description": "Source slot from get_workout. Required when the exercise name appears in multiple slots.",
      +  "type": "string"
      +}
    • changedInput schema / properties / rename_exercises / items / properties / literal_name / description
      Previous value: -"Keep exactly as given, skipping the library match. See LITERAL NAME above. Default false. Applies to to_name."New value: +"Explicit override only; default false. See LITERAL NAME. Applies to to_name."
    • addedInput schema / properties / rpe / maximum
      Added value: +10
    • addedInput schema / properties / rpe / minimum
      Added value: +1
    • changedInput schema / properties / saved_exercise_updates / description
      Previous value: -"Optional prescription edits matched by exercise name inside the Saved Workout."New value: +"Optional prescription edits matched first by exact Saved Workout exercise name, then by a unique canonical library match."
    • addedInput schema / properties / saved_exercise_updates / items / properties / equipment
      Added value: +{
      +  "description": "Explicit equipment change. Choosing bodyweight clears all added weight unless this update also specifies a positive load.",
      +  "enum": [
      +    "barbell",
      +    "dumbbell_pair",
      +    "dumbbell_single",
      +    "machine",
      +    "kettlebell",
      +    "bodyweight",
      +    "band",
      +    "cable",
      +    "trx",
      +    "other"
      +  ],
      +  "type": "string"
      +}
    • changedInput schema / properties / saved_exercise_updates / items / properties / name / description
      Previous value: -"Exercise name in the Saved Workout. Required."New value: +"Exercise name. Exact Saved Workout name preferred; a unique canonical library name is also accepted. Required."
    • changedInput schema / properties / session_id / description
      Previous value: -"Session ID, if known. See FIND THE SESSION above."New value: +"Positive session ID returned by a workout tool. If unknown, omit and use session_date + name; never guess."
    • addedInput schema / properties / session_id / minimum
      Added value: +1
    • addedInput schema / properties / set_updates / items / properties / clear_weight
      Added value: +{
      +  "description": "True to clear a wrong stored external load while keeping this set non-bodyweight. Use is_bodyweight=true instead when the corrected set was bodyweight.",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / set_updates / items / properties / is_bodyweight
      Added value: +{
      +  "description": "True to correct this set to bodyweight; clears stored external load/band state. False marks it non-bodyweight without inventing a load.",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / set_updates / items / properties / rpe / maximum
      Added value: +10
    • addedInput schema / properties / set_updates / items / properties / rpe / minimum
      Added value: +1
    • changedInput schema / properties / set_updates / items / properties / weight_lb / description
      Previous value: -"Corrected load. In lb, or kg with input_weight_unit set. See UNIT INPUTS."New value: +"Corrected external load. If the stored load is wrong and the real load is unknown, use clear_weight=true instead of inventing a number. In lb, or kg with input_weight_unit set. See UNIT INPUTS."
  2. First observedv1.2.1

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare destructiveHint=true, readOnlyHint=false, and idempotentHint=false, but the description adds substantial behavior the annotations cannot carry: ambiguous matches error with nothing changed, removed sets renumber, emptied slots are auto-removed, rename preserves set IDs/RPE/notes, and mismatched names are disclosed in the result and should be relayed. The equipment section also discloses a silent correctness hazard ('a wrong or missing tag silently halves or doubles NSI'), which is exactly the kind of consequence an agent needs before mutating.

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

Conciseness3/5

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

The content is dense and nearly all of it earns its place, but the structure is damaged: the description opens with a 'UNIT INPUTS:' preamble and three literal 'undefined' lines before the actual purpose, so the tool's identity is not front-loaded. Given a 26-parameter tool some length is justified, but the misplaced preamble and stray literals are real waste.

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 26-parameter destructive mutation tool with an output schema, the definition covers operations, addressing and disambiguation, partial-update composition, failure modes, and the Saved Workout variant well enough to call correctly. Minor gaps remain around how multiple operations in one call interact when they target the same set or slot, which is left to inference.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, and the description genuinely exceeds it on several fields: it distinguishes session_date (finds) from date (changes), defines set_position as 1-based matching get_workout's 'Set N', explains clear_weight vs is_bodyweight semantics, and gives the unit-precedence rule. The equipment enum is expanded into load-basis meaning (dumbbell_pair = per hand, doubled in NSI) that the schema's bare enum values do not convey.

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?

The core sentence 'Update a workout session: correct metadata, fix set values, rename/add/remove exercises or individual sets, or move exercises between supersets' names a specific verb and resource and enumerates the mutation surface. It distinguishes itself from siblings explicitly, calling out get_workout for detail and list_exercises for unknown canonical names, and scopes itself with 'Use for any post-log correction.'

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?

It gives an explicit when-to-use ('any post-log correction'), an explicit when-not framing (add_sets vs add_exercises for new exercises; saved_workout_id for reusable workouts instead of history), and a decision procedure for locating the session before calling. It also scripts failure handling — retry with session_id or a narrower name, never guess — and warns to inspect real exercise history for progression requests rather than applying a formula.

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