Permission
A Permission is what a Role may do: a Verb on a Noun within a scope, optionally bounded by a Limit.
Properties
| Property | Type | Required | Description |
|---|---|---|---|
scope | string | required | Where it applies, such as a Startup or a Tenant. |
limit | Limit | The Limit that bounds it. |
Object
{
"$id": "https: //api.sb/ ledgerlark.com/ permissions/ permission_1",
"$type": "Permission",
"scope": "Example scope",
"limit": "limit_1"
}Relationships
- A Permission allows one Verb: each Permission allows one Verb, within its scope and Limit.
allows, inverseallowedBy. - A Permission is held by one Role: a Role’s Permissions are what its Worker may do: Verbs on Nouns within a scope and a Limit.
heldBy, inverseholds.
Verbs
createCreates a Permission.POST /{namespace}/permissionsgetReturns one Permission by id.GET /{namespace}/permissions/{id}listReturns Permissions, newest first, one page at a time.GET /{namespace}/permissionsupdateChanges the given properties of a Permission.PATCH /{namespace}/permissions/{id}deleteDeletes a Permission; its history is kept.DELETE /{namespace}/permissions/{id}
Permissions
Which Access level may call each Verb. One-way Verbs wait their delay window.
| Operation | owner | admin | member | viewer |
|---|---|---|---|---|
Permission.create | Yes | Yes | No | No |
Permission.get | Yes | Yes | Yes | Yes |
Permission.list | Yes | Yes | Yes | Yes |
Permission.update | Yes | Yes | No | No |
Permission.delete | Yes | Yes | No | No |
Call it
Add a permission to PatentPad.Example
The Billing Specialist Role holds a Permission to refund on Order, within a $100 Limit.