ConnectCloud Developers

Effective permissions with their sources (identity:admin)

GET /api/hr/v1/employees/{id}/access

Module: HR · operationId: getEmployeeAccess · Tag: Access · Auth: access token (Authorization: Bearer <accessToken>)

Parameters

Name In Type Required Description
id path string (uuid) yes

Responses

  • 200 Access (application/json)

Fields of the 200 answer:

  • permissions (array of object): Effective permissions, sorted
    • permission (string): The permission
    • sources (array of object): Roles that grant it, directly or through a group
      • groupId (string): Id of the group the role comes through (omitted for a direct role)
      • groupName (string): Name of that group
      • roleId (string): Id of the role
      • roleName (string): Name of the role

Example 200 answer:

{
  "permissions": [
    {
      "permission": "desk:write",
      "sources": [
        {
          "groupId": "21a3c5e7-9b1d-4d3f-8a5c-7e9b1d3f5a91",
          "groupName": "Service Desk 1st Level",
          "roleId": "31b3d5f7-9a1c-4e3b-8d5f-7a9c1e3b5d40",
          "roleName": "Service Desk"
        }
      ]
    },
    {
      "permission": "tenant:access",
      "sources": [
        {
          "roleId": "13e5a7c9-1d3f-4a5c-9e7a-9b1d3f5a7c82",
          "roleName": "Mitarbeiter"
        },
        {
          "groupId": "21a3c5e7-9b1d-4d3f-8a5c-7e9b1d3f5a91",
          "groupName": "Service Desk 1st Level",
          "roleId": "31b3d5f7-9a1c-4e3b-8d5f-7a9c1e3b5d40",
          "roleName": "Service Desk"
        }
      ]
    }
  ]
}

Example request

curl -X GET 'https://api.mbcom.cloud/api/hr/v1/employees/3f2b8c1e-7d4a-4e9b-9c2a-5b1d6e8f0a12/access' \
  -H "Authorization: Bearer $ACCESS_TOKEN"

View as Markdown · Interactive reference · OpenAPI