Changing the Billing Mode from Pay-per-Use to Yearly/Monthly
Function
This API is used to change the billing mode of an RDS instance from pay-per-use to yearly/monthly.
- Before calling an API, you need to understand the API in Authentication.
URI
- Parameter description
Table 1 Parameters Parameter
Mandatory
Description
project_id
Yes
Explanation:
Project ID of a tenant in a region.
For details about how to obtain the project ID, see Obtaining a Project ID.
Constraints:
N/A
Value range:
N/A
Default value:
N/A
instance_id
Yes
Explanation:
Instance ID.
Constraints:
N/A
Value range:
N/A
Default value:
N/A
Request
- Parameter description
Table 2 Parameters Parameter
Mandatory
Type
Description
period_type
Yes
String
Explanation:
Period type.
Constraints:
N/A
Value range:
- MONTH
- YEAR
Default value:
N/A
period_num
Yes
int
Explanation:
Number of periods.
Constraints:
N/A
Value range:
N/A
Default value:
N/A
auto_pay_policy
No
String
Explanation:
Whether to enable automatic payment.
Constraints:
N/A
Value range:
- YES: Enable automatic payment.
- NO (default): Disable automatic payment.
Default value:
NO
auto_renew_policy
No
String
Explanation:
Whether to automatically renew the subscription upon expiration.
Constraints:
N/A
Value range:
- YES: Enable auto renewal.
- NO (default): Disable auto renewal.
Default value:
NO
- URI example
POST https://rds.ap-southeast-1.myhuaweicloud.com/v3/0483b6b16e954cb88930a360d2c4e663/instances/49b9dd1d6f464ba4bc91df5cbd2e52ebin03/to-period
- Request example
Change the billing mode of an RDS instance from pay-per-use to yearly/monthly.
{ "period_type" : "MONTH", "period_num" : 6, "auto_pay_policy" : "NO", "auto_renew_policy" : "NO" }
Response
- Normal response
Table 3 Parameters Parameter
Type
Description
order_id
String
Explanation:
ID of the order for changing the billing mode to yearly/monthly.
Value range:
N/A
- Example normal response
{ "order_id" : "CS2408170728W40QZ" }
- Abnormal response
For details, see Abnormal Request Results.
Status Code
- Normal
- Abnormal
For details, see Status Codes.
Error Code
For details, see Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot