About Our Limits
Limits are designed to prevent API abuse while minimizing impact on common usage patterns.
- Limits are enforced at both client and user levels using Redis-based distributed rate limiting
- Rate limits apply to different time windows: minute, hour, and day
- We use a token bucket algorithm for smooth rate limiting rather than hard resets
- All limits represent maximum allowed usage, not guaranteed minimums
- Limits are monitored in real-time through our Prometheus metrics system
Authentication Tiers
Different authentication methods have varying access levels and rate limits.API Token Authentication
Used for server-to-server API calls.Property | Value |
---|---|
Use Case | System integrations |
Token Duration | 1 hour (6 × NORMAL_TOKEN_EXPIRE_DURATION) |
Required Headers | Authorization: Bearer {credentials} |
SDK Token Authentication
Designed for mobile and client applications.Property | Value |
---|---|
Use Case | Mobile apps, SDKs |
Token Duration | 1 hour (6 × NORMAL_TOKEN_EXPIRE_DURATION) |
Required Headers | Authorization: Bearer {credentials} |
Access Token Authentication
For portal and dashboard access.Property | Value |
---|---|
Use Case | Web portals, admin dashboards |
Token Duration | 24 hours (6 × 24 × NORMAL_TOKEN_EXPIRE_DURATION) |
Grant Type | Password flow |
Rate Limits
Standard Rate Limits
Our API implements flexible rate limiting based on different time windows:Time Window | Default Limit | Error Response |
---|---|---|
Per Minute | 10 requests | HTTP 429 |
Per Hour | Configurable | HTTP 429 |
Per Day | Configurable | HTTP 429 |
Rate limits are applied per unique key (client_id, user_id, or IP address). Exceeding any limit will result in a
429 Too Many Requests
response.Task Processing Limits
Background task processing uses Celery with queue-based rate limiting:Pagination Limits
All list endpoints enforce consistent pagination limits to ensure optimal performance.Standard Pagination
Parameter | Min Value | Max Value | Default |
---|---|---|---|
limit | 10 | 1000 | 25 |
next_page_token | - | JWT token | None |
Time Range Limits
Statistical and logging endpoints implement strict time window restrictions:Maximum Query Range: 30 days
Future Dates: Not allowed
Date Validation: start_date ≤ end_date ≤ today
Future Dates: Not allowed
Date Validation: start_date ≤ end_date ≤ today
File Upload Limits
S3 Upload Restrictions
Property | Restriction |
---|---|
File Types | opus, mp3 |
Size Limit | Configurable per client |
Upload Method | Multipart supported |
Validation | MD5 checksum required |
Temporary Upload Limits
Monitoring Your Rate Limits
Prometheus Metrics
The platform provides comprehensive monitoring through Prometheus metrics:method
: HTTP method (GET, POST, etc.)endpoint
: API endpoint pathstatus_code
: HTTP response codeclient_id
: Client identifier
Request Tracing
Every API request includes detailed tracing information:Error Responses
Rate Limit Errors
When rate limits are exceeded, you’ll receive a structured error response:Standard HTTP Status Codes
Status Code | Error Type | Description |
---|---|---|
400 | Bad Request | Invalid request parameters |
401 | Unauthorized | Invalid or expired authentication |
403 | Forbidden | Insufficient permissions |
404 | Not Found | Resource does not exist |
422 | Validation Error | Request data validation failed |
429 | Too Many Requests | Rate limit exceeded |
500 | Internal Server Error | Server-side error |
Response Headers
Rate limit responses include helpful headers for managing your requests:Configuration Management
Environment Variables
Rate limiting behavior can be configured through environment variables:Dynamic Configuration
The platform supports dynamic configuration through AWS Secrets Manager, allowing for runtime adjustments without service restarts.
Best Practices
Rate Limit Management
- Implement Exponential Backoff: When receiving 429 responses, implement exponential backoff with jitter
- Monitor Your Usage: Use the provided metrics to track your API usage patterns
- Cache Responses: Cache API responses when appropriate to reduce request frequency
- Batch Requests: Use batch endpoints when available to reduce API calls
Error Handling
Optimization Tips
- Use appropriate page sizes for list endpoints (default: 25, max: 1000)
- Implement client-side caching for frequently accessed data
- Monitor your token expiration times and refresh proactively
- Use batch operations when processing multiple items
If you need higher rate limits for your use case, please contact our support team with details about your integration requirements.