tencent cloud

DescribeRoleList
Last updated: 2025-11-13 20:55:44
DescribeRoleList
Last updated: 2025-11-13 20:55:44

1. API Description

Domain name for API request: wedata.intl.tencentcloudapi.com.

This API is used to retrieve role list information.

A maximum of 20 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

Parameter Name Required Type Description
Action Yes String Common Params. The value used for this API: DescribeRoleList.
Version Yes String Common Params. The value used for this API: 2021-08-20.
Region Yes String Common Params. For more information, please see the list of regions supported by the product. This API only supports: ap-singapore, eu-frankfurt, na-ashburn, na-siliconvalley.
ShowAllRoles No Boolean Return all Roles
IncludeRoleTypes.N No Array of String Role type (system, tenant, project) that needs to be returned
DescribeMemberCount No Boolean Specifies the statistics of role binding personnel. Only supported in the private edition.
DescribeOperator No Boolean Specifies the operator information. describes the privatized multi-tenancy version.
DescribeSystemRoleOnly No Boolean System Role
DescribeCustomRoleOnly No Boolean Custom Role
DescribePrivileges No Boolean Permission to view
RoleIds.N No Array of String Filter criteria for Role ID
ProjectId No String Project ID
PageNumber No Integer Page number
PageSize No Integer Paging information
Filters.N No Array of Filter Query Field
OrderFields.N No Array of OrderFields Sorting Field

3. Output Parameters

Parameter Name Type Description
Data PageRoles This API is used to provide the Role List
RequestId String The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.

4. Example

Example1 test

Input Example

POST / HTTP/1.1
Host: wedata.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRoleList
<Common request parameters>

{
    "ShowAllRoles": true,
    "IncludeRoleTypes": [
        "abc"
    ],
    "DescribeMemberCount": true,
    "DescribeOperator": true,
    "DescribeSystemRoleOnly": true,
    "DescribeCustomRoleOnly": true,
    "DescribePrivileges": true,
    "RoleIds": [
        "abc"
    ],
    "ProjectId": "abc",
    "PageNumber": 0,
    "PageSize": 0,
    "Filters": [
        {
            "Name": "abc",
            "Values": [
                "abc"
            ]
        }
    ],
    "OrderFields": [
        {
            "Name": "abc",
            "Direction": "abc"
        }
    ]
}

Output Example

{
    "Response": {
        "Data": {
            "Rows": [
                {
                    "RoleId": "abc",
                    "RoleName": "abc",
                    "DisplayName": "abc",
                    "Description": "abc",
                    "RoleType": "abc",
                    "SystemDefault": true,
                    "Parameters": "abc",
                    "MemberCount": 0,
                    "Privileges": [
                        {
                            "PrivilegeId": "abc",
                            "PrivilegeName": "abc",
                            "RestPath": "abc",
                            "RestMethod": "abc",
                            "Description": "abc"
                        }
                    ],
                    "Operator": {
                        "UserId": "abc",
                        "UserName": "abc",
                        "DisplayName": "abc"
                    },
                    "OperateTime": 1,
                    "CreateTime": 1,
                    "CreateTimeStr": "abc",
                    "UpdateTimeStr": "abc",
                    "ProjectId": "abc"
                }
            ],
            "PageNumber": 0,
            "PageSize": 0,
            "TotalCount": 0,
            "TotalPageNumber": 0
        },
        "RequestId": "abc"
    }
}

Example2 test1

test1

Input Example

POST / HTTP/1.1
Host: wedata.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeRoleList
<Common request parameters>

{
    "ProjectId": "1554879954290339840"
}

Output Example

{
    "Response": {
        "Data": {
            "PageNumber": 1,
            "PageSize": 10,
            "Rows": [
                {
                    "CreateTime": null,
                    "CreateTimeStr": "1600938213660",
                    "Creator": null,
Responsible for daily project management, including member addition and role assignment.
"DisplayName": "ProjectManager"
                    "MemberCount": null,
                    "OperateTime": null,
                    "Operator": null,
                    "Parameters": null,
                    "Privileges": null,
                    "ProjectId": null,
                    "RoleId": "308335260274237440",
                    "RoleName": "ProjectManager",
                    "RoleType": null,
                    "SystemDefault": null,
                    "UpdateTime": null,
                    "UpdateTimeStr": "1629985314500"
                },
                {
                    "CreateTime": null,
                    "CreateTimeStr": "1600938213684",
                    "Creator": null,
Responsible for data integration, data development and service development
"DisplayName": "DataEngineer"
                    "MemberCount": null,
                    "OperateTime": null,
                    "Operator": null,
                    "Parameters": null,
                    "Privileges": null,
                    "ProjectId": null,
                    "RoleId": "308335260676890624",
                    "RoleName": "DataEngineer",
                    "RoleType": null,
                    "SystemDefault": null,
                    "UpdateTime": null,
                    "UpdateTimeStr": "1629985314533"
                },
                {
                    "CreateTime": null,
                    "CreateTimeStr": "1600938213690",
                    "Creator": null,
Ops center, responsible for platform and business ops. Platform ops mainly refers to operations in a private cloud environment.
"DisplayName": "OperationEngineer"
                    "MemberCount": null,
                    "OperateTime": null,
                    "Operator": null,
                    "Parameters": null,
                    "Privileges": null,
                    "ProjectId": null,
                    "RoleId": "308335260844662784",
                    "RoleName": "OperationEngineer",
                    "RoleType": null,
                    "SystemDefault": null,
                    "UpdateTime": null,
                    "UpdateTimeStr": "1629985314558"
                },
                {
                    "CreateTime": null,
                    "CreateTimeStr": "1600938213696",
                    "Creator": null,
Read-only account
"DisplayName": "Visitor"
                    "MemberCount": null,
                    "OperateTime": null,
                    "Operator": null,
                    "Parameters": null,
                    "Privileges": null,
                    "ProjectId": null,
                    "RoleId": "308335260945326080",
                    "RoleName": "Visitor",
                    "RoleType": null,
                    "SystemDefault": null,
                    "UpdateTime": null,
                    "UpdateTimeStr": "1629985314587"
                }
            ],
            "TotalCount": 4,
            "TotalPageNumber": 0
        },
        "RequestId": "8de3d3ad-978c-426b-83bb-f1af8b534ff1"
    }
}

5. Developer Resources

SDK

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

Command Line Interface

6. Error Code

The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

Error Code Description
FailedOperation Operation Failure.
OperationDenied.UserNotInWhitelistError The user is not in the allowlist.
Was this page helpful?
You can also Contact Sales or Submit a Ticket for help.
Yes
No

Feedback