Idempotency ensures that multiple identical requests to the Edge API have the same effect as making a single request. This is crucial for operations like payments or customer creation, where duplicate processing due to retries could cause unintended consequences, such as charging a customer multiple times.
requestId
header:
requestId
as the idempotency key, ensuring that even if the same request is sent multiple times, it will only be processed once.
Response (First Request):
unique-payment-id-123
) is a good approach.