SpinTheMic
Pro

Interview practice question

Duplicate orders from mobile retries

Backend Engineering · API Design · Intermediate

Mobile users on bad networks sometimes create duplicate orders when they tap "Pay" and the app retries. How do you fix it in the API?

What a strong answer covers

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

  • Idempotency-Key per checkout attempt.
  • Server dedups by key.
  • Return original response on retry.
  • Client generates key once and reuses.
  • Unique constraint as safety net.
Practise this topic

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

See all topics