@swype-org/deposit-mobile) opens Blink’s hosted deposit flow in an in-app browser (SFSafariViewController on iOS, Chrome Custom Tabs on Android). The user completes payment inside the browser, and the result is returned to your app via a deep link callback.
Install
Quick start (vanilla)
React Native (Expo)
status, result, error, displayMessage, and isActive values, plus requestDeposit, handleDeepLink, focus, and close actions. It manages the MobileDeposit lifecycle and cleans up on unmount.
Deep link setup
Your mobile app must be configured to handle the callback URL scheme so the hosted flow can redirect back after payment.Expo / React Native
Inapp.json:
iOS (native)
Register your URL scheme inInfo.plist:
Android (native)
Add an intent filter inAndroidManifest.xml:
Handling deep links
The SDK does not set up deep link listeners itself. This keeps it platform-agnostic. Forward incoming URLs tohandleDeepLink():
handleDeepLink() returns true if the URL was a Blink callback, false otherwise.
Configuration
Dark and light mode
The hosted deposit flow ships both a light and a dark palette. Pick one with theappearance.theme config, which mirrors the web SDK:
Unlike the web SDK, the mobile SDK does not auto-detect a theme — there is no host page to read a
color-scheme from. If you do not pass appearance, the flow renders light even in a dark-mode app.Following the device theme
theme: 'system' is the right default for most apps. It resolves inside the in-app browser against the same OS setting React Native’s useColorScheme() reports, and it keeps tracking the device theme for the whole flow:
Following an in-app theme toggle
If your app has its own light/dark switch that can diverge from the OS setting, pass the resolved value explicitly. TheMobileDeposit instance reads the theme at construction, and the hook creates that instance once on first render — so changing the prop alone does nothing. Remount with a key:
deposit.destroy(), then new MobileDeposit({ ..., appearance: { theme } }).
In-app browser chrome
appearance themes the Blink UI inside the browser. The browser’s own chrome — the Safari View Controller bar on iOS, the Custom Tabs toolbar on Android — is not controlled by the SDK. Style it through your openUrl implementation, for example WebBrowser.openBrowserAsync(url, { toolbarColor, controlsColor }) with expo-web-browser.
In-app browser requirements
The hosted deposit flow uses WebAuthn passkeys for transaction signing. This requires a system browser component:- iOS: Use
SFSafariViewController(supports WebAuthn).WKWebViewdoes not support WebAuthn. - Android: Use Chrome Custom Tabs (supports WebAuthn).
WebViewdoes not support WebAuthn. - Expo: Use
expo-web-browser(WebBrowser.openBrowserAsync), which uses the system browser component on each platform.
Custom signer function
If you need full control over the HTTP call to your signer (custom headers, auth tokens, different HTTP method), pass a function instead of a URL:Status flow
Error handling
See Mobile Error Codes for the full reference. Every error is aDepositError with a machine-readable code:
Shared types
The mobile SDK sharesDepositRequest, DepositResult, TransferSummary, SignerRequest, SignerResponse, and SignerFunction types with the web @swype-org/deposit SDK. See Types for definitions.