Skip to main content

createCrossmintWalletSigner

Returns an EmbeddedOfframpPayer for a Crossmint wallet, such as the one useWallet() returns. It supports EVM and Solana wallets. It throws a plain error when the deposit was prepared for another chain or another wallet. That error leaves the user on the confirming screen, so mount CrossmintEmbeddedOfframp only while this wallet has the same address and chain as the session’s payer.

Usage


OfframpSignatureRejectedError

Throw it from a custom payer when the user declines the transaction and nothing was broadcast. The component reports wallet-rejected and lets the user confirm again.

Usage

Note: A payer for an external wallet. Throw OfframpSignatureRejectedError only when the user declined and nothing was broadcast.

EmbeddedOfframpCredentials

The sessionId and clientSecret that Create Offramp Session returns. Create the session on your server.

EmbeddedOfframpPayer

Signs and sends the deposit. Pass createCrossmintWalletSigner(wallet) for a Crossmint wallet, or your own object for an external wallet.

OfframpStatus

The step of the offramp flow, reported by onStatusChange. orderId can change during one withdrawal, so keep the latest.

OfframpErrorReason

Why onError fired. When retriable is false, the session cannot continue: unmount the component.