Knowing what each role can call
Each role (administrator, organiser, reader, stand lead, HR right) opens a precise scope of routes. Rights are granted in Settings › Accounts; the accounts come from the OIDC directory or local accounts.
What the organiser role does not open
organisateur: opens/apionly in the editions its rights in force name (an “all editions” right covers them all). Another edition is refused like a non-existent one (EDITION_INCONNUE, 400) and absent from the list. It does not open the instance routes, reserved toadmin(403): accounts, webhooks, MCP key, API keys, backups, export and import of the whole database, the Debug screen, the solve machine, the sign-in log, the simulated clock, creation, renaming, duplication, activation and deletion of an edition, comparison of two editions. The screen offers these gestures to an administrator only, sends the others to one, and the address of the Debug screen or of the edition comparison tells them so in one sentence. Scenario import stays open to it, in its current edition only: anedition:section naming another, or one to create, is refused (400).lecteur(one edition): sees like an organiser, without the staff members' space token, phone number, e-mail address or date of birth (it only reads who is a minor on the event’s first day), but the server refuses every write, every solve and every raw-data export; only PDFs and ICS pass. The refusal is judged edition by edition:GET /api/auth/mesays (lectureSeule) whether the edition the request names is read-only for this account, and the screen follows that field, so an account reading one edition and organising another writes in the second (ADR 0099 (external site), inventory:RoutesLecteurStructuralTest).responsable_stand: opens only/api/responsable/*(ADR 0095 (external site), below)./mcpalso accepts an OAuth token from the provider, under the same rights (mcp-connexion.md); its API key remains.- A named API key (reader or organiser role, editions named): read like an account holding that right on those editions, through the same filters, on
/api(X-Api-Key) and on/mcp; never an administrator, so never the instance routes nor the management of keys (mcp-connexion.md, ADR 0136 (external site)). TheLecteurCanariTestsweep passes it like a reader account.
Route classification by role
File (src/test/resources/) |
What it lists |
|---|---|
routes-organisateur.txt |
Each route of a “per edition” resource that is not @InstanceOnly |
routes-responsable.txt |
The routes of ResponsableResource (read-only) |
The stand lead: a read right, not one more door
An account (OIDC or local) can carry a RESPONSABLE_STAND right (Settings › Accounts): one edition, one or more of its stands, an optional expiry. It gives the responsable_stand role: /api/* outside /api/responsable/* answers 403 (role-gestion does not contain it, and @RolesAllowed doubles the HTTP rule on each method).
- Read-only, with one exception: the two read routes are
GETs, and a single write exists, “someone is missing” (POST /api/responsable/stands/{standId}/manques): a shift under way of one of its stands, with no name or text, which changes neither the plan nor what was worked and which the organisation files on the Today screen. It is rate-limited per account and logged;ResponsableProjectionStructurelleTestrefuses any other method. - Active edition only (ADR 0072): the request names neither edition nor stand. The service reads the active edition and the stands of the rights in force, and returns an empty view when nothing opens (expired or withdrawn right, deactivated account, inactive edition): the answer does not tell “not yours” from “does not exist”.
- A projection, never the domain: hours, filled and empty seats and, per setting, first and last name. No address, phone, age or minor status. The plan read is the published one, never the working plan.
- No cache:
Cache-Control: no-store. - Only administrators set name visibility (
@InstanceOnly), and the sheet, built from the same view, follows the same setting.
The HR right: the compliance report, one edition at a time
An account can carry an RH right (Settings, Accounts tab), for one edition (the database refuses an HR right without an edition). It gives the rh role, which opens only /api/rh/* (role-rh, also open to admin); the rest of the API answers 403. It adds to the account’s other rights: an HR user who is also an organiser keeps the organiser scope.
- The edition is in the path, never in
X-Edition-Id: an HR-only account is organiser of no edition.RhServicedecides the right edition by edition; an edition without a right and an unknown edition answer the same404. - Each consultation and each export (PDF, CSV) is logged by
RhServicein the report’s edition (the response filter would file it under the header’s edition), with the account id, never its address: the two file routes are in the argued list ofCatalogueActionsfor this reason. - The report reads the published plan, never a draft (
409without publication), with no date of birth or address: a name, the minor status. No MCP tool: it never leaves for an assistant. - Emergency contacts and legal representatives (
/api/rh/editions/{id}/contacts) follow the same rules (HR right or administrator, one edition per right, indistinct404, reads and writes logged). The administrator and the organiser also read those of a single person (/api/animateurs/{id}/contacts, logged, closed to the read-only account and to the stand lead), never in a list. A staff member reads and writes their own through their space (/api/espace-animateur/{jeton}/contacts, code session required), never another’s; they correct their own phone number the same way (/api/espace-animateur/{jeton}/telephone), the only write of the fiche an espace opens. They live inanimateur_contact, not inAnimateur:ContactsEspaceTestlooks for the number entered in a colleague’s space, the records and the exported scenario, and finds it nowhere.
A mistake, an omission? Fix this page on GitHub. (external site)