> To build or manage a Wix site with an AI agent, follow https://www.wix.com/headless/skill.md
> It builds a new Wix site or puts your own site online, from a prompt, and keeps changing it afterwards. The pages are code in any web technology, and Wix runs the backend.
> It works through the Wix plugin (the Wix MCP and the Wix skills), the Wix CLI or no Wix login, and puts the site live on Wix hosting or on another host.
> Business features include a store, bookings, events and tickets, a restaurant, a blog, forms, members and many more.
> Read the Wix skills online at https://www.wix.com/skills
> 
> Portal Navigation:
> 
> - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version.
> - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages).
> - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`).
> - If a reference page seems to be missing its schema (parameters, return types, or type definitions), append `?schema=true` to its `.md` URL (e.g. `https://dev.wix.com/docs/contexts/contexts/stores/category-info/use-category-info-context.md?schema=true`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

## Resource: Quiz Grading

## Article: Quiz Grading

## Article Link: https://dev.wix.com/docs/api-reference/business-management/online-programs/quizzes/quiz-grading.md

## Article Content:

# Quiz Grading

The Quiz Submissions API evaluates answers against the current quiz definition when a submission is created. It stores the resulting earned grade, passing grade, status, and per-answer evaluations on the submission.

## Answer matching

A submission's `answers` map uses each question's `target` as its key. Targets must remain stable and unique within the quiz. If a submitted target doesn't match a quiz question, the submission can't be evaluated.

Automatic matching depends on the question type:

| Question type | Matching behavior |
| --- | --- |
| Numeric | Exact numeric equality. |
| Short text | Leading and trailing whitespace is ignored, and comparison is case-insensitive. |
| Single choice | Exact equality with the correct option's submitted value. |
| Multiple choice | Matches the correct options' submitted values regardless of order. Duplicate values aren't ignored. |
| Long text | Not evaluated. |
| File upload | Not evaluated. |

### Choice labels and submitted values

For questions created with `Create Quiz` or `Bulk Create Quizzes`, each string in `singleChoice.options` or `multiChoice.options` is both the displayed label and the submitted value, unless the underlying form is later edited to store distinct values.

A quiz authored through Wix Forms can store a separate label and value for an option. `Clone Quiz` and `Bulk Clone Quizzes` clone the underlying form and preserve this distinction. For example, an option can display `B) Associative property` and submit `B`. Grading resolves the correct option to its stored string value, falling back to its label when no string value is present. A selected correct option in this example must submit `B`, not the display text.

The Quiz API's `Get Quiz` response returns choice labels and doesn't expose a separate option-value mapping. For a Forms-authored quiz with distinct values, use the form's option values when building a custom submission flow; don't infer them from the labels returned by `Get Quiz` or from an option's position. Existing distinct values don't need to be rewritten to match their labels.

## Missing answer keys and non-evaluable questions

A missing stored answer key is different from an answer key hidden in an API response. Hidden answer keys still participate in server-side grading. See [Permissions and answer-key visibility](https://dev.wix.com/docs/api-reference/business-management/online-programs/quizzes/introduction.md#permissions-and-answer-key-visibility) for details.

If a numeric, short-text, single-choice, or multiple-choice question has no stored right answer, its submitted answer is non-evaluable. Long-text and file-upload answers are always non-evaluable.

Non-evaluable answers count as correct when calculating `earnedGrade`. Provide a right answer for every automatically graded question, and account for long-text and file-upload questions when setting a passing grade.

## Earned grade and question scores

When `passingGrade` is configured, the earned grade is an unweighted integer percentage:

```text
earnedGrade = floor((answers counted as correct / submitted answers) * 100)
```

Each submitted answer has equal weight. For example, 2 correct answers out of 3 produce an earned grade of `66`, not `67`. A configured question `score` is returned for evaluable answers, whether correct or incorrect, but doesn't weight `earnedGrade` or determine pass/fail status. Non-evaluable answers omit `score`, `correct`, and feedback `message`; they still return the submitted value and question `fieldId`.

A submission is `FAILED` when its earned grade is lower than the configured passing grade. Otherwise, its status is `COMPLETED`.

If `passingGrade` is omitted, both `earnedGrade` and `passingGrade` are absent from the submission, and its status is `COMPLETED`, even if an individual evaluated answer is incorrect. Per-answer evaluation still takes place.

Submission status describes quiz evaluation only. It doesn't by itself mark the associated Online Programs step as completed. Use the [Resolved Steps API](https://dev.wix.com/docs/api-reference/business-management/online-programs/resolved-steps/introduction.md) to record participant progress using the participant ID, program step ID, and quiz submission ID.

## Attempt limits

`settings.attempts` limits submissions per submitter. If omitted, the service doesn't apply an attempt-limit check.

Without a `groupId`, the count uses quiz ID and submitter ID. When a `groupId` is supplied, the count uses group ID and submitter ID without filtering by quiz ID. Reusing a group ID across quizzes therefore shares their attempt count, which is checked against the current quiz's `settings.attempts` limit.

Use the same `groupId` only for attempts that should share one limit. Don't reuse a program ID as the group ID for every quiz unless that shared count is intended.

## Definition changes

Every new submission uses the current quiz definition. Previously stored submissions keep the grade and answer evaluations recorded when they were created. As a result, attempts created before and after a definition change can reflect different questions, answer keys, or passing-grade settings.