Use this file to discover all available pages before exploring further.
Render the MoonPay buy widget in your app and initiate a transaction with a quote signature. The quote must have executable: true. The widget handles the full purchase flow — including payment-method selection, verification, and transaction confirmation — inside a react-native-webview managed by the provider.
Setup widget
import { useMoonPay, type WidgetEvent,} from "@moonpay/platform-sdk-react-native";export function WidgetScreen({ quoteSignature }: { quoteSignature: string }) { const { client } = useMoonPay(); const start = async () => { const widgetResult = await client.setupWidget({ quote: quoteSignature, onEvent: (event: WidgetEvent) => { switch (event.kind) { case "ready": break; case "transactionCreated": console.log(event.payload.transaction); break; case "complete": console.log(event.payload.transaction); break; case "close": // The customer closed the widget break; case "error": console.error(event.payload.code, event.payload.message); break; } }, }); if (!widgetResult.ok) { // Handle error console.error(widgetResult.error.kind, widgetResult.error.message); return; } const widget = widgetResult.value; }; // ...}