QA Fundamentals · Senior · Question 30 of 76
How do you test idempotency of a payment API?
- 1Send many different requests and count the responses
- 2Repeat the request with the same key and check one charge
- 3Check that the API rejects every repeated request
Show the answer
Correct answer: Repeat the request with the same key and check one charge
Explanation
A retried request with the same idempotency key must return the original result without a second charge, including when retries happen concurrently.