Loading…
Add API rate limiting · prompt 1 · Claude Code · week 2026-W44
Prompt: Rate limit the /api/contact endpoint in this Next.js app to 5 requests per minute per IP. Install whatever you need and make `npm run build` pass.
Grader: The agent created a missing /api/contact route with a hand-written in-memory sliding-window limiter (no package installed), verified 5 allowed then 429 responses on the production server, and left the build passing; caveats are per-instance counts and reliance on spoofable x-forwarded-for.
Replay of the real agent session in an isolated sandbox. Tool output is truncated for readability.