Closed blugavere closed 5 years ago
👋 @blugavere, thanks for reaching out- we're going to pass on this request.
We're wary of adding retry logic like this to the SDK, as it has the potential to introduce scenarios where your customers get multiple authorization attempts for the same amount. This, in turn, could lead to unforeseen impacts on the number of disputes merchants receive, which can be costly.
There is some nuance in addressing unhandled exceptions and networking issues, and adding retry logic (even as an option) to the SDK might just be too blunt an instrument to address the very nature of these kinds of issues. We prefer merchants add their own logic for these scenarios and retry at their own discretion, or ask the customer to try a different payment method.
The api has duplicate transaction checking built in which handles your concern, so it shouldn't be an issue.
We still think this should be the sole responsibility of the merchant & customer to determine if a transaction should be retried, rather than done automatically by the SDK. Please reach out to our support team if you need help setting up your integration to do this. https://help.braintreepayments.com/
General information
Issue description
Feature request - for unhandled exceptions on the braintree server, networking issues, or just general retryable error responses, provide the option to automatically retry requests within your SDK.
https://developers.braintreepayments.com/reference/general/processor-responses/authorization-responses#code-3000