Assign user consent scopes to application.
Assign the user consent scopes to an application by application id
Path parameters
-
The unique identifier of the application.
Body Required
-
organizationScopes array[string]
A list of organization scope id to assign to the application. Throws error if any given organization scope is not found.
-
resourceScopes array[string]
A list of resource scope id to assign to the application. Throws error if any given resource scope is not found.
-
organizationResourceScopes array[string]
A list of organization resource scope id to assign to the application. Throws error if any given resource scope is not found.
-
userScopes array[string]
A list of user scope enum value to assign to the application.
Values are
profile
,email
,phone
,address
,custom_data
,identities
,roles
,urn:logto:scope:organizations
, orurn:logto:scope:organization_roles
.
POST /api/applications/{applicationId}/user-consent-scopes
curl \
-X POST https://[tenant_id].logto.app/api/applications/{applicationId}/user-consent-scopes \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"organizationScopes":["string"],"resourceScopes":["string"],"organizationResourceScopes":["string"],"userScopes":["profile"]}'
Request examples
{
"organizationScopes": [
"string"
],
"resourceScopes": [
"string"
],
"organizationResourceScopes": [
"string"
],
"userScopes": [
"profile"
]
}