Get current user's roles
GET
/api/v1/rbac/user/roles
const url = 'https://localhost:8080/api/v1/rbac/user/roles';const options = {method: 'GET', headers: {Authorization: '<Authorization>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://localhost:8080/api/v1/rbac/user/roles \ --header 'Authorization: <Authorization>'Return the authenticated user’s organization and project role assignments with derived scope
Authorizations
Section titled “Authorizations ”Responses
Section titled “ Responses ”User roles with context
Media type application/json
object
organizationId
string
roles
Array<object>
object
organizationId
string
projectId
string
role
string
scope
string
userId
string
Example
{ "roles": [ { "organizationId": "org-7", "projectId": "", "role": "organization_owner", "scope": "organization" } ]}Unauthorized - Authentication required
Media type application/json
object
error
string
error_description
string
Example
{ "error": "Unauthorized", "error_description": "Invalid token"}