Skip to main content

Roles & permissions (RBAC policy)

RBAC v2 (ADR 0026, deployed to dev 2026-11-13) changes several rules on this page: Super Admin alone creates Admins, Administrator holds firmware: FULL, Installers hold plants: EDIT and scope ALL, connected End Users get a remote-control switch, Businesses gain a lifecycle and users can be blocked. See RBAC v2; where the two disagree, RBAC v2 wins.

This page explains the product RBAC policy (five product roles and an 18-row module matrix) and how this API implements it. The decision record is ADR 0014 (docs/adr/0014-rbac-policy.md in cse-http-be). The policy is built on the existing org model: a role is still one level per category plus a scope rule, held through a membership in one organisation. The Authorization page covers that model (organisations, scopes, shares, the evaluator).

Nothing on this page has been run against a deployment. Every example is illustrative and derived from packages/core/src/schemas.ts and packages/core/src/access/system-roles.ts.

In plain words​

The basic idea. Every user belongs to an organisation and has a role there. A role is a list of 15 permission areas (plants, devices, register read, register write, commands, team, sharing and so on), and each area has a level: NONE → VIEW → EDIT → MANAGE → FULL. The server checks that level on every action; what the app shows or hides never decides anything.

RoleLives inGets its access from
Super AdminCrown platform orgEverything, always. Nobody can change it.
AdminCrown platform orgThe Super Admin decides its levels. Those edits apply to PLATFORM-org Administrators only.
BusinessIts own company orgThe Business role, named Business Owner in the API (roleName, roles list) since 2026-11-27; role id 01M648CKS3Z1RKGQ0AQB1SJTM4 unchanged (the Super Admin can adjust its permissions).
InstallerInside a BusinessThe Business sets its levels, never above its own.
End UserOwn account, or a customer of a BusinessFull control of own plants, or what an Installer or Business grants.

How access is set up​

  1. Super Admin sets the rules. They can change what Admin and Business may do, for every company at once.
  2. Super Admin or Admin creates a Business. The company is created and its owner gets an in-app invitation.
  3. The owner accepts and gets the Business role.
  4. The Business adds Installers, adjusts the Installer role (for example: read registers, but no commands) and assigns which plants or customers each one sees.
  5. The Business or an Installer connects End Users by sharing a plant or opening a customer portal at a tier (VIEW, SERVICE, FULL…), and can switch off single permissions ("FULL, but no register writing"). On a FULL grant it can also switch on two extra ones: "Delete/archive" (archive and restore the plant) and "Share plant access" (share that plant with another person).

Independent End Users sign up in the mobile app, own their plants fully, and can share them.

Two rules hold at every step:

  • You cannot give more than you have. An Installer with view-only access cannot give anyone edit access (403 FORBIDDEN, details.reason: "ESCALATION").
  • Removing access takes effect at once. The next request is checked against the new levels; live device sessions are refreshed.

Super Admin and Admin reach everywhere. Without being a member, they can open any active organisation: Businesses, partners, customers and personal accounts (since 2026-11-02), at their own role's levels. MFA is required, and every change they make is written to that organisation's own access log, so it stays visible.

How one action is checked​

Example (illustrative). Ali, an End User, tries to change a register on his inverter:

  1. The app sends the request to the HTTP API.
  2. The server finds every way Ali can reach that plant: his own role (if it is his own plant), a share someone gave him, his company's customer portal.
  3. Each way gives a level for every permission area; the highest one wins.
  4. If "register write" is high enough, the action is allowed; otherwise 403.
  5. For live device actions the same levels go into a short-lived realtime ticket (10 minutes). The TCP server reads it and allows or blocks register reads, register writes and commands.

In one line: your role gives you levels, sharing can add more up to a cap, the best level wins, and the server checks it on every request.

How it works​

Who gives access to whom​

Every arrow is a grant, and nobody can grant more than they hold: the escalation check caps each step at the granter's own levels. Super Admin is the only exception (it skips every escalation check, see Five product roles) and can never be granted or edited by anyone else.

How one request is decided​

The same evaluator runs for every web and mobile request (policy §10.10). It finds every path the caller has to the plant, gives each a level per category, and the strongest path wins. HTTP routes check that result directly; the realtime ticket carries the same levels to the TCP server, which enforces register and command access.

  • Membership role: a built-in role (with any Super Admin edit applied, see Phase 2b) or the org's custom role, limited to the member's scope (all plants, region, tag, customer or a plant list).
  • Share / customer portal: the external tier's ceiling, lowered by the per-permission limit if one is set (see Phase 2a). For an org grantee it is also capped by that member's own role.
  • Not a path: anything not granted. A category no path reaches is NONE, and the route returns 403.

Levels​

NONE < VIEW < EDIT < MANAGE < FULL. Each level includes the ones below it. The policy letters map as follows: V = VIEW, E = EDIT, M and VCEDM = MANAGE, FULL = FULL, — = NONE. CFG (configurable) is NONE until the parent role grants it. Super Admin holds FULL on every category; Administrator also holds FULL on several categories by default (see the level tables). Being Super Admin is the role itself, never a level shape: since 2026-11-03 a Super Admin may set any role to any level (FULL everywhere or roles: FULL included), and such a role is still not a Super Admin.

The five product roles​

Policy roleHow it is implemented
Super AdminSUPER_ADMIN system role (R-01). FULL in every category, scope ALL, held in the PLATFORM org.
AdminADMINISTRATOR system role (R-02) by default. A narrower custom role in the PLATFORM org made by a Super Admin is an "Admin with assigned permissions".
BusinessNew BUSINESS system role (R-90, fixed roleId 01M648CKS3Z1RKGQ0AQB1SJTM4). The first member of every new non-personal OPERATOR org gets it (before ADR 0014 it was ADMINISTRATOR). Existing members keep their role; an owner can reassign it.
InstallerNew seeded template INSTALLER (R-91), copied into every new non-personal org except the PLATFORM (Crown) org (since 2026-12-01) as an editable custom role. The Business edits it but cannot raise it above its own levels (escalation check). The role is SCOPED, but since ADR 0026 (2026-11-13) an Installer in a Business reaches every plant of that Business (scope ALL whatever is stored).
End User (Independent)Owner of a personal org, holding the built-in END_USER system role (R-92, fixed roleId 01M6R61YX1RZXDSYWBKTRYPKKR, ADR 0021) with scope ALL — their own plants only. Until 2026-11-06 the owner held ADMINISTRATOR, a privilege bug; existing owners move with the RBAC roles backfill --only personal.
End User (Connected)A member of the Business org with the END_USER role and a PLANTS scope (IO-7), usually invited by an Installer, and going through the same invite → sign in → accept/decline flow. A share or customer portal (capped by the external ceiling table) still works for access outside the org, such as family or a helper.

GET /v1/orgs/{orgId}/roles lists 4 system roles (Super Admin, Administrator, Business, End User) first, then the org's custom roles. A new org gets 1 template (Installer). Viewer and the Operations Manager, Technician, Sales and Compliance Auditor templates are retired (2026-11-03, see below). Orgs created before ADR 0014 have no Installer role and their owner keeps ADMINISTRATOR until the owner runs the RBAC roles backfill.

Five product roles (2026-11-03)​

Owner decisions on the web console's "Five Product Roles Only" request. Each role decides for the one below it:

RoleWhoDecides for
Super AdminCrownEverything, everywhere
AdminCrown (PLATFORM org)What each Business can do
BusinessAn installation company (its own OPERATOR org)What its Installers can do
InstallerA member of a BusinessWhat the End Users of their plants can see and do
End User, connectedA customer reached through a share or a portalNothing; uses what was granted
End User, independentOwner of a personal orgTheir own plants and devices

What changed in the API:

  • Super Admin is unrestricted (R-0). The Super Admin identity is the Super Admin role (fixed roleId), never "FULL everywhere". A Super Admin skips every escalation check, may set any built-in or custom role to any level, and may create standing access in a personal org reached through the platform fallback. Authentication, MFA, 422 validation and access-log entries still apply. Only a Super Admin assigns or removes Super Admin; the last active one cannot be demoted. Details: Authorization.

  • Viewer retired (R-1). Not listed by GET …/roles. Assigning it to a member, inviting with it, or copying it with POST …/roles is 422 VALIDATION_FAILED, details.reason: "ROLE_RETIRED". A membership or invitation already holding it keeps the old Viewer levels. POST …/roles now requires copyFromRoleId.

  • Installer is the only seeded template (R-2). New orgs no longer get Operations Manager, Technician, Sales or Compliance Auditor. The RBAC roles backfill deletes the copies no member or pending invitation holds.

  • Admin holds at least every Business level (R-3b). Administrator settings and roles are MANAGE (were EDIT and VIEW). An Admin therefore assigns the Business role and creates Businesses through the normal escalation check, and may create and edit custom roles. Built-in role edits stay Super-Admin-only. This applies to every Administrator membership, so personal-org and customer/partner-org owners can now manage custom roles in their own org.

  • Several Installer roles (R-4). A Business may copy the Installer role (POST …/roles with copyFromRoleId = its Installer role) into e.g. "Installer – senior"; each copy is capped at the Business's levels.

  • Installer starts at sharing: MANAGE (R-5). A new Installer can share plants in their scope (POST …/shares, POST /v1/plants/{plantId}/shares) and approve or reject access requests for them, within their own levels. customers stays NONE; the Business may raise it. The backfill raises existing Installer roles that are below sharing: MANAGE. Reversed 2026-11-23 (RBAC-S6): new Installer roles started at sharing: VIEW. Restored 2026-11-26 (owner): the template is MANAGE again and the backfill raises every Installer role in a Business to it — template roles and plain copies (copies on sharing only). Shares reach any plant of the Business, whoever added it.

  • Independent End User (R-6): unchanged.

  • Per-Business limit (R-3a, built 2026-11-03). An Admin or Super Admin sets what one Business may do with PUT /v1/orgs/{platformOrgId}/businesses/{businessOrgId}/limit (partial 15-category map). It lowers every member of that Business (Super Admin excepted) and every share and portal it granted. Routes and rules: Business permission limits. Global edits of the Business role stay Super-Admin-only.

  • Plant ↔ Installer link (R-5 decision 2, built 2026-11-03). Each plant records who registered it (installedBy, never changes) and its assigned Installer (assignedInstaller). A member of a Business on a custom role is auto-assigned to the plants they register, and reaches them at their own role levels; the Business moves plants between Installers with POST /v1/plants/{plantId}/installer and reads the history. End Users get nothing through the link. Details: Assigned Installer. The Installer template starts at plants: EDIT (owner 2026-11-03), so Installers can register plants at once; Installer roles seeded earlier keep VIEW until the Business raises them (the backfill does not change plants).

  • Work orders: the Business assigns, the Installer works (ADR 0019, deployed on dev 2026-11-05). The Installer role keeps service: VIEW. These rules sit on top of the levels:

    • Assigning, reassigning, unassigning, closing, cancelling and reopening need service: MANAGE (the Business).
    • The order's assigned Installer may accept or decline it, work it (schedule, start, wait, resume, complete) and add notes and photos, at any visible level.
    • An Installer-tier member (operator membership below service: MANAGE) sees only the orders assigned to them.
    • An Installer role at service: VIEW is enough to be assigned. A roster profile is not needed.

    Lifecycle v2 (ADR 0023, built 2026-11-10, not deployed) moves holding and resuming to service: MANAGE (the Installer only asks, with :request-hold). It adds :verify and :reject-completion for MANAGE; the order's own Installer can never verify it, even with MANAGE. An Administrator already equals a Super Admin for work orders, except where a per-Business limit caps the Administrator.

    Details: who may act.

The 15 categories​

RolePerms, GET /v1/me/context levels and the share ceilings now carry 15 keys. The last five are new.

CategoryPolicy row(s)What it gates in this API
plantsDashboard, PlantsPlant routes, dashboard; unlocks the overview, plants, analytics modules
devicesDevice ManagementPlant ↔ serial binding; realtime ticket lv.devices (TCP enforces device reads)
alertsAlertsAlert routes; realtime ticket lv.alerts
commandsDevice CommandsRealtime ticket lv.commands (TCP enforces commands)
firmwareFirmwareFirmware routes
serviceService / O&MService plans and work orders
reportsAnalytics & ReportsReport routes
customersCustomers; Business Management (held in the PLATFORM org)Customer routes, portal level
teamTeam ManagementMembers, invitations, departments, scopes (Team & Access)
settingsOrganization Settings; Platform Settings (held in the PLATFORM org)GET/PATCH /v1/orgs/{orgId}
registersRead newDevice Registers (Read)Realtime ticket lv.registersRead; enforced by TCP
registersWrite newDevice Registers (Write)Realtime ticket lv.registersWrite; enforced by TCP
sharing newPlant SharingShares (list VIEW, writes MANAGE) and incoming access requests (MANAGE). Was customers.
roles newRoles & PermissionsRole list and detail (VIEW), create, edit, delete (MANAGE) in Team & Access. Was team VIEW and team FULL.
audit newAudit LogsAccess log (VIEW; changes and requestId at MANAGE). Was team.

Capabilities changed too: role.superadmin.assign now checks roles = FULL (was team = FULL), and audit.export is also unlocked by audit ≥ VIEW.

The navigation modules list (NavModuleKey) gained sharing, roles and audit, placed before settings. Each is unlocked by the category of the same name. Show the Sharing, Roles and Audit screens from these modules, not from team or customers.

Backward compatibility: the derivation rule​

A permission map with only the original 10 keys is still accepted everywhere: stored roles, share ceilings and request bodies such as PATCH /v1/orgs/{orgId}/roles/{roleId} perms. The RolePerms Zod schema fills each missing new key before validation (derivedPolicyLevels). A key you send explicitly always wins.

New keyDerived from
registersReaddevices
registersWritecommands
sharingcustomers
rolesFULL if team is FULL; VIEW if team is VIEW, EDIT or MANAGE; otherwise NONE
auditteam

Because of this rule every role stored before ADR 0014 keeps exactly its previous effective access, and no data backfill is needed. Responses always carry all 15 keys. A web console role editor should show and send all 15.

Illustrative: an older client sends this perms body.

{ "plants": "EDIT", "devices": "EDIT", "alerts": "MANAGE", "commands": "EDIT", "firmware": "NONE",
"service": "MANAGE", "reports": "MANAGE", "customers": "VIEW", "team": "MANAGE", "settings": "NONE" }

The server stores and returns it with registersRead: "EDIT", registersWrite: "EDIT", sharing: "VIEW", roles: "VIEW", audit: "MANAGE" added.

Level tables​

Business (R-90, system role, scope ALL)​

CategoryLevel
plants, devices, alerts, commands, service, reports, customers, team, settingsMANAGE
registersWrite, sharing, rolesMANAGE
registersRead, auditVIEW
firmwareNONE (policy CFG)

Business never holds FULL, so it gets no platform-only capability. auditTrail: false. Display colour INFO.

Installer (R-91, seeded template, scope SCOPED)​

Every policy cell for Installer is CFG: the Business decides. Defaults from IO-9 (product owner, 2026-11-05): the End User's levels and a little more. The RBAC roles backfill raises existing Installer copies to these defaults. It never lowers them, so a Business's higher choices stay.

CategoryLevel
devices, alerts, sharing, reportsMANAGE
plants, commands, service, registersWriteEDIT
customers, registersReadVIEW
firmware, team, settings, roles, auditNONE

Since 2026-11-12 reports is MANAGE (was EDIT), so Installers can delete and schedule reports on their plants (Role boundaries). Which roles each org may grant, and the End User role for customer-org members, are on the same page.

Before 2026-11-06 the Installer defaults were: plants EDIT; devices, alerts, service, reports and registersRead VIEW; sharing MANAGE; everything else NONE. From 2026-11-06 to 2026-11-13 plants was MANAGE; ADR 0026 D3.1 set it back to EDIT, so an Installer sees and edits every plant of its Business but never archives or deletes one. With customers: VIEW it can read customer records. A Business that doesn't want this lowers its Installer copy. Inviting End Users is not a team level: see the Installer path in Invitations.

End User (R-92, system role, scope SCOPED)​

Built-in (ADR 0021): one definition everywhere, retuned only platform-wide by a Super Admin (Phase 2b below), never per org. End User ≤ Installer ≤ Business in every category.

CategoryLevel
plants, devices, alerts, sharingMANAGE
commands, registersWriteEDIT
reports, registersReadVIEW
service, firmware, customers, team, settings, roles, auditNONE

Since 2026-11-12 (console request §4) service is NONE (was EDIT): End Users have no Work orders / Service area. Raising a service request on their own plant needs only plants ≥ VIEW, so it still works. They keep commands and registers to control their own devices, but GET /v1/me/context never lists the engineering module for the End User role (Role boundaries). A Super Admin override of End User stored before then keeps its own service level until it is edited.

Their own account settings (profile, password, notifications) are always available through /v1/me/*; settings here is the organisation's. Plant delete is not a level. Only the owner of a personal org may delete a plant of that org (DELETE /v1/plants/{plantId} with X-Org-Id). A connected End User (member of a Business) neither deletes nor archives: since ADR 0026 their plants level is capped at EDIT in the Business, and commands and registersWrite are NONE until the Business turns their remote control on (RBAC v2).

Personal orgs (ADR 0021 §5)​

  • A personal org is still created lazily, on the first plant or the legacy GET /v1/me fix-up (IO-3 option a). A new mobile user with no plant has no org at all; the console treats that like "personal org only".
  • It never takes a member invitation: 422 UNSUPPORTED_OPERATION, details.reason: "PERSONAL_ORG".
  • The owner cannot edit their own membership there (same 422), and End User is the only role assignable there.
  • A Super Admin, or a platform Administrator through the platform fallback (X-Org-Id set to the personal org), may change the owner's scope.

The Business raises these with PATCH /v1/orgs/{orgId}/roles/{roleId}. Granting any category above the caller's own level fails with 403 FORBIDDEN, details.reason: "ESCALATION".

The full matrix (and the retired roles) is on Authorization.

What the FE should do​

  • Gate screens on GET /v1/me/context modules and levels, not on role names. Custom roles can hold any mix.
  • Below the required level a route returns 403 FORBIDDEN. Hide the action; do not retry. A caller with no ACTIVE membership in the org gets 404 NOT_FOUND.
  • When editing a role, send all 15 keys. Sending 10 still works, but the derived values may not be what the user picked in the editor.
  • Rules that did not change: only a Super Admin assigns or removes Super Admin, the last ACTIVE Super Admin cannot be demoted, nobody grants a role or share level above their own (now across all 15 categories), and removing a membership or share revokes access.

Phase 2a: per-permission limits​

Built 2026-10-29 (ADR 0014). Policy §8.1 per-permission toggles for Connected End Users are an optional limit on top of the five external tiers, not a replacement for them.

  • Where: a share's permsLimit (Shares API) and a customer portal's portalPermsLimit (Customers API). Both are a partial map of the 15 categories to a Level.
  • Effect: per category, effective ceiling = min(tier ceiling, limit). An absent key keeps the tier value. A limit never raises anything: redaction (VIEW/MONITOR), the command risk cap (SERVICE LOW, FULL MEDIUM) and firmware NONE stay with the tier. The evaluator, realtime tickets, alert audiences and /me/context all use it.
  • Escalation: the granter's check runs on the limited ceiling, so an Installer can give a FULL tier narrowed to what it holds (403, details.reason: "ESCALATION" otherwise). Portal limits need customers ≥ MANAGE, and a limit with portalLevel: NONE is 422 VALIDATION_FAILED (details.field: "portalPermsLimit"). Setting portalLevel: NONE without a limit in the same request clears a stored limit. A reordered but equal limit is no change.
  • Lowering a limit is a narrowing: access.revoked.v1 with SHARE_NARROWED or PORTAL_NARROWED. null on PATCH removes a limit; {} equals no limit.

How the policy's toggles map to categories:

Policy toggleCategoryLevels
Create / edit plants, plant settingsplantsVIEW < EDIT
Delete/archive plantplantsMANAGE — configurable on a FULL share or portal only, by permsLimit plants: MANAGE (archive/restore; hard delete stays with the operator and platform)
Add / remove devicesdevices
Restart and other commandscommands
Register read / writeregistersRead / registersWrite
History and analyticsreports
Alertsalerts
Share plant accesssharingMANAGE — configurable on a FULL share or portal only, by permsLimit sharing: MANAGE; lets the End User re-share one plant

Illustrative example (not a captured run): a FULL share with "permsLimit": {"commands": "NONE", "registersWrite": "NONE", "sharing": "NONE"} gives the grantee FULL's plant and device access but no commands and no register writes, and no re-sharing.

FULL-tier opt-in: archive and re-share (built 2026-11-03)​

A limit only lowers, with one exception: on the FULL tier, permsLimit (share) or portalPermsLimit (portal) may RAISE plants and sharing up to MANAGE (OPT_IN_MAX in access/ceilings.ts). Without the key FULL keeps EDIT for both, so nothing stored earlier changes. The escalation check runs on the result, so only a granter holding MANAGE there (e.g. a Business) can switch them on.

Illustrative example (not a captured run): a FULL share with "permsLimit": { "plants": "MANAGE", "sharing": "MANAGE" } lets the End User archive/restore the plant and re-share it.

Re-share rules (POST /v1/plants/{plantId}/shares):

  • Individuals only (grantee.kind: USER), one plant per re-share.
  • Never above the re-sharer's own access (403, details.reason: "ESCALATION").
  • No chains: a re-share always has sharing: NONE.
  • Stored under the plant's operator org with a parent field, so the Business sees it in its share list and can revoke it.
  • Checked against its parent on every read (resolveReshares in access/loader.ts): it stops working once the parent share or portal is revoked, expired, closed, re-scoped or no longer sharing, or the re-sharer left the customer org, and is capped at the parent's ceiling. Through a portal it also stops once the plant moves to another customer, and is capped at the re-sharer's own role in the customer org.
  • Revoked with its parent. Revoking the parent share, or a parent change that removes sharing or the plant, a portal that stops sharing, and closing the customer revoke the re-shares straight away (their holders' sessions and alert lists are cleared). Changes without their own event (the re-sharer leaving or being downgraded, the plant moving, the parent expiring) take effect on the next request; a live realtime ticket can keep its old levels until it expires (up to 600 s).

Not possible: separate create-vs-delete or restart-vs-other-command switches (they share one category); raising a category above the tier (except the FULL opt-in above); granting firmware; per-register or per-command rules (TCP side, still to build).

FULL tier ceiling adjusted at the same time: registersRead VIEW (see the table in Shares API), and the escalation check on external grants skips the org-level roles/audit. No plant access changes; it lets a BUSINESS caller grant FULL.

Phase 2b: Super Admin edits built-in roles​

Built 2026-11-02 (ADR 0014 phase 2b). Not yet exercised against a deployment.

Guards: any level is allowed (since 2026-11-03, R-0: FULL on every category and roles: FULL too, because the Super Admin identity is the role, not its levels); sending the current perms again writes nothing and keeps the version; a lost write race is 409 VERSION_CONFLICT. If the override item cannot be read, requests from holders of Administrator or Business keep the last good copy, or fail 503 DEPENDENCY_UNAVAILABLE (retry) when there is none.

A Super Admin can change the perms of Administrator and Business (Viewer is retired: 422 UNSUPPORTED_OPERATION). Business changes apply in every organisation; Administrator changes apply only to PLATFORM-org Administrators (revalidation 2026-11-03). Super Admin itself is never editable (always FULL). Name, code, scope rule and colour stay fixed.

  • Route: the existing PATCH /v1/orgs/{orgId}/roles/{roleId} (no new route). {orgId} must be the Crown PLATFORM org, the caller must be Super Admin, and the body may hold only perms.
  • Concurrency: If-Match = the role's version, which GET roles returns for built-in roles only in the PLATFORM org. It is 1 until the first edit.
  • Reset: send the role's default perms. The stored override is cleared but the version keeps rising, so an old ETag never matches again.
  • Response: the role detail with its new version, plus affectedMembers (holders in the PLATFORM org only; holders in other orgs are not counted).
  • Errors: any other org, any other field, or Super Admin as target → 422 UNSUPPORTED_OPERATION (reason: SYSTEM_ROLE); another PLATFORM member → 403 FORBIDDEN (reason: SUPER_ADMIN_ONLY); stale version → 409 VERSION_CONFLICT with details.currentVersion.
  • Reads: GET roles (list and detail), member detail, invitations and every access decision use the effective (possibly edited) perms in every org.
  • Propagation: no per-holder access.revoked.v1 is sent (holders span every org). HTTP decisions see the change within about 30 s (per-container cache), realtime tickets when they expire (600 s), precomputed alert audiences at their next recompute. The FE should tell the Super Admin that changes are not instant.
  • Audit: each change writes ROLE_UPDATED to the PLATFORM org's access log with per-category from/to.

Illustrative request (not a captured execution):

PATCH /v1/orgs/<platformOrgId>/roles/<businessRoleId>
If-Match: "1"
Content-Type: application/json

{ "perms": { "plants": "MANAGE", "firmware": "VIEW", "...": "all 15 categories" } }

Revalidation 2026-11-03​

A security review and policy audit (ADR 0014, "Revalidation (2026-11-03)") fixed these. Not yet exercised against a deployment.

  1. Administrator edits apply to the PLATFORM org only. Personal, CUSTOMER/PARTNER and not-yet-backfilled Business owners also hold Administrator; their levels no longer change when the Super Admin edits "Admin". Business edits still apply in every org.
  2. No standing access in a personal org through the platform fallback (Admin only since 2026-11-03; a Super Admin is never refused). Invitations (create, edit), member role/scope changes, shares (create, edit) and access-request approval return 403 FORBIDDEN, details.reason: "PLATFORM_PERSONAL_ORG" when the personal org is reached only through the platform fallback. Viewing and other edits still work.
  3. Creating a Business also needs team ≥ MANAGE in the PLATFORM org (it invites the owner).
  4. Customer portal tiers are escalation-checked like shares on any tier or limit change (removing a limit included), except plain VIEW with no limit: 403 FORBIDDEN, details.reason: "ESCALATION".
  5. Hardening: a custom role with FULL on every category is 422 VALIDATION_FAILED (field: perms) unless a Super Admin makes it (R-0); the built-in role guards on all-FULL and roles: FULL were removed on 2026-11-03 (R-0); the role-change revocation projection now fails closed.

Not built yet (Phase 2)​

  1. Per-register and per-command restriction and safety-sensitive command rules (TCP side).
  2. End Users hold Administrator in their own personal/customer org, so team and customers show FULL there while the matrix says —; since R-3b (2026-11-03) also settings and roles MANAGE, so they can manage custom roles in their own org. Nothing reachable outside their own org depends on it. Owner decision.

Creating a Business through the API is built: see POST /v1/orgs/{orgId}/businesses.

The backfill for orgs created before ADR 0014 is built but must be run by the owner, per stage: see RBAC roles backfill.

Until TCP reads lv.registersRead and lv.registersWrite from the realtime ticket, it keeps gating register access on lv.devices and lv.commands. For every role stored before ADR 0014 those values are equal.