# REST Resource: projects.locations.dataSourceReferences

- [Resource: DataSourceReference](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceReference)
  - [JSON representation](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceReference.SCHEMA_REPRESENTATION)
- [DataSourceBackupConfigInfo](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceBackupConfigInfo)
  - [JSON representation](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceBackupConfigInfo.SCHEMA_REPRESENTATION)
- [DataSourceGcpResourceInfo](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceGcpResourceInfo)
  - [JSON representation](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceGcpResourceInfo.SCHEMA_REPRESENTATION)
- [CloudSqlInstanceDataSourceReferenceProperties](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#CloudSqlInstanceDataSourceReferenceProperties)
  - [JSON representation](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#CloudSqlInstanceDataSourceReferenceProperties.SCHEMA_REPRESENTATION)
- [FilestoreInstanceDataSourceReferenceProperties](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#FilestoreInstanceDataSourceReferenceProperties)
  - [JSON representation](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#FilestoreInstanceDataSourceReferenceProperties.SCHEMA_REPRESENTATION)
- [AlloyDBClusterDataSourceReferenceProperties](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#AlloyDBClusterDataSourceReferenceProperties)
  - [JSON representation](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#AlloyDBClusterDataSourceReferenceProperties.SCHEMA_REPRESENTATION)
- [Methods](https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#METHODS_SUMMARY)

## Resource: DataSourceReference

DataSourceReference is a reference to a DataSource resource.

| JSON representation |
|---|
| ``` { "name": string, "dataSource": string, "createTime": string, "dataSourceBackupConfigState": enum (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/BackupConfigState`), "dataSourceBackupCount": string, "dataSourceBackupConfigInfo": { object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceBackupConfigInfo`) }, "dataSourceGcpResourceInfo": { object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceGcpResourceInfo`) }, "totalStoredBytes": string } ``` |

| Fields ||
|---|---|
| `name` | `string` Identifier. The resource name of the DataSourceReference. Format: projects/{project}/locations/{location}/dataSourceReferences/{data_source_reference} |
| `dataSource` | `string` Output only. The resource name of the DataSource. Format: projects/{project}/locations/{location}/backupVaults/{backupVault}/dataSources/{dataSource} |
| `createTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` Output only. The time when the DataSourceReference 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"`. |
| `dataSourceBackupConfigState` | ``enum (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/BackupConfigState`)`` Output only. The backup configuration state of the DataSource. |
| `dataSourceBackupCount` | `string (https://developers.google.com/discovery/v1/type-format format)` Output only. Number of backups in the DataSource. |
| `dataSourceBackupConfigInfo` | ``object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceBackupConfigInfo`)`` Output only. Information of backup configuration on the DataSource. |
| `dataSourceGcpResourceInfo` | ``object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#DataSourceGcpResourceInfo`)`` Output only. The Google Cloud resource that the DataSource is associated with. |
| `totalStoredBytes` | `string (https://developers.google.com/discovery/v1/type-format format)` Output only. Total size of the storage used by all backup resources for the referenced datasource. |

## DataSourceBackupConfigInfo

Information of backup configuration on the DataSource.

| JSON representation |
|---|
| ``` { "lastBackupState": enum (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/LastBackupState`), "lastSuccessfulBackupConsistencyTime": string } ``` |

| Fields ||
|---|---|
| `lastBackupState` | ``enum (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/LastBackupState`)`` Output only. The status of the last backup in this DataSource |
| `lastSuccessfulBackupConsistencyTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` Output only. Timestamp of the last successful backup to this DataSource. 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"`. |

## DataSourceGcpResourceInfo

The Google Cloud resource that the DataSource is associated with.

| JSON representation |
|---|
| ``` { "gcpResourcename": string, "type": string, "location": string, // Union field `resource_properties` can be only one of the following: "cloudSqlInstanceProperties": { object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#CloudSqlInstanceDataSourceReferenceProperties`) }, "filestoreInstanceProperties": { object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#FilestoreInstanceDataSourceReferenceProperties`) }, "alloyDbClusterProperties": { object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#AlloyDBClusterDataSourceReferenceProperties`) } // End of list of possible types for union field `resource_properties`. } ``` |

| Fields ||
|---|---|
| `gcpResourcename` | `string` Output only. The resource name of the Google Cloud resource. Ex: projects/{project}/zones/{zone}/instances/{instance} |
| `type` | `string` Output only. The type of the Google Cloud resource. Ex: compute.googleapis.com/Instance |
| `location` | `string` Output only. The location of the Google Cloud resource. Ex: //"global"/"unspecified" |
| Union field `resource_properties`. The properties of the Google Cloud resource. `resource_properties` can be only one of the following: ||
| `cloudSqlInstanceProperties` | ``object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#CloudSqlInstanceDataSourceReferenceProperties`)`` Output only. The properties of the Cloud SQL instance. |
| `filestoreInstanceProperties` | ``object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#FilestoreInstanceDataSourceReferenceProperties`)`` Output only. The properties of the Filestore instance. |
| `alloyDbClusterProperties` | ``object (`https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences#AlloyDBClusterDataSourceReferenceProperties`)`` Output only. The properties of the AlloyDB cluster. |

## CloudSqlInstanceDataSourceReferenceProperties

CloudSqlInstanceDataSourceReferenceProperties represents the properties of a Cloud SQL resource that are stored in the DataSourceReference.

| JSON representation |
|---|
| ``` { "name": string, "databaseInstalledVersion": string, "instanceCreateTime": string, "instanceTier": string } ``` |

| Fields ||
|---|---|
| `name` | `string` Output only. Name of the Cloud SQL instance backed up by the datasource. Format: projects/{project}/instances/{instance} |
| `databaseInstalledVersion` | `string` Output only. The installed database version of the Cloud SQL instance. |
| `instanceCreateTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` Output only. The instance creation timestamp. 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"`. |
| `instanceTier` | `string` Output only. The tier (or machine type) for this instance. Example: `db-custom-1-3840` |

## FilestoreInstanceDataSourceReferenceProperties

FilestoreInstanceDataSourceReferenceProperties represents the properties of a Filestore resource that are stored in the DataSourceReference. .

| JSON representation |
|---|
| ``` { "name": string, "instanceCreateTime": string } ``` |

| Fields ||
|---|---|
| `name` | `string` Output only. Name of the Filestore instance backed up by the datasource. Format: projects/{project}/instances/{instance} |
| `instanceCreateTime` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#timestamp` format)`` Output only. The instance creation timestamp. 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"`. |

## AlloyDBClusterDataSourceReferenceProperties

AlloyDBClusterDataSourceReferenceProperties represents the properties of an AlloyDB cluster that are stored in the DataSourceReference.

| JSON representation |
|---|
| ``` { "name": string } ``` |

| Fields ||
|---|---|
| `name` | `string` Output only. Name of the AlloyDB cluster backed up by the datasource. Format: projects/{project}/locations/{location}/clusters/{cluster} |

| ## Methods ||
|---|---|
| ### `https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences/fetchForResourceType` | Fetch DataSourceReferences for a given project, location and resource type. |
| ### `https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences/get` | Gets details of a single DataSourceReference. |
| ### `https://docs.cloud.google.com/backup-disaster-recovery/docs/reference/rest/v1/projects.locations.dataSourceReferences/list` | Lists DataSourceReferences for a given project and location. |