crossmint_flutter_ui.dart.
CrossmintCheckoutConfig
Top-level configuration forCrossmintEmbeddedCheckout. Combines an order, payment method configuration, and optional appearance customization.
Props
Order to check out — either a [CrossmintCheckoutNewOrder] built from line items, or a [CrossmintCheckoutExistingOrder] referencing an already-created order by id.
Payment method configuration — fiat, crypto, and default method.
Optional appearance customization — CSS variables, rules, fonts.
Optional JWT for authenticated checkouts — attaches the user’s Crossmint session to the hosted page so the experience is signed-in when the user lands. Pass
client.auth.state.session?.jwt when you want the checkout to inherit the current app session.CrossmintCheckoutNewOrder / CrossmintCheckoutExistingOrder
Order configuration — either create a new order inline with line items, or resume an existing order by ID.Props
Line items in the order, each represented as a raw JSON map. Prefer the [CrossmintCheckoutNewOrder.typed] constructor and pass typed [CrossmintCheckoutLineItem] values; use the raw map shape only when a new API field is not yet modeled by the SDK.
Optional recipient for the order. When omitted, the hosted checkout collects recipient details from the buyer.
Optional BCP 47 locale tag (for example
en-US, es, pt-BR) used to localize the hosted checkout UI. Defaults to the buyer’s browser locale when null.Optional opaque metadata attached to the order. Forwarded verbatim to the Crossmint orders API and returned on order webhooks and status reads.
Usage
CrossmintCheckoutLineItem
A single asset to purchase in a checkout order. Use the named factory constructors:.collection(), .token(), .tokenWithExecutionParameters(), .product(), or .raw() for forward-compatible escape hatches.
Usage
CrossmintCheckoutPayment
Payment method configuration — at least one of fiat or crypto must be enabled. Controls which payment methods are shown and which is selected by default.Props
Fiat (card, Apple Pay, Google Pay) configuration — null disables the fiat tab entirely.
Crypto payment configuration — null disables the crypto tab.
Raw default payment method string. Prefer [defaultMethodType] for compile-time safety. When both are set, [defaultMethodType] wins.
Typed default payment method — one of [CrossmintCheckoutDefaultMethod]:
fiat (open on credit card / Apple Pay / Google Pay) or crypto (open on on-chain payment). Takes precedence over [defaultMethod].Email to receive the order receipt. Leave null to use the recipient email (for [CrossmintCheckoutEmailRecipient]) or rely on the user entering an email inside the hosted page.
CrossmintCheckoutFiatPayment
Fiat payment configuration — credit card, Apple Pay, Google Pay. Setenabled: false to hide the fiat tab entirely.
Props
Whether fiat payments are enabled.
ISO 4217 currency code preselected in the fiat tab (e.g.
"USD").When
false, hides the credit-card payment method. null keeps the project default.When
false, hides Apple Pay. null keeps the project default.When
false, hides Google Pay. null keeps the project default.CrossmintCheckoutCryptoPayment
Crypto payment configuration — on-chain payment via a connected wallet. Setenabled: false to hide the crypto tab.
Props
Whether crypto payments are enabled.
Chain preselected in the crypto tab (e.g.
"base", "solana"). Must appear in the payer’s [CrossmintCheckoutPayer.supportedChains] when a payer is attached.Currency preselected in the crypto tab (e.g.
"USDC").Optional app-side signer bridge. When null, the hosted page presents its own wallet-connect flow.
CrossmintCheckoutPayer
Interface for apps to provide crypto wallet signing capabilities. Implement this to bridge your wallet into the checkout. UseCrossmintEvmWalletCheckoutPayer for a ready-made EVM adapter.
Properties
Current wallet address.
Chain the wallet is initially connected on.
Chains the wallet can sign transactions on. The hosted checkout only offers chains that appear here.
Optional wallet provider identifier (e.g. “metamask”, “coinbase”). Returns null if not applicable.
Methods
Signs and broadcasts a serialized transaction. Return [CrossmintCheckoutTransactionSuccess] with the transaction id on success, or [CrossmintCheckoutTransactionFailure] with a user-facing message on failure.
Switches the wallet to [chain]. Called by the hosted page when the user changes chain in the UI.
Optional — return null if message signing is not supported.
CrossmintEvmWalletCheckoutPayer
Ready-made adapter that bridges aCrossmintEvmWallet into the checkout payer contract. Handles transaction signing and chain switching automatically.
Props
Usage
Recipients
Sealed type for who receives the purchased asset. Three variants:CrossmintCheckoutEmailRecipient, CrossmintCheckoutWalletRecipient, and CrossmintCheckoutPhysicalRecipient.
Usage
CrossmintCheckoutAppearance
UI customization for the hosted checkout page — CSS custom properties, rules targeting specific elements, and custom web fonts.Props
CSS custom properties for theming (e.g.
{'colorPrimary': '#0F172A'}).CSS rules for specific checkout elements (e.g.
{'.Input': {'borderColor': '#CBD5E1'}}).Custom font definitions (e.g.
[{'cssSrc': 'https://fonts.googleapis.com/...'}]).Usage
CrossmintCheckoutTransactionResult
Sealed result type fromCrossmintCheckoutPayer.signAndSendTransaction() — either CrossmintCheckoutTransactionSuccess (with txId) or CrossmintCheckoutTransactionFailure (with errorMessage).
CrossmintCheckoutDiagnostic
Structured runtime signal emitted by the embedded checkout widget. Covers blocked navigations, malformed messages, WebView resource errors, and console warnings/errors from the hosted page.Props
Short machine-readable identifier (e.g.
"navigation.blocked", "message.parse_failed").Human-readable description of the diagnostic.
Severity classification — one of [CrossmintCheckoutDiagnosticSeverity]:
info (interesting but not a problem, e.g. user closed the hosted modal), warning (likely recoverable — surface in dev / staging), error (hosted flow hit a problem that may affect checkout). Pass to logging infrastructure accordingly.Hosted-page event associated with this diagnostic, if any (e.g. the original postMessage event name that failed to parse).
URL associated with this diagnostic — set for navigation-related diagnostics (blocked navigations, resource errors).
Extra structured context for the diagnostic. Keys are stable — safe to forward to logging.

