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

# Authentication

> API keys, where the CLI keeps them, profiles for more than one key, workspaces, and how to give a key to a script.

## API keys

A key is created in ReachBoost under [Integrations > API keys](https://app.reachboost.io/integrations/api). It belongs to one workspace and has full access to it, with no per-user audit trail, so treat it as you would a password. The CLI stores it once and uses it for every later command.

```bash theme={null}
reachboost auth set-key --workspace "<workspace-uuid>"
```

`whoami` shows which key and workspace commands will use and checks that they work.

```bash theme={null}
reachboost whoami
```

## Where the key is stored

The key never sits in a flag or in shell history. Where it goes depends on the platform.

> [tab] macOS
>
> The key is stored in the macOS Keychain under your user account.

> [tab] Linux
>
> The key is stored in the system secret service when `secret-tool` is installed, otherwise in a file only your user can read.

> [tab] Windows
>
> There is no Credential Manager integration yet. The key is stored in a file protected by your user profile permissions. Keep the config folder on a local NTFS drive, not on a network share.

## Profiles

A profile holds one key and one default workspace. `--profile <name>`, or `REACHBOOST_PROFILE`, picks it; the profile called `default` is used when neither is given. An agency with several client workspaces, or a staging key next to production, keeps them apart this way.

```bash theme={null}
reachboost --profile staging auth set-key --workspace "<staging-workspace-uuid>"
reachboost --profile staging campaigns list
```

## Workspaces

A workspace key works for its own workspace. An agency key can act on the workspaces linked to it: list them, remember one as the default, or name one per command with `--workspace`.

```bash theme={null}
reachboost workspaces list
reachboost workspaces use "<workspace-uuid>"
reachboost leads list --workspace "<other-workspace-uuid>"
```

## Scripts and CI

In CI, set `REACHBOOST_API_KEY` from your secret store. A key that comes from the environment must be paired with an explicit workspace, from `--workspace` or `REACHBOOST_WORKSPACE`; a stored profile default is never mixed with it. The CLI says on stderr when it is using a key from the environment.

```bash CI theme={null}
export REACHBOOST_WORKSPACE="<workspace-uuid>"
reachboost campaigns list --json
```

```bash Key from stdin theme={null}
cat key.txt | reachboost auth set-key --workspace "<workspace-uuid>" --stdin
```

To store a key from a script rather than by typing it, pipe it in with `--stdin`.

> [!WARNING]
>
> There is no `--api-key` flag. A flag value shows up in process listings and shell history.

## Removing a key

Forget the key on this machine at any time. It stays valid until you revoke it in ReachBoost.

```bash theme={null}
reachboost auth remove
```

> [card] [Manage API keys](https://app.reachboost.io/integrations/api)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.