{"base_path":"/","components":null,"consumes":"","definitions":{"ComplianceRule":{"properties":{"backup_type":{"description":"备份类型","maxLength":36,"minLength":1,"type":"string"},"created":{"description":"规则创建时间","format":"int64","maximum":2147483647,"minimum":0,"type":"integer"},"description":{"description":"规则描述","maxLength":65532,"minLength":0,"type":"string"},"domain_id":{"description":"账号ID","example":"d1234567890","maxLength":36,"minLength":1,"type":"string"},"id":{"description":"id","example":"123e4567-e89b-12d3-a456-426614174000","maxLength":512,"minLength":1,"type":"string"},"is_cross_account_backup_forced":{"description":"是否开启强制跨账号备份","example":false,"type":"boolean"},"is_system_embedded":{"description":"是否系统内置规则","example":false,"type":"boolean"},"local_backup_enabled":{"description":"是否启用本地备份","type":"boolean"},"local_backup_frequency":{"description":"本地备份频率,如按天 2次/天,按周 周一,三,五每天执行2次","properties":{"days_of_week":{"description":"如果type是weekly必选,表示一周内那些天备份 如:[\"MO\", \"TU\", \"WE\", \"TH\", \"FR\", \"SA\", \"SU\"]","example":["MO","TU","WE","TH","FR","SA","SU"],"items":{"maxLength":2,"minLength":2,"type":"string"},"maxItems":7,"minItems":1,"type":"array"},"interval":{"default":1,"description":"daily类型下,间隔多少天,默认值:1","example":1,"format":"int32","maximum":30,"minimum":1,"type":"integer"},"times_per_day":{"description":"每日执行次数","example":1,"format":"int32","maximum":24,"minimum":1,"type":"integer"},"type":{"description":"备份频率类型,可选daily weekly","example":"weekly","maxLength":16,"minLength":1,"type":"string"}},"required":["times_per_day"]},"local_backup_retention":{"description":"本地备份副本保留时长","format":"int32","maximum":2147483647,"minimum":1,"type":"integer"},"local_worm_enabled":{"description":"本地副本是否启用WORM特性。","example":true,"type":"boolean"},"name":{"description":"合规规则名称","maxLength":128,"minLength":1,"type":"string"},"remote_backup_enabled":{"description":"是否启用异地复制。","type":"boolean"},"remote_backup_retention":{"description":"异地复制副本保留时长。","format":"int32","maximum":2147483647,"minimum":1,"type":"integer"},"remote_worm_enabled":{"description":"异地复制副本是否启用WORM特性。","example":false,"type":"boolean"},"resource_type":{"description":"资源类型","example":"virtual_machine","maxLength":32,"minLength":1,"type":"string"},"updated":{"description":"规则更新时间","format":"int64","maximum":2147483647,"minimum":0,"type":"integer"}},"type":"object"},"ErrorRsp":{"description":"失败时返回的错误对象","properties":{"error_code":{"description":"错误码","maxLength":36,"minLength":8,"type":"string"},"error_msg":{"description":"错误描述","maxLength":512,"minLength":2,"type":"string"}},"required":["error_code","error_msg"]},"LevelResourceCount":{"description":"每类资源数量","properties":{"count":{"description":"资源数量","format":"int32","maximum":2147483647,"minimum":0,"type":"integer"},"resource_type":{"description":"资源类型","maxLength":64,"minLength":1,"type":"string"}},"type":"object"},"LevelResourceCountList":{"description":"各类资源数量","items":{"$ref":"#/definitions/LevelResourceCount"},"type":"array"},"ResourceLevelItem":{"description":"资源分级单条数据","properties":{"apply_rule":{"description":"应用的规则","format":"int32","maximum":2147483647,"minimum":0,"type":"string"},"apply_type":{"description":"应用方式。1:按标签匹配;2:按照资源类型和资源名称正则匹配;3:按照资源ID","format":"int32","maximum":2147483647,"minimum":0,"type":"integer"},"compliance_rule":{"$ref":"#/definitions/ComplianceRule","description":"合规规则ID"},"description":{"description":"描述","maxLength":1024,"minLength":1,"type":"string"},"domain_id":{"description":"账户ID","maxLength":64,"minLength":1,"type":"string"},"id":{"description":"资源分级ID","maxLength":512,"minLength":1,"type":"string"},"organization_id":{"description":"组织ID","maxLength":64,"minLength":1,"type":"string"},"project_id":{"description":"企业项目ID","maxLength":64,"minLength":1,"type":"string"},"providers":{"description":"资源类型","items":{"maxLength":64,"minLength":1,"type":"string"},"maxItems":10,"minItems":0,"type":"array"},"resource_count_list":{"$ref":"#/definitions/LevelResourceCountList","description":"各类资源的规则"},"resource_level":{"description":"资产级别,支持五级 。1公开,2一般,3关键,4重要,5核心","format":"int32","maximum":5,"minimum":1,"type":"integer"},"resource_level_name":{"description":"资源分级名称","maxLength":32,"minLength":2,"type":"string"}},"type":"object"},"ResourceLevelList":{"description":"资源分级列表数据","items":{"$ref":"#/definitions/ResourceLevelItem"},"type":"array"},"ResourceLevelListRsp":{"description":"资源分级列表返回体","properties":{"count":{"description":"资源等级总数","format":"int64","maximum":1024,"minimum":0,"type":"integer"},"resource_level_list":{"$ref":"#/definitions/ResourceLevelList","description":"资源等级列表"}},"type":"object"}},"description":null,"group_id":"0cb6191c2c524d62be604224b207d979","host":"bcc.cn-north-4.myhuaweicloud.com","id":"fe1915a1eeec4966a9a2403fce0db463","info_version":"v1","method":"get","name":"ListResourcesLevel","parameters":{},"paths":{"/v1/{domain_id}/resource-levels":{"get":{"description":"列举资源分级","operationId":"ListResourcesLevel","parameters":[{"description":"账号ID","in":"path","maxLength":36,"minLength":1,"name":"domain_id","required":true,"type":"string"},{"description":"云服务类型:ecs-云服务器,evs-云硬盘,sfsturbo-高性能文件存储,workspace-云桌面,rds-关系型数据库,gaussdb-高斯数据库","enum":["ecs","evs","sfsturbo","workspace","rds","gaussdb"],"in":"query","maxLength":32,"minLength":1,"name":"provider","required":false,"type":"string"},{"description":"合规规则ID","in":"query","maxLength":24,"minLength":24,"name":"compliance_rule_id","required":false,"type":"string"},{"default":10,"description":"本次请求返回的最大记录条数。","format":"int32","in":"query","maximum":100,"minimum":1,"name":"limit","required":false,"type":"integer"},{"default":0,"description":"偏移量","format":"int64","in":"query","maximum":2147483647,"minimum":0,"name":"offset","required":false,"type":"integer"}],"produces":["application/json"],"responses":{"200":{"description":"资源分级列表返回体","examples":{"application/json":{"count":1,"resource_level_list":[{"apply_rule":"[{\"key\": \"CCE-Dynamic-Provisioning-Node\"},{\"key\":\"CCE-Cluster-ID\",\"value\":\"e84d639a-c116-11ef-bfed-0255ac100b05\"}]","apply_type":1,"compliance_rule":{"backup_type":"full_backup","description":"this is a compliance rule","domain_id":"****","id":"681b02fba21b7c331d81115d","is_cross_account_backup_forced":true,"is_system_embedded":false,"local_backup_enabled":true,"local_backup_frequency":{"interval":1,"times_per_day":1,"type":"daily"},"local_backup_retention":11,"local_worm_enabled":true,"remote_backup_enabled":true,"remote_backup_retention":10,"remote_worm_enabled":false,"resource_type":"cbr"},"description":"test","domain_id":"*****","id":"681b006230b4511a437d6fce","organization_id":null,"project_id":null,"providers":["ecs","evs"],"resource_count_list":[{"count":5,"resource_type":"evs"},{"count":3,"resource_type":"ecs"}],"resource_level":5,"resource_level_name":"一般"}]}},"schema":{"$ref":"#/definitions/ResourceLevelListRsp"}},"400":{"description":"请求错误","schema":{"$ref":"#/definitions/ErrorRsp"}},"401":{"description":"未提供认证信息或认证信息错误。","schema":{"$ref":"#/definitions/ErrorRsp"}},"403":{"description":"请求页面被禁止访问。","schema":{"$ref":"#/definitions/ErrorRsp"}},"404":{"description":"未找到资源。","schema":{"$ref":"#/definitions/ErrorRsp"}},"408":{"description":"请求超出了服务器的等待时间。","schema":{"$ref":"#/definitions/ErrorRsp"}},"429":{"description":"当前请求过多。","schema":{"$ref":"#/definitions/ErrorRsp"}},"500":{"description":"请求未完成,服务异常。","schema":{"$ref":"#/definitions/ErrorRsp"}},"503":{"description":"系统暂时不可用,请求受限。","schema":{"$ref":"#/definitions/ErrorRsp"}}},"summary":"列举资源分级","tags":["资源定级"],"x-api-type":"open-api","x-iam-auth-meta-anno":{"abacAction":"bcc::listResourcesLevel","authContextInitializerName":"iamAuthListContextInitializer","authLevel":"NO_INSTANCE","model":"v5","needAbacCheck":true,"needAbacResourceCheck":false,"needApigwJwtAuthCheck":false,"needCbcCheck":false,"needRbacCheck":false,"needResourceTagCheck":false,"supportAllGrantedEps":false},"x-is-registered":"Y","x-method-annotations":["@CtsMeta(resourceType = \"ResourceLevel\", traceName = \"ListResourcesLevel\", operationId = \"ListResourcesLevel\", isReadOnly=true)"],"x-order":0,"x-support-sdk":"Y"}}},"product_short":"BCC","region_id":"cn-north-4","schemes":["HTTPS"],"security_definitions":null,"summary":"列举资源分级","tags":"资源定级","uri":null,"version":"2.0"}