# REST Resource: projects.locations.backupCollections.backups

- [Resource: Backup](https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#Backup)
  - [JSON representation](https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#Backup.SCHEMA_REPRESENTATION)
- [BackupFile](https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#BackupFile)
  - [JSON representation](https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#BackupFile.SCHEMA_REPRESENTATION)
- [BackupType](https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#BackupType)
- [State](https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#State)
- [Methods](https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#METHODS_SUMMARY)

## Resource: Backup

Backup of an instance.

| JSON representation |
|---|
| ``` { "name": string, "createTime": string, "instance": string, "instanceUid": string, "totalSizeBytes": string, "expireTime": string, "engineVersion": string, "backupFiles": [ { object (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#BackupFile`) } ], "nodeType": enum (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/NodeType`), "replicaCount": integer, "shardCount": integer, "backupType": enum (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#BackupType`), "state": enum (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#State`), "encryptionInfo": { object (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/EncryptionInfo`) }, "uid": string } ``` |

| Fields ||
|---|---|
| `name` | `string` Identifier. Full resource path of the backup. the last part of the name is the backup id with the following format: \[YYYYMMDDHHMMSS\]_\[Shorted Instance UID\] OR customer specified while backup instance. Example: 20240515123000_1234 |
| `createTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` Output only. The time when the backup was created. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: `"2014-10-02T15:01:23Z"`, `"2014-10-02T15:01:23.045123456Z"` or `"2014-10-02T15:01:23+05:30"`. |
| `instance` | `string` Output only. Instance resource path of this backup. |
| `instanceUid` | `string` Output only. Instance uid of this backup. |
| `totalSizeBytes` | `string (https://developers.google.com/discovery/v1/type-format format)` Output only. Total size of the backup in bytes. |
| `expireTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` Output only. The time when the backup will expire. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: `"2014-10-02T15:01:23Z"`, `"2014-10-02T15:01:23.045123456Z"` or `"2014-10-02T15:01:23+05:30"`. |
| `engineVersion` | `string` Output only. valkey-7.5/valkey-8.0, etc. |
| `backupFiles[]` | ``object (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#BackupFile`)`` Output only. List of backup files of the backup. |
| `nodeType` | ``enum (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/NodeType`)`` Output only. Node type of the instance. |
| `replicaCount` | `integer` Output only. Number of replicas for the instance. |
| `shardCount` | `integer` Output only. Number of shards for the instance. |
| `backupType` | ``enum (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#BackupType`)`` Output only. Type of the backup. |
| `state` | ``enum (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups#State`)`` Output only. State of the backup. |
| `encryptionInfo` | ``object (`https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/EncryptionInfo`)`` Output only. Encryption information of the backup. |
| `uid` | `string` Output only. System assigned unique identifier of the backup. |

## BackupFile

Backup is consisted of multiple backup files.

| JSON representation |
|---|
| ``` { "fileName": string, "sizeBytes": string, "createTime": string } ``` |

| Fields ||
|---|---|
| `fileName` | `string` Output only. e.g: .rdb |
| `sizeBytes` | `string (https://developers.google.com/discovery/v1/type-format format)` Output only. Size of the backup file in bytes. |
| `createTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` Output only. The time when the backup file was created. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: `"2014-10-02T15:01:23Z"`, `"2014-10-02T15:01:23.045123456Z"` or `"2014-10-02T15:01:23+05:30"`. |

## BackupType

Type of the backup.

| Enums ||
|---|---|
| `BACKUP_TYPE_UNSPECIFIED` | The default value, not set. |
| `ON_DEMAND` | On-demand backup. |
| `AUTOMATED` | Automated backup. |

## State

State of the backup.

| Enums ||
|---|---|
| `STATE_UNSPECIFIED` | The default value, not set. |
| `CREATING` | The backup is being created. |
| `ACTIVE` | The backup is active to be used. |
| `DELETING` | The backup is being deleted. |
| `SUSPENDED` | The backup is currently suspended due to reasons like project deletion, billing account closure, etc. |

| ## Methods ||
|---|---|
| ### `https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups/delete` | Deletes a specific backup. |
| ### `https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups/export` | Exports a specific backup to a customer target Cloud Storage URI. |
| ### `https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups/get` | Gets the details of a specific backup. |
| ### `https://docs.cloud.google.com/memorystore/docs/valkey/reference/rest/v1beta/projects.locations.backupCollections.backups/list` | Lists all backups owned by a backup collection. |