Search the user's Hevy exercise library by name (fuzzy). Returns template id, exact title, type, muscle group and equipment.
List the user's routine folders (id + title). Check this before creating a folder — reuse an existing one when the name matches.
Create a routine folder, or return the existing folder if one with this exact title already exists (never duplicates).
List the user's existing routines (id, title, folder_id, exercise_count). Use to avoid creating duplicates.
create a routine (lb-first: weight_lb snaps to 2.5/5 lb increments; RPE folded into notes; supersets; duration/distance targets supported)
Get the user's most recent logged workouts, newest first, as compact summaries: title, date, duration, and per-exercise set count + top set. Use get_workout for full set-by-set detail of one workout.
Get one logged workout with every set (weights in kg). Use the id from get_workouts.
Total number of workouts the user has ever logged in Hevy.
past sets + estimated 1RM in lb for one exercise (full history, optional date range)
Get one routine in full (all exercises and sets). Always call this before update_routine so you can send back the complete routine.
Replace an existing routine. WARNING: this overwrites the routine — Hevy replaces its exercises with exactly what you send, so first call get_routine and include every exercise you want to keep. Folder cannot be changed here; duration/distance/custom-metric set targets round-trip safely.
weekly sessions/volume (lb), sets per muscle group, top-lift 1RM trend