Mengubah metode penagihan instans Database Apsara for MongoDB dari pay-as-you-go menjadi langganan.
Deskripsi operasi
Before you call this operation, make sure that you understand the billing methods and pricing.
A subscription instance cannot be changed to a pay-as-you-go instance. To avoid wasting resources, proceed with caution.
Before you call this API operation, make sure that the ApsaraDB for MongoDB instance meets the following requirements:
-
The instance is in the running state.
-
The billing method of the instance is pay-as-you-go.
-
The instance has no unpaid subscription orders.
-
The instance type is available for purchase. For more information about unavailable instance types, see Instance types.
To change the billing method of an instance whose instance type is no longer available to subscription, call the ModifyDBInstanceSpec or ModifyNodeSpec operation to first change the instance type.
Coba sekarang
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
dds:TransformToPrePaid |
update |
*Instance
|
None | None |
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| InstanceId |
string |
Yes |
ID instans. |
dds-bp1366caac83**** |
| Period |
integer |
Yes |
Durasi langganan instans. Unit: bulan. Nilai valid: 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, dan 36. |
1 |
| AutoPay |
boolean |
No |
Apakah akan mengaktifkan pembayaran otomatis. Nilai valid:
Catatan
Nilai default: true. |
true |
| BusinessInfo |
string |
No |
Informasi bisnis. Ini adalah parameter tambahan. |
{“ActivityId":"000000000"} |
| AutoRenew |
string |
No |
Apakah akan mengaktifkan perpanjangan otomatis untuk instans. Nilai valid:
Catatan
Nilai default: false. |
true |
| CouponNo |
string |
No |
Kode kupon. Nilai default: |
default |
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The ID of the request. |
2F42BB4E-461F-5B55-A37C-53B1141C**** |
| OrderId |
string |
The ID of the order. |
21022019252**** |
Contoh
Respons sukses
JSONformat
{
"RequestId": "2F42BB4E-461F-5B55-A37C-53B1141C****",
"OrderId": "21022019252****"
}
Kode kesalahan
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | MissingParameter | Period is mandatory for this action. | |
| 400 | InvalidParam | Period is invalid | |
| 400 | ResourceNotAvailable | Resource you requested is not available for finance user. | |
| 400 | InsufficientBalance | Your account does not have enough balance. | |
| 403 | AlreadyPrePaid | This instance is already prepaid | |
| 403 | RealNameAuthenticationError | Your account has not passed the real-name authentication yet. |
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.