add-permission
Skill2 starsChanged 4 months agoMITView on GitHub
Add or reuse a permission end-to-end (backend + frontend) for a new page, tab, endpoint, or protected action in Arthur MCP. Use whenever a feature introduces a new user-facing surface or protected action that needs a permission decision.
4 other projects use a version of this.
Adopted by
Most recently taken up by
- suxrobGM/logistics-apptheir own version, first seen Oct 8, 2026
- fpindej/netrocktheir own version, first seen Oct 8, 2026
- fullstackhero/dotnet-starter-kittheir own version, first seen Oct 8, 2026
- chenson42/stackkeeltheir own version, first seen Sep 22, 2026
Other versions4 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 4
- fullstackhero/dotnet-starter-kit★ 6.9ksame name
- fpindej/netrock★ 234same name
- suxrobGM/logistics-app★ 209same name
- chenson42/stackkeel★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository3 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- session-handoffSkill
The file
We split this skill into the rules it gives an agent
7 rules. 0 are common, 2 are distinctive, and 5 are very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
2
Distinctive
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 9
Decide: check whether an existing permission already covers this domain and risk.
- Very specific: line 11
Add the key to the RolePermissions contract.
- Very specific: line 12
Add it to built-in role presets in api/src/roles/permissions.ts.
- Very specific: line 15
Add the key to the Permission enum and UserPermissions.
- Very specific: line 16
Add it to role fallback presets in src/context/permissionPresets.ts.
- Distinctive: line 18
Add a restricted empty state or disabled control for view-but-not-act cases.
- Distinctive: line 22
Do not ship a frontend-only permission without backend enforcement, and do not ship backend-only protected behavior without a frontend …
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Wire a permission end-to-end for the feature being implemented. Full rules: .claude/rules/permissions.md and docs/DESIGN_PATTERNS.md (Guard and Decorator Authorization / Auth and Permission Context sections).
- Decide: check whether an existing permission already covers this domain and risk. If yes, reuse it and stop here — do not add a near-duplicate. If not, name the new permission
<domain>_<verb>matching the action's risk (not just its domain). - Backend, in the same change:
- Add the key to the
RolePermissionscontract. - Add it to built-in role presets in
api/src/roles/permissions.ts. - Guard the controller route with
RequirePermission(or the relevant guard).
- Add the key to the
- Frontend, in the same change:
- Add the key to the
Permissionenum andUserPermissions. - Add it to role fallback presets in
src/context/permissionPresets.ts. - Gate the nav item / route / button with
can(Permission.X). - Add a restricted empty state or disabled control for view-but-not-act cases; hide navigation only when the user cannot view the surface at all.
- Add the key to the
- Tests: cover the new guard/decorator behavior and the UI gate.
- Docs: record the decision per
docs/DESIGN_PATTERNS.md's change checklist; updatedocs/FLOWS.mdif the user journey changes.
Do not ship a frontend-only permission without backend enforcement, and do not ship backend-only protected behavior without a frontend permission model + restricted UI state. If backend support must be deferred, record the gap in docs/ROADMAP.md and keep the UI inaccessible until the backend permission exists.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

