Updated on 2024-04-19 GMT+08:00

Synchronizing a Backup

Function

This API is used to synchronize on-premises VMware backups.

URI

POST /v3/{project_id}/backups/sync

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token The token can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is the user token.

Table 3 Request body parameters

Parameter

Mandatory

Type

Description

sync

Yes

Array of BackupSync objects

List of backups to be imported

Array Length: 1 - 50

Table 4 BackupSync

Parameter

Mandatory

Type

Description

backup_id

Yes

String

Backup ID

backup_name

Yes

String

Backup name

Minimum: 1

Maximum: 64

bucket_name

Yes

String

Bucket name

image_path

Yes

String

Path to the backup chain on the storage unit

resource_id

Yes

String

ID of the object to be backed up

resource_name

Yes

String

Backup object name

resource_type

Yes

String

Resource type of the backup object

Default: OS::Native::Server

created_at

Yes

Integer

Backup time, in seconds. For example, 1548898428.

Response Parameters

Status code: 200

Table 5 Response body parameters

Parameter

Type

Description

sync

Array of BackupSyncRespBody objects

Return information of the API for importing backups

Table 6 BackupSyncRespBody

Parameter

Type

Description

backup_id

String

Backup ID

operation_log_id

String

Import task ID

Example Requests

Synchronizing an on-premises VMware backup

POST https://{endpoint}/v3/f841e01fd2b14e7fa41b6ae7aa6b0594/backups/sync

{
  "sync" : [ {
    "backup_id" : "1f9e6b47-7655-4a19-b563-21b4ef023025",
    "resource_id" : "96f7512d-239d-3f31-80cf-d1ce041df9a6",
    "resource_name" : "resource_name",
    "resource_type" : "OS::Native::Server",
    "bucket_name" : "1555230361623e4ce4700dab84b7d8169a5eaec05227d",
    "image_path" : "6abec15e-7baf-4d79-b5a9-6b98a2da7020/cfe0295c-5939-4b31-96cd-161b4725e7ad/cfe0295c-5939-4b31-96cd-161b4725e7ad",
    "created_at" : 1553587260,
    "backup_name" : "backup_name"
  } ]
}

Example Responses

Status code: 200

OK

{
  "sync" : [ {
    "backup_id" : "1f9e6b47-7655-4a19-b563-21b4ef023025",
    "operation_log_id" : "154f0a9d-ba53-4e91-a3e2-a918710a9e0d"
  } ]
}

Status Codes

Status Code

Description

200

OK

Error Codes

See Error Codes.