Ana içeriğe geç

Consumer Roles API

Overview​

A consumer role is a name that you assign to consumers and applications and that you use in the authorization settings of API proxies. Roles are under /apiops/projects/{projectName}/consumer-roles. The names of this API are the names that roleNameList of a consumer takes and that roleNames of a consumer returns. See the Consumers API.

A role name must be unique across the project and the admin project. The comparison ignores case. A name that another role holds answers 409 duplicateName.

A role name in the roleNameList of a consumer resolves in the project of the consumer first, then in the admin project.

Endpoints​

OperationMethodEndpointDescription
ListGET/consumer-rolesList the roles of the project
GetGET/consumer-roles/{roleName}Read one role
CreatePOST/consumer-rolesCreate a role
UpdatePUT/consumer-roles/{roleName}Update or rename a role
DeleteDELETE/consumer-roles/{roleName}Delete a role

Permissions​

OperationRequired Permission
List, GetIDENTITY + VIEW
Create, Update, DeleteIDENTITY + MANAGE

A project outside the scope of the caller answers 404 resourceNotFound. The admin project is served too: /apiops/projects/admin/consumer-roles manages the roles of the admin project.