Skip to main content

Rate Limits

To ensure fair usage and platform stability, the Case AI API enforces rate limits on all endpoints.

Default Limits

TierRequests per MinuteRequests per Day
Standard6010,000
Pro300100,000
EnterpriseCustomCustom

Rate Limit Headers

Every API response includes headers indicating your current rate limit status:
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 45
X-RateLimit-Reset: 1705330800
HeaderDescription
X-RateLimit-LimitMaximum requests allowed per minute
X-RateLimit-RemainingRequests remaining in current window
X-RateLimit-ResetUnix timestamp when the limit resets

Handling Rate Limits

When you exceed the rate limit, you’ll receive a 429 Too Many Requests response:
{
  "error": {
    "code": "rate_limit_exceeded",
    "message": "Too many requests. Please try again later."
  }
}

Best Practices

Implement Backoff

Use exponential backoff when you receive a 429 response. Wait before retrying.

Cache Responses

Cache product data locally to reduce unnecessary API calls.

Use Webhooks

Use webhooks for order updates instead of polling the API.

Batch Requests

Combine multiple operations where possible to reduce total requests.

Example: Exponential Backoff

async function fetchWithRetry(url, options, maxRetries = 3) {
  for (let i = 0; i < maxRetries; i++) {
    const response = await fetch(url, options);

    if (response.status === 429) {
      const retryAfter = response.headers.get('X-RateLimit-Reset');
      const waitTime = Math.min(1000 * Math.pow(2, i), 30000);
      await new Promise(resolve => setTimeout(resolve, waitTime));
      continue;
    }

    return response;
  }
  throw new Error('Max retries exceeded');
}

Need Higher Limits?

Contact us at [email protected] to discuss Enterprise plans with custom rate limits.