Global API
...
Request
Transaction
Create 3D Secure Transaction
2min
Note: This is currently only supported for the Stripe payment processor.
To create a Transaction in the Payment processor with 3DS secure authentication, please follow the below process:
- Call the "ChargeProcessor" action as you normally would. See here. This is the normal flow for any charge.
- If the related Payment method has 3D secure authentication enabled, the response will return an authenitcation_url.
- { "authentication_url" : "https://hooks.stripe.com/...", }
- The authentication_url is a link to a form that will do the 3D Secure authorization. This needs to be loaded in an iFrame hosted by you.
- After the 3DS authentication, Stripe will redirect to Breadwinner to process the success or failure of the authentication.
- After the completion of additional authentication, Breadwinner will post the payment_intent_id to your top-level page (the one hosting the iFrame)
- window.parent.postMessage({message: '3DS-authentication-complete', params: {payment_intent: payment_intent_id}, '*');
- You must extract payment_intent from postMessage and then retrieve the transaction with the "fetchTransaction" Global API action (example below). This will create the charge in Salesforce if successful or return a 402 error if the authentication fails.
Example of "ChargeProcessor" Global API action request and response for a 3DS credit card.
Example of "FetchTransaction" Global API action request and response for authentication success and failure.
Updated 01 Apr 2024
Did this page help you?