PATCH /api/v1/cats/{id}/status

Changes the status of a CAT (AssessmentStatus: DRAFT, RELEASED, ACTIVE, COMPLETED, GRADED, ARCHIVED, UPCOMING). Only admins and lecturers can update status.

Path parameters

  • id string Required

    CAT ID

application/json

Body Required

New status for the CAT

  • status string

    Values are DRAFT, RELEASED, ACTIVE, COMPLETED, GRADED, ARCHIVED, or UPCOMING.

Responses

  • 200 application/json

    CAT status updated successfully

  • 400

    Invalid status value

  • 403

    Insufficient permissions - requires ADMIN or LECTURER role

  • 404

    CAT not found

PATCH /api/v1/cats/{id}/status
curl \
 --request PATCH 'http://localhost:3500/api/v1/cats/123e4567-e89b-12d3-a456-426614174000/status' \
 --header "Content-Type: application/json" \
 --data '{"status":"RELEASED"}'
Request examples
{
  "status": "RELEASED"
}
Response examples (200)
{
  "cat": {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "status": "RELEASED"
  },
  "message": "CAT status updated successfully"
}