# Configuration

- Module: [Aspire.Hosting](/reference/api/go/aspire.hosting.md)
- Version: `17.0.0`
- Kind: `interface`
- Source: [GitHub](https://github.com/microsoft/aspire/tree/bcfa151cdca6d0a573f22d5d9c23f9c727cb3b2f)

## Definition

```go
type Configuration interface{}
```

## Methods

- [Exists](/reference/api/go/aspire.hosting/configuration/exists.md) -- `method` -- Checks whether a configuration section exists.
  ```go
  Exists(key string) (bool, error)
  ```
- [GetChildren](/reference/api/go/aspire.hosting/configuration/getchildren.md) -- `method` -- Gets the child sections of a configuration handle.
  ```go
  GetChildren() ([]ConfigurationSection, error)
  ```
- [GetConfigValue](/reference/api/go/aspire.hosting/configuration/getconfigvalue.md) -- `method` -- Gets a configuration value by key.
  ```go
  GetConfigValue(key string) (*string, error)
  ```
- [GetConnectionString](/reference/api/go/aspire.hosting/configuration/getconnectionstring.md) -- `method` -- Gets a connection string by name.
  ```go
  GetConnectionString(name string) (*string, error)
  ```
- [GetSection](/reference/api/go/aspire.hosting/configuration/getsection.md) -- `method` -- Gets a configuration section by key.
  ```go
  GetSection(key string) ConfigurationSection
  ```

## Applies to

- [`Configuration`](/reference/api/go/aspire.hosting/configuration.md)
