# invalid_api_key

> invalid_api_key (401): the API key is malformed, unknown, or belongs to an inactive account.

Canonical: https://corpoapi.com/errors/invalid_api_key

HTTP 401 · Invalid API key

The API key is malformed, unknown, or does not belong to an active account.

## Why it happens

The key was not found, or it was copied with missing characters, whitespace, or the wrong prefix.

## How to fix it

Copy the full key from the dashboard again and send it in one header. A test key starts with ck_test_ and is never billed.

## Example response

```json
{
  "type": "https://corpoapi.com/errors/invalid_api_key",
  "title": "Invalid API key",
  "status": 401,
  "code": "invalid_api_key",
  "detail": "The API key is not recognised."
}
```
