Authentication
API Key authentication methods
API Configuration
After saving, the Try It panel below sends real requests with this key.
Base: api.xrtoken.ai
Getting an API Key
Create an API Key in the Dashboard Key Management page. Keys are prefixed with tr-.
Authentication Methods
XRToken supports two authentication formats depending on your API protocol:
OpenAI Format
Pass via the Authorization header:
Authorization: Bearer YOUR_API_KEYAnthropic Format
Pass via the x-api-key header, along with the API version:
x-api-key: YOUR_API_KEY
anthropic-version: 2023-06-01Security Tips
- Never hardcode API Keys in client-side code
- Use environment variables to store keys
- Rotate keys regularly
- If a key is compromised, revoke it immediately in the dashboard and create a new one