> ## Documentation Index
> Fetch the complete documentation index at: https://cdktn.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# CSharp: DataTerraformRemoteStateGcsConfig

> CDKTN Core API Reference for DataTerraformRemoteStateGcsConfig in CSharp.

## Initializer <a name="Initializer" id="cdktn.DataTerraformRemoteStateGcsConfig.Initializer" />

```csharp theme={null}
using Io.Cdktn;

new DataTerraformRemoteStateGcsConfig {
    System.Collections.Generic.IDictionary<string, object> Defaults = null,
    string Workspace = null,
    string Bucket,
    string AccessToken = null,
    string Credentials = null,
    string EncryptionKey = null,
    string ImpersonateServiceAccount = null,
    string[] ImpersonateServiceAccountDelegates = null,
    string KmsEncryptionKey = null,
    string Prefix = null,
    string StoreageCustomEndpoint = null
};
```

## Properties <a name="Properties" id="Properties" />

| **Name**                                                                                                                                           | **Type**                                                               | **Description**                                                                                                                                                                                                                                                                                           |
| -------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.defaults">Defaults</a></code>                                                     | <code>System.Collections.Generic.IDictionary\< string, object ></code> | *No description.*                                                                                                                                                                                                                                                                                         |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.workspace">Workspace</a></code>                                                   | <code>string</code>                                                    | *No description.*                                                                                                                                                                                                                                                                                         |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.bucket">Bucket</a></code>                                                         | <code>string</code>                                                    | (Required) The name of the GCS bucket.                                                                                                                                                                                                                                                                    |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.accessToken">AccessToken</a></code>                                               | <code>string</code>                                                    | (Optional) A temporary \[OAuth 2.0 access token] obtained from the Google Authorization server, i.e. the Authorization: Bearer token used to authenticate HTTP requests to GCP APIs. This is an alternative to credentials. If both are specified, access\_token will be used over the credentials field. |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.credentials">Credentials</a></code>                                               | <code>string</code>                                                    | (Optional) Local path to Google Cloud Platform account credentials in JSON format.                                                                                                                                                                                                                        |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.encryptionKey">EncryptionKey</a></code>                                           | <code>string</code>                                                    | (Optional) A 32 byte base64 encoded 'customer supplied encryption key' used to encrypt all state.                                                                                                                                                                                                         |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.impersonateServiceAccount">ImpersonateServiceAccount</a></code>                   | <code>string</code>                                                    | (Optional) The service account to impersonate for accessing the State Bucket.                                                                                                                                                                                                                             |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.impersonateServiceAccountDelegates">ImpersonateServiceAccountDelegates</a></code> | <code>string\[]</code>                                                 | (Optional) The delegation chain for an impersonating a service account.                                                                                                                                                                                                                                   |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.kmsEncryptionKey">KmsEncryptionKey</a></code>                                     | <code>string</code>                                                    | (Optional) A Cloud KMS key ('customer-managed encryption key') used when reading and writing state files in the bucket.                                                                                                                                                                                   |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.prefix">Prefix</a></code>                                                         | <code>string</code>                                                    | (Optional) GCS prefix inside the bucket.                                                                                                                                                                                                                                                                  |
| <code><a href="#cdktn.DataTerraformRemoteStateGcsConfig.property.storeageCustomEndpoint">StoreageCustomEndpoint</a></code>                         | <code>string</code>                                                    | (Optional) A URL containing three parts: the protocol, the DNS name pointing to a Private Service Connect endpoint, and the path for the Cloud Storage API (/storage/v1/b).                                                                                                                               |

***

### `Defaults`<sup>Optional</sup> <a name="Defaults" id="cdktn.DataTerraformRemoteStateGcsConfig.property.defaults" />

```csharp theme={null}
public System.Collections.Generic.IDictionary<string, object> Defaults { get; set; }
```

* *Type:* System.Collections.Generic.IDictionary\< string, object >

***

### `Workspace`<sup>Optional</sup> <a name="Workspace" id="cdktn.DataTerraformRemoteStateGcsConfig.property.workspace" />

```csharp theme={null}
public string Workspace { get; set; }
```

* *Type:* string

***

### `Bucket`<sup>Required</sup> <a name="Bucket" id="cdktn.DataTerraformRemoteStateGcsConfig.property.bucket" />

```csharp theme={null}
public string Bucket { get; set; }
```

* *Type:* string

(Required) The name of the GCS bucket.

This name must be globally unique.

***

### `AccessToken`<sup>Optional</sup> <a name="AccessToken" id="cdktn.DataTerraformRemoteStateGcsConfig.property.accessToken" />

```csharp theme={null}
public string AccessToken { get; set; }
```

* *Type:* string

(Optional) A temporary \[OAuth 2.0 access token] obtained from the Google Authorization server, i.e. the Authorization: Bearer token used to authenticate HTTP requests to GCP APIs. This is an alternative to credentials. If both are specified, access\_token will be used over the credentials field.

***

### `Credentials`<sup>Optional</sup> <a name="Credentials" id="cdktn.DataTerraformRemoteStateGcsConfig.property.credentials" />

```csharp theme={null}
public string Credentials { get; set; }
```

* *Type:* string

(Optional) Local path to Google Cloud Platform account credentials in JSON format.

If unset, Google Application Default Credentials are used.
The provided credentials must have Storage Object Admin role on the bucket.

Warning: if using the Google Cloud Platform provider as well,
it will also pick up the GOOGLE\_CREDENTIALS environment variable.

***

### `EncryptionKey`<sup>Optional</sup> <a name="EncryptionKey" id="cdktn.DataTerraformRemoteStateGcsConfig.property.encryptionKey" />

```csharp theme={null}
public string EncryptionKey { get; set; }
```

* *Type:* string

(Optional) A 32 byte base64 encoded 'customer supplied encryption key' used to encrypt all state.

***

### `ImpersonateServiceAccount`<sup>Optional</sup> <a name="ImpersonateServiceAccount" id="cdktn.DataTerraformRemoteStateGcsConfig.property.impersonateServiceAccount" />

```csharp theme={null}
public string ImpersonateServiceAccount { get; set; }
```

* *Type:* string

(Optional) The service account to impersonate for accessing the State Bucket.

You must have roles/iam.serviceAccountTokenCreator role on that account for the impersonation to succeed.
If you are using a delegation chain, you can specify that using the impersonate\_service\_account\_delegates field.
Alternatively, this can be specified using the GOOGLE\_IMPERSONATE\_SERVICE\_ACCOUNT environment variable.

***

### `ImpersonateServiceAccountDelegates`<sup>Optional</sup> <a name="ImpersonateServiceAccountDelegates" id="cdktn.DataTerraformRemoteStateGcsConfig.property.impersonateServiceAccountDelegates" />

```csharp theme={null}
public string[] ImpersonateServiceAccountDelegates { get; set; }
```

* *Type:* string\[]

(Optional) The delegation chain for an impersonating a service account.

***

### `KmsEncryptionKey`<sup>Optional</sup> <a name="KmsEncryptionKey" id="cdktn.DataTerraformRemoteStateGcsConfig.property.kmsEncryptionKey" />

```csharp theme={null}
public string KmsEncryptionKey { get; set; }
```

* *Type:* string

(Optional) A Cloud KMS key ('customer-managed encryption key') used when reading and writing state files in the bucket.

Format should be projects/\{\{project}}/locations/\{\{location}}/keyRings/\{\{keyRing}}/cryptoKeys/\{\{name}}.
For more information, including IAM requirements, see [Customer-managed Encryption Keys](https://cloud.google.com/storage/docs/encryption/customer-managed-keys).

***

### `Prefix`<sup>Optional</sup> <a name="Prefix" id="cdktn.DataTerraformRemoteStateGcsConfig.property.prefix" />

```csharp theme={null}
public string Prefix { get; set; }
```

* *Type:* string

(Optional) GCS prefix inside the bucket.

Named states for workspaces are stored in an object called \< prefix >/\< name >.tfstate.

***

### `StoreageCustomEndpoint`<sup>Optional</sup> <a name="StoreageCustomEndpoint" id="cdktn.DataTerraformRemoteStateGcsConfig.property.storeageCustomEndpoint" />

```csharp theme={null}
public string StoreageCustomEndpoint { get; set; }
```

* *Type:* string

(Optional) A URL containing three parts: the protocol, the DNS name pointing to a Private Service Connect endpoint, and the path for the Cloud Storage API (/storage/v1/b).

[See here for more details](https://developer.hashicorp.com/terraform/language/settings/backends/gcs#storage_custom_endpoint)

***
