---
updatedAt: 2026-06-29T14:37:49.000Z
agentTools:
  projectIndex: https://developers.kommo.com/llms.txt
---

# Get role by ID

This method allows getting a particular role data by its ID

**Limitations**\
Method is available for administrator users only.

**Data type header when the request is successful**\
Content-Type: application/hal+json

**Data type header in case of an error**\
Content-Type: application/problem+json

**Parameters for GET-parameters “with”**

| Parameter | Description                                               |
| :-------- | :-------------------------------------------------------- |
| users     | Adds IDs of users with the current role into the response |

**Response parameters**\
Method returns a user role object. The properties of the object are listed below.\
Rights objects have a common structure. Depending on the entity type these objects contain available actions as keys and the rights for the action as a value. For example, `rights[leads][view]=A`.

| Parameter                 | Data type | Description                                                  |
| :------------------------ | :-------- | :----------------------------------------------------------- |
| id                        | int       | Role ID                                                      |
| name                      | string    | Role name                                                    |
| rights                    | object    | User rights                                                  |
| rights\[leads]            | object    | Leads access rights object                                   |
| rights\[contacts]         | object    | Contacts access rights object                                |
| rights\[companies]        | object    | Companies access rights object                               |
| rights\[tasks]            | object    | Tasks access rights object                                   |
| rights\[mail\_access]     | bool      | Defines whether Mail functionality is allowed for the user.  |
| rights\[catalog\_access]  | bool      | Defines whether Lists functionality is allowed for the user. |
| rights\[is\_admin]        | bool      | Defines whether the user has administrator rights.           |
| rights\[is\_free]         | bool      | Defines whether it is a free user.                           |
| rights\[is\_active]       | bool      | Defines whether the user is active.                          |
| rights\[group\_id]        | int\|null | ID of the user’s group                                       |
| rights\[role\_id]         | int\|null | ID of the user’s role                                        |
| rights\[status\_rights]   | array     | An array of the objects that define stages rights            |
| rights\[0]                | object    | An object of stage rights                                    |
| rights\[0]\[entity\_type] | string    | Entity type. Only lead entity is supported at the moment     |
| rights\[0]\[pipeline\_id] | int       | ID of the pipeline the stage is located in.                  |
| rights\[0]\[status\_id]   | int       | Stage ID                                                     |
| rights\[0]\[rights]       | object    | Rights object                                                |
| \_embedded\[users]        | array     | An array containing IDs of users with the current role       |

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "kommo-api-references",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://{subdomain}.kommo.com",
      "variables": {
        "subdomain": {
          "default": "subdomain"
        }
      }
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "oauth2",
        "flows": {}
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/api/v4/roles/{id}": {
      "get": {
        "summary": "Get role by ID",
        "description": "This method allows getting a particular role data by its ID",
        "operationId": "get-role-data-by-id",
        "parameters": [
          {
            "name": "with",
            "in": "query",
            "description": "This parameter takes a string which may consist of several values separated by commas. You can find 'with' parameters in the table.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "id",
            "in": "path",
            "description": "Role ID",
            "schema": {
              "type": "integer",
              "format": "int32"
            },
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Request successful": {
                    "value": "{\n    \"id\": XXXXXX,\n    \"name\": \"Example Role\",\n    \"rights\": {\n        \"leads\": {\n            \"view\": \"A\",\n            \"edit\": \"A\",\n            \"add\": \"A\",\n            \"delete\": \"A\",\n            \"export\": \"A\"\n        },\n        \"contacts\": {\n            \"view\": \"A\",\n            \"edit\": \"A\",\n            \"add\": \"A\",\n            \"delete\": \"A\",\n            \"export\": \"A\"\n        },\n        \"companies\": {\n            \"view\": \"A\",\n            \"edit\": \"A\",\n            \"add\": \"A\",\n            \"delete\": \"A\",\n            \"export\": \"A\"\n        },\n        \"tasks\": {\n            \"edit\": \"A\",\n            \"delete\": \"A\"\n        },\n        \"mail_access\": false,\n        \"catalog_access\": false,\n        \"status_rights\": [\n            {\n                \"entity_type\": \"leads\",\n                \"pipeline_id\": XXXXXX,\n                \"status_id\": XXXXXXX,\n                \"rights\": {\n                    \"edit\": \"A\",\n                    \"view\": \"A\",\n                    \"delete\": \"A\"\n                }\n            },\n            {\n                \"entity_type\": \"leads\",\n                \"pipeline_id\": XXXXXX,\n                \"status_id\": XXXXXXXX,\n                \"rights\": {\n                    \"edit\": \"A\",\n                    \"view\": \"A\",\n                    \"delete\": \"A\"\n                }\n            }\n        ]\n    },\n    \"_links\": {\n        \"self\": {\n            \"href\": \"https://example.kommo.com/api/v4/roles/XXXXX\"\n        }\n    }\n}\n     "
                  }
                }
              }
            }
          },
          "401": {
            "description": "401",
            "content": {
              "text/plain": {
                "examples": {
                  "User is not authorized": {
                    "value": ""
                  }
                }
              }
            }
          },
          "403": {
            "description": "403",
            "content": {
              "application/json": {
                "examples": {
                  "Insufficient rights to call this method": {
                    "value": "{}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {}
                }
              }
            }
          }
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```