Skip to main content
All RouteMCP API requests are authenticated using API keys. Include your key in the Authorization header as a Bearer token with every request:

Getting an API Key

API keys are managed from the RouteMCP dashboard:
  1. Log in to your dashboard at https://app.routemcp.com
  2. Navigate to API Keys
  3. Click Generate New Key
  4. Choose live (production) or test (sandbox) environment
  5. Copy the key — it’s only shown once

Key Types

Use sk_test_ keys during development and integration testing. Switch to sk_live_ keys for production.

Making Requests

cURL

JavaScript (fetch)

Python (requests)

Security Best Practices

  1. Never expose API keys in client-side code — keep them server-side only
  2. Use environment variables — don’t hardcode keys in source code
  3. Use test keys for developmentsk_test_ keys access sandbox data
  4. Rotate keys periodically — generate a new key from the dashboard and revoke the old one
  5. Use separate keys per environment — different keys for staging vs production

Error Responses