Quizzes belong to chapters and contain a set of questions with a time limit. Listing and viewing quizzes is open to all visitors without authentication. Creating, updating, and deleting quizzes requires an admin bearer token.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/geeky-hamster/Quizmaster/llms.txt
Use this file to discover all available pages before exploring further.
GET /api/quizzes
List all quizzes with their associated chapter. This endpoint is public. No request body. Response — 200 OK Returns an array of quiz objects, each including a nestedchapter object.
Quiz ID.
ID of the parent chapter.
Quiz title.
Scheduled date of the quiz.
Time limit string as set by the admin (e.g.
"30" for 30 minutes).Optional remarks or description.
Creation timestamp.
Last updated timestamp.
The parent chapter object.
cURL
GET /api/quizzes/chapter/:chapterId
List all quizzes for a specific chapter. This endpoint is public.The ID of the chapter whose quizzes to retrieve.
cURL
GET /api/quizzes/:id
Retrieve a single quiz by ID, including its chapter and questions. This endpoint is public.The ID of the quiz to retrieve.
chapter and questions arrays.
Errors
| Status | Message |
|---|---|
| 404 | Quiz not found |
cURL
POST /api/quizzes
Create a new quiz. Requires a valid bearer token with admin role.ID of the chapter this quiz belongs to.
Title of the quiz.
Optional description or remarks for the quiz.
Duration of the quiz as a string (e.g.
"30" for 30 minutes).Confirmation message:
Quiz created successfully.cURL
PUT /api/quizzes/:id
Update an existing quiz. Requires a valid bearer token with admin role.The ID of the quiz to update.
Updated quiz title.
Updated description.
Updated time limit string.
Move the quiz to a different chapter.
Confirmation message:
Quiz updated successfully.Updated quiz object.
cURL
DELETE /api/quizzes/:id
Delete a quiz by ID. Requires a valid bearer token with admin role.The ID of the quiz to delete.
Confirmation message:
Quiz deleted successfully.cURL