Skip to main content
Glama

Create a workout

create_workout

Creates a workout, assigned to a student (student_id) or as a template when student_id is empty, with its exercises: sets, reps (or a range with reps_max), load, rest, duration for cardio, notes. Exercises are matched to the Trainer Connect library by name so the student sees the demo video (or pass edb_exercise_id from search_exercises). For a program, call it once per training day with the same program name, the week name (week) and day_of_week: same program + week = one week with several days. The student is notified, like in the app.

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": {
      "title": "<title>",
      "exercises": "<exercises>"
    },
    "name": "create_workout"
  }
}

Input Schema

NameRequiredDescriptionDefault
weekNoWeek of the program this day belongs to, e.g. "Semana 1". Default "Semana 1" when program is set.
titleYesWorkout name, e.g. "Treino A - Peito e Tríceps".
programNoProgram/week name that groups the days, e.g. "Hipertrofia outubro".
exercisesYesExercises in order.
student_idNostudent_id from list_students. Empty = template in the trainer's library.
day_of_weekNomonday … sunday.
descriptionNoNotes for the student.
estimated_minutesNoExpected duration.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / week
      Added value: +{
      +  "description": "Week of the program this day belongs to, e.g. \"Semana 1\". Default \"Semana 1\" when program is set.",
      +  "maxLength": 255,
      +  "type": "string"
      +}
  2. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare this is a non-read-only, non-destructive, open-world write. The description adds real behavioral context beyond that: exercises are resolved against the Trainer Connect library by name so the student sees a demo video, and the student is notified as in the app, which is a side effect an agent must anticipate. It does not say what happens when a name fails to match or whether matching is fuzzy.

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 core action and mode split, then modes, then program grouping, then the notification side effect. Every sentence carries information, though the parentheticals and field list make it dense and slightly run-on.

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 an eight-parameter write tool with no output schema, the description covers the creation modes, exercise resolution, program grouping, and the student notification. The remaining gap is failure behavior when an exercise name does not resolve to a library entry, which matters because library matching drives the demo video.

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 still adds meaning: student_id empty means template, reps_max forms a range with reps, duration is for cardio, and edb_exercise_id comes from search_exercises. Its most valuable addition is the grouping semantics - same program plus week yields one week with several days - which the schema does 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?

States a specific verb and resource and immediately spans the two modes of the tool: assigned to a student via student_id, or a template when student_id is empty. It also enumerates the exercise payload fields, so an agent knows exactly what the call produces without opening the schema.

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

Usage Guidelines4/5

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

Gives clear conditional guidance: empty student_id means a library template, and for a program call once per training day reusing program plus week. It does not name alternatives such as create_program or apply_catalog_workout, so the agent gets conditions but no explicit exclusions.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources