📌 Description
app.ts mounts two independent rateLimiter() instances: a default 30/minute limiter for all mutating requests, and a stricter 10/minute limiter mounted specifically on /api/v1/quote. This dual-limiter setup is only explained by a code comment in app.ts and isn't mentioned in the README, so integrators have no way to discover the tighter quote-specific limit without reading source.
🧩 Requirements and context
- Add a README section (or extend an existing rate-limiting section) explaining both limiters, their thresholds, and which routes each applies to.
- Mention the 429 response shape and that clients should implement backoff.
- Cross-reference
src/app.ts and src/middleware/rateLimiter.ts line/section names so the doc stays discoverable from source.
🛠️ Suggested execution
- Edit
README.md to add a "Rate limiting" subsection distinguishing the global and /api/v1/quote-specific limiters.
- Reference the exact defaults (
DEFAULT_MAX = 30, DEFAULT_WINDOW_MS = 60_000 in src/middleware/rateLimiter.ts, and the { max: 10, windowMs: 60_000 } override in src/app.ts).
✅ Acceptance criteria
🔒 Security notes
N/A — documentation only; improves integrator awareness of rate-limit thresholds relevant to abuse-prevention design.
📋 Guidelines
- Minimum 95% test coverage
- Clear documentation
- Timeframe: 96 hours
📌 Description
app.tsmounts two independentrateLimiter()instances: a default 30/minute limiter for all mutating requests, and a stricter 10/minute limiter mounted specifically on/api/v1/quote. This dual-limiter setup is only explained by a code comment inapp.tsand isn't mentioned in the README, so integrators have no way to discover the tighter quote-specific limit without reading source.🧩 Requirements and context
src/app.tsandsrc/middleware/rateLimiter.tsline/section names so the doc stays discoverable from source.🛠️ Suggested execution
README.mdto add a "Rate limiting" subsection distinguishing the global and/api/v1/quote-specific limiters.DEFAULT_MAX = 30,DEFAULT_WINDOW_MS = 60_000insrc/middleware/rateLimiter.ts, and the{ max: 10, windowMs: 60_000 }override insrc/app.ts).✅ Acceptance criteria
app.ts/rateLimiter.tsvalues.🔒 Security notes
N/A — documentation only; improves integrator awareness of rate-limit thresholds relevant to abuse-prevention design.
📋 Guidelines