Redirect
Integration flow for Redirect module
(Optional) Create a
Customer
Create a customer object and pass it to your server if you want to save your customer's details and attach payment information to them. (This step is compulsory when you process recurring payment for a new customer)
From your server, access Airwallex API to Create a Customer API
Create a
PaymentIntent
Your client app will need a
PaymentIntent
to form a payment session for Airwallex SDK to present payment flow.From your server, access Airwallex API to Create a Payment Intent API and pass the
PaymentIntent
returned to client app.Create an
AWXOneOffSession
with thePaymentIntent
created in the previous step, areturnURL
to your app, and shipping address and shopper country code of this order.objectivecPresent payment flow by with the
Session
created in the previous step, Airwallex SDK will handle the rest of the payment process and let you know when the payment flow is completed or cancelled.objectivecQuery and present payment result
After the
PaymentIntent
is confirmed by SDK, this delegate will be called by the SDK automatically and you can check the status to see whether the payment process has been completed or not.objectivecNote that a completed flow does NOT imply a successful transaction, you need to query the payment result afterwards through your server to know whether the order is paid or not. Inside
AWXPaymentResultDelegate
, ask your server to retrieve thePaymentIntent
.On your server, retrieve the Payment Intent API, get the payment result within it and pass it to the client app.