Rate Limiting¶
Known Constraints¶
HallMaster enforces server-side rate limiting. The exact limits are not documented, but from observation:
- Concurrent requests: Keep to 2-3 simultaneous requests
- Burst behaviour: Rapid sequential requests may trigger 429 responses
- Session limits: Excessive requests may invalidate the session
Recommended Practices¶
- Reuse sessions — Avoid logging in on every request. Use session persistence.
- Add delays — When making bulk requests, add a small delay between them.
- Retry with backoff — HMWrapper's client includes automatic retry with exponential backoff for 429 and 5xx responses.
- Cache where possible — Room lists, activity types, and price rates rarely change. Cache these locally.
HMWrapper Retry Behaviour¶
The HallmasterClient retries automatically on:
- 429 (Too Many Requests) — Retries up to
max_retriestimes with exponential backoff - 5xx (Server Error) — Same retry behaviour
- Connection errors — Retries on network failures
Configure via constructor:
client = HallmasterClient(
max_retries=5, # default: 3
retry_backoff=2.0, # default: 1.0 seconds (doubles each retry)
)