Skip to main content
GET /api/user-challenges Requires authentication.
string
required
Bearer token obtained from /api/auth/login or /api/auth/signup. Format: Bearer <token>.

Example

Response

200 OK Returns an array of all user challenge objects, including ACTIVE, COMPLETED, and ABANDONED challenges. Results are ordered by start_date descending (most recent first). Each object includes the associated template data. Returns an empty array [] if the user has never accepted a challenge.
number
required
Unique numeric identifier for this user challenge.
string
required
UUID of the authenticated user.
number
required
ID of the challenge template this challenge is based on.
string
required
Current status of the challenge. One of ACTIVE, COMPLETED, or ABANDONED.
string
required
ISO 8601 timestamp of when the challenge was started.
string
ISO 8601 timestamp of when the challenge was completed. null if not yet completed.
string
Progress notes for the challenge. null if none have been added.
string
required
ISO 8601 timestamp of when the record was created.
string
required
ISO 8601 timestamp of the last update to this record.
object
required
The challenge template this challenge is based on.
Example response

Errors