InquiryBandwidthClusterPrice

1. 接口描述

本接口用于查询共享带宽包价格。

2. 请求参数

以下请求参数列表仅列出了接口中需要的请求参数

参数名称
必选
类型
描述

areaCode

String

共享带宽包所属地域。

具体地域信息可以查询DescribeBandwidthClusterAreas中的areaCode获取。

commitBandwidthMbps

Integer

保底带宽值。

单位: Mbps。

可选值范围:[0, 100000]。

默认值:0。

networkType

IP 网络类型。

internetChargeType

带宽计费方式。

默认为月95计费,如果需要日峰值计费,请联系Support开通相关权限。

默认值:MonthlyPercent95Bandwidth。

3. 响应结果

参数名称
类型
描述

requestId

String

唯一请求 ID。

每次请求都会返回。定位问题时需要提供该次请求的 RequestId。

4. 代码示例

1. 查询上海(SHA)地区共享带宽包 100 M保底,IP线路为BGP,计费类型为月95的价格。

POST /api/v2/traffic HTTP/1.1
Host: console.zenlayer.com
Content-Type: application/json
X-ZC-Action: InquiryBandwidthClusterPrice
<Common Request Params>

Request:
{
  "areaCode" : "SHA",
  "chargeType" : "POSTPAID",
  "commitBandwidthMbps" : 100,
  "networkType" : "BGP",
  "internetChargeType" : "MonthlyPercent95Bandwidth"
}

Response:
{
  "requestId": "TBF3D5D7B-DE28-42DC-AB14-03B73D777643",
  "response": {
    "price": {
      "unitPrice": 1300.000000,
      "originalPrice": null,
      "discountPrice": null,
      "discount": 100,
      "excessUnitPrice": 1.3,
      "excessAmountUnit": "Mbps",
      "stepPrices": null,
      "discountUnitPrice": 1300.000000,
      "chargeUnit": "MONTH",
      "amountUnit": null,
      "excessDiscountUnitPrice": 1.3
    },
    "requestId": "TBF3D5D7B-DE28-42DC-AB14-03B73D777643"
  }
}

5. 开发者工具

Zenlayer Cloud API 2.0 提供了配套的开发工具集(SDK),未来会陆续支持更多开发语言,方便快速接入和使用Zenlayer的产品和服务。

6. 错误码

下面包含业务逻辑中遇到的错误码,其他错误码见公共错误码

最后更新于