Modifies the backup source of a database. For more information, see ModifyBackupSourceEndpoint.

This operation is asynchronous. The returned value is the ID of the task. ModifyBackupSourceEndpoint the query results.

After you call this operation to obtain the target TaskId, you can call this operation to query the task ID.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Required ModifyBackupSourceEndpoint

The parameter specified by the system. Value: ModifyBackupSourceEndpoint.

BackupPlanId String Required dbs1h****usfa

The ID of the backup plan.

SourceEndpointInstanceType String Required rds

The location of the database. Valid values:

  • RDS
  • ECS
  • Express: a database connected over express connect, VPN Gateway, or smart gateway.
  • Agent: The database connected through the backup Gateway
  • DDS: apsaradb for MongoDB
  • Other: the database is directly connected through IP Address: Port.
SourceEndpointRegion String No cn-hangzhou

The region of the database. You must specify this parameter if you specify the value of the SourceEndpoint.InstanceType parameter as RDS, ECS, DDS, Express, or Agent.

SourceEndpointInstanceID String No rm-bp1p8c29479jvXXXX

The ID of the database instance. You must specify this parameter if the value of the SourceEndpoint.InstanceType parameter is set to RDS, ECS, DDS, or Express.

SourceEndpointIP String No 100.*. *.10:33204

The database endpoint. This parameter must be specified if the value of the SourceEndpoint.InstanceType parameter is express, agent, or other.

SourceEndpointPort Integer Optional 3306

The port number of the database. You must specify this parameter if you set the value of the SourceEndpoint.InstanceType parameter to express, agent, other, or ECS.

SourceEndpointDatabaseName String No test

The database name. When the database type is PostgreSQL or MongoDB, this parameter is required. When the database location is agent and the database type is MSSQL, this parameter is required.

SourceEndpointUserName String No test

The database account used to log on to the apsaradb for Redis instance. This parameter is required when the database location is agent and the database type is MSSQL.

SourceEndpointPassword String No test

The password required. You must specify a password when the database type is Redis, or the database location is agent and the database type is MSSQL.

BackupGatewayId Long No 21321323213

The ID of the backup gateway. If the value of the SourceEndpoint.InstanceType parameter is agent, this parameter is required.

BackupObjects String No [{"DBName":"The name of the database to be backed up", "SchemaName":"The name of the Schema to be backed up", "TableExcludes":[{"TableName":"The name of the table to be backed up" }], "TableExcludes":[{"TableName":"Name of the database to be backed up. Name of a table that does not need to be backed up" }] } ]

The ID of the backup object. If the agent is used to store the database, this parameter is required in other scenarios.

SourceEndpointOracleSID String No test

The SID of the Oracle Database. This parameter is required when the database type is Oracle.

RegionId String No cn-hangzhou

Region ID, call DescribeRegions to view the regions supported by DBS.

ClientToken String No ETnLKlblzczshOTUbOCzxxxxxxx

The client token that is used to ensure the idempotence of the request.

Response parameters

Parameter Type Example Description
BackupPlanId String dbs1h****usfa

The ID of the backup plan.

ErrCode String Param.NotFound

The error code.

ErrMessage String The specified parameter %s value is not valid.

The error message.

HttpStatusCode Integer 200

The HTTP status code.

NeedPrecheck Boolean false

Indicates whether the PreCheck is triggered by the modification. If the value is true, you need to call the StartBackupPlan operation to start a backup plan.

RequestId String D6E068C3-25BC-455A-85FE-45F0B22ECB1F

The ID of the request.

Success Boolean true

Indicates whether the request succeeded.

Examples

Sample requests

http(s)://dbs-api.cn-hangzhou.aliyuncs.com/? Action=ModifyBackupSourceEndpoint
&BackupPlanId=dbs1h****usfa
&SourceEndpointInstanceType=rds
&<Common request parameters>

Sample success responses

XML format

<ModifyBackupSourceEndpointReponse>
  <RequestId>D6E068C3-25BC-455A-85FE-45F0B22ECB1F</RequestId>
  <HttpStatusCode>200</HttpStatusCode>
  <BackupPlanId>dbs1h****usfa</BackupPlanId>
  <NeedPrecheck>false</NeedPrecheck>
  <Success>true</Success>
</ModifyBackupSourceEndpointReponse>

JSON format

{
    "RequestId": "D6E068C3-25BC-455A-85FE-45F0B22ECB1F",
    "HttpStatusCode": 200,
    "BackupPlanId": "dbs1h****usfa",
    "NeedPrecheck": false,
    "Success": true
}

Error codes

For a list of error codes, visit the API Error Center.