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

# anaconda auth api-key

## Usage

```bash theme={null}
anaconda auth api-key [OPTIONS]
```

## Description

Prints the stored API key to stdout. Useful for:

* Copying the key for use in CI/CD pipelines
* Setting up non-interactive environments
* Debugging authentication issues

> [!TIP]
>
> If the API key has expired, the command raises `TokenExpiredError`. For more information, see [Troubleshooting](https://anaconda.com/docs/cli-reference/anaconda-auth/troubleshooting.md).

## Options

Option

Description

`--at <SITE>`

Specify the Anaconda site (default: `anaconda.com`)

`-h, --help`

Show help for this command

## Examples

**Print the API key**

```bash theme={null}
anaconda auth api-key
```

**Use in a script**

```bash theme={null}
export ANACONDA_AUTH_API_KEY=$(anaconda auth api-key)
```
