---
title: "Create an API key for your organization"
description: "How to create a Bearly API key for your organization in Bearly Platform, choose a service account, personal, or admin key, set its models, monthly cap, rate limit, and expiry, and rotate or revoke it."
canonical: "https://bearly.ai/docs/platform/api-keys/"
markdown: "https://bearly.ai/docs/platform/api-keys.md"
---

# Create an API key for your organization

HTML: [https://bearly.ai/docs/platform/api-keys/](https://bearly.ai/docs/platform/api-keys/)

> How to create a Bearly API key for your organization in Bearly Platform, choose a service account, personal, or admin key, set its models, monthly cap, rate limit, and expiry, and rotate or revoke it.

Organization admins create API keys in [Bearly Platform](https://bearly.ai/docs/platform.md) under **Keys & access** ("Let scripts, services and the Bearly CLI use your organization's models, within limits you set."). A key lets your own code call Bearly's models through the [Bearly API](https://bearly.ai/docs/api-access.md) with the OpenAI or Anthropic SDK.

**You need:** the organization admin role, and **Bearly API** on under **Policies** → **Access** ([Turn the API and CLI on or off](https://bearly.ai/docs/platform/api-and-cli-access.md)). For a service-account key, add the [service account](https://bearly.ai/docs/platform/service-accounts.md) first and [API credit](https://bearly.ai/docs/platform/api-credit.md) to pay for its requests.

## Create a key



1. Open **Keys & access** → **API keys** and select **Create key**.
2. Choose a **Type**:
   - **Service account**: "For scripts and services. Spend counts against the service account's cap." Then choose the service account.
   - **Personal**: "Acts as you, with your policy and limits."
   - **Admin**: "Manages this organization through the API, such as reading usage or adding members. It can't call models." Choose what **It can** do: **Read usage**, **Read the audit log**, **Read members**, **Add and change members**, or **Create and revoke keys**. If Admin can't be chosen, the form says why.
3. Enter a **Name** that says where the key runs, such as "Nightly report job".
4. Optionally narrow the key:
   - **Models**: **Every model its policy allows**, or **Only models I choose**, still within its policy.
   - **Monthly cap**: the most the key can spend each month.
   - **Requests per minute**.
   - **Expires**: **Never**, **In 7 days**, **In 30 days**, **In 90 days**, or **In a year**.
   - **Group**: a group whose budget its spend also counts toward.

   An empty limit means the key has no limit of its own.
5. Select **Create key**. **Copy the key for _name_** shows the key, the API base URL `https://api.bearly.ai/v1`, and a first `curl` command, each with a copy button.



> **Caution**
> "You won't see this key again." Store it in your secrets manager before you close the dialog, and keep it out of browser code and public repositories.


## Check a key's status

**API keys** lists each key with its type, who it acts as, its limits, when it was last used, and its status: **Active**, **Replaced**, **At cap**, **Expired**, or **Revoked**. Select **Show revoked** to list revoked keys too.

## Edit, rotate, or revoke a key

Open a key's menu:

- **Edit** changes its name and limits.
- **Rotate** makes a new key with the same settings. Choose how long the current key keeps working: **Stop it now**, **Keep it for 1 hour**, or **Keep it for 24 hours**. Rotate when a key may have leaked or on a schedule.
- **Revoke** stops the key right away. "You can't undo this."

## When a key is refused

A service-account key is refused when:

- its key, its service account, its group, or the organization reaches a monthly limit, until the 1st (UTC);
- it uses up its requests per minute, until the minute passes;
- the organization's API credit runs out: `402` with "Your organization's API credit has run out. An admin can add credit in Bearly Platform.";
- **Bearly API** is off: `403` with "Your organization's policy doesn't allow API keys."

Admin keys can't call models. See [Errors](https://bearly.ai/docs/manual/api-and-agents.md#errors) for every response.

## Personal keys in Bearly

Members create their own personal keys in Bearly: account menu → **Developers** → **API keys**. Those keys act as the member and use their plan. See [Use the Bearly API](https://bearly.ai/docs/api-access.md#create-an-api-key).

## Related

- [Add a service account](https://bearly.ai/docs/platform/service-accounts.md)
- [Add API credit](https://bearly.ai/docs/platform/api-credit.md)
- [See your organization's AI usage](https://bearly.ai/docs/platform/usage.md): **Split by** → **By key** shows each key's spend.

## Continue through the documentation

- [Documentation index](https://bearly.ai/docs.md): Browse every Bearly guide.
- [Previous: Turn the Bearly API and CLI on or off for your organization](https://bearly.ai/docs/platform/api-and-cli-access.md)
- [Next: Add a service account for a script or integration](https://bearly.ai/docs/platform/service-accounts.md)
- [Related: Get started with Bearly Platform](https://bearly.ai/docs/platform.md)
- [Related: Use the Bearly API](https://bearly.ai/docs/api-access.md)
- [Related: Add prepaid API credit for your organization](https://bearly.ai/docs/platform/api-credit.md)
- [Related: Use Bearly from scripts and agents](https://bearly.ai/docs/manual/api-and-agents.md)
