# ConsulGatewayListProvider Methods

[Type overview](/orleans/docs/api/csharp/microsoft.orleans.clustering.consul/orleans.runtime.membership.consulgatewaylistprovider/)

## GetGateways {#getgateways-c58cd5d5}

[Dedicated page](/orleans/docs/api/csharp/microsoft.orleans.clustering.consul/orleans.runtime.membership.consulgatewaylistprovider/methods/getgateways-c58cd5d5/)

[Source](https://github.com/dotnet/orleans/blob/e4e752cedecc2976811db49802c7a999b1f1c704/src/Orleans.Clustering.Consul/ConsulGatewayListProvider.cs#L53-L63)

```csharp
public Task<IList<Uri>> GetGateways()
```

Returns the list of gateways (silos) that can be used by a client to connect to Orleans cluster. The Uri is in the form of: "gwy.tcp://IP:port/Generation". See Utils.ToGatewayUri and Utils.ToSiloAddress for more details about Uri format.

### Returns

The list of gateway endpoints.

## InitializeGatewayListProvider {#initializegatewaylistprovider-e1a38546}

[Dedicated page](/orleans/docs/api/csharp/microsoft.orleans.clustering.consul/orleans.runtime.membership.consulgatewaylistprovider/methods/initializegatewaylistprovider-e1a38546/)

[Source](https://github.com/dotnet/orleans/blob/e4e752cedecc2976811db49802c7a999b1f1c704/src/Orleans.Clustering.Consul/ConsulGatewayListProvider.cs#L47-L48)

```csharp
public Task InitializeGatewayListProvider()
```

Initializes the provider, will be called before all other methods.

### Returns

A `System.Threading.Tasks.Task` representing the work performed.
