Skip to main content

Rate Limits

ArchiCore API implements rate limiting to ensure fair usage.

Limits by Tier

TierRequests/dayRequests/minuteProjects
Free100103
Pro10,00010025
EnterpriseUnlimited1,000Unlimited

Rate Limit Headers

Every API response includes rate limit information:

HTTP/1.1 200 OK
X-RateLimit-Limit: 100
X-RateLimit-Remaining: 95
X-RateLimit-Reset: 1640000000
HeaderDescription
X-RateLimit-LimitMaximum requests allowed
X-RateLimit-RemainingRequests remaining in window
X-RateLimit-ResetUnix timestamp when limit resets

Rate Limit Exceeded

When you exceed the rate limit:

HTTP/1.1 429 Too Many Requests
Retry-After: 60
{
"success": false,
"error": "Rate limit exceeded",
"code": "RATE_LIMIT_EXCEEDED",
"retryAfter": 60
}

Best Practices

1. Check Headers

Always check X-RateLimit-Remaining before making requests:

async function makeRequest(url) {
const response = await fetch(url, { headers });

const remaining = response.headers.get('X-RateLimit-Remaining');
if (parseInt(remaining) < 10) {
console.warn('Rate limit running low:', remaining);
}

return response.json();
}

2. Implement Exponential Backoff

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

if (response.status !== 429) {
return response.json();
}

const retryAfter = response.headers.get('Retry-After') || 60;
await sleep(retryAfter * 1000 * Math.pow(2, i));
}

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

3. Cache Responses

Cache responses to reduce API calls:

const cache = new Map();

async function getCached(key, fetchFn, ttl = 60000) {
const cached = cache.get(key);
if (cached && Date.now() - cached.timestamp < ttl) {
return cached.data;
}

const data = await fetchFn();
cache.set(key, { data, timestamp: Date.now() });
return data;
}

4. Batch Operations

Use batch endpoints when available:

// Instead of multiple requests
for (const id of projectIds) {
await client.projects.get(id); // ❌ Multiple requests
}

// Use batch endpoint
await client.projects.getBatch(projectIds); // ✓ Single request

Increasing Limits

Need higher limits? Upgrade to Pro or contact us for Enterprise plans.