You need to enable JavaScript to run this app.
导航
QueryPriceForRenew - 续费询价
最近更新时间:2025.06.26 20:58:18首次发布时间:2025.03.11 13:10:10
我的收藏
有用
有用
无用
无用

续费询价

使用说明

  1. 此接口仅支持续费场景询价。
  2. 只可对请求用账号的实例进行询价。
  3. 单次请求实例组InstanceIDList最多支持20个。

注意事项

  1. 单账号QPS上限为10。
  2. 子用户使用该接口时,应具备BillingCenterFullAccess或BillingCenterReadOnlyAccess权限策略。

请求参数

下表仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数

参数
类型
是否必填
示例值
描述
Action
String

QueryPriceForRenew

要执行的操作,取值:QueryPriceForRenew。

Version
String

2022-01-01

API的版本,取值:2022-01-01。

Product
String

Product_1

商品

UseDuration
Integer

1

使用时长

InstanceIDList
Array of String

["InstancelD_1"]

实例ID列表,单次最大20个且不重复

返回参数

下表仅列出本接口特有的返回参数。更多信息请参见返回结构

参数
类型
示例值
描述
Currency
String

CNY

币种,CNY

TotalOriginalAmount
String

100

总刊例价

TotalDiscountAmount
String

50

总折扣价

InstanceAmountList
Array of Object

[
{
"InstanceID": "InstanceID_1",
"Product": "Product_1",
"ConfigurationCode": "ConfigurationCode_1",
"OriginalAmount": "100",
"DiscountAmount": "50"
}
]

对应实例金额列表

请求示例

POST /?Action=QueryPriceForRenew&Version=2022-01-01 HTTP/1.1
Host: billing.volcengineapi.com
Content-Type: application/json; charset=UTF-8
X-Date: 20250224T065129Z
X-Content-Sha256: 287e874e******d653b44d21e
Authorization: HMAC-SHA256 Credential=Adfks******wekfwe/20250224/cn-beijing/billing/request, SignedHeaders=host;x-content-sha256;x-date, Signature=47a7d934ff7b37c03938******cd7b8278a40a1057690c401e92246a0e41085f

{
  "InstanceIDList": [
    "InstancelD_1"
  ],
  "Product": "Product_1",
  "UseDuration": 1
}

返回示例

{
  "ResponseMetadata": {
    "RequestId": "2025022414515825201202803272CE62",
    "Action": "QueryPriceForRenew",
    "Version": "2022-01-01",
    "Service": "billing",
    "Region": "cn-beijing"
  },
  "Result": {
    "CalSerialNo": "CSN_1234567890",
    "Currency": "CNY",
    "TotalOriginalAmount": "100",
    "TotalDiscountAmount": "50",
    "InstanceAmountList": [
      {
        "InstanceID": "InstanceID_1",
        "Product": "Product_1",
        "ConfigurationCode": "ConfigurationCode_1",
        "OriginalAmount": "100",
        "DiscountAmount": "50"
      }
    ]
  }
}

错误码

下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。

状态码
错误码
错误信息
说明
400
MissingParameter

The request is missing %s parameter.

参数缺失

400
InvalidParam

The parameter %s is invalid.

参数无效

400
OperationDenied.ProductNotAllowed

The product %s is not allowed

该商品不允许进行此操作

400
OperationDenied.InstanceNotAllowed

The Instance %s is not allowed

该实例不允许进行此操作

400
OperationDenied.ConfigurationNotPublic

The configuration %s is not public

该配置未公开售卖

400
OperationDenied.ConfigurationNotOnline

The configuration %s is not online

该配置未上架售卖

400
OperationDenied.ChargeItemNotPublic

The chargeItem %s is not public

该计费项未公开售卖

400
OperationDenied.ChargeItemNotOnline

The chargeItem %s is not online

该计费项未上架售卖

400
OperationDenied.InstanceNotExist

The instance does not exist

该实例不存在

403
RequestReject

You have engaged in unauthorized operations, and the function is temporarily unavailable.

您涉及违规操作,暂时无法使用该功能

500
InternalError

Service has some internal Error. Pls Contact With Admin.

服务内部异常