Payment flow
The SDK provides a unified payment experience: customers complete transactions using multiple payment methods within a single integration. The diagram below illustrates the main payment workflow.RequestResponseSuccess
Payment flow steps
- Merchant Server:
Create Customerβ Yuno Server:Creates Customer - Merchant Client:
Initiate Checkoutβ Merchant Server:Create Checkout session - Merchant Server:
Create Checkout sessionβ Yuno Server:Creates Checkout session - Merchant Client:
Initiate CheckoutβInitiate SDKto continue payment flow - Merchant Client:
Initiate SDKto continue payment flow β Yuno SDK:Receive checkout session - Yuno SDK:
Receive checkout sessionβList payment methods - Yuno SDK:
List payment methodsβ User selects payment methods - Yuno SDK: User selects payment methods β Callback with the
one-time token - Yuno SDK: Callback with the
one-time tokenβ Merchant Client: Receiveone-time token(single use) - Merchant Client: Receive
one-time token(single use) βInitiate payment - Merchant Client:
Initiate paymentβInitiate SDKto continue payment flow - Merchant Client:
Initiate SDKto continue payment flow β Yuno SDK:Continue with the payment flow - Yuno SDK:
Continue with the payment flowβ Show screen for the user to complete payment - Yuno SDK: Show screen for the user to complete payment β Display
payment result(optional) - Merchant Client:
Initiate paymentβ Merchant Server:Create payment - Merchant Server:
Create paymentβ Yuno Server:Creates paymentin the payment provider
Payment flow using a vaulted token
If a customer has an enrolled payment method, they can use a vaulted token to pay without entering payment details again.RequestResponseSuccess
Vaulted token flow steps
- Merchant Client:
Initiate checkoutβ Merchant Server:Create Customer - Merchant Server:
Create Customerβ Yuno Server:Create Customer - Merchant Client:
Initiate SDKwith thecheckout sessionβ Yuno SDK:Receive checkout session - Yuno SDK:
Receive checkout sessionβList payment methods - Yuno SDK:
List payment methodsβ User selects payment methods - Yuno SDK: User selects payment method β Callback with the
one-time token - Yuno SDK: Callback with the
one-time tokenβ Merchant Client:Initiate payment - Merchant Client:
Initiate paymentβ Merchant Server:Create payment - Merchant Server:
Create paymentβ Yuno Server:Creates paymentin the payment provider - Merchant Client: Show
payment resultβ Merchant Server:Receive payment result - Merchant Server:
Receive payment resultβ Yuno Server: Providespayment result
Enrollment flow
Enrollment is the process of saving a payment method (e.g. a card) to a customerβs account so it can be used later (e.g. with a vaulted token). full-checkout supports enrollment; the diagram below describes the enrollment workflow.RequestResponseSuccess
Enrollment flow steps
- Merchant Server:
Create Customerβ Yuno Server:Creates Customer - Merchant Client:
Add payment methodβ Merchant Server:Create customer session - Merchant Server:
Create customer sessionβ Yuno Server:Creates customer session - Merchant Client:
Display payment methods to enrollβ Merchant Server:Request available payment methods to enroll - Merchant Server:
Request available payment methods to enrollβ Yuno Server:Returns available payment method - Merchant Client:
Display payment methods to enrollβ Merchant Client: User selects payment method to enroll - Merchant Client: User selects payment method to enroll β Merchant Client:
Initiate enrollment - Merchant Client:
Initiate enrollmentβ Merchant Client:Initiate SDKto continue enrollment - Merchant Client:
Initiate SDKto continue enrollment β Yuno SDK:Continue enrollment flow - Yuno SDK:
Continue enrollment flowβ Yuno SDK: Shows screens for the user to complete enrollment - Merchant Server: Receive
enrollment resultvia webhook β Yuno Server: Receiveenrollment resultsfrom payment provider - Yuno Server: Receive
enrollment resultsfrom payment provider β Yuno SDK: Displayenrollment result(optional)
Headless SDK flow
The Headless SDK provides maximum flexibility by allowing you to manage the entire user interface while Yuno handles the complex payment logic and security (like 3DS).RequestResponseSuccess
Headless flow steps
- Merchant Server:
Create Customerβ Yuno Server:Creates Customer - Merchant Client:
Initiate Checkoutβ Merchant Server:Create Checkout session - Merchant Client:
Collect Informationβ User enters card/payment details in your custom UI. - Merchant Client:
Generate Tokenβ Yuno SDK: CallgenerateToken(details)to receive aone-time token. - Merchant Client:
Process Paymentβ Merchant Server: Sendone-time tokento your backend. - Merchant Server:
Create Paymentβ Yuno Server: Call Create Payment API. - Merchant Client:
Handle Actionsβ If API response returnssdk_action_required: true, use the SDK to handle 3DS or other Payment Actions.