Skip to Content
DeveloperAPI ReferenceRate Limits

Rate Limits

HealthTalk API enforces rate limits to ensure fair usage and service availability.

Default Limits

Endpoint CategoryLimitWindow
Messages (send)100per minute
Messages (read)1000per minute
Patients500per minute
Templates200per minute
Webhooks50per minute

Rate Limit Headers

All responses include rate limit information:

X-RateLimit-Limit: 100 X-RateLimit-Remaining: 95 X-RateLimit-Reset: 1678901294

Handling Rate Limits

When rate limited, you receive:

HTTP/1.1 429 Too Many Requests Retry-After: 30
{ "error": { "code": "RATE_LIMIT_EXCEEDED", "message": "Rate limit exceeded. Please retry after 30 seconds." } }

Best Practices

Implement Backoff

async function apiCallWithRetry(fn, maxRetries = 3) { for (let i = 0; i < maxRetries; i++) { try { return await fn(); } catch (error) { if (error.status === 429 && i < maxRetries - 1) { const retryAfter = error.headers['retry-after'] || 30; await sleep(retryAfter * 1000); continue; } throw error; } } }

Batch Requests

Use bulk endpoints when available to reduce API calls:

POST /v1/messages/batch

Increasing Limits

Contact MEDrecord to discuss increased rate limits for high-volume use cases.

Last updated on