For the complete documentation index, see llms.txt. This page is also available as Markdown.

dApp Integration

Integrate Pay with Rozo Wallet into your dApp using the window.rozo provider for gasless USDC transfers on Stellar.

When your dApp is opened inside the Rozo Wallet mobile app, the window.rozo provider is automatically injected into the WebView, giving users:

  • Gasless USDC payments — fees sponsored by OpenZeppelin Relayer

  • Biometric authentication — Face ID / Touch ID

  • No wallet setup — the user's Rozo Wallet is ready to go

Architecture

┌─────────────────────────────────────────────────────────────┐
│                     Your dApp (WebView)                      │
│                                                              │
│  1. Detect window.rozo                                       │
│  2. Build USDC transfer transaction                          │
│  3. Call window.rozo.signAuthEntry()                         │
└──────────────────────────┬──────────────────────────────────┘
                           │ postMessage

┌─────────────────────────────────────────────────────────────┐
│                  Rozo Wallet App (Native)                    │
│                                                              │
│  4. Show confirmation modal → User approves                  │
│  5. Biometric authentication → Face ID / Touch ID            │
│  6. Sign with Passkey → Submit to Relayer (gasless!)        │
│  7. Return { hash, status, signedAuthEntry }                 │
└─────────────────────────────────────────────────────────────┘

Quick Start

1. Detect Rozo Wallet

2. Get Wallet Info

3. Build USDC Transfer Transaction

4. Simulate to Get Auth Entries

5. Extract Host Function XDR

6. Sign and Submit via window.rozo

What Happens in the Wallet

When you call window.rozo.signAuthEntry():

  1. Confirmation Modal appears showing the description, recipient, amount, and network

  2. User clicks "Confirm" — or cancels (throws "User rejected the signing request")

  3. Biometric Authentication — Face ID / Touch ID (cannot be bypassed)

  4. Sign with Passkey — signs in secure enclave, private key never exposed

  5. Submit to Relayer (when submit: true) — OpenZeppelin Relayer sponsors gas fees

  6. Return Result:

Complete Example: Vanilla JavaScript

React Example

Key Points

Always Use submit: true

This submits via OpenZeppelin Relayer, making transactions gasless for users.

Amount Conversion

USDC on Stellar has 7 decimals:

Amount
Stroops

1.00 USDC

10,000,000

10.50 USDC

105,000,000

Error Handling

Network Detection

Testing

  1. Install Rozo Wallet mobile app (iOS/Android)

  2. Start your dev server with HTTPS:

  3. Open your app in Rozo Wallet's Explore tab

  4. Test on testnet first before mainnet

Last updated