Roles & Permissions

Grant or revoke a permission for a user

Attaches an existing permission to a user, or detaches it, and returns the user's resulting permission names. This does not create new permissions.

post/api/permissions

Request

Request body

permissionNamestring required

Name of the permission in slug format.

userIdinteger required

Identifier of the user the permission applies to.

allowboolean required

True grants the permission to the user, false revokes it.

Response

The permission names the user holds after the change.

permissionsstring[]

Changes

No recorded changes to this operation across all 2 revisions of this API.