Permissions
Get a paginated list of all permissions (system and custom) in the directory. Filter by type (system/custom), resource_type, name (partial match).
x-pontive-instance-id<token>Instance ID for the request
type?stringFilter by permission type (system, custom)
resource_type?stringFilter by resource type
name?stringFilter by permission name (partial match)
page?integerPage number
limit?integerItems per page
sort?stringSort field; prefix with - for descending (e.g. -created_at). Allowed: created_at, updated_at, name, key. Default: -created_at
OK
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/authz/permissions'{ "data": [ { "created_at": "string", "description": "string", "key": "string", "name": "string", "object": "string", "resource_type": "string", "type": "system", "updated_at": "string", "used_in_roles": [ { "key": "string", "name": "string" } ] } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}The permissions of one resource type (D18), filtered as GET /authz/permissions is.
x-pontive-instance-id<token>Instance ID for the request
resource_type*stringResource type key
type?stringFilter by permission type (system, custom)
name?stringFilter by permission name (partial match)
page?integerPage number
limit?integerItems per page
sort?stringSort field; prefix with - for descending (e.g. -created_at). Allowed: created_at, updated_at, name, key. Default: -created_at
OK
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/authz/resource-types/string/permissions'{ "data": [ { "created_at": "string", "description": "string", "key": "string", "name": "string", "object": "string", "resource_type": "string", "type": "system", "updated_at": "string", "used_in_roles": [ { "key": "string", "name": "string" } ] } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}Create a custom permission. Required: key, resource_type. Optional: description, name. Name format: resource:action or resource:sub_resource:action.
x-pontive-instance-id<token>Instance ID for the request
resource_type*stringresource_type
Create Permission Request
application/json- body
Create Permission Request
description?stringkey*stringname?stringCreated
application/json- response
created_at?stringdescription?stringkey?stringname?stringobject?stringresource_type?stringtype?string"system""custom"updated_at?stringused_in_roles?array<>curl -X POST 'https://api.us.pontive.com/v1/authz/resource-types/string/permissions' \ -H 'Content-Type: application/json' \ -d '{ "key": "string"}'{ "created_at": "string", "description": "string", "key": "string", "name": "string", "object": "string", "resource_type": "string", "type": "system", "updated_at": "string", "used_in_roles": [ { "key": "string", "name": "string" } ]}Get a permission by name. Returns name, key, description, type, resource_type, created_at, updated_at, used_in_roles. Works for both system and custom permissions.
x-pontive-instance-id<token>Instance ID for the request
permission_key*stringPermission Key
resource_type*stringPermission resource type
OK
application/json- response
created_at?stringdescription?stringkey?stringname?stringobject?stringresource_type?stringtype?string"system""custom"updated_at?stringused_in_roles?array<>curl -X GET 'https://api.us.pontive.com/v1/authz/resource-types/string/permissions/string'{ "created_at": "string", "description": "string", "key": "string", "name": "string", "object": "string", "resource_type": "string", "type": "system", "updated_at": "string", "used_in_roles": [ { "key": "string", "name": "string" } ]}Update a custom permission. Can update: description, name. Cannot update: key (immutable), resource_type (immutable). System permissions cannot be updated.
x-pontive-instance-id<token>Instance ID for the request
permission_key*stringPermission Key
resource_type*stringPermission resource type
If-Match?stringThe ETag the document was read with: a stale one is refused 412 precondition_failed (D42)
Update Permission Request (description, name)
application/json- body
Update Permission Request (description, name)
description?stringname?stringOK
application/json- response
created_at?stringdescription?stringkey?stringname?stringobject?stringresource_type?stringtype?string"system""custom"updated_at?stringused_in_roles?array<>curl -X PATCH 'https://api.us.pontive.com/v1/authz/resource-types/string/permissions/string' \ -H 'Content-Type: application/json' \ -d '{}'{ "created_at": "string", "description": "string", "key": "string", "name": "string", "object": "string", "resource_type": "string", "type": "system", "updated_at": "string", "used_in_roles": [ { "key": "string", "name": "string" } ]}Delete a custom permission. System permissions cannot be deleted. Returns 204 No Content on success.
x-pontive-instance-id<token>Instance ID for the request
resource_type*stringPermission resource type
permission_key*stringPermission Key
force?booleanForce delete (bypass confirmation when permission is used in roles)
If-Match?stringThe ETag the document was read with: a stale one is refused 412 precondition_failed (D42)
No Content
curl -X DELETE 'https://api.us.pontive.com/v1/authz/resource-types/string/permissions/string'