Hi!
I am trying to create a new workout plan using the API (/api/v1/athlete/{id}/folders) but I receive a bad request (400 status code) due to JSON parsing.
I checked the JSON that I am passing as the body of the request with the one documented on the API docs (Intervals.icu API docs) and I didn’t find any difference between them.
What am I missing? I attach my JSON below.
Thanks in advance! ![]()
{
"hours_per_week_min": 3,
"auto_rollout_day": 1,
"name": "Plan de prueba numero 9354802150",
"start_date_local": "2025-09-05T13:13:04",
"workout_targets": [
"POWER"
],
"rollout_weeks": 1,
"owner": {
"sex": "",
"website": "",
"timezone": "",
"email": "",
"city": "",
"name": "Xavi",
"country": "",
"state": "",
"profileMedium": "",
"id": "i349268",
"bio": ""
},
"read_only_workouts": false,
"id": 9354802150,
"copy_folder_id": 9354802150,
"children": [
{
"icu_intensity": 70,
"icu_training_load": 100,
"hide_from_athlete": false,
"attachments": [],
"description": "Warmup\n- 30m 56-70% maximum 130ppm\n\nMain set\n- 10m 88-93% Sweet Spot\n- 5m recovery at maximum 56%\n- 10m 88-93% Sweet Spot\n- 5m recovery at maximum 56%\n- 45m 65-70%\n- 10m 88-93% Sweet Spot\n- 5m recovery at maximum 56%\n- 10m 88-93% Sweet Spot\n- 5m recovery at maximum 56%\n- 30m recovery at maximum 56%\n- 1h 65-70%\n\nCooldown\n- 15m maximum at 56% and 120ppm",
"time": "",
"targets": [],
"target": "",
"tags": [],
"joules": 0,
"color": "0xFFFFFF",
"moving_time": 7200,
"for_week": false,
"id": 2914145939,
"days": 0,
"updated": "2025-09-18T05:52:07",
"distance": 0,
"athlete_id": "i349268",
"name": "Endurance 7",
"indoor": false,
"carbs_per_hour": 0,
"joules_above_ftp": 0,
"plan_applied": "",
"folder_id": 9354802150,
"sub_type": "Ride",
"type": "Ride",
"day": 15,
"workout_doc": {
"steps": [],
"polarization_index": 0,
"zoneTimes": [],
"distance": 0,
"strain_score": {
"ss_w_prime": 0,
"strain_score": 0,
"ss_cp": 0,
"ss_p_max": 0
},
"duration": 7200,
"variability_index": 1.1,
"normalized_power": 210,
"average_watts": 200
}
},
{
"icu_intensity": 70,
"hide_from_athlete": false,
"icu_training_load": 100,
"attachments": [],
"description": "Warmup\n- 25m 56-70% maximum 135ppm\n\nMain set\n6x\n- 4m 110-115%\n- 4m recovery at maximum 56% or descent\n\n6x\n- 30s Sprint all out minimum 150%\n- 4m recovery at maximum 56%\n\nCooldown\n- 20m maximum at 56% and 120ppm",
"time": "",
"targets": [],
"target": "",
"tags": [],
"joules": 0,
"color": "0xFFFFFF",
"moving_time": 7200,
"for_week": false,
"id": 445984663,
"days": 0,
"updated": "2025-09-12T06:13:30",
"distance": 0,
"athlete_id": "i349268",
"name": "VO2MAX 1",
"indoor": false,
"joules_above_ftp": 0,
"carbs_per_hour": 0,
"plan_applied": "",
"folder_id": 9354802150,
"sub_type": "Ride",
"type": "Ride",
"day": 15,
"workout_doc": {
"steps": [],
"polarization_index": 0,
"zoneTimes": [],
"distance": 0,
"strain_score": {
"ss_w_prime": 0,
"strain_score": 0,
"ss_cp": 0,
"ss_p_max": 0
},
"duration": 7200,
"variability_index": 1.1,
"normalized_power": 210,
"average_watts": 200
}
}
],
"visibility": "PRIVATE",
"blurb": "fsda",
"canEdit": true,
"shareToken": "",
"description": "fds",
"type": "PLAN",
"num_workouts": 2,
"hours_per_week_max": 6,
"sharedWithCount": 0,
"duration_weeks": 1,
"starting_atl": 90,
"athlete_id": "i349268",
"starting_ctl": 90,
"activity_types": [
"Ride"
]
}