Repository navigation
Description
Summary
A pilot organization asks for roles at two levels: the organization role a person holds today, and a role per project. An organization role such as Editor keeps its rights in the organization and in every project. A person with a lower organization role, such as Member, can hold a higher role in one project, for example Editor or Developer. Today a person has exactly one role, the one on their organization membership. Teams decide only which projects a person reaches, never what they may do there. This issue records how access works now and the questions a design has to answer. It states no preference.
The request
Es sollte möglich sein, Rollen sowohl global als auch pro Projekt zuzuweisen. Eine globale Rolle wie Bearbeiter/Redakteur soll weiterhin globale Rechte sowie die entsprechenden Rechte in allen Projekten umfassen. Personen mit einer niedrigeren globalen Rolle, etwa Mitglied, sollen in einzelnen Projekten eine abweichende Rolle erhalten können, zum Beispiel Redakteur oder Entwickler.
"It should be possible to assign roles both globally and per project. A global role such as Editor should keep comprising the global rights and the corresponding rights in all projects. People with a lower global role, such as Member, should be able to get a different role in individual projects, for example Editor or Developer."
As read here, a project role only raises a person's rights inside that project. Whether it may also lower an organization role there was not asked and is not confirmed.
What the repository says today (main at b2560c2d7)
One role per person, on the membership. The roles are owner, admin, developer, editor, member and disabled (services/platform/backend/auth/access.ts:83-126). A role grants the same actions on every resource of its kind across the organization (uniformGrants, :49-73). Editor differs from Developer by read-only connectors, sync configurations, automations (wfDefinitions, wfExecutions) and governance policies (:98-109). The member row carries the role; no migration under services/platform/backend/db/migrations/ creates a project member or project role table.
Project access is the audience times the organization role. checkProjectAccess (services/platform/backend/core/projects/access.ts:92-108): owners and admins read, edit and administer every project. Everyone else reaches a project only through its audience, which is either the whole organization or a list of teams (:77-87). Once they reach it, canEdit is EDITOR_ROLES.has(userRole) (:106), and EDITOR_ROLES is owner, admin, developer and editor (services/platform/backend/core/lib/audience.ts:42-47). The domain spec states this as PROJ-R1 to PROJ-R3 with a table (services/platform/backend/domains/projects/spec.md:11-38): a member in a project's team can read it, and its settings are refused to them.
Rights that are not tied to one project.
- Creating a project needs an editor role (
services/platform/backend/domains/projects/service.ts:406-410; see feat(platform): let admins allow members to create projects #5040). - Only owners, admins and developers see Automations, "in the navigation and in projects" (
docs/en/platform/admin/members-and-roles.md:50). - Project secrets and the credential an agent acts as are for owners and admins only (PROJ-R13 and PROJ-R24,
spec.md:151,:183). - Tasks add one rule on top: every reader creates tasks and works their own (
access.ts:14-15;members-and-roles.md:54).
Per-person grants exist, scoped to the organization only. The competence register delegates four platform capabilities without a seat: tale:models.api, tale:notifications.export, tale:rest.act-as and tale:skills.publish (services/platform/lib/shared/competences.ts:23-39). A grant is "scoped by organization" (services/platform/backend/domains/governance/competence.ts:142), and none names a project.
Where a role comes from. Every door writes the one organization role: an admin under Settings › Members, the identity provider's role mapping at each SSO sign-in (services/platform/backend/domains/sso/service.ts:581-597), SCIM provisioning with the connection's default role (services/platform/backend/domains/scim/service.ts:86-92), and a trusted proxy's role header on every hand-off (docs/en/platform/admin/enterprise-sso.md:85).
What the docs promise. "Roles determine permitted actions; project access, teams, and conversation assignments determine which resources a person can reach." (docs/en/platform/admin/members-and-roles.md:6). The role table is at :41-48.
Blast radius (counted at b2560c2d7, not a design)
- 18 non-test files call
checkProjectAccessorhasProjectAccess, and 13 non-test sites testEDITOR_ROLES.hasorADMIN_ROLES.hasdirectly, for example task editing (services/platform/backend/domains/tasks/service.ts:4077) and project creation (projects/service.ts:407). - The client's ability (
services/platform/lib/permissions/ability.ts,defineAbilityFor) is built from the organization role and referenced in 34 non-test files. - The same audience rule covers other team-scoped resources (documents, skills, inbox queues) through
core/lib/audience.ts. - When a reviewer loses edit access, the review hand-over reads "a role without edit access" (
services/platform/tests/manual/reference/automation/tasks.md:60). GET /api/v1/mereports the membership role and capabilities (services/platform/backend/rest/v1-core.ts:352-358). The audit log records role changes per membership.
Questions a design has to answer
- Does a project role only raise rights, or may it also lower them (an organization Editor who only reads one project)?
- How does it combine with the audience? Does holding a project role admit a person to a team-restricted project, or does it apply only to people the audience already admits? What happens when they leave the team that admitted them?
- What does "Developer in a project" mean when Developer's distinguishing rights are organization-wide (automations, connectors, providers, API access)? Does it show the automations installed in that project, let the person build them, or let them equip agents with connectors?
- Who may assign a project role: owners and admins, or also the project's editors? May an IdP or SCIM assign it?
- Where is it shown and set: the project's settings, the member's page (compare Improvement: give members a right in one place — from their member page, or to a whole team at once #5047), or both?
- Does a project role count for reviewer candidates, the review hand-over on access loss, and the audit log?
- Would a role per team in a project (every member of team X is Editor in project Y) cover the need, instead of a role per person?
Options (no preference stated)
- A project role per person, stored per project.
checkProjectAccesstakes the higher of the organization role and the project role for the edit right. - A role per team entry of a project's audience: the members of that team get that role in that project.
- Project-scoped capability grants in the competence register (for example a project-scoped
tale:projects.edit), in the style of Improvement: give members a right in one place — from their member page, or to a whole team at once #5047, instead of a role. - Keep one role, and meet the concrete need with narrower changes, such as feat(platform): let admins allow members to create projects #5040 (members create projects).
Related
#5040 (members creating projects), #5047 (a right from the member's page or for a whole team), #5046, #5044 (pilot findings).
Activity
yannickmonney commentedon Oct 30, 2026
Second relay of the request (2026-10-30, evening):
"It should be possible to assign roles both globally and per team/project." The first relay said "per project". This one names teams too.
Today a team membership carries no role. The table
public."teamMember"has only the columnsid,teamId,userId,membershipKeyandcreatedAt(read from a fresh database onmainat49ce42fdd). A team decides which projects, team-shared skills, documents and inbox queues a person reaches, never what they may do there. So "a role per team" can mean two things, which bears on question 7 and option 2:yannickmonney commentedon Nov 14, 2026
Decision
Add project roles. A project role gives a person, or a team, a higher role in one project than their organization role. It never lowers a role and never admits anyone.
The rule
app.project_role_grants, with soft revocation. The holder is a person or a team, the same holder model as competence team grants.Answers
Rationale
Keeping reach (the audience) and rights (the role) as separate concepts means nobody reaches a restricted project through a side door, and no deny rules need checking at organization-wide doors. Reserving grants to owners and admins, and never letting an identity provider confer one, matches the rule competence team grants already follow and prevents escalation chains. Developer in a project stops at running what is installed there, because changing an automation's installations would widen or narrow it for every other project. Project-scoped capabilities in the competence register (option 3) would overload it, and #5040 alone (option 4) would not let a member edit an existing project.
Implementation units (base:
release/0.6; the spec unit forward-ports PROJ-R29 and numbers new rules from PROJ-R30)#5040 stays independent.
Cross-issue amendments (decisions taken together with #5040, #4878, #5374, #5046):