RenewalController::quizResults(). Same QuizResultResource shape as the quizzes entries of GET /api/v1/professional/renewals/{log_code}.{log_code} is a plain string; {quiz} is route-model-bound by primary key. 403 if no renewal with that log_code belongs to the caller, or if {quiz}'s log_code does not match the route's.App\Http\Controllers\Api\V1\Professional\RenewalController::quizResults()api.v1.professional.renewals.quiz.resultsAuthorization: Bearer {token}role:professional. A user without the professional role receives 403.GET/api/v1/professional/renewals/{log_code}/quiz/{quiz}| Parameter | Type | Description |
|---|---|---|
{log_code} | string(32) | Renewal course log code, as returned by GET /api/v1/professional/renewals. Not a primary key. |
{quiz} | integer | Quiz attempt id, as returned in quizzes[].id by GET /api/v1/professional/renewals/{log_code} |
200 OK{
"success": true,
"status": "success",
"message": "OK",
"data": {
"id": 900001,
"log_code": "7c1e5d9a3b2f4a68901d2c3b4a5f6e70",
"module_id": 300,
"total": 5,
"correct": 2,
"wrong": 3,
"score": 40,
"passed": false,
"date": "2026-03-07",
"start": "2026-03-07 22:09:57",
"end": "2026-03-07 22:11:20",
"questions": [
{
"id": 9797,
"text": "Example quiz question",
"missing": false,
"answers": [
{
"id": 37001,
"text": "Example right answer",
"is_correct": true,
"selected": false
},
{
"id": 37002,
"text": "Example wrong answer",
"is_correct": false,
"selected": true
}
]
}
]
}
}docs/api/diver/_resources.md -> "Quiz result".401 Unauthorized{
"success": false,
"status": "error",
"message": "Unauthenticated"
}message is Token expired or Invalid token when a bearer token was sent but is expired or unknown.403 Forbiddenprofessional role (role:professional middleware, body not captured), or no renewal with that log_code belongs to the caller, or {quiz}'s log_code does not match the route's. The last two use the standard envelope:{
"success": false,
"status": "error",
"message": "Forbidden"
}404 Not Found{quiz} id that does not exist returns 404 from route-model binding, before the controller runs. The body was not captured for this route.429 Too Many Requestsx-ratelimit-limit: 120. The body is the standard envelope with message: "Too many requests" and a Retry-After header.is_correct flag alongside selected.log_code answers 403, not 404.docs/api/professional/renewals/GET_quiz_results.mdcurl --location 'https://test.diveraid.com/api/v1/professional/renewals//quiz/' \
--header 'Authorization: Bearer <token>'{
"status": "success",
"message": "string",
"data": {
"id": 0,
"log_code": "string",
"module_id": 0,
"total": 0,
"correct": 0,
"wrong": 0,
"score": 0,
"passed": true,
"date": "2019-08-24",
"start": "2019-08-24T14:15:22.123Z",
"end": "2019-08-24T14:15:22.123Z",
"questions": [
{
"id": 0,
"text": "string",
"missing": true,
"answers": [
{
"id": 0,
"text": "string",
"is_correct": true,
"selected": true
}
]
}
]
}
}