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

# Authentication

> API key authentication for the Voxfra Management API

## API Keys

All Management API endpoints (except `GET /health`) require an API key passed in the `X-API-Key` request header.

```bash theme={null}
curl https://mgmt-api.voxfra.com/v1/auth/me \
  -H "X-API-Key: vox_mgmt_your_key_here"
```

API keys are:

* **Org-scoped** — every response is automatically filtered to your organization
* **Environment-tagged** — `production` or `sandbox`
* **Revocable** — contact support to rotate or revoke a key

## Getting a Key

Keys are issued by your Voxfra account manager or via the Voxfra admin console under **Settings → API Keys**.

## Verifying a Key

Use `GET /v1/auth/me` to confirm a key is valid and see what organization it is scoped to.

```bash theme={null}
curl https://mgmt-api.voxfra.com/v1/auth/me \
  -H "X-API-Key: vox_mgmt_your_key_here"
```

```json theme={null}
{
  "organization_id": "00000000-0000-0000-0000-000000000001",
  "api_key_id": "f014d466-1959-4d0d-be84-d64b5690ab7b",
  "key_name": "DealerMate Sandbox",
  "environment": "production"
}
```

## Errors

An invalid or missing key returns `401 Unauthorized`:

```json theme={null}
{
  "error": "Unauthorized"
}
```
