接口请求域名: cam.intl.tencentcloudapi.com 。
本接口(ListEntitiesForPolicy)可用于查询策略关联的实体列表。
默认接口请求频率限制:20次/秒。
以下请求参数列表仅列出了接口请求参数和部分公共参数,完整公共参数列表见 公共请求参数。
| 参数名称 | 必选 | 类型 | 描述 |
|---|---|---|---|
| Action | 是 | String | 公共参数,本接口取值:ListEntitiesForPolicy。 |
| Version | 是 | String | 公共参数,本接口取值:2019-01-16。 |
| Region | 否 | String | 公共参数,此参数为可选参数。 |
| PolicyId | 是 | Integer | 策略 id |
| Page | 否 | Integer | 页码,默认值是 1,从 1 开始 |
| Rp | 否 | Integer | 每页大小,默认值是 20 |
| EntityFilter | 否 | String | 可取值 'All'、'User'、'Group' 和 'Role','All' 表示获取所有实体类型,'User' 表示只获取子账号,'Group' 表示只获取用户组,'Role' 表示只获取角色,默认取 'All' |
| 参数名称 | 类型 | 描述 |
|---|---|---|
| TotalNum | Integer | 实体总数 |
| List | Array of AttachEntityOfPolicy | 实体列表 |
| RequestId | String | 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。 |
https://cam.intl.tencentcloudapi.com/?Action=ListEntitiesForPolicy
&PolicyId=524497
&Page=1
&Rp=10
&EntityFilter=All
&<公共请求参数>
{
"Response": {
"List": [
{
"Id": "1133398",
"RelatedType": 1,
"Uin": 3449203261,
"AttachmentTime": "2021-11-11 19:38:01",
"Name": "test1"
}
],
"TotalNum": 1,
"RequestId": "836d7034-9854-44f0-9d4a-ee57842f8644"
}
}
云 API 3.0 提供了配套的开发工具集(SDK),支持多种编程语言,能更方便的调用 API。
以下仅列出了接口业务逻辑相关的错误码,其他错误码详见 公共错误码。
| 错误码 | 描述 |
|---|---|
| InternalError.SystemError | 内部错误。 |
| InvalidParameter.EntityFilterError | EntityFilter字段不合法。 |
| InvalidParameter.ParamError | 非法入参。 |
| InvalidParameter.PolicyIdError | 输入参数PolicyId不合法。 |
文档反馈