You need to enable JavaScript to run this app.
导航

ModifyDBInstanceChargeType

最近更新时间2023.11.15 22:39:52

首次发布时间2023.11.15 22:39:52

调用 ModifyDBInstanceChargeType 接口修改实例计费类型。

请求类型

异步请求。

请求参数

名称类型是否必选示例值描述
InstanceIdStringpostgres-21a3333b****实例 ID。

ChargeType

String

PrePaid

付费类型。取值为 PrePaid(包年包月)。

说明

仅支持将按量计费类型的实例转为包年包月类型的实例。

AutoRenew

Boolean

true

预付费场景下是否自动续费。

  • true:自动续费。
  • false:不自动续费 (默认)。

PeriodUnit

String

Month

预付费场景下的购买周期。

  • Month:包月(默认)。
  • Year:包年。
PeriodInteger1预付费场景下的购买时长。默认值:1。

返回参数

名称类型示例值描述
InstanceIdStringpostgres-21a3333b****实例 ID。
OrderIdStringOrder709899242175681****订单 ID。

请求示例

POST /?Action=ModifyDBInstanceChargeType&Version=2022-01-01 HTTP/1.1
Content-Type: application/json
Host: rds.volcengineapi.com
X-Date: 20231002T101010Z
Authorization: HMAC-SHA256 Credential=AKLTN2I0MmFiNzMxNWE5NDgzMzk4MmVjMTVkODlkZTZ****/20211202/cn-beijing/rds_postgresql/request,SignedHeaders=x-date, Signature=71d31fc7bcf990142851c9833c5656391486cda0ae2e0b8ada733b7c6458****
{
    "InstanceId": "postgres-ca7b7019****",
    "ChargeType": "PrePaid",
    "PeriodUnit": "Month",
    "AutoRenew": false
}

返回示例

正常返回示例

{
    "ResponseMetadata": {
        "RequestId": "20230802104119518A5717C82679D86E18",
        "Action": "ModifyDBInstanceChargeType",
        "Version": "2022-01-01",
        "Service": "rds_postgresql",
        "Region": "cn-beijing"
    },
    "Result": {
        "InstanceId": "postgres-ca7b7019****",
        "OrderNO": "Order726254891288237****"
    }
}