API
Authentication
Authenticate with Dialect’s REST API using your API key for server-side notification sending
Getting Your API Key
To send notifications, you’ll need to authenticate as an application using your API key. If you don’t have your key yet, please open a ticket in our discord channel.
Using Your API Key
Include your API key in the x-dialect-api-key
header for all server-side requests:
Error Handling
Common Authentication Errors
401 Unauthorized: Invalid or missing API key
403 Forbidden: Valid API key but insufficient permissions
Error Handling Example
Best Practices
💡 Security:
- Store API keys securely (environment variables, secrets management)
- Never expose API keys in client-side code
- Use HTTPS for all API communication
💡 Error Handling:
- Always check response status codes
- Implement proper retry logic for transient failures
- Log authentication errors for debugging
💡 Rate Limiting:
- Respect API rate limits to avoid being blocked
- Implement exponential backoff for retries