Quizzes
These endpoints manage quizzes from code: their questions, the correct answers, and how an attempt is taken.
Surveys have the same requests under /v1/surveys, with their own key permissions: see Surveys.
Before you start
Section titled “Before you start”The overview explains sending requests and lists, and the errors page the errors every endpoint can answer. Authentication explains how keys work.
A quiz is a list of items. Each item is a question, which is a form field of any type except the ones that upload a file, a photo, a drawing or a signature, or a piece of content between the questions: a header, a paragraph, a video or a divider. A question can have a correct answer, and it’s worth points. A survey is the same list with no correct answers.
The correct answers never reach the page people take the quiz on.
List quizzes
Section titled “List quizzes”GET/v1/quizzes
Your quizzes and surveys, without their questions.
Key permission: get_quizzes (List quizzes)
Headers: X-Api-Key, X-Api-Secret
Query parameters: the list parameters. Filter by id, title, description, mode, isActive, viewsCount, opensCount, createdAt and updatedAt, and sort by any of them except description. Search by title or description.
Response: 200, with these fields for each item:
| Field | Type | Meaning |
|---|---|---|
id |
string | Its identifier. |
publicToken |
string | The token in its public address (/q/{publicToken}). |
title |
string | Its title. |
description |
string or null | Its description. |
mode |
string | quiz, whose questions can have correct answers, or survey, whose can’t. |
isActive |
boolean | Whether its link takes attempts. |
hasPassword |
boolean | Whether its link asks for a password. |
questionsCount |
integer | How many of its items are questions. |
timeLimitSeconds |
integer or null | How long an attempt can take, or null for no limit. |
viewsCount, opensCount |
integer | Counted as for forms. |
createdAt, updatedAt |
string | When it was created and last changed. |
| Status | When |
|---|---|
400 |
A filter, sort, or page isn’t valid. |
Create a quiz
Section titled “Create a quiz”POST/v1/quizzes
Creates a quiz or a survey. Your plan limits how many you can have.
Key permission: create_quiz (Create quiz)
Body:
| Field | Type | Meaning |
|---|---|---|
title |
string | Required, up to 255 characters. |
description |
string or null | Accepted from earlier clients only: it becomes the first paragraph of content.intro. Send the introduction in content.intro. |
mode |
string | quiz (default) or survey. A survey can’t have correct answers. |
isActive |
boolean | Whether its link takes attempts. Default true. |
content |
object | { "intro": [...], "items": [...], "language": "en", "translations": {...} }: the introduction and the items in the order you put them, up to 300, and the language versions. |
settings |
object | The settings. |
Response: 201, with the quiz as Get a quiz returns it, and its address in Location.
| Status | When |
|---|---|
400 |
passwordGuessingProtection is captcha and the quiz has a password, but no active reCAPTCHA integration has passed its test. |
403 |
Your plan has as many quizzes as it allows. |
422 |
A field isn’t valid. Each problem names its field, such as content.items[2].answerKey.correct. |
Example
Section titled “Example”curl 'https://api.doxtly.com/v1/quizzes' \ -H "X-Api-Key: $DOXTLY_API_KEY" \ -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' \ -d '{ "title": "Safety training test", "content": { "items": [ { "element": { "id": "q1", "elementType": "field", "type": "radio", "dataPath": "exit", "label": "Where is the nearest exit?", "options": [ { "value": "a", "label": "Behind you" }, { "value": "b", "label": "To your left" }, { "value": "none", "label": "None of the above" } ] }, "placement": "shuffled", "shuffleOptions": true, "pinnedOptions": ["none"], "points": 1, "answerKey": { "kind": "choice", "correct": ["b"] } } ] }, "settings": { "timeLimitSeconds": 1200, "navigation": "forward_only", "passPercent": 70 } }'Each item has these fields:
| Field | Type | Meaning |
|---|---|---|
element |
object | A form field (elementType field), or a header, paragraph, image, video or divider, written as in a form’s schema. Its id stays the same when you change the quiz. A question needs a dataPath, unique in the quiz. |
placement |
string | fixed (default) keeps its place. shuffled items are shuffled among the places the shuffled items hold, separately in every attempt. |
points |
number | What a correct answer is worth, from 0 to 1000. Default 1. |
answerKey |
object or null | The correct answer. null for a question that isn’t scored. |
feedback |
list of objects | What the person is told about the question when the answers are shown: a region of content items. |
shuffleOptions |
boolean | Whether the options of a choice are shuffled in every attempt. |
pinnedOptions |
list of strings | The values of options that keep their place when the rest are shuffled, such as “None of the above”. |
body |
list of objects | What a question says besides its label, shown before its answer: a region of content items. Content items have none. |
optionPictures |
object | A picture of an option of a choice, by the option’s value. |
optionLayout |
string | How a Single choice or Multiple choice lays out its options: list (default), or cards in a grid of grid2, grid3 or grid4 columns. |
jumps |
list of objects | A question’s logic: where it sends the person on, the first whose when (a form’s condition) holds - to is the id of a later section, or __end__. Whether any item is shown is its element’s condition, as in a form. At most 20. |
metric |
string or null | The score a survey question measures: nps (a scale from 0 to 10), csat (a rating from 1 to 5) or ces (a scale from 1 to 7). The question keeps that range. |
draw |
integer or null | On a section (elementType section): how many of its questions each attempt gets, drawn at random, at most its own questions plus drawFrom.count. null for all of them. |
drawFrom |
object or null | On a section: { "count": 3, "tags": ["fire safety"] }, the questions each attempt gets drawn at random from the question library, 1 to 100, among those carrying every tag (up to 10, capital letters aside; none for any question). They join the section’s own questions before its draw; a drawn question keeps its library id, so the results count it as one question across attempts. On any other item 422 at drawFrom. |
Correct answers
Section titled “Correct answers”The request can carry examinerNotes: notes for examiners by question id ({"q-essay": "Look for two causes."}), up to 5,000 characters each, for questions of this quiz only (else 422 at examinerNotes.<id>). Leave it out and the notes stay as they are. Get a quiz returns them only to a key or person that can grade or manage quizzes; to anyone else examinerNotes is null. They never reach the public page, attempts, results, workflows or webhooks.
kind says how the answer is judged:
kind |
For | Fields |
|---|---|---|
choice |
Single choice, Select, Multiple choice, Checkbox (yes/no) | correct: the values of the correct options; for a Checkbox (yes/no) ["true"] or ["false"]. partialCredit: whether ticking some of the correct checkboxes earns a share. |
text |
Text input, Email input, Text area | accepted: the answers accepted, compared after extra spaces are removed. caseSensitive: whether capital letters matter. |
number |
Number input, Scale / Slider, Rating | value, and tolerance: how far either side of it an answer may be. |
ai |
Text input, Text area | rubric: what the AI integration judges an open answer by. |
matrix |
Grid (matrix) | cells: the right column’s value by each row’s value, every row once. partialCredit: whether each row right earns its share; off, only every row right scores. |
ranking |
Ranking | correct: every option’s value, in the right order. partialCredit: whether each option in its right place earns its share; off, only the exact order scores. |
A correct answer of the kind choice, text or number can have a penalty: the points a wrong answer to that question costs, in place of the quiz’s grading.wrongAnswerPenalty. A question left unanswered costs nothing.
A text or e-mail question without a correct answer can ask about the person with identity: full_name, first_name, last_name, email, id_number or group, each once per quiz. On a link anyone can open, these answers name the attempt’s person. A person from the access list is always who the attempt is.
Introduction
Section titled “Introduction”content.intro is what a person reads before the first question: up to 50 items of the same shape as items, each a header, paragraph, image, video or divider - never a question (422 at content.intro[i].element). Their ids are unique together with the items’ ids, and their words are translated in translations.*.items like any other item’s. An introduction sent as blocks ({"id", "kind", ...}, as before) is read as the items it shows: a text a paragraph, a picture an image, a video a video.
Regions
Section titled “Regions”A question’s body and feedback, and content.passedResult and content.failedResult - what a person whose attempt passed, or failed, reads under the score -, are built like the introduction: up to 50 items each, a header, paragraph, image, video or divider, never a question (422 at, for example, content.items[0].body[1].element). Their ids are unique together with every other item’s, and their words are translated in translations.*.items. The result texts are served in the attempt’s language. Blocks of an earlier shape ({"id", "kind", ...}) are read as the items they show, and an old client’s settings.passedTexts / failedTexts become the result items.
Pictures
Section titled “Pictures”A picture of an option is an object:
| Field | Type | Meaning |
|---|---|---|
asset |
object | The picture. Send a new one as {"filename": "map.png", "content": "data:image/png;base64,..."}: it’s stored as a file of the quiz. Send a stored one back by its file alone, {"fileId": "...", "filename": "map.png"}, as you got it. |
alt |
string or null | What the picture shows, for whoever can’t see it. Up to 500 characters. |
An image item takes its picture in imageAsset, in the same shape. Pictures are JPEG, PNG, GIF or WebP, and count towards your organization’s storage. A quiz never keeps a picture’s content: you get each one back with its fileId, size and a signed url, good for about two hours. A picture you leave out is deleted, and so are all of them with the quiz. A fileId that isn’t one of this quiz’s pictures is dropped, so a picture of another quiz has to be sent with its content.
Language versions
Section titled “Language versions”content.language is the language the quiz is written in (pl, en, es, de, pt, fr, uk, th, zh, hi, ar, ja, tr, it); null means your organization’s. content.translations holds the quiz’s words in other languages, by language:
| Field | Type | Meaning |
|---|---|---|
title |
string or null | The title in this language. |
items |
object | The words of the items and of the introduction’s items, by element.id: label, helperText, placeholder, info, content (a header’s or paragraph’s text), options (labels by the option’s value), optionAlts (the options’ pictures’ alt texts by value) and accepted (the answers an exact-text key accepts in this language; null for the quiz’s own). pictureAlt is the alt text of an image item. |
A word left out or empty is read in the quiz’s own language. A version can’t be in the quiz’s own language, and it can only name items and options the quiz has: anything else answers 422 at its path, such as content.translations.en.items.q-1.options. The public page picks the version of the visitor’s languages, and an attempt is served and judged in the language it was started in.
Settings
Section titled “Settings”| Field | Type | Meaning |
|---|---|---|
timeLimitSeconds |
integer or null | The time an attempt has, from 60 to 86400 seconds; null for no limit. |
navigation |
string | free (default): any question in any order. forward_only: a question once left can’t be answered again. |
navigator |
string | The list of questions beside an attempt: hidden, all (default) or visited, only the questions reached so far. |
paging |
string | How the questions are split into pages: question (default: one question per page, in large type), section (one section per page; one page without sections) or all (everything on one page, a timed section on a page of its own). |
trackFocus |
boolean | Whether leaving the browser tab is counted. Default true. |
warnAfterFocusLosses, submitAfterFocusLosses |
integer or null | After how many times leaving the tab the person is warned, and the attempt is sent as it stands. |
showResult |
string | What the person sees at the end: none, score (default) or score_and_answers. |
passPercent |
integer or null | The share of the points that passes, 0 to 100. |
maxAttempts |
integer or null | How many attempts one person has. |
retentionDays |
integer or null | How many days attempts are kept; null keeps them as long as your organization keeps form submissions. |
publicLink |
object | The public link’s settings, the same as an interactive document’s: submitLabels, successMessage, successRedirect, metadata, queryParams, originValidation, ipBlacklist, honeypot, saveUserLocation, useRateLimits, passwordGuessingProtection and recaptchaIntegrationId. |
password |
string or null | The password the link asks for. It’s stored encrypted. |
access |
object | Who can take the quiz, and the sheet its access list follows. |
grading |
object | How attempts are graded: scaleId, one of your organization’s grading scales, or ownScale, a scale of this quiz’s own in the same shape as a scale’s rules (not both); passBy, percent (default: the pass mark decides) or scale (the grade reached decides); wrongAnswerPenalty, the points a wrong answer costs on an automatically scored question (default 0, none); allowNegativeTotal (default false), whether the total may fall below 0. |
countedAttempt |
string | Which of a person’s attempts counts for them: best (default), last or first. |
release |
string | When the person sees their result: after_grading (default: at once when every answer is scored automatically, after the last grade otherwise), immediately, or manually, when somebody releases it. |
sheetPrefix |
string or null | What an attempt’s sheet number starts with, up to 20 letters, digits, spaces and . _ / -: EXAM- gives EXAM-0042. |
schedule |
object | When the quiz can be taken: opensAt and closesAt (ISO 8601 moments or null) and maxResponses, how many attempts it takes in all (or null). Outside them a start is refused, and A quiz closes reaches workflows once. |
anonymous |
boolean | A survey’s: true keeps no name, e-mail, group, IP address, user agent, location or link parameters with a response and links it to no access-list person or contact; the person is marked as responded up to 10 minutes later, and the results show nothing of a group of fewer than 5. Questions with an identity are refused (422 at settings.anonymous). Always false for a quiz. |
retake |
object | When a person may try again within maxAttempts: cooldownMinutes, a pause after their last attempt (or null), and onlyIfFailed (default false), whether only someone whose counted attempt failed may start another. |
certificate |
object | The attempt’s certificate: workflowId, the workflow that generates it, one of your organization’s (or null for none), and immediate (default true), whether the result page waits for it and offers it for download, and seal (default false), whether the signing service seals it (PAdES). Each certificate issued gets a number its public page checks: GET /v1/public/certificate-verifications/{code}, no key, answers status (valid or changed), the person, quiz, result, date, sealed and the file’s sha256. See Certificates. |
look |
object | How its public page looks: themeId, a built-in theme’s key or one of your organization’s themes; left out or null, a new quiz gets the organization’s default theme and an update keeps the quiz’s own; progress, bar (default), steps, percent or none; autoAdvance (default true), whether a single choice moves on by itself with one question per page. The public view sends the theme’s tokens as theme, never its id. |
proctoring |
object | A quiz’s exam safeguards, each false by default: fullscreen, the page asks for fullscreen and counts each exit from it as leaving the tab; blockPaste, nothing can be pasted into an answer; oneDevicePerKey, the attempt of a person of the access list or of a personal link answers only the device it began on (see the public page). A survey’s are always all false. |
Access
Section titled “Access”settings.access says who can take the quiz, as in the Access section:
| Field | Type | Meaning |
|---|---|---|
mode |
string | link (default): anyone with the link, after password if there is one. passwords: only the people on the access list, each with their own password; password is not used. invitations: only the people on the list, each through their personal link; nobody types a password. |
sheet |
object or null | The live sheet the list follows, or null for none. |
sheet has these fields:
| Field | Type | Meaning |
|---|---|---|
file |
object | Required: integrationId (the drive), fileId and path, as for a data source. |
format |
string | auto (default), native (a Google Sheet), xlsx, xls, csv or ods. |
sheet |
string | The sheet of the spreadsheet to read. |
headerRow |
integer | 1 to 1000, default 1. |
refreshMinutes |
integer | How often it is read: 1, 5, 15 (default), 60 or 1440. |
emailColumn |
string | Required: the column of the e-mail addresses. |
passwordColumn |
string | The column of the passwords; required with passwords. |
nameColumn |
string | The column of the names; empty for none. |
groupColumn |
string | The column of each person’s group; empty for none. Each read sets a person’s group to their row’s, and an empty cell takes it away. |
inviteNewPeople |
boolean | With invitations: whether each person the sheet adds is sent their link at once, while the quiz is active. Default false. |
The sheet counts towards your plan’s data sources, and is read once the quiz is saved. A field that isn’t valid answers 422 at its path, such as settings.access.sheet.passwordColumn.
"access": { "mode": "passwords", "sheet": { "file": { "integrationId": "01a1c7e2-5f3b-7c41-9a08-2d6e4b7f1c93", "fileId": "1mS0w2bT9kQx", "path": "Training/Participants.xlsx" }, "format": "auto", "sheet": "", "headerRow": 1, "refreshMinutes": 15, "emailColumn": "E-mail", "passwordColumn": "Password", "nameColumn": "Name", "groupColumn": "Class", "inviteNewPeople": false }}Get a quiz
Section titled “Get a quiz”GET/v1/quizzes/{id}
One quiz with its items, their correct answers and its settings.
Key permission: read_quiz (Read quiz)
Response: 200, with the fields of List quizzes except questionsCount and timeLimitSeconds, plus answersById (always false), content, settings, maxScore, the points of every scored question added up, and variableWarnings: each {{ }} variable of its texts that prints nothing where it stands, as itemId, path, problem (unknown, later for an answer to a later question, result_only for _attempt outside the result texts and explanations) and language (null for the quiz’s own). The texts are saved as written; creating and updating return the same fields. settings.password holds the password only when the key also has create_quiz, update_quiz, delete_quiz or duplicate_quiz. Any other key gets null, and can tell from hasPassword that there is one.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
Update a quiz
Section titled “Update a quiz”PUT/v1/quizzes/{id}
Saves the whole quiz: send every field, as for Create a quiz. A setting you leave out goes back to its default, and settings.password left out or null removes the password.
Key permission: update_quiz (Update quiz)
Response: 200, with the quiz as Get a quiz returns it.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
A field isn’t valid. |
Duplicate a quiz
Section titled “Duplicate a quiz”POST/v1/quizzes/{id}/duplicate
Makes an inactive copy with an address of its own: the same content, pictures (stored again as the copy’s own files), language versions, settings, password, examiner notes and AI reference material (what a copy holds). Attempts, grades, the access log, invitations, personal links, certificates issued, analyses and saved reports stay with the original. POST /v1/surveys/{id}/duplicate copies a survey the same way. The body is optional:
| Field | Type | Meaning |
|---|---|---|
title |
string | The copy’s title, up to 255 characters. Left out, it is the original’s with the word for a copy after it, in the language of the answers: “ (copy)” for Accept-Language: en, “ (copia)” for es, “ (Kopie)” for de and so on, “ (kopia)” when you send none. The original’s title is shortened so that the two fit in 255 characters. |
accessList |
boolean | true copies the people added to the access list by hand or from a file, each with a new password and personal link; nobody is invited. Default false. Needs the key’s manage_quiz_access_list (manage_survey_access_list for a survey). |
workflows |
boolean | true copies the workflows started by the quiz’s attempts, inactive, named with the same word for a copy, and started by the copy; a certificate made by one of them is then made by its copy. Left false, a certificate made by the original’s own workflow is cleared. Needs Manage workflows and the key’s create_workflow. |
Key permission: duplicate_quiz (Duplicate quiz)
Response: 201, with the copy as Get a quiz returns it, and its address in Location.
| Status | When |
|---|---|
403 |
Your plan has as many quizzes as it allows, or with workflows, as many workflows; or workflows or accessList was asked for without what it needs. |
404 |
There’s no quiz with this id in your organization. |
422 |
title is blank or longer than 255 characters. |
Export a quiz
Section titled “Export a quiz”GET/v1/quizzes/{id}/export
The quiz or survey as a portable file, to import into this organization or another (Import and export). It holds the content with its pictures inside, the settings, the theme and the grading scale by value, and the name of the reCAPTCHA integration of its link as a requirement. It never holds attempts, answers, the access list, personal links, distributions, the password or the certificate workflow.
| Query parameter | Type | Description |
|---|---|---|
examinerNotes |
boolean | false leaves the examiner notes out. Default true: they go in, under content.examinerNotes with forExaminersOnly: true, when the key also has an operation of Manage quizzes or Grade attempts. |
Key permission: export_quiz (Export quizzes)
Response: 200, with format (doxtly.quiz), version, title, requirements and content. Importing it is done in the app.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
Send a quiz’s link
Section titled “Send a quiz’s link”POST/v1/quizzes/{id}/send-link
Sends the quiz’s or survey’s public link to a list of people, each in a message of their own, by email, SMS or WhatsApp. It works exactly as Send a form’s link: without templateId, your organization’s default “Quiz link” message goes, and a template chosen must be written for that purpose. The template gets {{ quizUrl }}, {{ quizName }}, {{ senderName }} and {{ organizationName }}. A survey’s link goes in the “Survey link” message, whose template gets {{ surveyUrl }} and {{ surveyName }} in their place. Each message counts towards your plan’s emails, as a form’s link does.
Key permission: send_quiz_link (Send quiz links)
Response: 200, with the link sent (url), the channel and how the message to each recipient went (sendings), as for a form.
| Status | When |
|---|---|
400 |
The quiz is inactive. |
404 |
There’s no quiz with this id in your organization. |
422 |
A recipient isn’t an address or a phone number, or the template isn’t written for a quiz’s link. |
curl -X POST 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/send-link' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' \ -d '{"channel":"email","recipients":["helena.lindqvist@fjordline.example"],"queryParams":{"team":"warehouse"}}'{ "url": "https://northbridge.app.doxtly.com/q/Qz7mV2pL9sKx4TnBaR1uW8cYe5HdFjG0oNiE3hZq6Lw?team=warehouse", "channel": "email", "sendings": [ { "recipient": "helena.lindqvist@fjordline.example", "status": "success", "id": "01a1d2c9-0e4f-7a62-8b13-5f6c2d9e8a41", "errorMessage": null } ]}List attempts
Section titled “List attempts”GET/v1/quizzes/{id}/attempts
The quiz’s attempts, newest first, a page at a time (page, perPage). Each says when it started and was sent, how it ended (endedBy: submitted, time_up, focus_lost), its status (in_progress, grading, completed, needs_review), its score, maxScore, percent and passed, how long it took (durationSeconds, null while it is still being taken), how often the person left the tab (focusLosses) and whether the time the page reported was cut to what the server measured (timingAdjusted). Answers are never listed. filter[status][eq]=needs_review lists only the attempts that wait for a grade by hand.
Key permission: get_quiz_attempts (List quiz attempts)
Response: 200, with items and the page’s pagination. On a quiz with an access list, each attempt’s person names who took it: id, name, email and removedAt, set once they were taken off the list. On a quiz anyone with the link takes, person is null.
Each attempt also has its sheetNumber (the quiz’s sheetPrefix and four digits, numbered in the order attempts start), personName, personEmail and personGroup (from the access list, or from the identity questions on an open link), grade (bandId, label in the attempt’s language, code, passed, color; null without a grading scale or before the score is final), counted (whether it’s the attempt that counts for its person), releasedAt (when the person was shown the result) and gradingRevision, which grows with every change of the points, grade or release.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
Get an attempt
Section titled “Get an attempt”GET/v1/quizzes/{id}/attempts/{attemptId}
One attempt as a grader reads it: its row of the list (attempt), each question with the answer given and how it was judged (questions), every grade given by hand, newest first (gradeChanges), and its certificate: pending while the result page waits for it, ready once it is there, null for none.
Each question has questionId, number, label, type, answer (as given: a text, a number, the values of the options ticked, true or false; null for none), options (value and label, to read a choice), verdict (correct, partial, incorrect, unanswered, pending while it waits for a grade, ungraded), judgedBy (exact, ai, manual), points, maxPoints, feedback, and from its answer key answerKind, the rubric of an open answer, the correct options or accepted texts (a grid’s rows each with its right column, a ranking’s options in order) and correctNumber, and for a grid its rows (value and label). A password question’s answer is always null.
Key permission: read_quiz_attempt (Read quiz attempts with answers). The answers are the person’s, so this needs the Grade attempts permission, not only the one to list attempts.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization, or the quiz has no such attempt. |
Get a certificate’s address
Section titled “Get a certificate’s address”GET/v1/quizzes/{id}/attempts/{attemptId}/certificate-address
A signed address the attempt’s certificate is downloaded from, good for 10 minutes: open it, or hand it to a browser, within that time. The attempt’s row in List attempts says whether there is one: certificate is ready, pending while the workflow makes it, failed when its run ended without one, or null when the quiz gives none.
Key permission: read_quiz_certificate (Download quiz certificates)
Response: 200, with downloadUrl and expiresAt.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization, the quiz has no such attempt, or the attempt has no certificate yet. |
Get an answer sheet
Section titled “Get an answer sheet”GET/v1/quizzes/{id}/attempts/{attemptId}/answer-sheet
The attempt’s answer sheet as a PDF, in the attempt’s language: its sheet number, the header the quiz’s settings choose (settings.answerSheet.headerFields), every question with the answer given, its points and the comment for the person, section subtotals, and at the end the points, percent, grade and whether it passed. It is the sheet the person may read: never the examiner’s notes.
Key permission: read_quiz_answer_sheet (Download quiz answer sheets)
Response: 200, application/pdf, opened in the browser (Content-Disposition: inline).
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization, or the quiz has no such attempt. |
409 |
The attempt is still being taken. |
Get an examiner’s copy
Section titled “Get an examiner’s copy”GET/v1/quizzes/{id}/attempts/{attemptId}/examiner-sheet
The examiner’s copy of the attempt’s answer sheet as a PDF: the answer sheet with the correct answers and explanations always shown and, under each question, its examiner note, its rubric with the items applied marked, and the AI’s suggestion with its confidence and reasons. Printed on demand and never kept; quizzes only.
Key permission: read_quiz_examiner_sheet (Download examiner copies of quiz answer sheets)
Response: 200, application/pdf, opened in the browser (Content-Disposition: inline).
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization, or the quiz has no such attempt. |
409 |
The attempt is still being taken. |
Get a quiz’s item analysis
Section titled “Get a quiz’s item analysis”GET/v1/quizzes/{id}/summary/items
Each scored question in the quiz’s order, over each person’s counted, finished attempt (attempts says how many): facility (0 to 1), discrimination (point-biserial, -1 to 1; null below three attempts or without spread), upperLowerIndex (the top third’s facility less the bottom third’s), medianSeconds, flags (too_easy, negative_discrimination) and, for a choice, options with how many chose each in all (chosen) and by score third (top, middle, bottom). Quizzes only.
Key permission: get_quiz_summary (Read and export quiz summaries)
Print answer sheets
Section titled “Print answer sheets”POST/v1/quizzes/{id}/answer-sheets
Prints the sheets of every finished attempt the summary’s filters leave (attempts still being taken are left out), up to 1,000 at a time, in the background: format=merged_pdf (default) joins them into one PDF, format=zip packs a PDF per sheet. The answer is 202 with the print’s id and the sheets it holds (rows). Whoever asked in the application is notified when it is ready; an access key asks for the file until it is. On /v1/surveys/{id}/answer-sheets it prints a survey’s response sheets.
Key permission: read_quiz_answer_sheet (Download quiz answer sheets)
| Status | When |
|---|---|
400 |
No finished attempt matches the filters, or more than 1,000 do. |
409 |
The survey is anonymous: its responses have no sheets. |
GET/v1/quizzes/{id}/answer-sheets/{printId}
The print’s file (application/pdf or application/zip), for whoever started it (the same person, or the same access key); anybody else gets 404. 409 while it is being made, or when it could not be. Files are kept for 7 days.
Key permission: read_quiz_answer_sheet (Download quiz answer sheets)
Get a quiz summary
Section titled “Get a quiz summary”GET/v1/quizzes/{id}/summary
The quiz’s class list: one row per person (rows=people, the attempt that counts for them, or the one they are taking) or per attempt (rows=attempts), with the sheet number, name, e-mail, group, points, percent, grade, pass, time taken (seconds, null for an attempt still being taken), attempts used, status and each section’s subtotal. Above the rows, stats gives the number of rows and people, the mean and median percent, the pass rate and how many reached each grade, over every row the filters leave; groups lists every group the quiz’s attempts are of, whatever the filters. It never reads the answers.
| Query | Meaning |
|---|---|
rows |
people (default) or attempts |
search |
Part of a name, an e-mail or a sheet number |
group, language, grade |
Exact group, attempt language, grade band id |
status |
in_progress, awaiting_grading, graded, released |
passed |
true or false |
finishedFrom, finishedTo |
Days YYYY-MM-DD in your organization’s time zone, both included |
sort, direction |
sheet, name, group, points, percent, grade, passed, time, attempts, finished; asc or desc |
page, perPage |
From 1; at most 100 rows a page |
questions |
true adds each question’s points (questions columns, items[].questions) |
Key permission: get_quiz_summary (Read and export quiz summaries)
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
A query value is not one of those above. |
Export a quiz summary
Section titled “Export a quiz summary”GET/v1/quizzes/{id}/summary/export
The same rows as a file in the reader’s language: format=xlsx (default; a Summary sheet with the quiz, the filter and the figures above typed number, percentage (to two decimals), date and duration cells, and a Questions sheet with each question’s mean points, share correct and median time) or format=csv (the rows, UTF-8, semicolons where the language writes a decimal comma). It takes the summary’s filters and sort, at most 50,000 rows; more are answered 400: export them in the background. include=answers adds an Answers sheet to the Excel file: each row’s answer to each question, choices by their labels, with its points.
Key permission: get_quiz_summary (Read and export quiz summaries)
Export a quiz summary in the background
Section titled “Export a quiz summary in the background”POST/v1/quizzes/{id}/summary/exports
For more rows than an export made at once holds: the same query parameters (format, include and the summary’s filters), up to 1,000,000 rows. The answer is 202 with the export’s id and the rows it holds; the file is made in the background. Whoever asked in the application is notified when it is ready; an access key asks for the file until it is.
Key permission: get_quiz_summary (Read and export quiz summaries)
GET/v1/quizzes/{id}/summary/exports/{exportId}
The export’s file, for whoever started it (the same person, or the same access key); anybody else gets 404. 409 while it is being made, or when it could not be. Files are kept for 7 days.
Key permission: get_quiz_summary (Read and export quiz summaries)
Grade an attempt
Section titled “Grade an attempt”PUT/v1/quizzes/{id}/attempts/{attemptId}/grades
Gives questions of a sent attempt points and a comment by hand: the open answers the AI could not grade, or any scored question you grade again.
{ "grades": [ { "questionId": "q-essay", "points": 1.5, "feedback": "Right idea, no example." } ]}| Field | Type | Meaning |
|---|---|---|
grades |
array | One entry per question, each question once; a question left out keeps its grade. |
grades[].questionId |
string | A question of the attempt that is worth points. |
grades[].points |
number or null | From 0 to what the question is worth, fractions allowed. Leave it out for the points the rubric items make, or with acceptSuggestion. |
grades[].feedback |
string or null | Up to 2,000 characters, shown to the person with their answers where the quiz shows them. |
grades[].rubricItemIds |
array or null | The ids of the question’s rubric items that apply. Without points, they make the points: added from 0, or taken from the most the question is worth when its rubric is scored by deducting. Leave it out to keep the items applied before. |
grades[].acceptSuggestion |
boolean | true takes the AI’s suggestion for the answer as its grade: its points, items and feedback (a feedback you send wins). |
grades[].version |
integer or null | The answer’s version as you read it. When another examiner graded the answer since, nothing is changed and the answer is 409 with the grade as it stands. |
grades[].flagged |
boolean or null | Marks the answer to come back to, or clears the mark. |
A grade that changes nothing is not recorded; every other one is, with who gave it and when, and what the question had before. The score is summed again from every question’s points. Once no answer waits for a grade, an attempt that needed review is completed, passes or not by the pass mark, and A quiz attempt is finished reaches workflows and outgoing webhooks with the final score. That happens once: grading the attempt again changes its score and its history, and tells nothing twice.
Key permission: grade_quiz_attempt (Grade quiz attempts)
Response: 200, the attempt as Get an attempt gives it.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization, or the quiz has no such attempt. |
409 |
The attempt is still being taken, or the AI is still grading it. Or code quiz_grade_stale: the answer changed since the version you sent; questionId, points, feedback, rubricItemIds, version and gradedBy say how it stands now. |
422 |
A grade names a question that is not worth points or appears twice (grades[0].questionId), gives more points than the question is worth (grades[0].points), or accepts a suggestion the answer does not have (grades[0].acceptSuggestion). |
Each question of Get an attempt carries what grading needs: rubricItems and rubricScoring, the rubricItemIds applied, aiSuggestion (the AI’s points, rubricItemIds, feedback, rationale for the examiner and confidence: low, medium or high), version and flagged.
Release an attempt’s device
Section titled “Release an attempt’s device”POST/v1/quizzes/{id}/attempts/{attemptId}/device-release
With One device per key on, a listed person’s attempt is held to the device it began on, and they can’t begin a fresh attempt on another device while it’s being taken. Releasing it lets the next device they open it on take it over: when a laptop breaks down mid-exam, say. No body. An attempt held to no device, or already sent, is left as it is. Who released it is logged.
Key permission: grade_quiz_attempt (Grade quiz attempts)
Response: 200, the attempt as Get an attempt gives it; heldOnDevice is then false.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization, or the quiz has no such attempt. |
Grading workspace
Section titled “Grading workspace”GET/v1/quizzes/{id}/grading/queue
GET/v1/quizzes/{id}/grading/questions/{questionId}/answers
POST/v1/quizzes/{id}/grading/questions/{questionId}/accept-suggestions
What the grading workspace reads. Only open questions - judged by the AI or by an examiner - are in it; closed ones are graded by their correct answers.
- queue:
questions(each withquestionId,number,label,kind,maxPoints,total,pending,suggestedandflagged),attemptswaiting for grades (attemptId,sheetNumber,personName,personGroup,status,finishedAt,pending),pendingacross the quiz,unreleased, the graded attempts not shown to their people yet, andgroups, the people’s groups for the filter. No answers. Key permissionget_quiz_grading_queue. - answers: one question’s answers across the finished attempts, 100 a page (
page, from0);status=pendingleaves out the graded ones,only=low_confidencekeeps those the AI was unsure of andonly=flaggedthe flagged ones,group=one group’s people,blind=1leaves out names and sheet numbers. With the question’srubric,rubricItems,rubricScoringandexaminerNotes, and each answer’sanswer,group, grade,aiSuggestion,version,flaggedandclaimedBy(another examiner grading it now).groupslists the answers of the same text, evened out, with how many.savedCommentsare the comments examiners have given on the question (text,uses), the most used first. Key permissionread_quiz_attempt. - accept-suggestions: accepts the AI’s suggestions for the question as the answers’ grades: those it is sure of (
confidencehigh), and with{ "unsure": true }in the body the others too. Answers{ "accepted": 12, "unsureLeft": 3 }: how many were accepted, and how many suggestions it was not sure of are still waiting. Key permissiongrade_quiz_attempt.
All three answer 403 without quizzes.grade, and 404 for a quiz of another organization or a question that is not open.
Examiners and second marking. With examiners assigned (settings.grading.examiners: a list of { "userId", "questionIds", "groups" }, an empty list meaning all), the queue and the answers hold only the reader’s share, grading another examiner’s answer answers 403 with exceptions.quiz.grading_not_assigned, and somebody not listed sees nothing. Whoever has quizzes.manage sees everything; the queue gives them examiners and graders (userId, name: those assigned and the organization’s people to assign from), and examiner= on the queue and the answers shows one examiner’s share. With settings.grading.secondMarking (enabled, blind, default true, threshold in points), a grade of an open answer is the examiner’s mark: the answer stays pending until two examiners marked it, marks within threshold give their mean, marks further apart wait for the next grade, which is final. The queue then has secondMarkingThreshold and each question toReconcile; each answer has marks (examinerId, examinerName, points, rubricItemIds, feedback, markedAt, mine: with blind marking only your own until both are given), markCount and toReconcile; only=reconcile keeps the answers to reconcile, and with status=pending the answers you marked already are left out.
Regrade attempts
Section titled “Regrade attempts”POST/v1/quizzes/{id}/regrade/preview
POST/v1/quizzes/{id}/regrade
Applies the quiz’s current correct answers and grading scale to its finished attempts, or gives everybody full points for questions. Preview first: it writes nothing and says how many attempts would change.
{ "keys": true, "scale": false, "fullPoints": ["q-7"] }| Field | Type | Meaning |
|---|---|---|
keys |
boolean | Judge every automatically graded answer again by its question’s current correct answer, out of the points it was worth when served. Default true. |
scale |
boolean | Grade by the quiz’s grading scale as it is now, in place of the one the attempt was graded by. Default false. |
fullPoints |
array | Question ids every attempt gets full points for, whoever graded them. |
notify |
boolean | E-mail each person whose result was already shown to them and changes the result message again, with the new result. Default false. |
An answer graded by a person, a workflow or the AI keeps its grade unless its question is in fullPoints. Each answer changed is recorded with your name; each attempt whose score, pass or grade changes sends A quiz attempt is regraded to workflows and outgoing webhooks, with the outcome before the change.
Key permission: regrade_quiz (Regrade quiz attempts)
Response: 200, the finished attempts looked at, those whose points change, those whose outcome changes and, of those, notifiable: the results already shown to people with a known e-mail (told again with notify).
{ "attempts": 120, "changed": 14, "outcomes": 3, "notifiable": 2 }| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
fullPoints has more than 200 questions. |
AI grading reference material
Section titled “AI grading reference material”GET/v1/quizzes/{id}/grading/reference
PUT/v1/quizzes/{id}/grading/reference
POST/v1/quizzes/{id}/grading/reference/refresh
What the AI is given beside the rubric when it grades the quiz’s open answers: pasted text - course notes, regulations, model answers - and up to 10 web pages, fetched when you save them and kept as text. Participants never see it.
{ "text": "The Vistula flows through Warsaw…", "pages": [{ "url": "https://example.com/notes" }] }| Field | Type | Meaning |
|---|---|---|
text |
string | Up to 50,000 characters. |
pages |
array | Up to 10 { url }. A page kept at the same address keeps what was fetched; a new one is fetched now; one left out is removed. |
refresh fetches every page again; a page that cannot be fetched keeps what it had.
Key permission: get_quiz_grading_reference to read it, manage_quiz_grading_reference to change or refresh it.
Response: 200, the material: text, pages (each with id, url, title, status - pending, ready or failed -, characters, fetchedAt and error) and characters, how much of it reaches the AI (at most 100,000).
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
The text is too long, there are more than 10 pages, or an address is not a public web page (pages[0].url). |
Release results
Section titled “Release results”POST/v1/quizzes/{id}/attempts/release
Shows graded attempts to their people, for a quiz whose release is manually, or any graded attempt not shown yet.
{ "attemptIds": ["0193a5d6-7c1e-7b51-9a8f-3f5d2c1b0a99"] }| Field | Type | Meaning |
|---|---|---|
attemptIds |
array | Up to 5,000 attempt ids. Leave it out, or send it empty, to release every graded attempt of the quiz that is still waiting. |
Only completed attempts that are not released yet are released; the others are passed over. Each person whose e-mail is known, from the access list or from an identity question, is sent the Quiz result message with a link to their result, and A quiz result is released reaches workflows and outgoing webhooks. The release happens in the background, a moment after the answer.
Key permission: release_quiz_results (Release quiz results to participants)
Response: 202, how many attempts are being released.
{ "count": 1 }| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
An id is not a UUID (attemptIds[0]), or there are more than 5,000. |
List the recipients
Section titled “List the recipients”GET/v1/quizzes/{id}/recipients
Everyone the quiz was given to, as the People tab shows them: the people on its access list and the contacts sent a personal link to it, side by side, a page at a time (page, perPage up to 100). The list’s people come first, in the list’s order, then the contacts. Contacts are listed only when the caller may read contacts; a key needs get_contacts for them as well. The answer holds every listed person’s password and link, so give this operation only to a key that should hand them out.
Key permission: get_quiz_access_list (Read quiz access lists). Only a key whose holder has Manage quizzes can be given it.
Query parameters:
| Parameter | Meaning |
|---|---|
kind |
list for the people on the access list, contact for the contacts. |
status |
One of the statuses below. |
search |
Text in the name or the address, in any letter case. |
removed |
1 lists the people taken off the list too. |
Response: 200, with items and the page’s pagination. Each item:
| Field | Type | Meaning |
|---|---|---|
kind |
string | list or contact. |
id |
string | The person’s identifier on the list, or the personal link’s. |
name |
string | Their name; empty when they have none. |
address |
string or null | Their e-mail address, or the phone number a contact’s link went to. |
status |
string | Where they stand, below. |
channel |
string | How they were sent their link: email, sms or whatsapp. Always email for the list’s people. |
group |
string or null | The list’s group they belong to. |
contactId |
string or null | The contact, for a contact. |
origin |
string or null | How a person of the list was added: manual, upload, sheet or lti. |
password |
string or null | A person’s password on the list. |
link |
string or null | The address that lets them in: a person’s personal link, or a contact’s link while it still opens. |
createdAt |
string | When they were added or first sent the link. |
invitedAt, openedAt, startedAt, finishedAt |
string or null | When they were last invited, first opened the quiz, started it and finished it. |
remindersSent |
integer | Reminders sent since the last invitation. |
lastRemindedAt, nextReminderAt |
string or null | The last reminder, and when the next one is due. |
expiresAt, revokedAt |
string or null | When their way in expires, and when it was revoked. |
removedAt |
string or null | When a person was taken off the list. |
inviteFailure |
string or null | Why the last invitation could not be sent. |
result |
object or null | Their latest finished attempt: score, maxScore, percent, passed and finishedAt. A survey’s has no score. |
| Status | Meaning |
|---|---|
not_invited |
On the list, never sent their link. |
invited |
Sent their link, not opened yet. |
opened |
Opened the quiz. |
started |
Started an attempt. |
finished |
Finished an attempt. |
failed |
The last message to them could not be sent. |
revoked |
Their way in was revoked. |
expired |
Their way in expired. |
curl 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/recipients?status=invited&perPage=50' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET"| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
The recipients’ funnel
Section titled “The recipients’ funnel”GET/v1/quizzes/{id}/recipients/funnel
How far the recipients got: total, and how many were invited, opened, started and finished. Each step counts everyone past it too, so opened includes those who finished. Contacts count only when the caller may read contacts, as in the list.
Key permission: get_quiz_access_list (Read quiz access lists)
Response: 200:
{ "total": 240, "invited": 240, "opened": 180, "started": 150, "finished": 132 }| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
Add people to the access list
Section titled “Add people to the access list”POST/v1/quizzes/{id}/access-entries
Adds people, up to 5,000 on the list in all. A person whose address is on the list already is changed instead, and brought back if they had been removed.
Key permission: manage_quiz_access_list (Manage quiz access lists)
Body: entries, a list of people, at least one:
| Field | Type | Meaning |
|---|---|---|
name |
string | Up to 100 characters. |
email |
string or null | A valid e-mail address. A person needs a name, an address or both. |
password |
string or null | 4 to 100 characters. Left out or empty, Doxtly makes up one of 10 characters, or keeps the one a person already on the list has. |
group |
string or null | Up to 100 characters: a class, a shift or a team, which the results can be split by. |
Response: 200, with how many people were added, updated and skipped (the same address twice in the request: the first one stands).
curl -X POST 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/access-entries' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' \ -d '{"entries":[{"name":"Helena Lindqvist","email":"helena.lindqvist@fjordline.example","password":null}]}'{ "added": 1, "updated": 0, "skipped": 0 }| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
A field isn’t valid, the list would hold more than 5,000 people, or a password belongs to someone else on the list (at entries[2].password). Nothing is added then. |
Change a person on the access list
Section titled “Change a person on the access list”PUT/v1/quizzes/{id}/access-entries/{entryId}
Saves a person’s name, email and password, with the same rules as adding them. A password left out or empty keeps theirs.
Key permission: manage_quiz_access_list (Manage quiz access lists)
Response: 200, with the person:
| Field | Type | Meaning |
|---|---|---|
id |
string | The person’s identifier on the list. |
name, email, password |
string or null | As saved. |
group |
string or null | Their group. |
personalLink |
string | Their personal link, the quiz’s address with their key. |
origin |
string | How they were added: manual, upload, sheet or lti. |
createdAt, invitedAt, removedAt |
string or null | When they were added, last sent their invitation and taken off the list. |
| Status | When |
|---|---|
404 |
There’s no quiz with this id, or no such person on its list. A removed person can’t be changed. |
422 |
A field isn’t valid, or the address or the password belongs to someone else on the list. |
Remove a person from the access list
Section titled “Remove a person from the access list”DELETE/v1/quizzes/{id}/access-entries/{entryId}
Takes the person off the list: their password and their link stop working. Their attempts and their entries in the access log stay, with removedAt set.
Key permission: manage_quiz_access_list (Manage quiz access lists)
Response: 204, with no body.
| Status | When |
|---|---|
404 |
There’s no quiz with this id, or no such person on its list. |
Preview a file of people
Section titled “Preview a file of people”POST/v1/quizzes/{id}/access-entries/upload-preview
Reads an Excel or CSV file, sent as multipart/form-data in file, and says what it holds, without storing anything. To take the file from a connected cloud drive instead, send the form fields storageId (the drive’s id) and path (the file’s path in it) in place of file: an .xlsx, .xls, .ods or .csv file, or a Google Sheets file, read once with your organization’s integration. This needs the View cloud files permission as well (a key also needs get_cloud_files). The first row names the columns. Optional fields emailColumn, passwordColumn, nameColumn and groupColumn name the columns to take; without them, Doxtly guesses them from the header, in several languages (a group from headers such as Group, Class, Team or Department).
Key permission: manage_quiz_access_list (Manage quiz access lists)
Response: 200:
| Field | Type | Meaning |
|---|---|---|
columns |
list of strings | The header. |
rowCount |
integer | How many rows that aren’t empty the file has. |
emailColumn, passwordColumn, nameColumn, groupColumn |
string or null | The columns taken for each, named or guessed. |
sample |
list | The first five rows, each a list of cells. |
curl -X POST 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/access-entries/upload-preview' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -F 'file=@participants.xlsx'| Status | When |
|---|---|
403 |
A file from a drive, without the View cloud files permission. |
404 |
There’s no quiz with this id in your organization, no such drive connected in it, or no file at that path. |
422 |
No file, a file that isn’t a spreadsheet or has no rows, more than 5,000 rows, or a column named that the file doesn’t have. |
Add people from a file
Section titled “Add people from a file”POST/v1/quizzes/{id}/access-entries/upload
Adds the people of the file, sent as for the preview. A row with an address that isn’t valid, a second row with the same address and a row with someone else’s password are skipped; a person already on the list is updated, and brought back if they had been removed. Each new person without a password gets a made-up one. An empty group cell leaves a listed person’s group as it was.
Key permission: manage_quiz_access_list (Manage quiz access lists)
Response: 200, with how many people were added, updated and skipped.
| Status | When |
|---|---|
403 |
A file from a drive, without the View cloud files permission. |
404 |
As for the preview. |
422 |
As for the preview, no column is taken at all, or the list would hold more than 5,000 people. |
Send the invitations
Section titled “Send the invitations”POST/v1/quizzes/{id}/distributions
Emails people of the access list their personal link, each in a message of their own, from your organization’s email integration, as one wave: with a deadline and reminders if you like. Without templateId, the “Quiz link” message goes (“Survey link” for a survey, with {{ surveyUrl }}), as for Send a quiz’s link, with {{ recipientName }} set to the person’s name and {{ quizUrl }} to their personal link; {{ deadline }} is the wave’s deadline, and {{ reminder }} is yes in a reminder and empty otherwise. The messages are sent in the background; a person’s invitedAt is set once theirs has gone. To send the quiz to contacts, send them personal links with the target quiz: those make a wave too.
Key permission: send_quiz_invitations (Send quiz invitations)
Body:
| Field | Type | Meaning |
|---|---|---|
entryIds |
list of strings | The people to send it to; those without an address are left out. Empty or left out: everyone on the list with an address. |
onlyNotInvited |
boolean | Without entryIds: only the people who haven’t been sent theirs yet. Default true. |
templateId |
string or null | An email template written for a quiz’s link. |
language |
object or null | A language source: {"mode": "organization"} or {"mode": "fixed", "code": "en"}; null for your organization’s. |
schedule |
object | The deadline and the reminders, below. Left out: no deadline and no reminders. |
sendAt |
string | When to send the wave: a later moment on a quarter of an hour (09:00, 09:15), ISO 8601. Left out: now. |
schedule has these fields:
| Field | Type | Meaning |
|---|---|---|
deadlineAt |
string or null | The deadline. Past it the links still work, unless closeAtDeadline is on. |
closeAtDeadline |
boolean | With a deadline: whether the links stop working at it. Default false. |
reminderDays |
list of integers | The days after the invitation a reminder goes on: up to 5, each 1 to 90, in ascending order and without repeats. Empty for none. |
reminderAudience |
string | Who is reminded: not_finished (default), everyone who hasn’t finished, or not_started, only those who haven’t started. |
reminderTime |
string | The time of day the reminders go at, in your organization’s time zone, on a quarter of an hour: 09:00 (default), 13:45. |
Reminders never go to anyone who finished, whose way in was revoked or expired, or who was taken off the list.
With sendAt, the wave keeps the people chosen now and goes in the quarter-hourly run of its time, once. Anyone revoked, expired or taken off the list by then is left out, and the reminders count from the actual sending. If the quiz is inactive at that time, the wave isn’t sent and its state says not_sent. Until it goes, you can cancel it.
Response: 202, with the wave, whose recipients says how many people are to be sent their link.
curl -X POST 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/distributions' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' \ -d '{"schedule":{"deadlineAt":"2026-12-04T17:00:00+01:00","reminderDays":[3,6],"reminderAudience":"not_finished","reminderTime":"09:00"}}'{ "id": "01a1d6f2-3c8e-7b14-a2d9-6e0f4b1c7a35", "audience": "list", "channel": "email", "deadlineAt": "2026-12-04T17:00:00+01:00", "closeAtDeadline": false, "reminderDays": [3, 6], "reminderAudience": "not_finished", "reminderTime": "09:00", "recipients": 24, "sent": 0, "failed": 0, "senderName": "Northbridge Advisory", "createdAt": "2026-11-25T10:12:40+01:00", "state": "sending", "sendAt": null, "sentAt": "2026-11-25T10:12:40+01:00"}| Status | When |
|---|---|
400 |
The quiz is inactive. |
404 |
There’s no quiz with this id in your organization. |
422 |
An id or the template id isn’t valid, or the schedule isn’t: at schedule.reminderDays or schedule.reminderTime; or sendAt isn’t a later quarter of an hour, or the deadline isn’t after it (schedule.deadlineAt). |
The wave object
Section titled “The wave object”| Field | Type | Meaning |
|---|---|---|
id |
string | The wave’s identifier. |
audience |
string | list for people of the access list, contacts for contacts sent personal links. |
channel |
string | email, sms or whatsapp. |
deadlineAt |
string or null | Its deadline. |
closeAtDeadline |
boolean | Whether its links stop working at the deadline. |
reminderDays, reminderAudience, reminderTime |
Its reminders, as sent. | |
recipients |
integer | How many people it was sent to. |
sent, failed |
integer | How many messages have gone, and how many could not be sent, so far. |
senderName |
string | Who sent it: the user’s name, or your organization’s for a key. |
createdAt |
string | When it was made. |
state |
string | scheduled (waiting for sendAt), sending, sent (every message has answered), cancelled or not_sent (the quiz was inactive at sendAt). |
sendAt |
string or null | When a scheduled wave goes; null for one sent at once. |
sentAt |
string or null | When it started going; null while it waits, and once cancelled or not sent. |
List the waves
Section titled “List the waves”GET/v1/quizzes/{id}/distributions
The quiz’s waves of invitations, to the access list and to contacts, the newest first: the last 50, not paged.
Key permission: get_quiz_distributions (List quiz invitation waves)
Response: 200, with items, each a wave.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
Get a wave
Section titled “Get a wave”GET/v1/quizzes/{id}/distributions/{distributionId}
One wave, to follow how its sending goes.
Key permission: get_quiz_distributions (List quiz invitation waves)
Response: 200, with the wave.
| Status | When |
|---|---|
404 |
There’s no quiz with this id, or no such wave of it. |
Cancel a scheduled wave
Section titled “Cancel a scheduled wave”DELETE/v1/quizzes/{id}/distributions/{distributionId}
Cancels a wave scheduled with sendAt before it goes: nobody is sent anything, and its state becomes cancelled. A wave to contacts can be cancelled only by someone who may read contacts.
Key permission: send_quiz_invitations (Send quiz invitations)
Response: 204.
curl -X DELETE 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/distributions/01a1d6f2-3c8e-7b14-a2d9-6e0f4b1c7a35' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET"| Status | When |
|---|---|
403 |
The wave goes to contacts, and you may not read contacts. |
404 |
There’s no quiz with this id, or no such wave of it. |
409 |
The wave has gone already, or was cancelled or not sent. |
Choosing recipients
Section titled “Choosing recipients”The three endpoints below act on many recipients at once. Their body names them, or asks for every one that matches the filters of the list:
| Field | Type | Meaning |
|---|---|---|
entryIds |
list of strings | People of the access list, by their id. |
linkIds |
list of strings | Contacts, by the id of their personal link. |
all |
boolean | true: every recipient the filters below match, in place of the ids. |
kind, status, search |
string | The filters, as for the list; search up to 200 characters. |
Up to 10,000 recipients. Contacts are reached only when the caller may read contacts, and another quiz’s recipients never. Neither ids nor all: 422 at entryIds.
Remind recipients
Section titled “Remind recipients”POST/v1/quizzes/{id}/recipients/remind
Sends the chosen recipients their link again now, in the message of the wave that last sent it, whatever its schedule says. Only those who haven’t finished and whose way in is still open are reminded. Their scheduled reminders go on as before.
Key permission: send_quiz_invitations (Send quiz invitations)
Body: the recipients.
Response: 200, with selected, how many recipients were chosen, and changed, how many were reminded.
curl -X POST 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/recipients/remind' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' -d '{"all":true,"status":"opened"}'{ "selected": 30, "changed": 30 }| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
No recipient chosen, or an id isn’t valid. |
Revoke recipients
Section titled “Revoke recipients”POST/v1/quizzes/{id}/recipients/revoke
Closes the chosen recipients’ way in: neither their link nor their own password lets them in any more, and the quiz’s page tells them it was revoked. Their attempts stay, and so do they, on the list and in the results. They are sent no more reminders. You can restore their access later; the link they had stays dead.
Key permission: manage_quiz_access_list (Manage quiz access lists)
Body: the recipients.
Response: 200, with selected, how many recipients were chosen, and changed, how many still had their way open until now.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
No recipient chosen, or an id isn’t valid. |
Restore recipients
Section titled “Restore recipients”POST/v1/quizzes/{id}/recipients/restore
Opens the way in again for the chosen recipients whose access was revoked, so you can send them a new invitation. Nothing is sent: send the invitation yourself. A person of the access list gets a new key and stands as not invited; the link of their old invitation stays dead and answers 410 Gone. A contact’s revoked link stays revoked, and the next one you send them is a new link. Recipients whose access was never revoked are left as they are.
Key permission: manage_quiz_access_list (Manage quiz access lists)
Body: the recipients.
Response: 200, with selected, how many recipients were chosen, and changed, how many can be invited again: the people of the list restored and the contacts whose link was revoked.
curl -X POST 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/recipients/restore' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' -d '{"all":true,"status":"revoked"}'{ "selected": 3, "changed": 3 }| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
No recipient chosen, or an id isn’t valid. |
Export recipients
Section titled “Export recipients”POST/v1/quizzes/{id}/recipients/export
The chosen recipients as a CSV file, people.csv, that opens in Excel: name, address, kind, group, status, when they were invited, opened, started and finished, reminders, score, percent and passed. Times are in your organization’s time zone.
Key permission: get_quiz_access_list (Read quiz access lists)
Body: the recipients.
Response: 200, with the file (text/csv).
curl -X POST 'https://api.doxtly.com/v1/quizzes/01a1d2c4-7b3e-7f10-9c55-3e8a41b07d29/recipients/export' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' -d '{"all":true}' -o people.csv| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
No recipient chosen, or an id isn’t valid. |
The access sheet’s status
Section titled “The access sheet’s status”GET/v1/quizzes/{id}/access-sheet
How the live sheet the list follows is doing: sourceId, status (fresh, failed, file_missing or reconnect_required), statusReason, refreshing and refreshedAt, as for a data source.
Key permission: get_quiz_access_list (Read quiz access lists)
Response: 200, with the status.
| Status | When |
|---|---|
404 |
There’s no quiz with this id, or it follows no sheet. |
Read the access sheet now
Section titled “Read the access sheet now”POST/v1/quizzes/{id}/access-sheet/refresh
Asks for the sheet to be read again, as Read now does, and returns its status, as above. The list changes once the sheet has been read.
Key permission: manage_quiz_access_list (Manage quiz access lists)
Response: 200, with the status.
| Status | When |
|---|---|
404 |
There’s no quiz with this id, or it follows no sheet. |
List the access log
Section titled “List the access log”GET/v1/quizzes/{id}/access-logs
Who of the access list came in, newest first, a page at a time (page, perPage): each person once a day for each address they came from, for the last 90 days. People removed from the list since are included.
Key permission: get_quiz_access_logs (List quiz access logs)
Response: 200, with items and the page’s pagination. Each item has enteredAt, person (id, name, email, removedAt) and ipAddress, which can be null.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
Get the results
Section titled “Get the results”GET/v1/quizzes/{id}/results
What the quiz’s or survey’s responses add up to: the headline figures, where people stopped, the spread of scores, the trend over time and every question’s results. Pass a filter as JSON in filter to read only some responses; Query the results takes segments as well.
Key permission: get_quiz_results (Read quiz results)
Response: 200, with quizTitle, mode and results:
| Field | Meaning |
|---|---|
kpis |
started (attempts begun), finished (sent or ended by their time), completionRate (finished of started, in %), medianSeconds; for a quiz also averagePercent and passRate of the graded responses. |
pages |
For each page, from 1: how many attempts reached it, and how many stopped on it unfinished. |
scores |
A quiz’s graded responses in tenths of the scale: from, to, count. Empty for a survey. |
trend |
Finished responses by day, week, month or year (unit, chosen by the span) in your organization’s time zone: each bucket’s start, responses and the metrics of the questions in metricQuestions. |
questions |
Every question’s results, in the quiz’s order, as form results give them, by the question’s id in key. A question with a metric has its score in metric. |
small |
true when fewer than 5 responses are counted: read the numbers with care. |
withheld |
An anonymous survey’s view or segment of 1 to 4 responses: true, with only kpis counted and pages, scores, trend and questions empty. Its text answers list nothing either. |
A question’s metric has metric (nps, csat, ces), value, responses and what the score is made of: an NPS (-100 to 100) its promoters (9-10), passives (7-8), detractors (0-6) and marginOfError at 95 % confidence; a CSAT (the % who answered 4 or 5) its satisfied; a CES its mean.
Results are counted from the encrypted answers and kept until a response changes, so the same view asked again comes back at once.
A quiz or survey with more than 20,000 responses is counted in the background. Until a view has been counted, the answer is 202 with {"computing": true, "responses": 23512}: ask again a few seconds later. Once it has been counted, new responses are counted in the background again, and in the meantime the answer is 200 with the view as it was last counted and countedAt, when that was. countedAt is null for a view of the responses as they are now. Whoever opened the view in the app is told when it is ready.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
filter is not a filter the results can read; the violation names the condition. |
Query the results
Section titled “Query the results”POST/v1/quizzes/{id}/results/query
The results over the responses a filter leaves, and beside them up to 4 segments, each a name and a filter applied within the main one: “Kraków” beside “Warsaw”. One reading of the responses counts them all.
{ "filter": { "conditions": [{ "field": "finished", "operator": "between", "from": "2026-11-01", "to": "2026-11-30" }] }, "segments": [ { "name": "Kraków", "filter": { "conditions": [{ "field": "answer", "question": "q-city", "operator": "in", "values": ["krakow"] }] } }, { "name": "Warsaw", "filter": { "conditions": [{ "field": "answer", "question": "q-city", "operator": "in", "values": ["warszawa"] }] } } ]}Key permission: get_quiz_results (Read quiz results)
Response: 200, as Get the results, with segments: each segment’s name and its results in the same shape. More than 20,000 responses are counted in the background, as there: 202 until they are.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
A condition is incomplete, or there are more than 4 segments. |
Filters
Section titled “Filters”A filter is a list of conditions; a response counts when it meets all of them. Several values of one condition are alternatives (“chose A or B”).
| Field | Meaning |
|---|---|
field |
What the condition reads: answer (the answer to the question whose id is in question), finished (the day it was finished), language, status (in_progress, grading, completed, needs_review), device (desktop, tablet, mobile), param or metadata (named in question), group (the group of who took it: their access-list entry’s, else a group question’s answer). |
operator |
in (one of values; for checkboxes, any of those ticked), between (min and max for a number, from and to as YYYY-MM-DD for a day, both included), contains (text, whatever the case and accents), answered, skipped. |
finished takes only between; language, status and device only in; group takes in, answered and skipped. Each person counts once, by the attempt the quiz counts for them (best, last or first).
Cross-tabulate the results
Section titled “Cross-tabulate the results”POST/v1/quizzes/{id}/results/crosstab
How many finished responses fall in each pair of a row and a column. rows and columns each name a field: answer with the question (a single or multiple choice, a checkbox, a rating, a scale, or a number in ranges), language, status, device, param or metadata with its name in question. An NPS question’s answers can be read by their group with "grouping": "nps": the categories detractors (0-6), passives (7-8) and promoters (9-10); grouping on any other question is answered 400, on anything but an answer 422. A filter narrows the responses as above.
Key permission: get_quiz_results (Read quiz results)
Response: 200, with rowsLabel, columnsLabel, rows and columns (each key, label and total), counts by row and column (in an anonymous survey null in every cell of a row or column of fewer than 5 responses, and so is its residual), total (the responses that answered both), and significance: Pearson’s chi-square test of the table (chiSquare, degreesOfFreedom, pValue) and each cell’s adjusted standardised residual in residuals. A residual of 1.96 or more means significantly more responses than expected at the 5 % level; -1.96 or less, significantly fewer. When the table is not tested, significance is null and untested says why: too_few (an expected count below 5) or multiple (a response can be in several rows or columns, as with checkboxes).
| Status | When |
|---|---|
400 |
The question is a text or a date, which fall in no categories (code quiz_crosstab_not_categorical). |
404 |
There’s no quiz with this id in your organization, or it has no such question. |
Read the quotas
Section titled “Read the quotas”GET/v1/quizzes/{id}/results/quotas
How full a survey’s quotas are. A quiz keeps no quotas, so for a quiz items is always empty; a survey’s are read at GET /v1/surveys/{id}/results/quotas.
Key permission: get_quiz_results (Read quiz results)
Response: 200, {"items": []}. For a survey, each item has id, label, limit, filled and full, in the survey’s order.
AI analysis
Section titled “AI analysis”The AI analysis of a quiz’s or a survey’s open answers: each open question’s themes and the summary. Running an analysis, and its estimate, are for people signed in to the application, since each run is paid: they are not access-key operations.
GET/v1/quizzes/{id}/analyses
Key permission: get_quiz_results (Read quiz results)
Response: 200, with available (a run may be asked for: a paid plan with AI), consentNeeded, scrubPersonalData, anonymous, running, questions and summary. Each question has questionId, label, answers (responses that answered it), analysed, newAnswers (what an update would read), status (queued, running, ready, paused, failed, or null before the first run), stop (budget, cap, unavailable, failed), sentiments (positive, neutral, negative, mixed counts), withheld, finishedAt, cost (allowancePercent, balanceUsd, integrationUsd) and themes, the largest first: id, name, definition, edited, count, share (percent of the analysed answers), sentiments and quotes (attemptId, text: words copied exactly from that response’s answer, each quote different words; count: how many answers of the theme said those same words). In an anonymous survey a theme of fewer than 5 answers is left out, and a question of fewer than 5 analysed answers is withheld with no themes. summary has status, stop, headline, strengths and problems (each title, detail), actions, responses, finishedAt and cost, or is null.
GET/v1/quizzes/{id}/analyses/answers?question={questionId}&theme={themeId}
The answers in one theme, the newest first, page and perPage as in other lists: each attemptId, text, themeIds, sentiment, edited (a person chose its themes) and finishedAt.
Key permission: get_quiz_results (Read quiz results)
PUT/v1/quizzes/{id}/analyses/themes
A person’s change of a question’s themes, which no later update undoes. The body has questionId and operation: rename (themeId, name, definition), merge (the themes of themeIds into themeId), split (the answers of attemptIds out of themeId into a new theme name), delete (themeId; its answers stay, in no theme), create (name, definition) or reassign (attemptId into themeIds, at most three, with its sentiment).
Key permission: manage_quiz_analyses (Manage the AI analysis of quizzes)
Response: 200, with the analysis as GET .../analyses returns it.
PUT/v1/quizzes/{id}/analyses/settings
scrubPersonalData (on by default): whether e-mail addresses, phone numbers, account, card and ID numbers and the respondent’s own name are taken out of the answers before they are sent.
Key permission: manage_quiz_analyses (Manage the AI analysis of quizzes)
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
409 |
The question has not been analysed (code quiz_analysis_not_analysed), has no such theme (quiz_analysis_theme_not_found) or answer (quiz_analysis_answer_not_found), or an analysis is under way (quiz_analysis_running). |
Export the responses
Section titled “Export the responses”GET/v1/quizzes/{id}/results/export?format=xlsx
The responses the results count that a filter (JSON, as GET .../results takes it) leaves, as a file in the language of Accept-Language, one row each with its answers in words: a choice by its label, a grid as “Row: column; …”, a ranking as “1. first; 2. second”. format is xlsx (the default: the title, when it was made, the filter in words and the number of rows above the rows; numbers, moments and durations as typed cells) or csv (the rows only, UTF-8). A quiz’s rows have the sheet number, name, e-mail, group, status, points, %, grade and whether it passed; a survey’s the respondent when known; an anonymous survey’s no person and only the day each was finished, in no particular order. Up to 20,000 responses the results count; for more, export in the background.
Key permission: export_quiz_results (Export quiz attempts); for a survey, export_survey_results (Export survey responses)
| Status | When |
|---|---|
400 |
More than 20,000 responses: export them in the background. |
404 |
There’s no quiz with this id in your organization. |
409 |
An anonymous survey with fewer than 5 finished responses under the filter. |
422 |
The filter is not valid. |
Export the responses in the background
Section titled “Export the responses in the background”POST/v1/quizzes/{id}/results/exports?format=xlsx
For more responses than an export made at once holds: the same query parameters (format and filter), up to 1,000,000 responses. The answer is 202 with the export’s id and the responses the results count; the file is made in the background. Whoever asked in the application is notified when it is ready; an access key asks for the file until it is.
POST/v1/quizzes/{id}/results/exports/drive?format=xlsx
The same, with the file also saved to a folder of a connected cloud drive once made. The body says where: storageId (the drive), directory (the folder, "" for the drive’s top; made when missing) and name (the file’s name). A name already taken there keeps both files (NDA (2).xlsx). The notification says where the file went, or that it could not be saved and is there to download. This needs the Manage cloud files permission as well (a key also needs upload_cloud_file).
GET/v1/quizzes/{id}/results/exports/{exportId}
The export’s file, for whoever started it (the same person, or the same access key); anybody else gets 404. 409 while it is being made, or when it could not be. Files are kept for 7 days.
Key permission: export_quiz_results (Export quiz attempts); for a survey, export_survey_results (Export survey responses)
| Status | When |
|---|---|
400 |
More than 1,000,000 responses, or the filter is not valid JSON. |
403 |
Saving to a drive without the Manage cloud files permission. |
404 |
There’s no quiz with this id in your organization, no such drive, or no such export of yours. |
409 |
The file is still being made, or could not be made. |
Results report (PDF)
Section titled “Results report (PDF)”GET/v1/quizzes/{id}/results/report.pdf
The results the Results show for the responses a filter (JSON, as GET .../results takes it) leaves, as a PDF in the language of Accept-Language, ready to print or send: the organization’s logo, the title, the filter in words, the headline figures (started, finished, completion rate, median time; a quiz’s average score and pass rate), the trend, a quiz’s spread of scores, where people stopped, and a card for every question in the quiz’s order under its section - bars with counts and shares, a grid’s rows split across its columns, a ranking’s options by their mean place, NPS as a dial with its three groups, CSAT and CES beside their answers, the latest answers of a long text. Charts are drawn in the organization’s accent colour; the paper is the answer sheets’ (A4 or Letter). No card is ever split between two pages. An anonymous survey with fewer than 5 finished responses under the filter gives only how many began and finished.
Key permission: export_quiz_results (Export quiz attempts); for a survey, export_survey_results (Export survey responses)
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
422 |
The filter is not valid. |
Saved reports
Section titled “Saved reports”GET/v1/quizzes/{id}/reports
The quiz’s saved reports of its results, by name: {"reports": [...]}. Each has id, name, createdBy (who saved it first, or null), updatedAt and view: the filter and up to 4 segments as POST .../results/query takes them, charts (a question card’s chart by its question’s key: bars, donut or table; a card not listed draws bars) and tab (overview, questions, crosstab, responses, summary, grading, people or ai).
POST/v1/quizzes/{id}/reports
PUT/v1/quizzes/{id}/reports/{reportId}
DELETE/v1/quizzes/{id}/reports/{reportId}
POST saves a report ({"name": "Board", "view": {...}}, 201), PUT renames it or keeps another view in it, DELETE removes it (204); the responses are never touched. A quiz keeps at most 50 reports.
Key permission: get_quiz_reports (View saved quiz reports) to list, manage_quiz_reports (Manage saved quiz reports) to save, change and delete; for a survey, get_survey_reports and manage_survey_reports
| Status | When |
|---|---|
404 |
There’s no quiz with this id, or no report with this id in the quiz, in your organization. |
409 |
The quiz already keeps 50 reports. |
422 |
No name, a name over 120 characters, more than 4 segments, or a chart or tab that does not exist. |
Share a saved report
Section titled “Share a saved report”PUT/v1/quizzes/{id}/reports/{reportId}/share
DELETE/v1/quizzes/{id}/reports/{reportId}/share
PUT shares a saved report by a link, or changes how: {"password": "…", "removePassword": false, "expiresAt": "2026-12-31T23:59:00+01:00"}, every field optional. A password (4 to 128 characters) is set, none keeps the one the link has, removePassword removes it; expiresAt is when the link stops opening (null: until sharing stops). A report shared already keeps its link. The answer is the report with share: token (the report opens at https://<your address>/r/{token}), hasPassword, expiresAt, expired and views (how often it was shown through the link). DELETE stops sharing: the link no longer opens, and sharing again gives another one. Every report has share, null while it is not shared.
The link shows the report’s view over the responses as they are now, and aggregates only: no question asking who someone is, no text answer, no key of a quiz, no segment of fewer than 5 finished responses, and of a view of fewer than 5 only how many started and finished. The filter is said in words unless it reads a text, a link parameter, metadata or a question asking who someone is.
The link’s own endpoints need no key: GET /v1/public/quiz-reports/{token} (401 while it asks for a password), POST /v1/public/quiz-reports/{token}/secure with {"password": "…"}, and POST /v1/public/quiz-reports/{token}/report.pdf (with the password in the body when it has one) for the PDF. Wrong passwords count against your organization’s rate limits; an expired link answers 410, a report not shared 404.
Key permission: manage_quiz_reports (Manage saved quiz reports); for a survey, manage_survey_reports
| Status | When |
|---|---|
400 |
expiresAt has passed. |
404 |
There’s no quiz with this id, or no report with this id in the quiz, in your organization. |
422 |
A password shorter than 4 or longer than 128 characters. |
List a text question’s answers
Section titled “List a text question’s answers”GET/v1/quizzes/{id}/results/answers?question={questionId}
A text question’s answers, newest first, a page at a time (page, perPage): all of them, those of one group of a short text, or those containing query, over the responses filter leaves. Each has text, submissionId (the attempt’s id) and sentAt.
GET/v1/quizzes/{id}/results/groups?question={questionId}
A short text’s groups of answers, the largest first: answers that say the same whatever their case, spaces and accents, each with key, label and count.
Key permission: get_quiz_results (Read quiz results)
| Status | When |
|---|---|
400 |
The question is not a text. |
404 |
There’s no quiz with this id in your organization, or it has no such question. |
Export a person’s quiz data
Section titled “Export a person’s quiz data”GET/v1/quizzes/people/export
Everything your organization’s quizzes and surveys hold about one person, for a request to see their data: found by their e-mail address, as a contact, or both, across every quiz. email and contactId are query parameters; at least one is required, and contactId needs the right to read contacts.
Key permission: manage_quiz_person_data (Export and erase a person’s quiz data)
Response: 200:
| Field | Type | Meaning |
|---|---|---|
listed |
list | Their places on access lists: quiz, name, email, group, invitedAt, openedAt, finishedAt. |
links |
list | The personal links to quizzes they were sent: quiz, sentTo, invitedAt, openedAt, finishedAt. |
attempts |
list | Every attempt they took through either, or wrote that address in: quiz, mode, number, status, startedAt, finishedAt, score, maxScore, percent, passed, grade, ipAddress, and answers, each a question with its answer. |
curl 'https://api.doxtly.com/v1/quizzes/people/export?email=helena.lindqvist%40fjordline.example' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET"| Status | When |
|---|---|
403 |
contactId is given by a caller who may not read contacts. |
404 |
There’s no contact with this id in your organization. |
422 |
Neither email nor contactId, or an address that isn’t valid. |
Erase a person’s quiz data
Section titled “Erase a person’s quiz data”POST/v1/quizzes/people/erase
Erases one person from your organization’s quizzes and surveys, for a request to be forgotten, found as for the export. Their attempts lose everything that names them: name, address, group, IP address, location, browser and the link’s parameters. Their answers are deleted, unless keepAnswers keeps them, anonymised, in the results. They are taken off every access list, and the contact’s personal links to quizzes are deleted. The workflow runs their attempts and invitations started are deleted with their steps and data; a run still under way is deleted once it ends. This can’t be undone.
Key permission: manage_quiz_person_data (Export and erase a person’s quiz data)
Body: email, contactId (at least one), and keepAnswers, default false.
Response: 200, with how many attempts were anonymised, how many places on lists (entries) and personal links were deleted.
curl -X POST 'https://api.doxtly.com/v1/quizzes/people/erase' \ -H "X-Api-Key: $DOXTLY_API_KEY" -H "X-Api-Secret: $DOXTLY_API_SECRET" \ -H 'Content-Type: application/json' \ -d '{"email":"helena.lindqvist@fjordline.example","keepAnswers":true}'{ "attempts": 3, "entries": 2, "links": 0 }| Status | When |
|---|---|
403 |
contactId is given by a caller who may not read contacts. |
404 |
There’s no contact with this id in your organization. |
422 |
Neither email nor contactId, or an address that isn’t valid. |
The public page and personal links
Section titled “The public page and personal links”A person of the access list has a personal link: the quiz’s public address with their key added, /q/{publicToken}?key=.... A contact sent a personal link opens the quiz at /cq/{token}, and the public endpoints, /v1/public/quizzes/{token}…, take that token in place of the public one; the page then has prefill, the answers the link fills in from the contact’s details, by the question’s data key. Either way, the person is let in and known whatever the quiz’s access mode, and their attempt is theirs. A key or a link revoked or expired is answered 410 Gone with code personal_link_revoked or personal_link_expired, and branding, the name, logo and colour of your organization.
On a quiz for invited people, the public page lets in no one else; without a key or a link, it answers 401 with code invitation_required, mode (quiz or survey, to word the page by) and asks for nothing. On a quiz with passwords, each person of the list types their own.
A survey sent to a contact carries a link to decline surveys, {{ optOutUrl }} in the message. GET /v1/public/quizzes/{token}/opt-out, with the token of the contact’s link, says whether they declined already (optedOut) with your branding, and POST to the same address declines: the contact’s surveysOptOutAt is set, and they are sent no more surveys or their reminders. Another token answers 404. Once the contact declined, both answer resubscribeToken too, a signed token: POST /v1/public/surveys/resubscribe/{resubscribeToken} subscribes them to your surveys again (optedOut is then false), and a token Doxtly did not sign answers 404. Only the contact can do this: neither your team nor an access key can undo an opt-out. A quiz’s message carries no such link: an exam is part of a course or a job.
Exam safeguards on the public page
Section titled “Exam safeguards on the public page”The public view, GET /v1/public/quizzes/{token}, carries proctoring, the same object as the quiz’s settings, for the page to act on. The page keeps fullscreen and blockPaste itself; the server keeps oneDevicePerKey.
The page sends its device mark, a string of up to 100 characters it keeps in the browser for each quiz, as deviceId in the body of the start (POST /v1/public/quizzes/{token}/attempts), of the progress (POST /v1/public/quizzes/{token}/attempts/{attempt}/progress) and of the submit (POST /v1/public/quizzes/{token}/attempts/{attempt}/submit), and as ?device= on GET /v1/public/quizzes/{token}/attempts/{attempt}. When the quiz has oneDevicePerKey and the attempt starts with a key of the access list or a personal link, it is held to that mark; Doxtly keeps only a digest of it. While the attempt is in progress, a request with another mark, or with none, changes nothing and is answered 409 Conflict: This attempt is being taken on another device. Continue there, or ask the examiner to release it. An attempt started from the open link, or without a mark, is not held.
Import questions from a file
Section titled “Import questions from a file”POST/v1/quizzes/questions/import
Key permission: import_quiz_questions (Import questions from files)
Reads the questions of a file for a quiz or a survey and stores nothing: add them to the content.items of Update a quiz. Send multipart/form-data:
| Field | What it is |
|---|---|
file |
GIFT, Aiken, Moodle XML (.xml), or an Excel or CSV sheet with the columns question, type (single, multiple, text, number, essay, truefalse), options (one per line or split by |), correct (option texts or letters, accepted answers, or the number), points and tolerance, and for the question library tags (split by commas or |), difficulty (1 to 5) and id (a library question’s id). At most 2 MB and 500 questions. |
storageId, path |
In place of file: a file on one of the organization’s connected drives, read on the server with the same limits. The key also needs get_cloud_files, the person the View cloud files permission; another organization’s drive answers 404, a file of another kind 422 before it is read. |
format |
Optional: gift, aiken, moodle_xml or sheet. Left out, the extension and then the text decide. |
trueLabel, falseLabel |
Optional: the two options of a true-or-false question, in your language. True and False by default. |
columns[field] |
Optional, for a sheet: the column read as question, type, options, correct, points, tolerance, tags, difficulty, id, body or explanation, by its header, e.g. columns[question]=Pytanie. The fields not given are found by their names. |
Response: 200
{ "questions": [ { "type": "single", "label": "2 + 2 =", "options": [{ "label": "4", "correct": true }, { "label": "5", "correct": false }], "accepted": [], "value": null, "tolerance": 0, "points": null, "line": 1, "id": null, "tags": [], "difficulty": null } ], "problems": [{ "line": 4, "reason": "unsupported", "excerpt": "Match the capitals…" }], "columns": [], "mapping": {}}reason is unsupported (matching, cloze and other kinds Doxtly has no field for), no_text, no_options, no_answer or unreadable. Each question also carries id, tags and difficulty, read from a sheet’s id, tags and difficulty columns (null and [] otherwise), and body and explanation: the question’s content and explanation as Markdown, from a sheet’s body and explanation columns, from a GIFT or Moodle XML question text of several paragraphs (all but the last) and from its general feedback; null where the file says nothing of them. All are for Import questions into the library. For a quiz’s content.items, each question also has bodyItems and explanationItems: that Markdown already made into items, exactly as the library makes them (a paragraph each block, a heading each # line, a divider each ---, a video each YouTube or Vimeo address on a line of its own), to put as the question’s body and feedback under ids of your own; [] where there is none, and a survey’s explanationItems is always []. A picture can’t come from words: picturesLeftOut counts those the Markdown named. For a sheet, columns is its header and mapping the column read as each field (null for none); mapping is always an object, {} for the other formats; while no column is read as question, the answer has no questions, so you can send the file again with columns[question]. POST /v1/surveys/questions/import (import_survey_questions) reads a survey’s sheet, whose questions need no right answers.
| Status | When |
|---|---|
422 |
No file, a file over 2 MB, one that cannot be read as its format, or one with no questions. |
Question library
Section titled “Question library”Your organization’s question library: questions saved once, with tags and a difficulty, to add to any quiz or to draw for each attempt with a section’s drawFrom. It holds up to 2,000 questions. Surveys have their own library: every request below also exists under /v1/surveys/question-bank, with the survey key permissions get_survey_question_bank (Read the survey question library) and manage_survey_question_bank (Manage the survey question library). A survey question has no right answer, and a survey’s library exports to sheet only: gift and moodle_xml answer 422. A question of the other kind or of another organization answers 404.
A library question has these fields:
| Field | Type | Meaning |
|---|---|---|
id |
string | Its identifier in the library. |
kind |
string | quiz, or survey for a survey’s library. |
item |
object | The question, an item as in a quiz: element, answerKey, points and the rest. |
tags |
list of strings | What it is filed under. |
difficulty |
integer or null | From 1 to 5, or null when not set. |
updatedAt |
string or null | When it was last changed. |
language |
string or null | The language the question is written in, null for your organization’s. |
translations |
object | Its words in other languages, by language, as a quiz’s language versions hold them: by the id of the question and of the items in its body and explanation. |
A library question’s pictures are its own files: removing the quiz it came from doesn’t take them away.
List the question library
Section titled “List the question library”GET/v1/quizzes/question-bank
Key permission: get_quiz_question_bank (Read the quiz question library)
Headers: X-Api-Key, X-Api-Secret
Query parameters: tag, only the questions carrying this tag, capital letters aside; search, only those whose question text holds these words.
Response: 200, the questions in the order of their text, every tag of the library with how many questions carry it, and total, how many questions the library holds whatever the filters:
{ "items": [ { "id": "01a2037f-0470-7e1a-92cd-56cc6b00419e", "kind": "quiz", "item": { "element": { "elementType": "field", "type": "radio", "dataPath": "bank_3f156e75bafcbe0a", "label": "Where is the nearest exit?", "placeholder": null, "info": null, "helperText": null, "required": true, "pattern": null, "cssClass": null, "options": [ { "value": "a", "label": "Behind you", "condition": null }, { "value": "b", "label": "To your left", "condition": null } ], "optionsSource": null, "scaleConfig": null, "ratingConfig": null, "textareaConfig": null, "numberConfig": null, "dateConfig": null, "timeConfig": null, "dateTimeConfig": null, "fileConfig": null, "computedConfig": null, "codeConfig": null, "defaultValue": null, "spamProtection": false, "drawingConfig": null, "resultsConfig": null, "matrixConfig": null, "id": "bank_3f156e75bafcbe0a", "condition": { "enabled": false, "mode": "simple", "dataPath": null, "operator": null, "value": null, "expression": null } }, "placement": "fixed", "points": 1, "answerKey": { "kind": "choice", "correct": [ "b" ], "partialCredit": false, "accepted": [], "caseSensitive": false, "value": null, "tolerance": 0, "rubric": null, "penalty": null, "rubricItems": [], "rubricScoring": "additive" }, "feedback": [], "shuffleOptions": false, "pinnedOptions": [], "body": [], "optionPictures": {}, "optionLayout": "list", "metric": null, "identity": null, "draw": null, "jumps": [], "drawFrom": null, "timeLimitSeconds": null }, "tags": [ "fire safety", "induction" ], "difficulty": 2, "updatedAt": "2026-11-22T14:43:05+01:00", "language": "en", "translations": { "pl": { "title": null, "items": { "bank_3f156e75bafcbe0a": { "label": "Gdzie jest najbliższe wyjście?", "helperText": null, "placeholder": null, "info": null, "content": null, "options": { "a": "Za tobą", "b": "Po lewej" }, "accepted": null, "pictureAlt": null, "optionAlts": {} } } } } } ], "tags": [ { "tag": "fire safety", "count": 1 }, { "tag": "induction", "count": 1 }, { "tag": "LANE4 TEST", "count": 1 }, { "tag": "Produkt", "count": 1 } ], "total": 2}Save questions to the library
Section titled “Save questions to the library”POST/v1/quizzes/question-bank
Key permission: manage_quiz_question_bank (Manage the quiz question library)
Body:
| Field | Type | Meaning |
|---|---|---|
items |
list of objects | Required: 1 to 100 questions, each an item as in a quiz. |
tags |
list of strings | Up to 20, each up to 50 characters, given to every question saved. |
difficulty |
integer or null | From 1 to 5, or null. |
quizId |
string or null | The quiz the questions come from. A picture sent by its fileId that this quiz holds is copied for the library; any other picture sent by its fileId is left out. |
language |
string or null | The language the questions are written in, null for your organization’s. |
translations |
object | Their words in other languages, by language, as a quiz’s language versions hold them. The words of the questions sent and of the items in their bodies and explanations are kept; any others are left out. |
Each question is saved as a question of its own: it gets a new element id and data path, bank_ followed by 16 hexadecimal characters, and the quiz it came from keeps its own. Its pictures are copied as files of its own; a new picture can also be sent with its content, as in a quiz. Only a question can be saved, and on its own: without a condition, jumps or an identity role.
Response: 201, with { "items": [...] }: the questions saved, as List the question library returns them.
| Status | When |
|---|---|
422 |
A field isn’t valid. items[n].element: an item isn’t a question (content or a section). items[n].jumps: it has a condition, jumps or an identity role. items[n].answerKey: a survey question has a right answer. items: the library would hold more than 2,000 questions. |
Change a library question
Section titled “Change a library question”PUT/v1/quizzes/question-bank/{id}
Key permission: manage_quiz_question_bank (Manage the quiz question library)
Body: as for Save questions to the library, with exactly one item. The question keeps its element id and data path. The tags, the difficulty and the language versions sent replace the old ones. A picture sent back by its fileId is kept; one no longer sent is removed.
Response: 200, with the question as List the question library returns it. Quizzes it was added to keep their copies.
| Status | When |
|---|---|
404 |
There’s no question with this id in your organization’s library of this kind. |
422 |
As for saving; items when more than one item is sent. |
Remove a library question
Section titled “Remove a library question”DELETE/v1/quizzes/question-bank/{id}
Key permission: manage_quiz_question_bank (Manage the quiz question library)
Response: 204, with no body. Sections stop drawing it, and attempts that drew it keep it.
| Status | When |
|---|---|
404 |
There’s no question with this id in your organization’s library of this kind. |
Copy library questions for a quiz
Section titled “Copy library questions for a quiz”POST/v1/quizzes/question-bank/copies
Key permission: get_quiz_question_bank (Read the quiz question library)
Body: ids, 1 to 300 library question ids, in the order you will add them.
Response: 200, with { "items": [...] }, each { "item", "language", "translations" }: the question with each picture’s content as a data URI and no fileId, so the quiz you add it to stores the picture as its own file when it is saved. Nothing is stored. An id of another kind’s library or of another organization’s is left out.
Import questions into the library
Section titled “Import questions into the library”POST/v1/quizzes/question-bank/import
Key permission: manage_quiz_question_bank (Manage the quiz question library)
Stores in the library the questions read from a file, as Import on the library’s page does. Read the file first with Import questions from a file, which stores nothing, and send its questions back.
Body:
| Field | Type | Meaning |
|---|---|---|
questions |
list of objects | Required: 1 to 500 questions, exactly as Import questions from a file answered them: type, label, options (each with label and correct), accepted, value, tolerance, points, line, id, tags, difficulty, body and explanation. Questions read from a Word file in the app have the same shape. |
tags |
list of strings | Added to each question’s own tags. |
difficulty |
integer or null | From 1 to 5: replaces each question’s own difficulty. null keeps theirs. |
duplicates |
string | What happens to a question the library already holds: skip leaves it as it is, update updates it from the question sent. |
language |
string or null | The language the questions are written in, null for your organization’s. |
A question sent is one the library already holds when its id is the id of a question in this library; without an id, when the library has a question with the same text, capital letters and spaces aside, and of the same kind (a single choice, a multiple choice, a text question and so on). A question sent twice is stored once.
An update changes what the question sent holds: the text, the options’ labels by their place (extra options are added, missing ones removed), the right answer, the points, the tags (the question’s own tags or, when it has none, the library question’s, plus the body’s tags) and the difficulty. It keeps the option pictures, the language versions and the exact field type within its kind: a dropdown stays a dropdown, a slider a slider. A question sent of another kind, such as a single choice that became a multiple choice, is made anew under the same id, keeping its body and explanation.
Response: 200, with { "added": [...], "updated": [...], "skipped": 3, "picturesLeftOut": [4] }: the questions added and updated, as List the question library returns them, how many were left as they were, and the line of each question whose body or explanation named a picture that was left out.
body and explanation become the question’s body and feedback items: a paragraph each block, a heading each # line, a divider each ---, a video each YouTube or Vimeo address on a line of its own; a picture can’t come from words and is left out. On an update, Markdown equal to what the question’s items are exported as keeps those items exactly, pictures, videos and versions included; other Markdown makes the region anew, and its old pictures are deleted. null keeps the region. A survey’s question has no explanation.
| Status | When |
|---|---|
422 |
A question isn’t valid, or the library would hold more than 2,000 questions. |
Export library questions
Section titled “Export library questions”POST/v1/quizzes/question-bank/export
Key permission: get_quiz_question_bank (Read the quiz question library)
Body:
| Field | Type | Meaning |
|---|---|---|
format |
string | Required: sheet (an Excel file in the columns of Import questions from a file, with each question’s id), gift or moodle_xml. |
ids |
list of strings | The library questions to export. Without it, those tag and search choose, as in List the question library. |
tag |
string | Without ids: only the questions carrying this tag. |
search |
string | Without ids: only those whose question text holds these words. |
Response: 200, the file as an attachment: an .xlsx workbook, a .gift text file or an .xml file. The header X-Total-Count says how many questions it holds; questions its format cannot describe are left out. The sheet has body and explanation columns (a survey’s only body), the question’s content and explanation as Markdown, a picture as ; GIFT writes them as a [markdown] text before the question and a #### general feedback, Moodle XML as a format="markdown" question text and a generalfeedback. The template (GET .../question-bank/template) has the same columns and a second sheet of instructions.
sheetdescribes single choice and dropdown questions (assingle), multiple choice, short text and e-mail (astext), long text (asessay), and number, slider and rating questions (asnumber, with the answer key’s value). Yes/no, date, time, date and time, grid and ranking questions are left out.giftandmoodle_xmlhold single and multiple choice, short text with its accepted answers, numbers with their right answer, and open questions. Questions without a right answer (other than open ones), sliders, ratings and the typessheetleaves out are left out. GIFT carries no points; Moodle XML writes them as the default grade and the question’s id as its ID number.
A file holds words, not pictures: the pictures, explanations and language versions stay in the library.
| Status | When |
|---|---|
422 |
A field isn’t valid; for a survey’s library, gift or moodle_xml. |
Download the sheet template
Section titled “Download the sheet template”GET/v1/quizzes/question-bank/template
Key permission: get_quiz_question_bank (Read the quiz question library)
Response: 200, an Excel file in the library’s columns with an example row of each kind of question, written in the language of the request.
Delete several library questions
Section titled “Delete several library questions”POST/v1/quizzes/question-bank/delete
Key permission: manage_quiz_question_bank (Manage the quiz question library)
Body: ids, 1 to 2,000 library question ids.
Response: 200, with { "count": 3 }, how many questions were deleted. Ids of another organization’s library or of the other product’s are ignored. As with Remove a library question, sections stop drawing them, and quizzes and attempts keep their copies.
Change the tags of library questions
Section titled “Change the tags of library questions”POST/v1/quizzes/question-bank/tags
Key permission: manage_quiz_question_bank (Manage the quiz question library)
Body:
| Field | Type | Meaning |
|---|---|---|
ids |
list of strings | The library questions to change. |
add |
list of strings | Tags given to each of them. |
remove |
list of strings | Tags taken from each of them, capital letters aside. |
A question keeps at most 20 tags.
Response: 200, with { "count": 2 }, how many questions’ tags changed.
Delete a quiz
Section titled “Delete a quiz”DELETE/v1/quizzes/{id}
Key permission: delete_quiz (Delete quiz)
Response: 204, with no body.
| Status | When |
|---|---|
404 |
There’s no quiz with this id in your organization. |
409 |
Workflows still use it (code used_by_workflows, with workflows: their id and name). Change them first. The workflows of its results sheet (/results-sheet-workflow) don’t count: they are deleted with it, and the spreadsheet stays in the drive. |
What keys can’t do
Section titled “What keys can’t do”Some things stay in the app, for a person signed in:
- The designer’s helpers: the preview, the template gallery and your organization’s templates (saving a quiz as one included), drafting questions with AI, reading questions from a Word file, and trying a rubric on a sample answer. To build a quiz from code, send its items to Create a quiz, or read a sheet with Import questions from a file.
- Importing a portable file. See Import and export.
- Running the AI analysis and its estimate, since each run is paid.
- Setting up the starter workflows of a certificate and of a results sheet. A key builds the same with Create a workflow.
- Claiming an answer in the grading workspace. A key grades with the answer’s
versioninstead: see Grade an attempt.
The same holds for surveys, which have no certificate.