write_routine
Create a new workout routine or update an existing one by ID, configuring exercises, sets, reps, progression, and supersets for an openGym training plan.
Instructions
Create a routine (no id) or change one (id). exercises, when given, is the new list in that order, in the format read_routine returns: for an exercise the routine already has, every field left out keeps its value and null removes it; a new exercise starts from the app's defaults (3 × 10, timed 3 × 45 s, cardio 1 × 20 min at 8 km/h). Fields openGym keeps that leap does not know are kept. Weights in the profile unit. progression is the routine default: off, linear (default), greyskull, double, triple (reps climb to the top of the range, then a set is added up to setsMax, then the weight goes up). Also per exercise: last set to failure, back-off sets, pyramids (reps, rest and weight per set), what a dumbbell weight means, and a superset's name and rest.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | ||
| name | No | ||
| emoji | No | The app's icon key, e.g. figureStrength; unknown keys show the default icon; empty removes it | |
| exercises | No | ||
| progression | No | ||
| excludeFromProgression | No | Sessions of this routine (e.g. a deload) do not count for progression |