Batch Modifying Subscriptions
Function
This API is used to modify subscriptions in batches for a DB instance.
- Before calling this API, learn how to authenticate it.
- Before calling this API, learn about request header parameters.
Authorization Information
- If you are using role/policy-based authorization, see Permissions and Supported Actions for details on the required permissions.
- If you are using identity policy-based authorization, the following identity policy-based permissions are required.
|
Action |
Access Level |
Resource Type (*: required) |
Condition Key |
Alias |
Dependencies |
|---|---|---|---|---|---|
|
rds:instance:update |
write |
- |
- |
rds:instance:modify |
- |
URI
- Parameter description
Table 1 Parameters Parameter
Mandatory
Description
project_id
Yes
Definition
Project ID of a tenant in a region.
To obtain the value, see Obtaining a Project ID.
Constraints
The value cannot be empty.
Range
N/A
Default Value
N/A
instance_id
Yes
Definition
Instance ID.
Constraints
The value cannot be empty.
Range
N/A
Default Value
N/A
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
subscription_ids |
Yes |
Array of strings |
Definition IDs of subscriptions to modify. Constraints The subscriptions to modify must belong to the same instance. Range N/A Default Value N/A |
|
job_schedule |
Yes |
Object |
Definition Snapshot schedule. For details, see Table 3. Constraints N/A |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
id |
No |
String |
Definition Schedule ID. Constraints N/A Range N/A Default Value N/A |
|
job_schedule_type |
No |
String |
Definition Schedule type. Constraints N/A Range
Default Value recurring |
|
one_time_occurrence |
No |
Object |
Definition Execution time when the task is executed only once. For details, see Table 4. Constraints N/A |
|
frequency |
No |
Object |
Definition Interval of the schedule. For details, see Table 5. Constraints This parameter is valid only when the schedule ID is empty. |
|
daily_frequency |
No |
Object |
Definition Daily frequency of the schedule. For details, see Table 6. Constraints This parameter is valid only when the schedule ID is empty. |
|
duration |
No |
Object |
Definition Validity period of the schedule. For details, see Table 7. Constraints This parameter is valid only when the schedule ID is empty. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
active_start_date |
No |
String |
Definition Execution date, in the format of yyyy-MM-dd. Constraints N/A Range 1990-01-01 to 2099-12-31 Default Value N/A |
|
active_start_time |
No |
String |
Definition Execution time, in the format of HH:mm:ss. Constraints N/A Range N/A Default Value N/A |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
freq_type |
No |
String |
Definition Frequency type of the schedule. Constraints N/A Range
Default Value N/A |
|
freq_interval |
No |
Integer |
Definition Execution interval. Constraints N/A Range 1–99 Default Value N/A |
|
freq_interval_weekly |
No |
Array of strings |
Definition Days in a week when the task is executed. Constraints This parameter is mandatory when freq_type is set to weekly. If freq_type is not set to weekly, this parameter does not take effect. Range Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, Sunday Default Value N/A |
|
freq_interval_day_monthly |
No |
Integer |
Definition Monthly execution dates. Constraints This parameter is mandatory when freq_type is set to monthly_day. If freq_type is not set to monthly_day, this parameter does not take effect. Range 1 to the total number of days in the month, for example, 1 to 31 Default Value N/A |
|
freq_interval_monthly |
No |
String |
Definition Days in a week when the task is executed in the current month. Constraints This parameter is mandatory when freq_type is set to monthly_week. If freq_type is not set to monthly_week, this parameter does not take effect. Range Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, day, weekday, weekend Default Value N/A |
|
freq_relative_interval_monthly |
No |
String |
Definition Week in a month when the task is executed. Constraints This parameter is mandatory when freq_type is set to monthly_week. If freq_type is not set to monthly_week, this parameter does not take effect. Range first, second, third, fourth, last Default Value N/A |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
freq_subday_type |
No |
String |
Definition Daily frequency type. Constraints N/A Range
Default Value N/A |
|
active_start_time |
No |
String |
Definition Time of the first execution on each day. If freq_subday_type is set to once, the task is executed only once a day. The value is in HH:mm:ss format. Constraints N/A Range N/A Default Value N/A |
|
active_end_time |
No |
String |
Definition Last execution time, in the format of HH:mm:ss. Constraints This parameter is mandatory when the task is executed multiple times a day. It does not take effect when the task is executed only once a day. Range N/A Default Value N/A |
|
freq_subday_interval |
No |
Integer |
Definition Execution interval. Constraints This parameter is mandatory when the task is executed multiple times a day. It does not take effect when the task is executed only once a day. Range 1–99 Default Value N/A |
|
freq_interval_unit |
No |
String |
Definition Execution interval unit. Constraints This parameter is mandatory when the task is executed multiple times a day. It does not take effect when the task is executed only once a day. Range
Default Value N/A |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
active_start_date |
No |
String |
Definition First execution date, in the format of yyyy-MM-dd. Constraints N/A Range 1990-01-01 to 2099-12-31 Default Value N/A |
|
active_end_date |
No |
String |
Definition Last execution date, in the format of yyyy-MM-dd. By default, the execution does not end. Constraints N/A Range N/A Default Value N/A |
Example Request
Modify subscriptions in batches for a DB instance.
PUT https://{Endpoint}/v3/054e292c9880d4992f02c0196d3ea468/instances/3d39c18788b54a919bab633874c159dfin04/replication/subscriptions
{
"subscription_ids": [
"5b7dfa4f-a16e-4588-9d4e-89353f823512"
],
"job_schedule": {
"id": "569d69c2-53e5-4bef-a356-d7ea2ff6fb98",
"user_defined": false,
"schedule_type": "sync",
"job_schedule_type": "automatically",
"one_time_occurrence": {
},
"frequency": {
},
"daily_frequency": {
},
"duration": {
}
}
}
Response
- Normal response
Table 8 Response body parameters Parameter
Type
Description
subscriptions
Array of objects
Definition
Subscription modification results.
For details, see Table 9.
Range
N/A
- Example normal response
{ "subscriptions": [ { "id": "5b7dfa4f-a16e-4588-9d4e-89353f823512", "result": "success" } ] } - 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