huawei-cloud-api-definitions-WorkspaceApp 0.1.20260612

Huawei Cloud API definitions, generated from OpenAPI spec
Documentation
1
{"base_path":null,"components":null,"consumes":"[\"application/json\"]","definitions":{"BaseResp":{"description":"API响应基类。","properties":{"error_code":{"description":"错误码,失败时返回。","example":"WKS.00149901","maxLength":16,"minLength":1,"type":"string"},"error_msg":{"description":"错误描述。","example":"The request message is invalid.","maxLength":255,"minLength":1,"type":"string"}}},"JobDetail":{"description":"Job信息详情。","properties":{"begin_time":{"description":"Job处理开始时间。","example":"2022-03-07T10:40:43Z","format":"date-time","readOnly":true,"type":"string"},"end_time":{"description":"job处理结束时间。","example":"2022-03-07T10:40:43Z","format":"date-time","readOnly":true,"type":"string"},"execute_code":{"description":"Job执行结果码","example":"0","readOnly":true,"type":"string"},"execute_message":{"description":"Job执行结果描述,以及每个SubJob的执行结果描述。","example":"success","readOnly":true,"type":"string"},"expected_end_time":{"description":"云服务预估的Job处理结束时间,只针对job有效,针对子job无效。","example":"2022-03-07T10:40:43Z","format":"date-time","readOnly":true,"type":"string"},"job_id":{"description":"任务ID。","example":"1","readOnly":true,"type":"string"},"job_status":{"description":"job执行状态\n- 0:失败。(如果是开通失败,云运营查询到失败状态,直接退费给客户。如果是变更失败,当前是发运维工单,暂时还不是直接退费给客户。)\n- 1:成功。(处理结果成功。)\n- 2:处理中。\n- 3:正在初始化。","example":1,"readOnly":true,"type":"integer"},"job_type":{"description":"job类型,固定值1。","example":1,"readOnly":true,"type":"integer"},"sub_jobs":{"description":"子任务信息。","items":{"$ref":"#/definitions/SubJobInfo"},"readOnly":true,"type":"array"}}},"JobResourceInfo":{"description":"具体的资源信息。","properties":{"cloud_service_type":{"description":"云服务类型编码;新购、规格变更场景,必填。","readOnly":true,"type":"string"},"extend_params":{"description":"expireTime:到期时间,域名注册服务使用。\n UTC时间,格式:yyyy-MM-ddTHH:mm:ssZ(2016-06-28T00:00:00Z)。","readOnly":true,"type":"string"},"is_main_resource":{"description":"该resourceId是否是主资源(仅开通场景使用,其他场景为空)。\n* `1` - 是\n* `0` - 否","example":1,"readOnly":true,"type":"integer"},"main_resources":{"description":"resourceId的主资源。\n 是挂载到/绑定到/依附到/包含于/关联到资源,比如IP的主资源‘云主机’、数据盘的主资源‘云主机’。\n 如果resourceId是依附在多个资源上,则有多个主资源,比如共享盘挂载到多个云主机上。\n 无关联主资源,则空,比如独立未挂载的数据盘。","items":{"$ref":"#/definitions/RelativeResource"},"readOnly":true,"type":"array"},"measure":{"description":"specSize的单位编码,比如GB、M,有specSize时,此字段必填。","format":"int32","readOnly":true,"type":"integer"},"old_cloud_service_type":{"description":"仅针对ECS/BMS云服务的“切换操作系统”场景使用:云主机切换操作系统的云服务类型编码会变化场景。\n填写变更前老的云服务类型编码。云服务类型未变化,无此字段。","readOnly":true,"type":"string"},"old_resource_id":{"description":"仅针对ECS/BMS云服务的“切换操作系统”场景使用。\n云主机切换操作系统的资源id会变化场景。\n填写变更前老的资源Id。资源Id未变化,无此字段。","maxLength":128,"minLength":0,"readOnly":true,"type":"string"},"old_resource_type":{"description":"仅针对ECS/BMS云服务“切换操作系统”场景使用。\n云主机切换操作系统的资源类型编码会变化场景。\n填写变更前老的资源类型编码。资源类型未变化,无此字段。","readOnly":true,"type":"string"},"processed_time":{"description":"处理时间。","example":"2022-03-07T10:40:43Z","format":"date-time","readOnly":true,"type":"string"},"resource_id":{"description":"客户在云服务Console上可见的资源实例Id,全局唯一,且不可更改,最大64个字符。\n 注:“规格变更”场景下(包括升降配),是对某个资源实例的规格进行调整,\n 该资源实例其他信息(比如资源Id、资源名称)和运行的业务数据不变化。","maxLength":128,"minLength":0,"readOnly":true,"type":"string"},"resource_name":{"description":"资源名称;创建、有最新资源名称场景,必填。","readOnly":true,"type":"string"},"resource_spec_code":{"description":"资源规格编码;新购、规格变更场景,必填。","readOnly":true,"type":"string"},"resource_type":{"description":"资源类型编码;新购、规格变更场景,必填。","readOnly":true,"type":"string"},"spec_size":{"description":"某些规格属性大小:比如带宽大小、数据盘大小。","format":"double","readOnly":true,"type":"number"},"spec_type":{"additionalProperties":{"properties":{},"type":"object"},"description":"规格类型,运营上需要呈现和使用的一些规格属性,多个使用K:V格式。\n比如带宽的共享/独享(shareable:true/false),数据盘的系统盘/数据盘类型(root:true/false)。\n当前针对共享带宽、共享盘使用,必填。","readOnly":true,"type":"object"}}},"RelativeResource":{"description":"关联资源","properties":{"extend_params":{"description":"扩展信息,Key:Value格式。","readOnly":true,"type":"string"},"relative_cloud_service_type":{"description":"比如ECS云服务类型为‘hws.service.type.ec2’。","readOnly":true,"type":"string"},"relative_resource_id":{"description":"关联的资源ID。","maxLength":128,"minLength":0,"readOnly":true,"type":"string"},"relative_resource_name":{"description":"有资源名称的云资源,都需要返回resourceName,如果为空值,则返回“”。","readOnly":true,"type":"string"},"relative_resource_type":{"description":"比如VM的资源类型为‘hws.resource.type.vm’。","readOnly":true,"type":"string"},"relative_type":{"description":"* 关联关系类型,描述relativeResourceId和resourceId间的关联关系:\n   * 0:挂载(弱关联),表示relativeResourceId和resourceId两者有关联关系,\n    * 但是两者可以独立使用、分别进行交易,且分别使用和交易都不影响整套云服务的使用;比如云主机和数据盘。 *\n    1:绑定(强关联),表示relativeResourceId和resourceId是强绑定关系,\n     两者必须一起使用、一起进行交易,缺少其中一个会造成整套云服务不能使用;比如云主机和系统盘。\n          缺省值为0(挂载)。\n          subResources中的RelativeResource,此字段是必填;mainResources中的RelativeResource。","example":1,"maximum":1,"minimum":0,"type":"integer"}}},"ShowJobResp":{"description":"查询任务详情。","properties":{"job":{"$ref":"#/definitions/JobDetail","readOnly":true}}},"SubJobInfo":{"description":"子任务信息。","properties":{"begin_time":{"description":"任务开始时间。","example":"2022-03-07T10:40:43Z","format":"date-time","readOnly":true,"type":"string"},"end_time":{"description":"任务结束时间。","example":"2022-03-07T10:40:43Z","format":"date-time","readOnly":true,"type":"string"},"entities":{"description":"SubJob中处理的云服务/云资源对象。 创建、规格变更等场景是必填;冻结、解冻、删除等场景可空。","items":{"$ref":"#/definitions/JobResourceInfo"},"readOnly":true,"type":"array"},"execute_code":{"description":"Job执行结果码。","example":"0","readOnly":true,"type":"string"},"execute_message":{"description":"Job执行结果描述,以及每个SubJob的执行结果描述。","example":"execute fail!","readOnly":true,"type":"string"},"expected_end_time":{"description":"云服务预估的Job处理结束时间,只针对job有效,针对子job无效。","example":"2022-03-07T10:40:43Z","format":"date-time","readOnly":true,"type":"string"},"job_id":{"description":"子job标识。","example":"1","readOnly":true,"type":"string"},"job_status":{"description":"job状态\n- 0:失败。\n- 1:成功。\n- 2:处理中。\n- 3:正在初始化。","example":1,"readOnly":true,"type":"integer"},"job_type":{"description":"任务类型,固定值2:子Job。","example":2,"readOnly":true,"type":"integer"}}}},"description":null,"group_id":"fe7dbee2e20f4aa589be7dce935a38ad","host":"appstream.cn-north-4.myhuaweicloud.com","id":"9130b573d35844c797f9d58758ab005e","info_version":"v1","method":"get","name":"ShowJob","parameters":{},"paths":{"/v1/{project_id}/job/{job_id}":{"get":{"consumes":["application/json"],"description":"查询Job的执行状态。\n\n对于创建云应用服务器命令下发后会返回job_id,通过job_id可以查询任务的执行状态。","operationId":"ShowJob","parameters":[{"description":"用户Token。\n通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。","in":"header","maxLength":2147483647,"minLength":0,"name":"X-Auth-Token","required":false,"type":"string","x-example":"MIIDkgYJKoZIhvcNAQcCoIIDgzCCXXXXXX..."},{"description":"项目唯一标识。","in":"path","maxLength":128,"minLength":1,"name":"project_id","required":true,"type":"string","x-example":"2b31ed520xxxxxxebedb6e57xxxxxxxx"},{"description":"任务ID。","in":"path","maxLength":255,"minLength":1,"name":"job_id","required":true,"type":"string","x-example":"2382dd96-xxxxx56d-axxxc4b09a35b58"}],"produces":["application/json"],"responses":{"200":{"description":"成功响应。","examples":{"application/json":{"job":{"begin_time":"2023-06-06T02:30:06Z","end_time":"2023-06-06T02:45:49Z","execute_code":"","execute_message":"","expected_end_time":"2023-06-06T15:55:57Z","job_id":"575768277444198400","job_status":0,"job_type":1,"sub_jobs":[{"begin_time":"2023-06-06T02:30:06Z","end_time":"2023-06-06T02:45:49Z","entities":[],"job_id":"575768277481947136","job_status":0,"job_type":2}]}}},"schema":{"$ref":"#/definitions/ShowJobResp"}},"400":{"description":"由于包含语法错误,当前请求无法被服务器理解。","schema":{"$ref":"#/definitions/BaseResp"}},"401":{"description":"鉴权失败。","schema":{"$ref":"#/definitions/BaseResp"}},"403":{"description":"没有操作权限。","schema":{"$ref":"#/definitions/BaseResp"}},"500":{"description":"服务内部错误,具体返回错误码请参见错误码说明。","schema":{"$ref":"#/definitions/BaseResp"}}},"security":[{"apig-auth-iam-used-authn5":[]}],"summary":"查询任务的执行状态","tags":["Job"],"x-api-type":"open-api","x-apiexplorer-hide":"N","x-apig-group":"internal,public","x-apigateway-backend":{"httpVpcEndpoints":{"description":"","method":"GET","name":"wks-bundlemanager-lb","path":"/v1/{project_id}/job/{job_id}","scheme":"https","timeout":30000},"parameters":[{"description":"","in":"header","name":"X-Auth-Token","origin":"request","value":"X-Auth-Token"},{"description":"","in":"path","name":"project_id","origin":"request","value":"project_id"},{"description":"","in":"path","name":"job_id","origin":"request","value":"job_id"}],"type":"HTTP-VPC"},"x-apigateway-cors":false,"x-apigateway-match-mode":"NORMAL","x-apigateway-ratelimit":"workspace_base","x-apigateway-request-type":"public","x-is-registered":"Y","x-request-examples-url-1":"GET /v1/29dfe82ada564ac2b927e1ff036d9a9b/job/575768277444198400","x-support-sdk":"Y"}}},"product_short":"WorkspaceApp","region_id":"cn-north-4","schemes":["HTTPS"],"security_definitions":{"apig-auth-app":{"in":"header","name":"Authorization","type":"apiKey","x-apigateway-auth-type":"AppSigv1"},"apig-auth-iam":{"in":"header","name":"unused","type":"apiKey","x-apigateway-auth-type":"IAM"},"apig-auth-iam-used-authn5":{"in":"header","name":"unused","type":"apiKey","x-apigateway-auth-opt":{"inner-auth-type":"iam_auth_n5"},"x-apigateway-auth-type":"IAM"}},"summary":"查询任务的执行状态","tags":"查询Job状态","uri":null,"version":"2.0"}