Every key has two limits, configured when it’s issued:

LimitDefault valueWhen exceeded
Per minute120 requests per minute429 with Retry-After until the window frees up
Monthly quota (optional)No quota, unless your contract sets oneWarnings when thresholds are crossed and, depending on the contract, 429 until the next period

If your volume needs more, ask for it during onboarding or from support: the limit is adjusted per key.

Headers #

Responses report the state of your current window:

HTTP
RateLimit-Limit: 120
RateLimit-Remaining: 87
RateLimit-Reset: 23
RateLimit-Policy: 120;w=60
HeaderMeaning
RateLimit-LimitRequests allowed in the window.
RateLimit-RemainingHow many you have left.
RateLimit-ResetSeconds until the window resets.
RateLimit-PolicyPolicy applied (quota and window w= in seconds).
Retry-AfterOnly on 429: seconds to wait before retrying.

A 429 arrives as problem+json with type: https://errors.compense.co/gateway/rate-limited.

How to respond to a 429 #

The SDKs retry 429s on reads (and on writes if you enabled retry_writes), honoring Retry-After (Retries). If the attempts run out, you get the exception with the wait time:

import time
from compense_gateway import RateLimitError

try:
    page = client.credits.list_applications(status="RECEIVED")
except RateLimitError as e:
    time.sleep(e.retry_after or 60)   # or requeue the job

Design to stay under the limit #

  • Batch bulk processes. To load affiliates use affiliates.cross (up to 1,000 per request) or the file upload, not one call per affiliate.
  • Webhooks instead of polling. Don’t check an operation’s status in a loop: subscribe to the event (Webhooks).
  • Bounded concurrency. Limit how many workers call the gateway at once and use a queue with deferred retries.
  • Cache stable reads (biller catalog, top-up carriers, health catalog): they change rarely, so don’t request them on every transaction.

Size limits #

WhatLimitWhen exceeded
JSON request body1 MB413
Affiliates file (multipart/form-data)25 MB413
affiliates.cross batch1,000 records per request422
page_size / limit100Capped at 100