Free-Tier API Quota Rotation Architecture Across 3 Rolling Windows
Modern AI, search, scraping, and B2B providers distribute generous free tiers—but enforce tight per-minute, per-day, and monthly caps. FuelRouter pools 20 $0 free-tier upstreams across 5 domains and balances load proportionally to remaining quota headroom.
Aggregated $0 Free-Tier Capacity Across 5 Capability Pools
| Pool ID | Free $0 Accounts | Combined Free RPM | Combined Free RPD | Combined Free Monthly | Wholesale Overflow Tiers |
|---|---|---|---|---|---|
| ai_chat_json | 5 free slots | 140 RPM | 32,800 RPD | 984,000 / mo | 3 low-cost/standard ($0.0012-$0.0025) |
| embeddings_rerank | 3 free slots | 160 RPM | 9,000 RPD | 220,000 / mo | 3 low-cost/standard ($0.00025-$0.0006) |
| web_search | 3 free slots | 100 RPM | 800 RPD | 5,500 / mo | 3 low-cost/standard ($0.0008-$0.0015) |
| clean_scrape_extract | 4 free slots | 70 RPM | 1,320 RPD | 22,500 / mo | 2 low-cost/standard ($0.0015-$0.0022) |
| b2b_domain_dns_enrichment | 5 free slots | 120 RPM | 5,425 RPD | 103,200 / mo | 2 low-cost/standard ($0.0018-$0.0025) |
Exact Remaining-Quota Ratio Load Balancing
Naive round-robin rotation burns through a 5-RPM account at the same pace as a 60-RPM account, triggering avoidable HTTP 429 penalties. FuelRouter computes remaining_free_quota_ratio = min((rpm - rpm_used)/rpm, (rpd - rpd_used)/rpd, (monthly - monthly_used)/monthly) from rolling 60s, 86,400s, and 2,592,000s SQLite WAL windows.
Among equal-cost $0 candidates with comparable dynamic health scores, FuelRouter automatically routes to the slot with the highest remaining quota ratio, preventing single-account starvation.
Zero-Friction Spillover to Wholesale Fallback Under Budget Locks
When every free-tier account in a pool reaches its RPM, RPD, or monthly limit, FuelRouter seamlessly spills traffic to low-cost wholesale upstreams ($0.00025 to $0.0025 per unit)—provided spent_upstream_micros + unit_cost_micros stays within the caller's max_cost_micros lock.
Callers who want strictly free-tier-only execution can set max_cost_micros: 0 on test dispatches or inspect planned routes via POST /v1/router/quote.
Check Remaining RPM/RPD/Monthly Headroom Before Batch Jobs
curl -fsSL "https://fuelrouter.fastmesh.dev/v1/router/pools?pool_id=ai_chat_json"
# Inspect per-upstream quota_remaining:
# "quota_remaining": { "rpm": 30, "rpd": 14400, "monthly": 432000 }
Quota Rotation Best Practices
- Combine free-tier rotation with 7d-30d cross-tenant caching so repeat queries consume zero free-tier quota.
- Track all three windows simultaneously (60s RPM, 86,400s RPD, 2,592,000s monthly) to avoid silent monthly lockouts.
- Use SQLite WAL atomic commits so 20+ concurrent worker threads never oversubscribe a tight 5-RPM slot.
- Honor upstream Retry-After headers (capped at 300s) whenever an account hits an unannounced burst ceiling.
Frequently Asked Technical Questions
What happens as soon as an upstream hits 100% of its RPM or RPD quota?
The candidate eligibility filter skips that upstream automatically without sending a doomed HTTP request, rotating immediately to the next eligible free slot.
Does FuelRouter wait for a monthly reset before serving requests?
No. It rotates across the remaining free-tier slots and, once all free slots are full, falls back to low-cost wholesale slots within max_cost_micros.
How accurate is the sliding-window counter under high concurrency?
All dispatch commits execute inside thread-safe SQLite WAL transactions, verified under 20-thread concurrent stress testing with zero race errors.
Live Try-Now Console & Machine Discovery
Test failover routing, dry-run quotes, and circuit breaker metrics on the live gateway or connect via JSON-RPC 2.0 MCP.
Related FuelRouter Architecture Guides
- AI Chat & Structured JSON Inference Failover Pool (ai_chat_json) — structured JSON LLM inference failover pool
- Embeddings & Semantic Rerank Pool with 30-Day Adaptive Cache — embeddings and semantic rerank API failover cache
- Web Search & SERP Grounding Failover Pool (web_search) — web search SERP grounding API failover router