Appearance
Initialize Quiz (Anonymous)
Initialize a quiz for an anonymous user and generate an empty answer object.
Overview
This endpoint creates an empty quiz answer object for anonymous users and returns both the answer object and the anonymous user ID.
Method: POST
Endpoint:/api/v1/namespaces/:namespaceId/quizzes/:quizId/users/anonymous/initQuiz
Quiz must support anonymous participation.
Request
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
namespaceId | string | ✅ | Namespace unique ID |
quizId | string | ✅ | Quiz unique ID |
invitedUserUUID | string | ✅ | Invited user unique ID |
Body
json
{
"anonymousUserId": "anon_12345ABC"
}Body Parameters
| Field | Type | Required | Description |
|---|---|---|---|
anonymousUserId | string | ✅ | Anonymous user identifier |
language | string | ✅ | Require language for questions, en for English, es for Spanish |
customParams | object | ❌ | Optional custom parameters, useful for tracking UTM tags or any information needed |
Response
json
{
"answers": {
"id": "12345ABCD-anon1234",
"userId": "anon1234",
"quizId": "abc12345",
"qAnswers": {},
"completionStatus": 1,
"isAnonymous": true
},
"anonymousUserId": "anon_12345ABC"
}