接口说明
面向政企版租户开放查询电脑关联的定时任务 限流:根据租户实现用户级别的限流,限制为100次每秒
URL
GET https://ecloud.10086.cn/api/Computer_api/cem_openapi/ccacem/api/v1/resource-policy/getPolicyInfoByInstanceId
请求参数
Query
|
参数名称
|
类型
|
必填
|
描述
|
|
instanceId
|
string
|
是
|
订购资源实例id |
请求示例
GET https://ecloud.10086.cn/api/Computer_api/cem_openapi/ccacem/api/v1/resource-policy/getPolicyInfoByInstanceId
返回参数
返回码:200
OK
|
参数名称
|
类型
|
描述
|
|
body
|
CemDescResourcePolicyApiResp
|
请求成功时返回的数据 |
|
createdTime
|
string
|
创建时间 |
|
creator
|
string
|
创建人 |
|
modifiedTime
|
string
|
修改时间 |
|
modifier
|
string
|
修改人 |
|
mopUserId
|
string
|
租户id |
|
mopUserName
|
string
|
租户名称 |
|
policyDesc
|
string
|
策略描述 |
|
policyName
|
string
|
策略名称 |
|
policyUid
|
string
|
定时任务策略uuid |
|
poolCode
|
string
|
所属资源池编码 |
|
poolName
|
string
|
所属资源池名称 |
|
status
|
string
|
create:创建成功,deleted:已删除 |
|
taskDescInfoList
|
<TaskInfo> array
|
任务详情 |
|
taskType
|
string
|
任务类型,定时任务类型(开机available,关机shutdown,重启restart) |
|
executePolicy
|
string
|
执行策略,eg:1:周一,2:周二,3:周三,4:周四,5:周五,6:周六,7:周日,如果选多个日期传字符串即可,用逗号隔开 |
|
executeTime
|
string
|
执行时间,时间自动默认为00:00 |
|
tenantId
|
string
|
租户主键id |
|
errorCode
|
string
|
统一错误码 |
|
errorMessage
|
string
|
错误码提示信息 |
|
requestId
|
string
|
每个请求的序列号 |
|
state
|
enum(OK,ERROR,EXCEPTION,FORBIDDEN,REMAINING,TIMEOUT)
|
返回状态码;返回正常:OK,返回错误:ERROR,返回异常:EXCEPTION,需要告警实现的:ALARM,禁止访问:FORBIDDEN |
返回示例
返回码:200
OK
{
"state":"OK",
"body":{
"policyUid":"ro-e4c7847bf8654408880e8578d718da26",
"policyName":"定时任务测试",
"tenantId":"1720405295939649537",
"mopUserId":"CIDC-U-5073a322eb2f48079cd9ce47126b2b27",
"mopUserName":"csy_csb_saas_wusai_ext_02",
"status":"create",
"policyDesc":"",
"creator":"csy_csb_saas_wusai_ext_02",
"modifier":"csy_csb_saas_wusai_ext_02",
"poolCode":"CIDC-RP-25",
"poolName":"华东-苏州",
"taskDescInfoList":[
{
"taskType":"available",
"executePolicy":"2",
"executeTime":"14:07"
},
{
"taskType":"shutdown",
"executePolicy":"3",
"executeTime":"00:00"
},
{
"taskType":"restart",
"executePolicy":"4",
"executeTime":"00:00"
}
],
"modifiedTime":"2025-04-14 14:04:20",
"createdTime":"2025-04-11 16:51:03"
},
"errorCode":"200",
"errorMessage":"",
"requestId":"804a2f520565ebf1"
}