查询订单的资源开通详情(旧)
功能介绍
客户在自建平台查询订单的资源详情及开通状态。
注意事项:
该接口只允许客户的AK/SK或者Token调用。
该接口即将下线,替代接口将由云服务后续提供。
URI
GET /v1.0/{domain_id}/common/order-mgr/orders-resource/{order_id}
参数说明请参见下表。
|
参数 |
是否必选 |
取值范围 |
描述 |
|---|---|---|---|
|
domain_id |
是 |
最大长度:64 |
客户账号ID。获取方法请参见如何获取客户的customer_id/domain_id。 |
|
order_id |
是 |
最大长度:64 |
订单ID。 订购包年/包月产品时系统会生成一个订单ID。 |
|
参数 |
是否必选 |
参数类型 |
取值范围 |
描述 |
|---|---|---|---|---|
|
offset |
是 |
Integer |
[1-2147483647] |
页数,默认值为1。 |
|
limit |
是 |
Integer |
[1-50] |
每页查询条数,默认值为10。 |
请求消息
请求参数
无。
请求示例
GET https://bss.myhuaweicloud.com/v1.0/{domain_id}/common/order-mgr/orders-resource/CS*****YE?offset=1&limit=10 HTTP/1.1 Content-Type: application/json X-Auth-Token:MIIPAgYJKoZIhvcNAQcCo...ggg1BBIINPXsidG9rZ
响应消息
响应参数
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
error_code |
String |
状态码。 只有失败时才返回此参数,具体请参考状态码。 |
|
error_msg |
String |
错误描述信息。只有失败时才返回此参数。 |
|
totalSize |
Integer |
资源总数。 只有成功时才返回此参数。 |
|
resources |
List<Resource> |
资源信息列表。 只有成功时才返回此参数,具体请参见表3。 |
|
参数 |
参数类型 |
描述 |
|---|---|---|
|
resourceId |
String |
资源实例ID。 只有有资源实例ID并且开通成功的资源才会返回该字段。 |
|
cloudServiceType |
String |
云服务类型编码,例如OBS的云服务类型编码为“hws.service.type.obs”。您可以调用查询云服务类型列表接口获取。 |
|
regionCode |
String |
云服务区编码,例如:“cn-north-1”。具体请参见地区和终端节点对应云服务的“区域”列的值。 |
|
resourceType |
String |
资源类型编码,例如ECS的VM为“hws.resource.type.vm”。您可以调用查询资源类型列表接口获取。 |
|
resourceSpecCode |
String |
云服务产品的资源规格。如果是VM的资源规格,则需要在规格后面添加“.win”或“.linux”,例如“s2.small.1.linux”。 |
|
resourceSize |
Double |
资源容量大小,与“resouceSizeMeasureId”配合。 例如购买的卷大小或带宽大小。 |
|
resouceSizeMeasureId |
Integer |
资源容量度量标识,枚举值如下:
|
|
status |
Integer |
资源开通状态:
|
响应示例:
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: length
Date: response time
{
"totalSize": 5,
"resources": [
{
"resourceId": "01c*****5f7",
"cloudServiceType": "hws.service.type.ec2",
"regionCode": "cn-north-1",
"resourceType": "hws.resource.type.vm",
"resourceSpecCode": "h1.8xlarge.4.gwc01",
"resourceSize": null,
"resouceSizeMeasureId": null,
"status": 1
},
{
"resourceId": "df1*****def",
"cloudServiceType": "hws.service.type.vpc",
"regionCode": "cn-north-1",
"resourceType": "hws.resource.type.ip",
"resourceSpecCode": "5_bgp",
"resourceSize": null,
"resouceSizeMeasureId": null,
"status": 1
},
{
"resourceId": "3d*****585",
"cloudServiceType": "hws.service.type.ebs",
"regionCode": "cn-north-1",
"resourceType": "hws.resource.type.volume",
"resourceSpecCode": "SATA",
"resourceSize": 40,
"resouceSizeMeasureId": 17,
"status": 1
},
{
"resourceId": "23b*****3321",
"cloudServiceType": "hws.service.type.ebs",
"regionCode": "cn-north-1",
"resourceType": "hws.resource.type.volume",
"resourceSpecCode": "SATA",
"resourceSize": 100,
"resouceSizeMeasureId": 17,
"status": 1
},
{
"resourceId": "3e00*****d779",
"cloudServiceType": "hws.service.type.vpc",
"regionCode": "cn-north-1",
"resourceType": "hws.resource.type.bandwidth",
"resourceSpecCode": "19_bgp",
"resourceSize": 1,
"resouceSizeMeasureId": 15,
"status": 1
}
]
}