Authentication
How to authenticate with the MNDR API using API keys.
All API requests require an API key passed in the x-api-key header.
Creating API Keys
- Go to Settings > Developer in the MNDR dashboard
- Click Create API Key
- Give it a name (e.g. "Shopify Integration")
- Copy the key — it's shown only once
Using API Keys
Include the key in every request:
curl -X GET https://your-domain.com/api/v1/contacts/by-email/user@example.com \
-H "x-api-key: mndr_your_api_key_here"Key Format
API keys follow the format mndr_ followed by 40 hex characters:
mndr_a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2Security Best Practices
Keep your API keys secret. Do not expose them in client-side code, public repositories, or browser requests.
- Never commit API keys to version control
- Never include them in frontend JavaScript
- Store keys in environment variables or a secrets manager
- Rotate keys immediately if compromised
- Use separate keys for different integrations so you can revoke individually
Error Responses
| Status | Error | Meaning |
|---|---|---|
401 | Missing x-api-key header | No API key provided |
401 | Invalid API key | Key not found in database |
401 | API key is inactive | Key was disabled in dashboard |
401 | API key has expired | Key past its expiration date |