SilentChat

Rate Limits

To ensure fair usage and platform stability, the SilentChat API enforces rate limits on all endpoints. Limits are applied per API key or authenticated user, per endpoint group, and per minute unless noted otherwise.

Limits by Endpoint Group

GroupLimitWindowScope
Auth (/v1/auth/*)10 requests1 minutePer IP address
API (all other /v1/*)100 requests1 minutePer user / API key
Widget (/v1/widget/*)30 requests1 minutePer visitor session

Enterprise plans have higher limits. Contact sales if your integration requires increased throughput.

Rate Limit Headers

Every API response includes headers that tell you the current state of your rate limit:

HeaderDescription
X-RateLimit-LimitThe maximum number of requests allowed in the current window.
X-RateLimit-RemainingThe number of requests remaining in the current window.
X-RateLimit-ResetThe Unix timestamp at which the current window resets.
Retry-AfterOnly present on 429 responses. The number of seconds to wait before retrying.

Example Response Headers

HTTP/1.1 200 OK
X-RateLimit-Limit: 100
X-RateLimit-Remaining: 87
Content-Type: application/json

Handling 429 Too Many Requests

When you receive a 429 response the API includes a Retry-After header indicating how many seconds to wait before making another request. Do not retry immediately — doing so will not succeed and may extend the backoff.

HTTP/1.1 429 Too Many Requests
Retry-After: 23
Content-Type: application/json
{
"error": {
"code": "RATE_LIMITED",
"message": "Too many requests. Please retry after 23 seconds.",
"status": 429
}
}

Recommended Retry Strategy

  1. Read the Retry-After header from the 429 response.
  2. Wait for the indicated number of seconds.
  3. Add a small random jitter (0–1 s) to avoid thundering-herd problems when many clients reset at the same time.
  4. Retry the request once. If you receive another 429, apply exponential backoff.

Example (JavaScript)

async function fetchWithRetry(url, options, maxRetries = 3) {
for (let attempt = 0; attempt <= maxRetries; attempt++) {
const response = await fetch(url, options);
if (response.status !== 429) {
return response;
}
const retryAfter = parseInt(response.headers.get('Retry-After') || '5', 10);
const delay = Math.min(retryAfter * 1000 * Math.pow(2, attempt), 60000);
console.warn(`Rate limited. Retrying in ${delay / 1000}s...`);
await new Promise((resolve) => setTimeout(resolve, delay));
}
throw new Error('Max retries exceeded');
}

Best Practices

  • Cache responses where possible to reduce the number of API calls.
  • Use webhooks instead of polling for real-time updates.
  • Batch operations when the API supports it (e.g. bulk contact import).
  • Monitor your X-RateLimit-Remaining header and slow down proactively as you approach the limit.
  • Distribute requests evenly over time rather than sending bursts.
Rate Limits | SilentChat