Authentication
XenonFlare uses API keys to authenticate requests. You can find and manage your API keys in the Developer Settings section of your dashboard.
Passing the API Key
You can authenticate your requests by passing your API key in one of two ways:
1. X-API-Key Header (Recommended)
Add the X-API-Key header to your request with your API key as the value.
curl -H "X-API-Key: xf_your_api_key_here" https://xenonflare.com/api/v1/...
2. Authorization Header
Use the standard Bearer token format in the Authorization header.
curl -H "Authorization: Bearer xf_your_api_key_here" https://xenonflare.com/api/v1/...
Security Best Practices
- Keep your keys secret: Never share your API keys or commit them to version control.
- Rotate keys regularly: If you suspect a key has been compromised, revoke it immediately and generate a new one.
- Environment Variables: Store your keys as environment variables in your application.