- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Idempotency Protection for payment requests
Does Authorize.net's API offer idempotency protection in some form?
I've seen idempotency protection in the form of unique ids in headers (e.g. Stripe), or in the form of some behind-the-scenes heuristics (i.e. Repay).
โ11-09-2021 12:39 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @DennisDang,
Authorize.net offer a duplicateWindow setting that can be set up to 8hours, this will prevent processing duplicate transactions within the set window. Read more on the Payment Transaction Developer Guide (Transaction Settings -> duplicateWindow), duplicate transactions requests will return error code 11.
Thanks
-Mansour
โ11-29-2021 08:10 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you @MansourH. I didn't realize I had double-posted. Sorry.
What data are you using to deduplicate? Is it a conglomerate of things? In addition to setting the duplicateWindow time, is there a unique constraint of sorts on txn refIds? If that's the case, I imagine duplicateWindow + unique refIds will serve me well enough.
โ11-29-2021 09:20 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
There are a bunch of fields that are validated for duplicate requests, I've included a link to error code 11 that list these fields:
https://developer.authorize.net/api/reference/responseCodes.html?code=11
Thanks
-Mansour
โ11-29-2021 09:52 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hey did you find out if refId could be use for the duplicate window?
I'm looking to use 1 of the fields in @MansourH 's link but it's not obvious wich of those fields can be a UUID generated by my application to ensure the idempotency of payments.
โ10-25-2023 11:00 AM