useMoonPay() returns the SDK client made available by <MoonPayProvider>. Call it from any function component below the provider to access integration methods.
ConnectScreen.tsx
Return value
useMoonPay() returns an object with a single client property. The client exposes every integration method — see the MoonPayProvider reference for the full list.
Errors
useMoonPay() throws if called outside a <MoonPayProvider>: