How Concurrency Limits Work
Instead of traditional rate limits (requests per minute), Helios limits the number of concurrent requests your account can have processing at once.Why concurrency limits? Health data analysis takes several minutes per request. Traditional rate limits don’t work well for long-running operations, so we limit concurrent requests instead.
Default Limits
| Agent Type | Default Limit |
|---|---|
| Light Agent | 7 concurrent requests |
| Deep Agent | 7 concurrent requests |
| Lab Results Agent | 7 concurrent requests |
Need higher limits? Contact support@heliosinc.xyz to discuss custom limits for your account.
Response Headers
Every API response includes headers showing your current concurrency status:| Header | Description | Example |
|---|---|---|
X-Concurrent-Limit | Maximum concurrent requests allowed | 7 |
X-Concurrent-Active | Currently active requests (including this one) | 3 |
X-Concurrent-Remaining | Available slots | 4 |
These headers are included on every API response (200 OK, 429, etc.), not just rate limit errors. This allows you to monitor your concurrency usage proactively.
Example Response Headers (200 OK)
Handling Rate Limit Errors
When you exceed your concurrency limit, the API returns a429 Too Many Requests response:
Response Headers on 429
Retry-After header suggests how long to wait before retrying (in seconds).
Best Practices
Monitor your concurrency headers
Monitor your concurrency headers
Check the
X-Concurrent-Remaining header on every response to know when you’re approaching your limit.Implement exponential backoff
Implement exponential backoff
When you receive a 429, wait before retrying:
Queue requests on your side
Queue requests on your side
For high-volume use cases, implement a queue to control how many requests you submit:
Track active requests
Track active requests
Store the
runId of submitted requests so you can track what’s in progress:Slot Release
Concurrency slots are automatically released when:- Processing completes - Successfully or with an error
- Webhook is delivered - After the final webhook is sent
- Timeout occurs - After ~14 minutes if processing hangs (safety mechanism)