Fixing 401 errors and invalid API keys
Work through these:
- Header format: it must be
Authorization: Bearer YOUR_API_KEY, with one space and no quotes around the key. - Whole key: make sure the full key was copied, with no spaces or line breaks.
- Revoked or expired: check Settings → API Keys. If the key is gone, revoked or expired, create a new one.
- Lost key: the full key is only shown when it's created. If you don't have it, create a new key and revoke the old one.
- Right base path: requests go to
/api/external/v1/.... Old paths such as/api/v1/...aren't part of the partner API.
If you still get 401s, ask the AI assistant to connect you with a person. Never paste your API key into the chat.