# `Dagger.Env`
[🔗](https://github.com/dagger/dagger/blob/v0.21.7/sdk/elixir/lib/dagger/gen/env.ex#L2)

Dagger.Env

# `t`

```elixir
@type t() :: %Dagger.Env{client: term(), query_builder: term()}
```

# `check`

```elixir
@spec check(t(), String.t()) :: Dagger.Check.t()
```

Return the check with the given name from the installed modules. Must match exactly one check.

> #### Experimental {: .warning}
>
> "Checks API is highly experimental and may be removed or replaced entirely."

# `checks`

```elixir
@spec checks(t(), include: [String.t()], no_generate: boolean() | nil) ::
  Dagger.CheckGroup.t()
```

Return all checks defined by the installed modules

> #### Experimental {: .warning}
>
> "Checks API is highly experimental and may be removed or replaced entirely."

# `id`

```elixir
@spec id(t()) :: {:ok, String.t()} | {:error, term()}
```

A unique identifier for this Env.

# `input`

```elixir
@spec input(t(), String.t()) :: Dagger.Binding.t()
```

Retrieves an input binding by name

# `inputs`

```elixir
@spec inputs(t()) :: {:ok, [Dagger.Binding.t()]} | {:error, term()}
```

Returns all input bindings provided to the environment

# `output`

```elixir
@spec output(t(), String.t()) :: Dagger.Binding.t()
```

Retrieves an output binding by name

# `outputs`

```elixir
@spec outputs(t()) :: {:ok, [Dagger.Binding.t()]} | {:error, term()}
```

Returns all declared output bindings for the environment

# `services`

```elixir
@spec services(t(), [{:include, [String.t()]}]) :: Dagger.UpGroup.t()
```

Return all services defined by the installed modules

> #### Experimental {: .warning}
>
> "Services API is highly experimental and may be removed or replaced entirely."

# `with_address_input`

```elixir
@spec with_address_input(t(), String.t(), Dagger.Address.t(), String.t()) :: t()
```

Create or update a binding of type Address in the environment

# `with_address_output`

```elixir
@spec with_address_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Address output to be assigned in the environment

# `with_cache_volume_input`

```elixir
@spec with_cache_volume_input(t(), String.t(), Dagger.CacheVolume.t(), String.t()) ::
  t()
```

Create or update a binding of type CacheVolume in the environment

# `with_cache_volume_output`

```elixir
@spec with_cache_volume_output(t(), String.t(), String.t()) :: t()
```

Declare a desired CacheVolume output to be assigned in the environment

# `with_changeset_input`

```elixir
@spec with_changeset_input(t(), String.t(), Dagger.Changeset.t(), String.t()) :: t()
```

Create or update a binding of type Changeset in the environment

# `with_changeset_output`

```elixir
@spec with_changeset_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Changeset output to be assigned in the environment

# `with_check_group_input`

```elixir
@spec with_check_group_input(t(), String.t(), Dagger.CheckGroup.t(), String.t()) ::
  t()
```

Create or update a binding of type CheckGroup in the environment

# `with_check_group_output`

```elixir
@spec with_check_group_output(t(), String.t(), String.t()) :: t()
```

Declare a desired CheckGroup output to be assigned in the environment

# `with_check_input`

```elixir
@spec with_check_input(t(), String.t(), Dagger.Check.t(), String.t()) :: t()
```

Create or update a binding of type Check in the environment

# `with_check_output`

```elixir
@spec with_check_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Check output to be assigned in the environment

# `with_cloud_input`

```elixir
@spec with_cloud_input(t(), String.t(), Dagger.Cloud.t(), String.t()) :: t()
```

Create or update a binding of type Cloud in the environment

# `with_cloud_output`

```elixir
@spec with_cloud_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Cloud output to be assigned in the environment

# `with_container_input`

```elixir
@spec with_container_input(t(), String.t(), Dagger.Container.t(), String.t()) :: t()
```

Create or update a binding of type Container in the environment

# `with_container_output`

```elixir
@spec with_container_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Container output to be assigned in the environment

# `with_current_module`

```elixir
@spec with_current_module(t()) :: t()
```

Installs the current module into the environment, exposing its functions to the model

Contextual path arguments will be populated using the environment's workspace.

# `with_diff_stat_input`

```elixir
@spec with_diff_stat_input(t(), String.t(), Dagger.DiffStat.t(), String.t()) :: t()
```

Create or update a binding of type DiffStat in the environment

# `with_diff_stat_output`

```elixir
@spec with_diff_stat_output(t(), String.t(), String.t()) :: t()
```

Declare a desired DiffStat output to be assigned in the environment

# `with_directory_input`

```elixir
@spec with_directory_input(t(), String.t(), Dagger.Directory.t(), String.t()) :: t()
```

Create or update a binding of type Directory in the environment

# `with_directory_output`

```elixir
@spec with_directory_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Directory output to be assigned in the environment

# `with_env_file_input`

```elixir
@spec with_env_file_input(t(), String.t(), Dagger.EnvFile.t(), String.t()) :: t()
```

Create or update a binding of type EnvFile in the environment

# `with_env_file_output`

```elixir
@spec with_env_file_output(t(), String.t(), String.t()) :: t()
```

Declare a desired EnvFile output to be assigned in the environment

# `with_env_input`

```elixir
@spec with_env_input(t(), String.t(), t(), String.t()) :: t()
```

Create or update a binding of type Env in the environment

# `with_env_output`

```elixir
@spec with_env_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Env output to be assigned in the environment

# `with_file_input`

```elixir
@spec with_file_input(t(), String.t(), Dagger.File.t(), String.t()) :: t()
```

Create or update a binding of type File in the environment

# `with_file_output`

```elixir
@spec with_file_output(t(), String.t(), String.t()) :: t()
```

Declare a desired File output to be assigned in the environment

# `with_generator_group_input`

```elixir
@spec with_generator_group_input(
  t(),
  String.t(),
  Dagger.GeneratorGroup.t(),
  String.t()
) :: t()
```

Create or update a binding of type GeneratorGroup in the environment

# `with_generator_group_output`

```elixir
@spec with_generator_group_output(t(), String.t(), String.t()) :: t()
```

Declare a desired GeneratorGroup output to be assigned in the environment

# `with_generator_input`

```elixir
@spec with_generator_input(t(), String.t(), Dagger.Generator.t(), String.t()) :: t()
```

Create or update a binding of type Generator in the environment

# `with_generator_output`

```elixir
@spec with_generator_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Generator output to be assigned in the environment

# `with_git_ref_input`

```elixir
@spec with_git_ref_input(t(), String.t(), Dagger.GitRef.t(), String.t()) :: t()
```

Create or update a binding of type GitRef in the environment

# `with_git_ref_output`

```elixir
@spec with_git_ref_output(t(), String.t(), String.t()) :: t()
```

Declare a desired GitRef output to be assigned in the environment

# `with_git_repository_input`

```elixir
@spec with_git_repository_input(t(), String.t(), Dagger.GitRepository.t(), String.t()) ::
  t()
```

Create or update a binding of type GitRepository in the environment

# `with_git_repository_output`

```elixir
@spec with_git_repository_output(t(), String.t(), String.t()) :: t()
```

Declare a desired GitRepository output to be assigned in the environment

# `with_http_state_input`

```elixir
@spec with_http_state_input(t(), String.t(), Dagger.HTTPState.t(), String.t()) :: t()
```

Create or update a binding of type HTTPState in the environment

# `with_http_state_output`

```elixir
@spec with_http_state_output(t(), String.t(), String.t()) :: t()
```

Declare a desired HTTPState output to be assigned in the environment

# `with_json_value_input`

```elixir
@spec with_json_value_input(t(), String.t(), Dagger.JSONValue.t(), String.t()) :: t()
```

Create or update a binding of type JSONValue in the environment

# `with_json_value_output`

```elixir
@spec with_json_value_output(t(), String.t(), String.t()) :: t()
```

Declare a desired JSONValue output to be assigned in the environment

# `with_main_module`

```elixir
@spec with_main_module(t(), Dagger.Module.t()) :: t()
```

Sets the main module for this environment (the project being worked on)

Contextual path arguments will be populated using the environment's workspace.

# `with_module`

> This function is deprecated. Use withMainModule instead
.

```elixir
@spec with_module(t(), Dagger.Module.t()) :: t()
```

Installs a module into the environment, exposing its functions to the model

Contextual path arguments will be populated using the environment's workspace.

# `with_module_config_client_input`

```elixir
@spec with_module_config_client_input(
  t(),
  String.t(),
  Dagger.ModuleConfigClient.t(),
  String.t()
) :: t()
```

Create or update a binding of type ModuleConfigClient in the environment

# `with_module_config_client_output`

```elixir
@spec with_module_config_client_output(t(), String.t(), String.t()) :: t()
```

Declare a desired ModuleConfigClient output to be assigned in the environment

# `with_module_input`

```elixir
@spec with_module_input(t(), String.t(), Dagger.Module.t(), String.t()) :: t()
```

Create or update a binding of type Module in the environment

# `with_module_output`

```elixir
@spec with_module_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Module output to be assigned in the environment

# `with_module_source_input`

```elixir
@spec with_module_source_input(t(), String.t(), Dagger.ModuleSource.t(), String.t()) ::
  t()
```

Create or update a binding of type ModuleSource in the environment

# `with_module_source_output`

```elixir
@spec with_module_source_output(t(), String.t(), String.t()) :: t()
```

Declare a desired ModuleSource output to be assigned in the environment

# `with_search_result_input`

```elixir
@spec with_search_result_input(t(), String.t(), Dagger.SearchResult.t(), String.t()) ::
  t()
```

Create or update a binding of type SearchResult in the environment

# `with_search_result_output`

```elixir
@spec with_search_result_output(t(), String.t(), String.t()) :: t()
```

Declare a desired SearchResult output to be assigned in the environment

# `with_search_submatch_input`

```elixir
@spec with_search_submatch_input(
  t(),
  String.t(),
  Dagger.SearchSubmatch.t(),
  String.t()
) :: t()
```

Create or update a binding of type SearchSubmatch in the environment

# `with_search_submatch_output`

```elixir
@spec with_search_submatch_output(t(), String.t(), String.t()) :: t()
```

Declare a desired SearchSubmatch output to be assigned in the environment

# `with_secret_input`

```elixir
@spec with_secret_input(t(), String.t(), Dagger.Secret.t(), String.t()) :: t()
```

Create or update a binding of type Secret in the environment

# `with_secret_output`

```elixir
@spec with_secret_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Secret output to be assigned in the environment

# `with_service_input`

```elixir
@spec with_service_input(t(), String.t(), Dagger.Service.t(), String.t()) :: t()
```

Create or update a binding of type Service in the environment

# `with_service_output`

```elixir
@spec with_service_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Service output to be assigned in the environment

# `with_socket_input`

```elixir
@spec with_socket_input(t(), String.t(), Dagger.Socket.t(), String.t()) :: t()
```

Create or update a binding of type Socket in the environment

# `with_socket_output`

```elixir
@spec with_socket_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Socket output to be assigned in the environment

# `with_stat_input`

```elixir
@spec with_stat_input(t(), String.t(), Dagger.Stat.t(), String.t()) :: t()
```

Create or update a binding of type Stat in the environment

# `with_stat_output`

```elixir
@spec with_stat_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Stat output to be assigned in the environment

# `with_string_input`

```elixir
@spec with_string_input(t(), String.t(), String.t(), String.t()) :: t()
```

Provides a string input binding to the environment

# `with_string_output`

```elixir
@spec with_string_output(t(), String.t(), String.t()) :: t()
```

Declares a desired string output binding

# `with_up_group_input`

```elixir
@spec with_up_group_input(t(), String.t(), Dagger.UpGroup.t(), String.t()) :: t()
```

Create or update a binding of type UpGroup in the environment

# `with_up_group_output`

```elixir
@spec with_up_group_output(t(), String.t(), String.t()) :: t()
```

Declare a desired UpGroup output to be assigned in the environment

# `with_up_input`

```elixir
@spec with_up_input(t(), String.t(), Dagger.Up.t(), String.t()) :: t()
```

Create or update a binding of type Up in the environment

# `with_up_output`

```elixir
@spec with_up_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Up output to be assigned in the environment

# `with_workspace`

```elixir
@spec with_workspace(t(), Dagger.Directory.t()) :: t()
```

Returns a new environment with the provided workspace

# `with_workspace_input`

```elixir
@spec with_workspace_input(t(), String.t(), Dagger.Workspace.t(), String.t()) :: t()
```

Create or update a binding of type Workspace in the environment

# `with_workspace_output`

```elixir
@spec with_workspace_output(t(), String.t(), String.t()) :: t()
```

Declare a desired Workspace output to be assigned in the environment

# `without_outputs`

```elixir
@spec without_outputs(t()) :: t()
```

Returns a new environment without any outputs

# `workspace`

```elixir
@spec workspace(t()) :: Dagger.Directory.t()
```

---

*Consult [api-reference.md](api-reference.md) for complete listing*
