Skip to main content

Overview

All API endpoints are authenticated using API keys. Pass your key as a Bearer token in the Authorization header.

API Keys

Format

API keys follow the format cc_ followed by 64 lowercase hexadecimal characters:

Creating a key

  1. Log in to Carboncopy
  2. Navigate to Settings → API Keys
  3. Click Create Key, choose a name and scopes
  4. Copy the key — it’s shown exactly once and cannot be retrieved later

Scopes

Every key is issued with a set of scopes that control what it can access. Always issue keys with the minimum scopes your use-case requires.
write scope implies read for the same resource. You don’t need to grant both.

Key lifecycle

  • Maximum 10 active keys per account.
  • Keys can have an optional expiry timestamp.
  • Revoke a key anytime from Settings → API Keys.

Security best practices

Never commit API keys to source control. Use environment variables or a secrets manager.
  • Rotate regularly — set an expiry and automate rotation in production.
  • Narrow scopes — monitoring bots only need portfolio:read; they don’t need traders:write.
  • One key per service — easier to audit, easier to revoke if compromised.
  • Revoke immediately if a key is exposed.

Error responses

If authentication fails, the API returns a 401 Unauthorized:
If you authenticate successfully but your key lacks the required scope, you’ll receive 403 Forbidden:
See Errors for the full error reference.