Grading scales
A grading scale turns an attempt’s score into a grade: a school’s 1 to 6, a university’s 2.0 to 5.0, A to F. Quizzes choose one in their settings (grading.scaleId). See Grading scales for how they work in the app.
Before you start
Section titled “Before you start”The overview explains sending requests, and the errors page the errors every endpoint can answer.
A scale’s rules hold its grades as thresholds: each grade runs from its minimum up to the next grade’s.
| Field | Type | Meaning |
|---|---|---|
basis |
string | percent (default): the minimums are a share of the points, 0 to 100. points: they are points, for a quiz whose highest score is the same for every attempt. |
decimals |
integer | 0 to 2 (default 2): the percent is rounded half up to this many decimals before it is graded, so 74.995 at two decimals is 75.00. |
bands |
array | 2 to 12 grades. Each has a minimum, different from every other grade’s, one of them 0; a label, its name by language ({"pl": "dobry", "en": "good"}, up to 60 characters each, at least one written); a code of up to 10 characters (4, B+); passed, whether the grade passes when the quiz passes by grade; color, #rrggbb or null; and an id, letters, digits, - and _. |
An attempt keeps the scale it was graded on. Changing a scale changes no grade given already.
List grading scales
Section titled “List grading scales”GET/v1/grading_scales
Your organization’s scales by name. archived=1 lists the archived ones too.
Key permission: get_grading_scales (Read grading scales)
Response: 200, with items. Each scale has id, name, description, rules, preset (the preset it was made from, or null), archived, usedBy (how many quizzes grade by it now) and updatedAt.
Get a grading scale
Section titled “Get a grading scale”GET/v1/grading_scales/{id}
Key permission: get_grading_scales (Read grading scales)
Response: 200, the scale as the list gives it.
| Status | When |
|---|---|
404 |
There’s no scale with this id in your organization. |
List the presets
Section titled “List the presets”GET/v1/grading_scales/presets
The scales Doxtly ships, each named in your language, to create one of yours from: Polish school 1-6, Polish university 2.0-5.0, letter grades A-F, ECTS A-F, UK degree classes, German school 1-6, Pass / Merit / Distinction and Pass / Fail. Their thresholds are common defaults, not rules.
Key permission: get_grading_scales (Read grading scales)
Response: 200, with items: each has key, name and rules.
Create a grading scale
Section titled “Create a grading scale”POST/v1/grading_scales
{ "name": "Our school 1-6", "description": null, "preset": "polish_school", "rules": { "basis": "percent", "decimals": 0, "bands": [ { "id": "pass", "minimum": 50, "label": { "en": "Pass" }, "code": "P", "passed": true, "color": "#16A34A" }, { "id": "fail", "minimum": 0, "label": { "en": "Fail" }, "code": "F", "passed": false, "color": "#DC2626" } ] }}| Field | Type | Meaning |
|---|---|---|
name |
string | Required, up to 100 characters. |
description |
string or null | Up to 500 characters. |
rules |
object | The grades, as above. |
preset |
string or null | The preset it was made from, kept for reference. |
Key permission: manage_grading_scales (Create, change and archive grading scales)
Response: 201, the scale.
| Status | When |
|---|---|
422 |
A field is wrong, named by its path: two grades start at the same value (rules.bands[1].minimum), no grade starts at 0 or there are fewer than 2 or more than 12 (rules.bands), a grade has no name (rules.bands[0].label). |
Update a grading scale
Section titled “Update a grading scale”PUT/v1/grading_scales/{id}
Takes the same body as Create a grading scale. Grades already given keep the scale they were given on; the next attempts are graded on the new grades.
Key permission: manage_grading_scales (Create, change and archive grading scales)
Response: 200, the scale.
| Status | When |
|---|---|
404 |
There’s no scale with this id in your organization. |
422 |
As for Create a grading scale. |
Delete a grading scale
Section titled “Delete a grading scale”DELETE/v1/grading_scales/{id}
Deletes a scale no quiz uses. A scale a quiz grades by is archived instead: that quiz keeps it, and no other quiz can choose it.
Key permission: manage_grading_scales (Create, change and archive grading scales)
Response: 204.
| Status | When |
|---|---|
404 |
There’s no scale with this id in your organization. |