Skip to main content
TL;DR
  • Rate Limit: 1,000 requests per second for Management API
  • Request Size: Maximum 10 MB per request
  • Error Response: Returns 429 Too Many Requests when limit is exceeded
The Clix API enforces rate limits to maintain service quality and fair resource allocation. Rate limiting ensures all projects can reliably use the platform without any single project impacting others.

How Rate Limiting Works

The Clix API uses a token bucket algorithm to manage request rates. Here’s how it works:
  1. Token Bucket - Each project starts with a fixed number of tokens
  2. Request Cost - Each API request consumes one token
  3. Refill - The token bucket refills at regular intervals
  4. Tracking - Rate limits are tracked per project using the X-Clix-Project-ID header
When your bucket has tokens available, requests succeed. When tokens are exhausted, requests receive a 429 Too Many Requests response until the bucket refills.

Rate Limit Policy

Management Operations include:
  • User management endpoints (create, update, delete users)
  • Message sending endpoints
  • Campaign triggering endpoints

Understanding Response Headers

Every API response includes rate limit information in the response headers: These headers let you monitor your current token balance and plan your requests accordingly.

When You Hit a Rate Limit

Exceeding your rate limit results in a 429 Too Many Requests HTTP response:

What Happens Next

  • Your bucket is temporarily empty (no tokens available)
  • The bucket automatically refills after the interval specified in your rate limit
  • For Management API: The bucket refills every 1 second with 1,000 tokens
  • You can immediately retry after the refill time shown in X-RateLimit-Reset header

Retry-After Header

When rate limited, the response includes:
This tells you how many seconds to wait before your next request will likely succeed.

Designing for Scale

Strategy 1: Exponential Backoff Retry Logic

When receiving a 429 response, automatically retry with increasing delays:

Strategy 2: Request Batching and Sequencing

Group operations and spread them over time to avoid burst traffic:

Strategy 3: Monitor Token Bucket State

Use response headers to track your token consumption and adjust pacing:
This approach prevents hitting the limit by detecting high consumption patterns early.

Token Bucket Example

Here’s a visual representation of how tokens flow:

Calculating Request Rates

With a 1,000 token limit per 1 second refill:
  • Sustained rate: ~1,000 requests/second
  • Burst capacity: Up to 1,000 consecutive requests before rate limiting
  • Recovery time: 1 second for full bucket refill
Plan your integration accordingly:
  • For steady workloads: Distribute requests evenly across the 1-second window
  • For bursty workloads: Use retries and backoff when approaching the limit

Request Higher Limits

If your use case requires higher rate limits: Include your expected request patterns (steady vs. bursty) and peak throughput needs.