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

# astro env variable list

<Info>
  This command is only available on Astro.
</Info>

List the environment variables for a scope. At Deployment scope, the list includes variables linked from the Workspace unless you set `--resolve-linked` to `false`.

## Usage

```bash wrap theme={null}
astro env variable list
```

## Options

| Option              | Description                                                                                                                                                                | Possible Values                      |
| ------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------ |
| `--format`          | The output format. Defaults to `table`.                                                                                                                                    | `table`, `json`, `yaml`, or `dotenv` |
| `--output`          | Write the output to a file. Use `-` for stdout. Defaults to `-`.                                                                                                           | Any valid file path, or `-`          |
| `--include-secrets` | Surface secret values in the output. Requires an Organization policy that allows it.                                                                                       | None                                 |
| `--resolve-linked`  | Include objects linked from another scope, such as a Workspace variable resolved at Deployment scope. Enabled by default. Set to `false` to return addressable object IDs. | `true` (default), `false`            |
| `--workspace-id`    | Set the Workspace scope. Mutually exclusive with `--deployment-id`. Defaults to your current Workspace from CLI context.                                                   | Any valid Workspace ID               |
| `--deployment-id`   | Set the Deployment scope. Mutually exclusive with `--workspace-id`.                                                                                                        | Any valid Deployment ID              |

## Examples

```bash wrap theme={null}
# List Workspace variables
astro env variable list --workspace-id <workspace-id>

# List the variables a Deployment resolves, including those linked from the Workspace
astro env variable list --deployment-id <deployment-id> --resolve-linked
```

## Related commands

* [`astro env variable get`](/docs/cli/v1.43/astro-env-variable-get)
* [`astro env variable export`](/docs/cli/v1.43/astro-env-variable-export)
* [`astro env variable create`](/docs/cli/v1.43/astro-env-variable-create)
