409
payments.duplicate_referencepaymentsRule R2A payment with this reference is already open or paid
reference is your own identifier for the thing being paid for, and paygate enforces that it is unique per tenant and mode across payments that are created, requires_action, processing or succeeded. A payment that expired, failed or was canceled releases its reference.
Why the API refuses
WHEN CreatePayment is executed with a reference, THE SYSTEM SHALL reject it if another payment of the same tenant and mode has the same reference and a status of created, requires_action, processing or succeeded.
What to do
- If you meant to retry the same call, retry it with the same
Idempotency-Keyinstead. Idempotent replay returns the original payment; a new key with a used reference is what produces this error. - If you meant a new payment for the same order (the payer abandoned the first and came back), fetch the open payment with
GET /payments?reference=<your reference>and show itsnext_actionagain rather than creating a second one. - If the first payment should be abandoned, cancel it —
payments.cancel_not_allowedcovers when you cannot.