Interview practice question
Huge requests take down the API
Backend Engineering · Auth and Security · Intermediate
An attacker sends requests with very large page sizes and huge JSON bodies, and your API slows down for everyone. How do you protect it?
What a strong answer covers
Your AI report card counts how many of these ideas you cover.
- Unrestricted resource consumption.
- Cap page size and body size.
- Rate limit per user/IP.
- Timeouts on queries.
- Limit nesting/complexity (GraphQL).
Practise this topic
Start without signing up. Sign in free to get an AI report card on your answer.