Obtaining API Keys
- Log in to the Admina dashboard
- Select Settings from the top-right user settings menu
- Choose API Keys in the left navigation menu
- Click the Create New API Key button
- Enter a name for the API key and set an expiration date if necessary
- Click the Create button to generate the API key
- Copy and save the displayed API key in a secure location
mb_live_ prefix and are about 47 characters long (e.g. mb_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx).
The API key is displayed only once. Be sure to save it in a secure location.
Adding Authentication to Requests
All API requests must include the API key in theX-API-Key header.
Header Format
Example with cURL
Example with JavaScript
Security Best Practices
- Do not embed API keys in source code or client-side code
- Use environment variables or secret management systems to manage API keys
- Delete API keys that are no longer needed
- Consider rotating API keys regularly
- Monitor for API access from unexpected locations
Authentication Errors
When theX-API-Key header is missing or invalid, the API returns HTTP 401 with the following body:
X-API-Key header value and whether the key has expired.
