DescribeGroupRoleRules
      更新时间:2025-10-30 09:37:31
    
    
    
    
    
    
    
    
      
        
        PDF
      
      
    
  查询角色组规则。
请求参数
| 参数 | 类型 | Description | 是否必选 | 
|---|---|---|---|
| action | String | DescribeGroupRoleRules(查询角色组规则) | true | 
| zone | String | 区域 id | false | 
| project_id | String | 项目 id | true | 
| offset | Integer | 数据偏移量,默认为 0 | false | 
| limit | Integer | 返回数据长度,默认为 20,最大为 100 | false | 
| group_roles | Array | 角色组 id 列表 | true | 
| verbose | Integer | 是否返回冗长的信息,若为 1,则返回角色组的规则详情信息 | false | 
响应消息
| 参数 | 条目 | 类型 | Description | 
|---|---|---|---|
| action | - | String | DescribeGroupRoleRulesResponse | 
| item_set | - | Array | 规则集 | 
| total_count | - | Integer | 根据过滤条件得到的规则总数 | 
| ret_code | - | Integer | 执行成功与否,0 表示成功,其他值则为错误代码 | 
| group_role_rule_set | - | Array | 被更新的角色组描述 | 
| - | status | String | 启用状态,enabled 启用;disabled 未启用 | 
| - | description | String | 规则描述 | 
| - | group_role_id | String | 角色组 id | 
| - | iam_policy_id | String | IAM 策略 id | 
| - | status_time | TimeStamp | 角色组更新时间 | 
| - | create_time | TimeStamp | 角色组创建时间 | 
| - | principle | Json | 规则详情 | 
| - | policy | String | 规则类型 | 
| - | group_role_rule_id | String | 规则 id | 
示例
请求示例
https://api.qingcloud.com/iaas/?zone=test
&project_id=pj-xzvlxlb5
&action=DescribeGroupRoleRules
&offset=0
&limit=100
&group_roles=["gr-5590xkq2"]
&verbose=1响应示例
{
    "action": "DescribeGroupRoleRulesResponse",
    "item_set": [],
    "group_role_rule_set": [
        {
            "status": "disabled",
            "description": "",
            "group_role_id": "gr-5590xkq2",
            "iam_policy_id": "",
            "create_time": "2021-12-27T14:08:46",
            "principle": "{\"resource_type\":\"instance\",\"actions\":[\"CreateBrokers\",\"DeleteBrokers\",\"DescribeInstances\"]}",
            "policy": "action",
            "status_time": "2021-12-27T15:03:40",
            "group_role_rule_id": "grr-opgcd9te"
        },
        {
            "status": "enabled",
            "description": null,
            "group_role_id": "gr-5590xkq2",
            "iam_policy_id": "",
            "create_time": "2021-12-27T10:54:35",
            "principle": "",
            "policy": "all.describe",
            "status_time": "2021-12-27T10:54:35",
            "group_role_rule_id": "grr-tlq2l8tk"
        }
    ],
    "total_count": 2,
    "ret_code": 0
}