Using IA/ChatGPT to write intervals.icu workouts

can you post the json you are trying to send?

Here is my code, thanks a lot


 {
  "trainings": [
    {
      "date": "2025-09-30",
      "name": "Run - VMA courte",
      "steps": [
        {"duration": "15m", "zone": "Z1", "description": "Échauffement"},
        {"duration": "30s", "zone": "Z5", "description": "VMA 1"},
        {"duration": "1m", "zone": "Z1", "description": "Récup"},
        {"duration": "30s", "zone": "Z5", "description": "VMA 2"},
        {"duration": "1m", "zone": "Z1", "description": "Récup"},
        {"repeat": 8,
         "steps": [
           {"duration": "30s", "zone": "Z5", "description": "VMA effort"},
           {"duration": "1m", "zone": "Z1", "description": "Récup"}
         ]
        },
        {"duration": "10m", "zone": "Z1", "description": "Retour au calme"}
      ]
    },
    {
      "date": "2025-10-02",
      "name": "Run - Seuil",
      "steps": [
        {"duration": "15m", "zone": "Z1", "description": "Échauffement"},
        {"duration": "8m", "zone": "Z3", "description": "Seuil 1"},
        {"duration": "3m", "zone": "Z1", "description": "Récup"},
        {"duration": "8m", "zone": "Z3", "description": "Seuil 2"},
        {"duration": "3m", "zone": "Z1", "description": "Récup"},
        {"duration": "8m", "zone": "Z3", "description": "Seuil 3"},
        {"duration": "10m", "zone": "Z1", "description": "Retour au calme"}
      ]
    },
    {
      "date": "2025-10-04",
      "name": "Run - Sortie longue",
      "steps": [
        {"duration": "10m", "zone": "Z1", "description": "Échauffement"},
        {"duration": "80m", "zone": "Z2", "description": "Endurance"},
        {"duration": "10m", "zone": "Z1", "description": "Retour au calme"}
      ]
    },
    {
      "date": "2025-10-01",
      "name": "Bike - Endurance",
      "steps": [
        {"duration": "10m", "zone": "Z1", "description": "Échauffement"},
        {"duration": "70m", "zone": "Z2", "description": "Endurance vélo"},
        {"duration": "10m", "zone": "Z1", "description": "Retour au calme"}
      ]
    },
    {
      "date": "2025-10-05",
      "name": "Bike - Sortie Club",
      "steps": [
        {"duration": "240m", "zone": "Z2", "description": "Sortie longue 100km avec D+"}
      ]
    },
    {
      "date": "2025-10-03",
      "name": "Swim - Endurance technique",
      "steps": [
        {"duration": "10m", "zone": "Z1 HR", "description": "Échauffement crawl facile"},
        {"duration": "20m", "zone": "Z2 HR", "description": "Endurance continue"},
        {"duration": "10m", "zone": "Z1 HR", "description": "Retour au calme + éducatifs"}
      ]
    }
  ]
}

It that’s pasted verbatim, then you need to change the “smart” double quotes (i.e “ and ”) for regular ones (" ").

So it would begin with

{
"trainings": [
{
"date":"2025-09-30",

For future reference, there are various places & tools you can use to validate the JSON and tell you where errors in the syntax are. JSON Online Validator and Formatter - JSON Lint is one.

1 Like

I think these double quotes were correct. Instead the forum software changed them, when using blockquote instead of code quotes.

There is a similar problem with json workouts

The json looks valid, so maybe @david can have a look of his interpreter what’s wrong.

2 Likes

Actually, what url are you using?

Yes, that’s it, you’re right

I use https://chatgpt.com/g/g-6867cd930e808191a76d6a03cc7765b5-coach-gpt-for-intervals-icu

1 Like

Sorry, i meant the intervals.icu url that you’re trying to call.

see here

  • don’t unse “trainings”
  • date should be “start_date_local” in a format like this “2025-03-04T09:00:00”
  • you need the “category” and “type”
  • instead of “steps[ ]” I would use the description field. You can probably use the “steps” json but I couldn’t find the documentation with a quick look to fix your code

the first 2 workouts corrected are like this

[
    {
        "start_date_local": "2025-09-30T09:00:00",
        "name": "Run - VMA courte",
        "category": "WORKOUT",
        "type": "Run",
        "description": "- Échauffement 15m Z1 Pace\n- VMA 1 30s Z5 Pace\n- Récup 1m Z1 Pace\n- VMA 2 30s Z5 Pace\n- Récup 1m Z1 Pace\n\n8x\n- VMA 1 30s Z5 Pace\n- Récup 1m Z1 Pace\n\n-Retour au calme 10m Z1 Pace"
    }
,
    {
      "start_date_local": "2025-10-02T09:00:00",
      "name": "Run - Seuil",
      "category": "WORKOUT",
     "type": "Run",
      "description" : "-  Échauffement 15m Z1 Pace\n- Seuil 1 8m Z3 Pace\n- Récoup 3m Z1 Pace\n- Seuil 2 8m Z3 Pace\n- Récoup 3m Z1 Pace\n- Seuil 3 8m Z3 Pace\n- Récoup 3m Z1 Pace\n- Retour au calme 10m Z1 Pace"
    }
]

2 Likes

In ChatGPT do the prompt “Make zwo file” and then import it into intervals

I used your ChatGPT agent just now to create a Workout Text for a sample EZ recovery job and this worked out well :slight_smile: Initially it created me using % CP but I use Stryd and Garmin, so I had to tell him to use % FTP and it worked. However on Garmin when I display the workout on my watch from training calendar, I don’t see the typical details like I would with Stryd Workouts - I only see the splits, duration and the description is always “Power 3s”. Is there a fix for that, or a different way to enter the Workout Text in Intervals?