Goal
In this guide, you will:- Initialize the SDK
- Mount wallet buttons and card fields
- Run 3D Secure when required
- Forward encrypted payment data to your backend
1. Initialize Rinne
checkout.ts
2. Mount Payment Elements
Mount wallet buttons for Apple Pay and Google Pay, and a card element for manual entry.checkout.ts
If you omit
currency and country, the SDK defaults to BRL and BR.3. Handle Card Submission with 3DS
This example follows the session-first pattern: create a 3DS session, authenticate, then create the transaction. When the customer submits the card form, read the encrypted values, run authentication by mounting the 3DS element, and create the transaction after authentication succeeds. Mounting is what runs the authentication — the element resolves frictionless flows silently and shows the issuer’s challenge only when one is required.checkout.ts
create3DSSession and createTransaction represent calls to your backend. Rinne also supports a transaction-first pattern where you create the transaction before authentication. See the Card + 3DS Guide for both flows with full backend examples.4. Verify Success
Your checkout is correctly wired when:
- Wallet authorization triggers
onCaptureand your backend receives an encrypted payload - Card submission creates a 3DS session, mounts the 3DS element to authenticate, and creates the transaction with the authenticated session ID after
onSuccess fail()is called whenever wallet backend processing fails
Next Steps
Card + 3DS Guide
Explore session-first and transaction-first flows for production card payments.
Wallet Guide
Build the backend endpoint that processes wallet capture payloads.
Card Element
Configure themes, validation events, and field options.
3D Secure Element
Handle modal vs embedded challenges, retries, and session expiry.

