> For the complete documentation index, see [llms.txt](https://docs.currents.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.currents.dev/dashboard/administration/api-keys.md).

# API Keys

API keys authenticate programmatic access to Currents - the [REST API](https://docs.currents.dev/api/), the [MCP Server](/ai/mcp-server.md), the CLI tools, and other integrations. Every request is authorized against the permissions of the API key it carries, not the dashboard role of the user who created it.

{% hint style="info" %}
API keys are **organization-wide** credentials. They should be treated like passwords - stored in a secret manager and never committed to source control.
{% endhint %}

## Managing API Keys

Only organization **Admins** can create or revoke API keys. **Actions Admin** and **Member** roles can view existing keys, while **Guest** users cannot. See [Manage Team](/dashboard/administration/manage-team.md) for the full permissions matrix.

To create a key:

1. Navigate to **Organization → API Keys**
2. Click **Create API Key**
3. Set a **label** (used to identify the key in audit logs and notifications)
4. Choose the key **permission** (see below)
5. Copy the generated key - it is shown only once

## API Key Permissions

Each key is assigned one of two permission levels that govern what it can do across the entire organization:

| Permission       | Access                                                                 |
| ---------------- | ---------------------------------------------------------------------- |
| **Read Only**    | Read-only access to `GET` endpoints (runs, tests, analytics, metrics). |
| **Read & Write** | Full read access plus write operations (create, update, delete).       |

Authorization is enforced **server-side at the REST API layer**. A **Read Only** key that attempts a write operation - deleting a run, creating a webhook, changing an action, or creating a Jira issue - is rejected with an **HTTP 403 Forbidden**, regardless of which client or tool issued the request.

{% hint style="warning" %}
**Legacy keys** created before permission levels were introduced default to **Read & Write** for backward compatibility. For read-only access, a new key with the **Read Only** permission should be created rather than reusing an older key.
{% endhint %}

### Scope

API key permissions are **organization-wide**. A key applies to all projects and data in the organization exposed by the endpoints it can reach. There is currently no per-project, per-tool, or per-endpoint key scoping - only the Read Only vs Read & Write distinction.

## Using API Keys

The key is passed as a bearer token in the `Authorization` header:

```bash
curl https://api.currents.dev/v1/runs \
-H "Authorization: Bearer API_KEY_HERE"
```

For MCP and integration setups, the key is provided through the relevant configuration (for example the `CURRENTS_API_KEY` environment variable). See the [MCP Server](/ai/mcp-server.md) documentation for details.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.currents.dev/dashboard/administration/api-keys.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
