Cloud Backup API, gRPC: BackupService
A set of methods for managing backups.
Call | Description |
---|---|
List | List backups using filters. |
ListArchives | List archives that holds backups for specified folder or specified Compute Cloud instance. |
ListFiles | ListFiles of the backup. |
Get | Get backup by its id. |
StartRecovery | Start recovery process of specified backup to specific Compute Cloud instance. |
StartFilesRecovery | StartFilesRecovery runs recovery process of selected files to specific Compute Cloud instance. |
Delete | Delete specific backup. |
Calls BackupService
List
List backups using filters.
rpc List (ListBackupsRequest) returns (ListBackupsResponse)
ListBackupsRequest
Field | Description |
---|---|
id | oneof: compute_instance_id , archive , folder_id , instance_policy , resource_id or policy_id |
compute_instance_id | string List backups that belongs to specific Compute Cloud instance. |
archive | ArchiveParameters List backups that belongs to specific archive of specific folder. |
folder_id | string List backups that belongs to specific folder. |
instance_policy | InstancePolicy List backups that belongs to specific instance and policy at the same time. |
resource_id | string List backups by specific resource ID. |
policy_id | string List backups by specific policy ID. |
order_by | string By which column the listing should be ordered and in which direction, format is "createdAt desc". "createdAt desc" if omitted. |
filter | string Filter list by various parameters. Supported parameters are:
Supported logic operators:
|
ArchiveParameters
Field | Description |
---|---|
archive_id | string Required. Archive ID. |
folder_id | string Required. Folder ID. |
InstancePolicy
Field | Description |
---|---|
compute_instance_id | string Compute Cloud instance ID. |
policy_id | string Policy ID. |
ListBackupsResponse
Field | Description |
---|---|
backups[] | Backup |
Backup
Field | Description |
---|---|
id | string ID of the backup. |
vault_id | string ID of the backup vault. |
archive_id | string ID of the backup archive. |
created_at | google.protobuf.Timestamp |
last_seen_at | google.protobuf.Timestamp |
size | int64 Backup size. |
deduplicated_size | int64 Deduplicated backup size. |
backed_up_data_size | int64 Backed up data size. |
original_data_size | int64 Original data size. |
attributes | BackupAttributes |
compute_instance_id | string Compute Cloud instance ID. |
disks[] | Disk |
type | enum Type |
deleted | bool If this field is true, it means that the backup was deleted. |
policy_id | string Policy ID. |
resource_id | string Resource ID. It identifies Compute Cloud instance in backup service. |
BackupAttributes
Field | Description |
---|---|
stream_name | string Backup stream name. |
uri | string URI of the backup archive. |
Disk
Field | Description |
---|---|
device_model | string Device model. |
name | string Disk name. |
size | int64 Disk size. |
volumes[] | Volume |
Volume
Field | Description |
---|---|
free_space | int64 Free space in the volume. |
is_bootable | bool If this field is true, it means that the volume is bootable. |
is_system | bool If this field is true, it means that the volume is a system volume. |
name | string Volume name. |
size | int64 Volume size. |
mount_strid | string Mount string ID. |
ListArchives
List archives that holds backups for specified folder or specified Compute Cloud instance.
rpc ListArchives (ListArchivesRequest) returns (ListArchivesResponse)
ListArchivesRequest
Field | Description |
---|---|
id | oneof: folder_id or compute_instance_id |
folder_id | string List of archives in specified folder. |
compute_instance_id | string List of archives of the specified Compute Cloud instance. |
ListArchivesResponse
Field | Description |
---|---|
archives[] | Archive |
Archive
Field | Description |
---|---|
id | string ID of the backup. |
name | string Name of the backup. |
vault_id | string ID of the backup vault. |
attributes | ArchiveAttributes Archive attributes. |
size | int64 Archive size. |
compressed_data_size | int64 Compressed data size. |
data_size | int64 Data size. |
original_data_size | int64 Original data size. |
logical_size | int64 Logical size. |
format | enum Format
|
created_at | google.protobuf.Timestamp |
updated_at | google.protobuf.Timestamp |
last_backup_created_at | google.protobuf.Timestamp |
last_seen_at | google.protobuf.Timestamp |
protected_by_password | bool If this field is true, it means that any of encryption algorithm has been chosen. |
encryption_algorithm | enum EncryptionAlgorithm |
actions[] | enum Action |
backup_plan_id | string Backup plan ID. |
backup_plan_name | string Backup plan name. |
description | string Backup plan description. |
display_name | string Display name, e.g. INSTANCE_NAME - POLICY_NAME . |
compute_instance_id | string Compute Cloud instance ID. |
consistent | bool If this field is true, it means that the archive is consistent. |
deleted | bool If this field is true, it means that the archive was deleted. |
resource_id | string Resource ID. |
ArchiveAttributes
Field | Description |
---|---|
aaib | string Archive attribute. Default value: 0 . |
uri | string URI of the backup archive. |
ListFiles
ListFiles of the backup.
rpc ListFiles (ListFilesRequest) returns (ListFilesResponse)
ListFilesRequest
Field | Description |
---|---|
folder_id | string Required. Folder ID. |
backup_id | string Required. Backup ID. |
source_id | string Empty source will list disks of the backup. |
ListFilesResponse
Field | Description |
---|---|
files[] | BackupFile |
BackupFile
Field | Description |
---|---|
id | string Required. ID of the item. Should be used as source ID in case of listing. |
parent_id | google.protobuf.StringValue Might be empty if this is root directory. |
type | enum Type Required. Type of the item. |
full_path | string Required. Absolute path of the item. |
name | string Required. Name of the directory / file. |
size | int64 Size in bytes of the item. |
actions | Actions Required. Actions that might be done on the object. |
modified_at | google.protobuf.Timestamp Required. |
Actions
Field | Description |
---|---|
restore_to_disk | bool Allows to send request to restore item to disk |
go_to_location | bool Allows to move to location by id. |
Get
Get backup by its id.
rpc Get (GetBackupRequest) returns (Backup)
GetBackupRequest
Field | Description |
---|---|
backup_id | string Required. Backup ID. |
folder_id | string Required. Folder ID. |
Backup
Field | Description |
---|---|
id | string ID of the backup. |
vault_id | string ID of the backup vault. |
archive_id | string ID of the backup archive. |
created_at | google.protobuf.Timestamp |
last_seen_at | google.protobuf.Timestamp |
size | int64 Backup size. |
deduplicated_size | int64 Deduplicated backup size. |
backed_up_data_size | int64 Backed up data size. |
original_data_size | int64 Original data size. |
attributes | BackupAttributes |
compute_instance_id | string Compute Cloud instance ID. |
disks[] | Disk |
type | enum Type |
deleted | bool If this field is true, it means that the backup was deleted. |
policy_id | string Policy ID. |
resource_id | string Resource ID. It identifies Compute Cloud instance in backup service. |
BackupAttributes
Field | Description |
---|---|
stream_name | string Backup stream name. |
uri | string URI of the backup archive. |
Disk
Field | Description |
---|---|
device_model | string Device model. |
name | string Disk name. |
size | int64 Disk size. |
volumes[] | Volume |
Volume
Field | Description |
---|---|
free_space | int64 Free space in the volume. |
is_bootable | bool If this field is true, it means that the volume is bootable. |
is_system | bool If this field is true, it means that the volume is a system volume. |
name | string Volume name. |
size | int64 Volume size. |
mount_strid | string Mount string ID. |
StartRecovery
Start recovery process of specified backup to specific Compute Cloud instance.
For details, see Restoring a VM from a backup.
rpc StartRecovery (StartRecoveryRequest) returns (operation.Operation)
Metadata and response of Operation:
Operation.metadata:StartRecoveryMetadata
Operation.response:google.protobuf.Empty
StartRecoveryRequest
Field | Description |
---|---|
compute_instance_id | string Required. Destination Compute Cloud instance ID to which backup should be applied. The maximum string length in characters is 50. |
backup_id | string Required. Backup ID that will be applied to destination Compute Cloud instance. |
Operation
Field | Description |
---|---|
id | string ID of the operation. |
description | string Description of the operation. 0-256 characters long. |
created_at | google.protobuf.Timestamp Creation timestamp. |
created_by | string ID of the user or service account who initiated the operation. |
modified_at | google.protobuf.Timestamp The time when the Operation resource was last modified. |
done | bool If the value is false , it means the operation is still in progress. If true , the operation is completed, and either error or response is available. |
metadata | google.protobuf.Any Service-specific metadata associated with the operation. It typically contains the ID of the target resource that the operation is performed on. Any method that returns a long-running operation should document the metadata type, if any. |
result | oneof: error or response The operation result. If done == false and there was no failure detected, neither error nor response is set. If done == false and there was a failure detected, error is set. If done == true , exactly one of error or response is set. |
error | google.rpc.Status The error result of the operation in case of failure or cancellation. |
response | google.protobuf.Any if operation finished successfully. |
StartRecoveryMetadata
Field | Description |
---|---|
progress_percentage | double Progress of the backup process. |
src_backup_id | string Source Backup ID that will be applied. |
dst_compute_instance_id | string Destination Compute Cloud instance ID to which backup will be applied. |
StartFilesRecovery
StartFilesRecovery runs recovery process of selected files to specific Compute Cloud instance.
rpc StartFilesRecovery (StartFilesRecoveryRequest) returns (operation.Operation)
Metadata and response of Operation:
Operation.metadata:StartFilesRecoveryMetadata
Operation.response:google.protobuf.Empty
StartFilesRecoveryRequest
Field | Description |
---|---|
compute_instance_id | string Required. Destination instance ID. |
backup_id | string Required. Backup ID. |
opts | FilesRecoveryOptions Required. |
source_ids[] | string The number of elements must be greater than 0. |
FilesRecoveryOptions
Field | Description |
---|---|
overwrite | enum Overwrite Overwrite options declares the behavior for files that already exists on the file system.
|
reboot_if_needed | bool specifies whether the recovery plan is able to reboot host if needed. |
type | oneof: original or custom Path strategy for selected files. |
original | TargetPathOriginal Keep original paths of files. |
custom | TargetPathCustom Set custom folder for file recovery. |
TargetPathOriginal
Empty.
TargetPathCustom
Field | Description |
---|---|
path | string Custom folder for file recovery. |
Operation
Field | Description |
---|---|
id | string ID of the operation. |
description | string Description of the operation. 0-256 characters long. |
created_at | google.protobuf.Timestamp Creation timestamp. |
created_by | string ID of the user or service account who initiated the operation. |
modified_at | google.protobuf.Timestamp The time when the Operation resource was last modified. |
done | bool If the value is false , it means the operation is still in progress. If true , the operation is completed, and either error or response is available. |
metadata | google.protobuf.Any Service-specific metadata associated with the operation. It typically contains the ID of the target resource that the operation is performed on. Any method that returns a long-running operation should document the metadata type, if any. |
result | oneof: error or response The operation result. If done == false and there was no failure detected, neither error nor response is set. If done == false and there was a failure detected, error is set. If done == true , exactly one of error or response is set. |
error | google.rpc.Status The error result of the operation in case of failure or cancellation. |
response | google.protobuf.Any if operation finished successfully. |
StartFilesRecoveryMetadata
Field | Description |
---|---|
progress_percentage | double |
compute_instance_id | string Required. Destination instance ID. |
backup_id | string Required. Backup ID. |
source_ids[] | string The number of elements must be greater than 0. |
Delete
Delete specific backup.
rpc Delete (DeleteBackupRequest) returns (operation.Operation)
Metadata and response of Operation:
Operation.metadata:DeleteBackupMetadata
Operation.response:google.protobuf.Empty
DeleteBackupRequest
Field | Description |
---|---|
compute_instance_id | string Required. Compute Cloud instance ID of the Backup. The maximum string length in characters is 50. |
backup_id | string Required. Backup ID that should be deleted. |
Operation
Field | Description |
---|---|
id | string ID of the operation. |
description | string Description of the operation. 0-256 characters long. |
created_at | google.protobuf.Timestamp Creation timestamp. |
created_by | string ID of the user or service account who initiated the operation. |
modified_at | google.protobuf.Timestamp The time when the Operation resource was last modified. |
done | bool If the value is false , it means the operation is still in progress. If true , the operation is completed, and either error or response is available. |
metadata | google.protobuf.Any Service-specific metadata associated with the operation. It typically contains the ID of the target resource that the operation is performed on. Any method that returns a long-running operation should document the metadata type, if any. |
result | oneof: error or response The operation result. If done == false and there was no failure detected, neither error nor response is set. If done == false and there was a failure detected, error is set. If done == true , exactly one of error or response is set. |
error | google.rpc.Status The error result of the operation in case of failure or cancellation. |
response | google.protobuf.Any if operation finished successfully. |
DeleteBackupMetadata
Field | Description |
---|---|
compute_instance_id | string Compute Cloud instance ID of the Backup. |
backup_id | string Backup ID that should be deleted. |