Skip to main content
The MobileDeposit class is the main entry point for the mobile SDK. It manages the signer call, in-app browser lifecycle, deep link handling, and completion detection.

Constructor

Creates a new MobileDeposit instance. Throws a DepositError with code INVALID_REQUEST if any required config field is missing or invalid.

MobileDepositConfig

appearance is read when the instance builds the hosted-flow URL. To change the theme, call destroy() and construct a new MobileDeposit.

Methods

requestDeposit

Opens the hosted deposit flow in an in-app browser. The returned Promise resolves when the user completes the payment (via deep link callback) and rejects with a DepositError on failure. The merchant must listen for incoming deep links and pass them to handleDeepLink() for the promise to resolve. If a flow is already active, calling requestDeposit again cancels the previous flow and starts a new one. See Types for DepositRequest and DepositResult definitions.
Feed an incoming deep link URL to the SDK. Returns true if the URL was a valid Blink callback and the SDK handled it, false if the URL did not match the expected callback pattern. Call this from your deep link listener (e.g. Linking.addEventListener('url', ...)).

on

Register an event listener. Returns this for chaining.

off

Remove a previously registered event listener. Returns this for chaining.

close

Cancel the current flow. Rejects the pending promise with DEPOSIT_DISMISSED.

focus

No-op retained for API compatibility with @swype-org/deposit.

destroy

Tear down the instance and release all resources. Clears all timers, removes all event listeners, and marks the instance as destroyed. Subsequent calls to requestDeposit will reject with INVALID_REQUEST. Call this on component unmount.

Properties

status

Current phase of the deposit flow. One of 'idle', 'signer-loading', 'browser-active', 'completed', or 'error'.

result

Last successful DepositResult, available when status === 'completed'.

error

Last DepositError, available when status === 'error'.

isActive

true when a deposit flow is in progress (status is 'signer-loading' or 'browser-active').