huawei-cloud-api-definitions-Workspace 0.1.20260116

Huawei Cloud API definitions, generated from OpenAPI spec
Documentation
1
{"base_path":null,"components":null,"consumes":"[\"application/json\",\"application/json;charset=utf-8\",\"application/json;charset=UTF-8\"]","definitions":{"BaseResponse":{"description":"API响应基类。","properties":{"encoded_authorization_message":{"description":"加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。","readOnly":true,"type":"string"},"error_code":{"description":"错误码。","maxLength":12,"minLength":0,"type":"string"},"error_detail":{"description":"错误详情。","maxLength":1000,"minLength":0,"type":"string"},"error_msg":{"description":"错误描述。","maxLength":1000,"minLength":0,"type":"string"}}},"CreateOrderRsp":{"description":"创建订单响应体。","properties":{"order_id":{"description":"订单号,下单成功时返回订单ID。","readOnly":true,"type":"string"}}},"CreateResourcePackageOrderReq":{"description":"创建资源包订单请求体。","properties":{"enterprise_project_id":{"description":"企业项目ID,上传则指定企业项目,不上传则表示所有企业项目。","maxLength":36,"minLength":0,"pattern":"^[a-zA-Z0-9_-]+$","type":"string"},"extend_param":{"$ref":"#/definitions/OrderExtendParam"},"resource_packages":{"description":"资源包。","items":{"$ref":"#/definitions/DesktopResourcePackage"},"maxItems":50,"minItems":1,"type":"array","x-maxLength":50,"x-minLength":1},"resource_size":{"description":"购买资源包数量。","format":"int32","maximum":100,"minimum":0,"type":"integer"}},"required":["resource_packages"]},"DesktopResourcePackage":{"properties":{"architecture":{"description":"产品架构:arm、x86。","maxLength":255,"minLength":0,"type":"string"},"cloud_service_type":{"description":"云服务类型。","type":"string"},"cpu":{"description":"cpu。","maxLength":255,"minLength":0,"type":"string"},"description":{"additionalProperties":{"readOnly":true,"type":"string"},"description":"产品描述<语言,各语言对应的产品名>。","type":"object"},"domain_ids":{"description":"该产品套餐支持的专有域id(domainId)。","items":{"maxLength":255,"minLength":0,"type":"string"},"maxItems":100,"minItems":0,"type":"array"},"memory":{"description":"内存。","maxLength":255,"minLength":0,"type":"string"},"name":{"additionalProperties":{"readOnly":true,"type":"string"},"description":"产品名称<语言,各语言对应的产品名>。","readOnly":true,"type":"object"},"package_type":{"description":"规格。","type":"string"},"resource_packages":{"description":"按需套餐包规格列表。","items":{"$ref":"#/definitions/ResourcePackage"},"type":"array"},"resource_spec_code":{"description":"资源规格编码。","type":"string"},"resource_type":{"description":"资源类型。","type":"string"}}},"OrderExtendParam":{"description":"订单的扩展参数。","properties":{"is_auto_pay":{"description":"是否自动付款。true:自动支付; false:不自动支付;默认false。","maxLength":255,"minLength":0,"type":"string"}}},"ResourcePackage":{"description":"按需资源包。","properties":{"description":{"additionalProperties":{"readOnly":true,"type":"string"},"description":"产品描述<语言,各语言对应的产品名>。","type":"object"},"measurement_name":{"description":"资源包单位,hour:小时。","type":"string"},"period_type":{"description":"周期类型,MONTH:月。","type":"string"},"period_value":{"description":"数量,单位:月。","type":"integer"},"resource_spec_code":{"description":"资源规格编码。","type":"string"},"status":{"description":"产品状态,normal/onSell:正常、sellout:售空、abandon:下线。","type":"string"},"threshold":{"description":"资源包总量。","type":"integer"}}}},"description":null,"group_id":"7383c32d5d5e4d0481c071faeb994404","host":"workspace.cn-north-4.myhuaweicloud.com","id":"e34d34ab44cb498c8f6820a026d60b2c","info_version":"v2","method":"post","name":"CreateResourcePackagesOrder","parameters":{},"paths":{"/v2/{project_id}/resource-packages/order":{"post":{"consumes":["application/json"],"description":"创建资源包订单。","operationId":"CreateResourcePackagesOrder","parameters":[{"description":"项目ID。","in":"path","maxLength":255,"minLength":1,"name":"project_id","required":true,"type":"string","x-annotations":"@Size(max = 255, min = 1)","x-example":"2b31ed520xxxxxxebedb6e57xxxxxxxx"},{"description":"创建资源包订单请求体。","in":"body","name":"CreateResourcePackagesOrderRequestBody","required":true,"schema":{"$ref":"#/definitions/CreateResourcePackageOrderReq"}}],"produces":["application/json"],"responses":{"200":{"description":"下单响应体。","examples":{"application/json":{"order_id":"string"}},"schema":{"$ref":"#/definitions/CreateOrderRsp"}},"400":{"description":"由于包含语法错误,当前请求无法被服务器理解。","schema":{"$ref":"#/definitions/BaseResponse"}},"409":{"description":"操作冲突。","schema":{"$ref":"#/definitions/BaseResponse"}},"500":{"description":"服务器内部错误。","schema":{"$ref":"#/definitions/BaseResponse"}}},"summary":"创建资源包订单","tags":["Order"],"x-api-type":"open-api","x-apiexplorer-hide":"N","x-apig-group":"public,internal_token","x-apigateway-request-type":"public","x-imports":["com.huawei.workspace.auth.iam5.WksDependIamAuthMeta","com.huawei.clouds.wushan.auth.token.IamAuthMeta","com.huawei.clouds.wushan.auth.token.IamAuthLevel","com.huawei.clouds.wushan.integration.common.auth.EnableAuth","com.huawei.clouds.wushan.cts.meta.CtsMeta"],"x-is-registered":"Y","x-methodAnnotations":["@EnableAuth","@IamAuthMeta(authLevel = IamAuthLevel.PROJECT,  authContextInitializerName = \"workspaceCommonAuthContextInitializer\", abacAction = \"workspace:orders:createResourcePackagesOrder\",  needApigwJwtAuthCheck = false, needRbacCheck = false)","@CtsMeta(serviceType = \"Workspace\", resourceType = \"workspace\", traceName = \"CreateResourcePackagesOrder\")"],"x-request-examples-1":{"enterprise_project_id":"string","extend_param":{"is_auto_pay":"string"},"resource_packages":[{"desktop_resource_spec_code":"string","resource_package_name":"string","resource_spec_code":"string"}]},"x-request-examples-text-1":{"enterprise_project_id":"string","extend_param":{"is_auto_pay":"string"},"resource_packages":[{"desktop_resource_spec_code":"string","resource_package_name":"string","resource_spec_code":"string"}]},"x-support-sdk":"Y"}}},"product_short":"Workspace","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":"订单","uri":null,"version":"2.0"}