TrainingAttempt
object type
A TrainingAttempt (🎓 — THE TRAINING PROGRAM, THE WIRE): ONE sitting of a course's test by ONE person — ALWAYS the caller who started it (nobody starts one for someone else). At start the platform draws 10 ACTIVE questions of the course (every active question when fewer; below 3 the start refuses CONFLICT/TRAINING_TOO_FEW_QUESTIONS) and stores EXACTLY that draw (questionIds); passMark is copied from the strictest requirement binding the person for the course, else the default; curriculumVersion is the play's content hash at the sitting. At submit the answers are GRADED SERVER-SIDE against the STORED draw (a later bank edit never re-grades it) — score 0..100, passed = score >= passMark; a PASS mints the TrainingCertificate in the SAME transaction (certificateId). open (live) → submitted (terminal, kept) by the subject · open → doomed (terminal) by manage authority. ONE open sitting per (person, course) — a second start refuses CONFLICT/TRAINING_ATTEMPT_OPEN; at most 5 sittings per (person, course) per UTC day (CONFLICT/TRAINING_CAP). The by-id read answers the subject or the training-manage right; the listing is the manage right's. NOT searchable.
Fields
| Field | Type | Notes |
|---|---|---|
id | ID ID! | The record’s id — a UUID the platform assigned when the record was created; every reference to this record uses it. |
sysId | String String! | The group-scoped human-facing system id (TT-…). |
type | String String! | The kind of record — always TrainingAttempt here. |
caption | String String! | The record’s display name — what people see it called. |
status | String String! | The FSM state: open | submitted | doomed. |
parentId | ID ID! | The parent org group; for a TrainingAttempt parentId === rootId. |
rootId | ID ID! | The org-group family root. |
createdAt | String String! | When the record was created, as a UTC timestamp. |
updatedAt | String String! | When the record last changed, as a UTC timestamp. |
revisionNum | Int Int! | How many times this record has been edited; the first save is 0. |
revision | ID ID! | The OCC revision token — supply it on every mutation of this record; rotates on every write. |
refCaptions | RefCaption [RefCaption!]! | The server-composed captions of this record's declared references (the referenced-caption rule) — one row per referenced id; see RefCaption. |
userId | ID ID! | The subject — the User who started the sitting; ALWAYS the caller. IMMUTABLE at birth. |
orgId | ID ID! | The organization the sitting was started in (the session’s acting org) — the progress record’s second coordinate. IMMUTABLE at birth. |
courseKey | String String! | The course — a live play key. IMMUTABLE at birth. |
questionIds | ID [ID!]! | THE DRAW — 3..10 question ids drawn from the ACTIVE bank at start, in the order asked; the grade is taken against exactly these. IMMUTABLE at birth. |
answers | Int [Int!] | One option index per drawn question, in the draw order — set ONCE at submit; null while open or doomed. |
score | Int | The grade 0..100 (rounded) — set at submit; null while open or doomed. |
passed | Boolean | score >= passMark — set at submit; null while open or doomed. |
passMark | Int Int! | Copied at start from the strictest requirement binding the person for the course, else the default 80. IMMUTABLE at birth. |
startedAt | String String! | The start instant (UTC ISO-8601). IMMUTABLE at birth. |
submittedAt | String | The submit instant (UTC ISO-8601); null while open or doomed. |
curriculumVersion | String String! | The play’s content hash at the sitting (16 hex — sha-256 over its title, line and the steps’ words); ’s refresh rule compares it. IMMUTABLE at birth. |
certificateId | ID | The certificate a PASSING submit minted in the same transaction; null on a fail, while open, or when doomed. |