Updated on 2026-06-30 GMT+08:00

Start a Migration Task

Function

This API is used to start a migration task when the migration task is paused or failed.

Calling Method

For details, see Calling APIs.

URI

POST /v2/{project_id}/tasks/{task_id}/start

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

The project ID.

Minimum: 1

Maximum: 1024

task_id

Yes

Long

The migration task ID.

Minimum: 0

Maximum: 999999999999999

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

The token used for IAM authentication.

Minimum: 1

Maximum: 16384

Table 3 Request body parameters

Parameter

Mandatory

Type

Description

src_ak

No

String

The AK for accessing the source node. Enter a maximum of 100 characters. This parameter is not required for URL list–based migration task groups.

Minimum: 1

Maximum: 100

src_sk

No

String

The SK for accessing the source node. Enter a maximum of 100 characters. This parameter is not required for URL list–based migration task groups.

Minimum: 1

Maximum: 100

connection_string

No

String

The connection string, which is used for Microsoft Azure Blob authentication.

Minimum: 0

Maximum: 2048

src_crypto_type

No

String

The encryption/decryption type. The default value is DEFAULT. The options are DEFAULT and KMS.

Default: DEFAULT

Minimum: 1

Maximum: 32

Enumeration values:

  • DEFAULT

  • KMS

src_kms_key_id

No

String

The KMS key ID, which contains 36 characters.

Minimum: 0

Maximum: 36

json_auth_file

No

String

The file used for Google Cloud Storage authentication.

Minimum: 0

Maximum: 65535

src_security_token

No

String

The temporary token for accessing the source node.

Minimum: 0

Maximum: 16384

dst_ak

Yes

String

The AK for accessing the destination node. Enter a maximum of 100 characters.

Minimum: 1

Maximum: 100

dst_sk

Yes

String

The SK for accessing the destination node. Enter a maximum of 100 characters.

Minimum: 1

Maximum: 100

dst_crypto_type

No

String

The encryption/decryption type. The default value is DEFAULT. The options are DEFAULT and KMS.

Default: DEFAULT

Minimum: 1

Maximum: 32

Enumeration values:

  • DEFAULT

  • KMS

dst_kms_key_id

No

String

The KMS key ID, which contains 36 characters.

Minimum: 0

Maximum: 36

dst_security_token

No

String

The temporary token for accessing the destination node.

Minimum: 0

Maximum: 16384

source_cdn_authentication_key

No

String

The CDN authentication key.

Minimum: 0

Maximum: 255

source_cdn_crypto_type

No

String

The encryption/decryption type. The default value is DEFAULT. The options are DEFAULT and KMS.

Default: DEFAULT

Minimum: 1

Maximum: 32

Enumeration values:

  • DEFAULT

  • KMS

source_cdn_kms_key_id

No

String

The KMS key ID, which contains 36 characters.

Minimum: 0

Maximum: 36

migrate_failed_object

No

Boolean

Indicates whether to migrate all objects in the migration task. The default value is false, which indicates a full migration.

If the value is true, only failed objects will be migrated again.

If the value is false or not specified, all objects in the migration task will be migrated again.

Default: false

Response Parameters

Status code: 200

OK

Status code: 400

Table 4 Response body parameters

Parameter

Type

Description

error_msg

String

Error message.

error_code

String

Error code.

Example Requests

  • This example starts a paused task that does not use the URL list–based migration method using the AK/SK pairs of the source and destination accounts.

    POST https://{endpoint}/v2/{project_id}/tasks/{task_id}/start
    
    {
      "src_ak" : "src_ak",
      "src_sk" : "src_sk",
      "dst_ak" : "dst_ak",
      "dst_sk" : "dst_sk",
      "migrate_failed_object" : false
    }
  • This example starts a paused task that uses the URL list–based migration method using the AK/SK pair of the destination bucket.

    POST https://{endpoint}/v2/{project_id}/tasks/{task_id}/start
    
    {
      "dst_ak" : "dst_ak",
      "dst_sk" : "dst_sk",
      "migrate_failed_object" : false
    }

Example Responses

None

Status Codes

Status Code

Description

200

OK

400

Bad Request

Error Codes

See Error Codes.