OAuth 2.0 scope management API
The Server Scope Endpoint API (version 1.0.0).
Download the OpenAPI definition (YAML)
Scope Management
Return all available scopes
GET /scopes
This API is used to get all the available scopes.
Scope(Permission) required: internal_oauth_scope_view
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
startIndex | query | integer | The start index of the list of scopes to be retrieved | |
count | query | integer | Number of scopes to retrieve from the point of the start index | |
includeOIDCScopes | query | boolean | Retrieve OIDC scopes as well via OAuth2 scopes endpoint. | |
requestedScopes | query | string | If specified, requested set of scopes will be return. |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Successfully Retrieved | array of scope |
401 | Unauthorized | error |
404 | Not Found | error |
500 | Server Error | error |
Register a scope
POST /scopes
This API is used to create a scope.
Scope(Permission) required: internal_oauth_scope_create
Request body (required): application/json
Define a scope with bindings to register it
Schema: scope
5 properties
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | |
displayName | string | Yes | |
description | string | ||
bindings | array of string | ||
scopeBindings | array of scopeBinding |
Responses
| Code | Description | Schema |
|---|---|---|
201 | Successfully Created | scope |
400 | Bad Request | error |
401 | Unauthorized | error |
409 | Conflict | error |
500 | Server Error | error |
Return a scope by name
GET /scopes/name/{name}
This API is used to retrieve details of a scope by a given scope name.
Scope(Permission) required: internal_oauth_scope_view
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
name | path | string | Yes | Name of the scope that is to be retrieved |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Successfully Retrieved | scope |
401 | Unauthorized | error |
404 | Not Found | error |
500 | Server Error | error |
Update a scope
PUT /scopes/name/{name}
This API is used to update a scope by a given scope name.
Scope(Permission) required: internal_oauth_scope_update
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
name | path | string | Yes | Name of the scope that is to be updated |
Request body (required): application/json
updated scope
Schema: scopeToUpdate
4 properties
| Name | Type | Required | Description |
|---|---|---|---|
displayName | string | Yes | |
description | string | ||
bindings | array of string | ||
scopeBindings | array of scopeBinding |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Successfully updated | scope |
401 | Unauthorized | error |
404 | Not Found | error |
500 | Server Error | error |
Delete a scope
DEL /scopes/name/{name}
This API is used to delete a scope by a given scope name.
Scope(Permission) required: internal_oauth_scope_delete
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
name | path | string | Yes | Name of the scope that is to be deleted |
Responses
| Code | Description | Schema |
|---|---|---|
204 | Successfully deleted | string |
401 | Unauthorized | error |
404 | Not Found | error |
500 | Server Error | error |
Check scope existence using scope name
HEAD /scopes/name/{name}
This API is used to check a scope's existence using a given scope name.
Scope(Permission) required: internal_oauth_scope_view
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
name | path | string | Yes | Name of the scope that is to be checked |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Scope Exists | string |
401 | Unauthorized | error |
404 | Not Found | error |
500 | Server Error | error |
Schemas
scope
Type: object
5 properties
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | |
displayName | string | Yes | |
description | string | ||
bindings | array of string | ||
scopeBindings | array of scopeBinding |
scopeToUpdate
Type: object
4 properties
| Name | Type | Required | Description |
|---|---|---|---|
displayName | string | Yes | |
description | string | ||
bindings | array of string | ||
scopeBindings | array of scopeBinding |
scopeBinding
Type: object
2 properties
| Name | Type | Required | Description |
|---|---|---|---|
bindingType | string | ||
binding | array of string |
Was this page helpful?