Rate Limits Guide
Shim enforces two types of limits: requests per minute and monthly repairs. Behavior differs by tier.Tier Limits
| Tier | Requests/Min | Monthly Repairs | Overage Behavior |
|---|---|---|---|
| Free | 100 | 1,000 | Throttle at 110% |
| Pro | 1,000 | 100,000 | Throttle at 110% |
| Team | 10,000 | 1,000,000 | Bill $0.30/1K over 110% |
Free and Pro Tiers
Grace Period (100-110%)
Continue at full speed. No degradation.Phase 1 Throttle (110-150%)
Throttle to reduced rate:- Free: 10 requests/min
- Pro: 100 requests/min
Phase 2 Throttle (150%+)
Hard throttle:- Free: 1 request/min
- Pro: 10 requests/min
Why Throttle?
Free and Pro tiers are fixed-price. Throttling prevents runaway costs while keeping your app online.Team Tier
Grace Period (100-110%)
Continue at full speed. No degradation.Metered Billing (110%+)
Full speed. Billed $0.30 per 1,000 repairs over 110%.Why Metered?
Team tier expects high volume. Metered billing scales with usage without throttling.Response Headers
Per-Minute Rate Limit
Standard rate limit headers on every response:Monthly Usage
Usage tracking headers on every response:X-Shim-Overage
Overage phase header (only present when usage exceeds 100%):Handling Rate Limits
Check Headers
Exponential Backoff
Alert on High Usage
Console Monitoring
View real-time usage in your console:- Go to console.shim.so
- Check usage meter
- View daily breakdown
Upgrading Tiers
Free → Pro
Increase limits:- 1K → 100K monthly repairs
- 100 → 1K requests/min
Pro → Team
Unlock metered billing:- 100K → 1M base limit
- 1K → 10K requests/min
- Overage billing instead of throttling
Best Practices
1. Monitor Usage Headers
CheckX-Shim-Usage on every request:
2. Cache Repairs
Avoid repairing the same output twice:3. Use Streaming for Large Outputs
Streaming doesn’t reduce repair count, but spreads requests over time:4. Set Alerts
Configure alerts at 80% and 100%:FAQ
Does streaming count as one repair or many?
One repair. A streaming session (start → push × N → finalize) counts as one repair.When do limits reset?
Monthly limits reset on your billing cycle date. View in dashboard.Can I request a limit increase?
Team tier is the highest standard tier. Contact sales for custom plans.What happens if I downgrade?
Limits adjust immediately. If over new limit, throttling applies.Next Steps
Authentication
View your API key and tier
Error Codes
Handle RATE_LIMIT_EXCEEDED
Upgrade
Upgrade your tier
Console
Monitor usage in real-time
