Skip to main content
Headless enrollment was a pure-tokenization API: you collected the data in your own UI, called apiClient.continueEnrollment(collectedData, context), and got back a Map<String, Any?> with vaultedToken, customerSession, and status. In the unified API, headless enrollment is no longer a separate client. It’s the same Transaction.start(activity, paymentSelected) with transactionData set on the PaymentMethodSelected. The SDK runs the enrollment internally and reports completion through onStatus.

Before you start

  • Replace the com.yuno.sdk.* imports with their com.yuno.payments.sdk.api.* counterparts (the side-by-side lists them). Your public API key and the customer sessions your backend creates do not change (Before you begin).
  • There is no payment to create: createPayment is not invoked during enrollment, so overriding it has no effect.

Side-by-side

What changes

Grouped in the order you edit the code. Renamed: same role, new name. Moved: same value, new owner. Removed: nothing to call. New: no legacy counterpart. The last column is the only thing you have to do beyond the rename.

Initialization and config

Controller

Entry points