Request
| Basic information | |
|---|---|
| HTTP URL | https://oapi.dingtalk.io/topapi/role/getrolegroup |
| HTTP Method | POST |
| Supported app types | appType-Internal appappType-Third-party enterprise app |
| Required permissions | permission-qyapi_get_department_list-Read permission for Contacts department information |
Query parameter
| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| access_token | String | Yes | bE74xxxx | The App credential used to call this API. - For an Internal app, obtain it through the API for getting the access_token of an Internal app. - For a Third-party enterprise app, obtain it through the API for getting the access_token of a third-party organization. |
Request body
| Name | Type | Required | Example | Description |
|---|---|---|---|---|
| group_id | Number | Yes | 1507113580 | The ID of the role group. |
Request example
Response
Response body
| Name | Type | Example | Description |
|---|---|---|---|
| role_group | OpenRoleGroup | The role group information. | |
| roles | OpenRole[] | The list of roles. | |
| role_id | Number | 1507113580 | The role ID. |
| role_name | String | Supervisor | The role name. |
| group_name | String | Default | The role group name. |
| errcode | Number | 0 | The return code. |
| errmsg | String | ok | The description of the return code. |
| request_id | String | 8lgzequlri0o | The request ID. |
Response example
Error codes
If an error occurs when you call this API, refer to the Global error codes document to find a solution based on the error message.| Error code (errcode) | Error message (errmsg) | Solution |
|---|---|---|
| 400002 | Invalid parameter | Verify whether groupId is valid. |
| -1 | System is busy | Try again later. |