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

# API keys

> For scripts, CI jobs and headless agents that can't sign in with OAuth.

Keys start with `enr_` and use your account's credits. Send `Authorization: Bearer YOUR_API_KEY` on authenticated requests. Never put a key in a URL, browser bundle or public repository.

## Use a key with MCP

MCP uses JSON-RPC at `/mcp`, not the REST request format. This example checks account usage without spending credits:

```bash Shell theme={null}
curl https://mcp.enricho.co/mcp \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call",
       "params":{"name":"account_usage","arguments":{}}}'
```

## Use a key with REST

REST requests use `/api/` endpoints and ordinary JSON, not JSON-RPC. Start with the [API overview](https://docs.enricho.co/api-reference/overview.md) for authentication, endpoint references, examples and errors.

## Get a key

Sign in and open [API keys](https://app.enricho.co/keys), then choose **Create key** and give it a name. You can have up to 20 active keys. The secret is returned only once—save it securely.

Key creation uses a signed-in app session, not an existing API key. See [API authentication](https://docs.enricho.co/api-reference/authentication.md) for the session-authenticated creation endpoint. If you need help getting access, email [support@enricho.co](mailto:support@enricho.co?subject=API%20key) from your account's address.

> [!WARNING]
>
> Treat your key like a password: anyone with the key can spend your credits.

Extra keys don't add capacity: request limits apply per key and per account. See [Credits and limits](https://docs.enricho.co/credits-and-limits.md#rate-limits).


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