Gallantree Developer API

Rate limits

Every developer app is rate-limited by tier. The limits below apply per app, per environment, measured against a rolling 60-second window.

Tiers

Tier Requests per minute
Sandbox 60
Starter 300
Growth 1,000
Enterprise 5,000

Response headers

Every response carries three headers so you can throttle client-side:

Header Meaning
x-ratelimit-limit The tier limit (constant per app)
x-ratelimit-remaining Requests you can still make in the current window
x-ratelimit-reset Unix timestamp (seconds since epoch, UTC) when the window resets

Watch x-ratelimit-remaining in your client — if it hits 0, the next request will return 429 regardless of urgency.

When you're throttled

HTTP
HTTP/1.1 429 Too Many Requests
Retry-After: 27
x-ratelimit-limit: 300
x-ratelimit-remaining: 0
x-ratelimit-reset: 1755267600

{ "message": "Too many requests. Please try again later." }

Sizing your integration

If you're pulling data on a schedule, plan the polling cadence against your tier — a sync that lists every loan every minute at page-size 25 uses N/25 requests per run, so a 1,000-loan lender fits comfortably on Starter (40 requests, well under 300/min) but a 30,000-loan lender needs Growth or webhooks (see Subscribe to events).

Webhooks are almost always a better answer than polling — they don't count against your API rate limit, and they arrive within seconds of the underlying change.

Runnable example — client-side back-off

Shell
call() {
  response=$(curl -sS -w "\n%{http_code}" -D headers.tmp \
    "https://developers.gallantreecapital.com/api/v1/loans" \
    -H "x-api-key: $GALLANTREE_API_KEY")
  status=$(echo "$response" | tail -n1)
  body=$(echo "$response" | head -n -1)
  if [ "$status" = "429" ]; then
    wait=$(grep -i "^retry-after:" headers.tmp | awk '{print $2}' | tr -d '\r')
    echo "429 — sleeping ${wait}s"
    sleep "$wait"
    call
  else
    echo "$body"
  fi
}
call
Was this page helpful?

Built with Token Gesture