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

# Auth

> Configure and manage your Bugster API key for CLI authentication

The `bugster auth` command allows you to configure and manage your Bugster API key for CLI authentication.

## Basic Usage

```bash theme={null}
bugster auth
```

## Command Overview

Configure or update your Bugster API key for authentication with the Bugster platform.

### When to Use

* When setting up Bugster for the first time
* When switching between organizations or teams
* If your API key expires or gets rotated
* When API key authentication fails

### Key Features

* Interactive API key setup
* Secure storage in `~/.bugsterrc`
* Environment variable support via `BUGSTER_CLI_API_KEY`
* API key validation and verification

<Note>
  API keys start with the `bugster_` prefix and are required for all Bugster operations.
</Note>

## Command Syntax

```bash theme={null}
bugster auth [options]
```

### Options

<ParamField query="--api-key" type="string">
  Set the Bugster API key directly without interactive prompts. The key must start with 'bugster\_'.
</ParamField>

<ParamField query="--clear" type="boolean">
  Remove the existing API key from local storage.
</ParamField>

## Examples

### Interactive Setup

```bash theme={null}
bugster auth
```

This opens an interactive prompt to enter your API key.

### Direct API Key Setup

```bash theme={null}
bugster auth --api-key bugster_org_abc123def456...
```

### Clear Existing Authentication

```bash theme={null}
bugster auth --clear
```

## Authentication Storage

Your API key is stored securely in:

* **Local file**: `~/.bugsterrc`
* **Environment variable**: `BUGSTER_CLI_API_KEY` (optional)

<Warning>
  Keep your API key secure and never commit it to version control. The environment variable takes precedence over the local file.
</Warning>
