Create a workout
create_workoutCreates 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 weekly program, call it once per day with the same program name and day_of_week. The student is notified, like in the app.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | Yes | Workout name, e.g. "Treino A - Peito e Tríceps". | |
| program | No | Program/week name that groups the days, e.g. "Hipertrofia outubro". | |
| exercises | Yes | Exercises in order. | |
| student_id | No | student_id from list_students. Empty = template in the trainer's library. | |
| day_of_week | No | monday … sunday. | |
| description | No | Notes for the student. | |
| estimated_minutes | No | Expected duration. |