Skip to content

update create program according to new endpoint #297

@DenizBilgeAkkoc

Description

@DenizBilgeAkkoc

Update Create Program According to New Endpoint

Description

The create program modal needs to be updated to match the new endpoint structure. The current implementation doesn't match the required data structure, particularly in how workouts are organized within weeks.

Changes Required

  • Add new fields: level,type,weeks,intercal
  • Update request payload to match endpoint schema:
{
  "title": "String",
  "description": "String",
  "type": "BODY_BUILDING",
  "level": "INTERMEDIATE",
  "interval": 2,
  "weeks": [
    {
      "workouts": [
        {
          "name": "Workout 1",
          "exercises": [
            {
              "exerciseId": number,
              "repetitions": number,
              "sets": number
            }
          ]
        }
      ]
    }
  ]
}

Expected Behavior

  • Data structure matching the API endpoint requirements

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions