# Cloud IoT v1 API - Enum GatewayAuthMethod (2.2.0)

<button class="button button-with-icon cloud-select-dropdown__button " aria-haspopup="true">Version latest</button>

- [2.2.0 (latest)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Iot.V1/latest/Google.Cloud.Iot.V1.GatewayAuthMethod)
- [2.1.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Iot.V1/2.1.0/Google.Cloud.Iot.V1.GatewayAuthMethod)
- [2.0.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Iot.V1/2.0.0/Google.Cloud.Iot.V1.GatewayAuthMethod)
- [1.2.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Iot.V1/1.2.0/Google.Cloud.Iot.V1.GatewayAuthMethod)
- [1.1.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Iot.V1/1.1.0/Google.Cloud.Iot.V1.GatewayAuthMethod)
- [1.0.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Iot.V1/1.0.0/Google.Cloud.Iot.V1.GatewayAuthMethod)

    public enum GatewayAuthMethod

Reference documentation and code samples for the Cloud IoT v1 API enum GatewayAuthMethod.

The gateway authorization/authentication method. This setting determines how
Cloud IoT Core authorizes/authenticate devices to access the gateway.

## Namespace

[Google.Cloud.Iot.V1](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Iot.V1/latest/Google.Cloud.Iot.V1)

## Assembly

Google.Cloud.Iot.V1.dll

| ## Fields ||
|---|---|
| **Name** | **Description** |
| `AssociationAndDeviceAuthToken` | The device is authenticated through both device credentials and gateway association. The device must be bound to the gateway and must provide its own credentials. |
| `AssociationOnly` | The device is authenticated through the gateway association only. Device credentials are ignored even if provided. |
| `DeviceAuthTokenOnly` | The device is authenticated through its own credentials. Gateway association is not checked. |
| `Unspecified` | No authentication/authorization method specified. No devices are allowed to access the gateway. |