/api/challenge-templates
Requires authentication.
Bearer token obtained from
/api/auth/login or /api/auth/signup. Format: Bearer <token>.Request body
Display name of the challenge. Must not be empty.
Full description of the challenge goal and instructions.
Number of consecutive days the challenge runs. Must not be empty.
Example
Response
201 Created Returns the newly created challenge template object.Unique numeric identifier assigned to the new template.
Display name of the challenge.
Full description of the challenge goal and instructions.
Number of consecutive days the challenge runs.
ISO 8601 timestamp of when the template was created.
ISO 8601 timestamp of the last update to the template.
Example response
Errors
| Status | Description |
|---|---|
400 | title or duration_days is missing, or the 10-template limit has been reached. |
401 | Missing, invalid, or expired token. |