SpinTheMic
Pro

Interview practice question

An API returns 100,000 rows

System Design · Scalability · Beginner

An endpoint returns all of a user's orders, and big customers have 100,000 orders. The API is timing out. What do you change?

What a strong answer covers

Your AI report card counts how many of these ideas you cover.

  • Add pagination with page size limit.
  • Cursor-based on created_at or ID.
  • Index supporting the sort.
  • Return only needed fields.
  • Offer async export for full data.
Practise this topic

Start without signing up. Sign in free to get an AI report card on your answer.

See all topics