AuthenticationΒΆ
All API requests require authentication using an API key.
API Key AuthenticationΒΆ
ReputeAPI uses API keys passed via the X-API-Key HTTP header.
Example RequestΒΆ
Getting Your API KeyΒΆ
- Sign up at reputeapi.com
- Navigate to your dashboard
- Click "API Keys" β "Create New Key"
- Copy your API key (you won't see it again!)
- Store it securely in environment variables
Best PracticesΒΆ
Store Keys SecurelyΒΆ
β Never do this:
β Do this instead:
Environment VariablesΒΆ
Bash/Zsh:
Windows PowerShell:
.env file:
Rotate Keys RegularlyΒΆ
Generate new keys periodically and revoke old ones:
- Generate new API key
- Update your applications
- Verify everything works
- Revoke the old key
Testing Your API KeyΒΆ
Expected response:
Error ResponsesΒΆ
Missing API KeyΒΆ
HTTP Status: 401 Unauthorized
Invalid API KeyΒΆ
HTTP Status: 401 Unauthorized
Revoked API KeyΒΆ
HTTP Status: 401 Unauthorized
Multiple API KeysΒΆ
Create separate keys for different environments:
- Production:
REPUTE_PROD_API_KEY - Staging:
REPUTE_STAGING_API_KEY - Development:
REPUTE_DEV_API_KEY
This allows you to: - Track usage per environment - Revoke keys without affecting other environments - Set different rate limits
Next StepsΒΆ
- Rate Limits - Understand rate limiting
- Quick Start - Make your first request
- Common Errors - Troubleshoot issues