Skip to main content
On this page

Split card payments let a customer distribute one order across multiple cards in a supported DEUNA experience. The current public SDK examples configure two cards with behavior.paymentMethods.creditCard.splitPayments.maxCards.

See split payments in checkout#

The following demo shows a customer dividing one order across two cards in the DEUNA checkout experience:

Split Payments lets the customer allocate the order total across supported cards. Watch the demo directly on YouTube if the embedded player is unavailable.

Use the demo for visual orientation. Your backend must still reconcile every attempt and verify the overall order state before fulfillment.

Payment flow#

Flow diagram
1One merchant order2Card 1 amount andauthorization3Card 2 remainingamount andauthorization4-- Partial or failed5Verify final orderstate6Reconcile attemptsand show recovery
Merchant or customerException or stopResult or outcome
01 · order
Create one order
Keep totals and currency authoritative on the backend.
02 · widget
Enable two cards
Pass the split behavior to Payment Widget or Elements.
03 · customer
Allocate and submit
The experience validates amounts and processes the configured cards.
04 · backend
Reconcile all attempts
Fulfill only when the overall order reaches the required final state.

Enable the behavior#

await DeunaSDK.initPaymentWidget({
  orderToken,
  behavior: {
    paymentMethods: {
      creditCard: {
        splitPayments: {maxCards: 2},
      },
    },
  },
  callbacks,
});

Web and React Native type the behavior object. iOS and Android accept the same public shape as JSON. Keep key spelling and nesting exactly as shown.

Events and callbacks#

SignalUse
onCardBinDetected / onBinDetectedDetect the active card’s BIN without collecting raw card data.
onInstallmentSelectedAssociate the selected plan option with the card currently being configured.
paymentMethodSplitPaymentsNative Elements event indicating the split-payment path.
paymentProcessing / onPaymentProcessingLock duplicate actions while the combined operation is in flight.
purchase, purchaseError, purchaseRejectedClient lifecycle only; always reconcile the order and its attempts.

Do not reconstruct the financial result by summing client events. Use the current backend order and transaction records.

Failure and recovery#

Split payments can create a partial operational outcome: one attempt can reach a different state from another. Design the recovery path before enabling the feature.

ScenarioMerchant behavior
First card fails before another succeedsKeep the order open only if the current order state permits another attempt.
One card succeeds and the other failsReconcile both attempts; do not submit a new full-order payment blindly.
Customer closes mid-flowRetrieve the order before restoring payment options.
Client loses connectivityTreat the result as unknown until the backend responds.
Duplicate tap or retryReuse your operation controls and documented idempotency strategy.

Test matrix#

  • Two cards with exact allocation and supported currency precision.
  • Installments on an eligible card and no installments on an ineligible card.
  • Decline on the first and second card separately.
  • App backgrounding, refresh, or network loss between cards.
  • Customer closure after entering one card.
  • Slow authorization and repeated submit gestures.
  • Final webhook and API state matching the customer confirmation screen.