Authorization header.
Getting your API key
Log in to Partnero
Access your Partnero dashboard.
Using your API key
Include the API key in theAuthorization header of every request:
Example request
Authentication errors
| Status Code | Error | Solution |
|---|---|---|
| 401 | Unauthorized | Check that your API key is correct and not expired |
| 403 | Forbidden | Verify your account has API access and the key has required permissions |
Best practices
Use environment variables
Use environment variables
Store API keys in environment variables, not in your codebase:
Rotate keys regularly
Rotate keys regularly
Periodically generate new API keys and revoke old ones to maintain security.
Use separate keys for environments
Use separate keys for environments
Create different API keys for development, staging, and production environments.
Server-side requests only
Server-side requests only
Make API calls from your server, never from client-side JavaScript. Use the JavaScript SDK for client-side tracking.
