Skip to main content
Non-custodial wallets support multiple authentication flows. Each method resolves the wallet for the authenticated identity. If your app supports account linking, linked identities can access the same wallet.

Social login

Social login is the recommended flow for consumer-facing fintechs and payment apps. Users authenticate via their existing Google account. No password or seed phrase is involved. Use the SDK’s default Google redirect flow when your app can authenticate through a browser redirect. Mobile apps start the redirect, open the returned authorization URL, and complete authentication from the deep-link callback URL.
const result = await oms.wallet.signInWithOidcRedirect({
  provider: 'google',
})

if (result && 'walletAddress' in result) {
  console.log('Wallet address:', result.walletAddress)
}
On first login, OMS Wallet creates or resolves the wallet for the provider identity and returns the active wallet.

Email OTP

Email OTP is ideal for financial products where users may not have a social account or prefer not to link one. The user enters their email, receives a one-time code, and the wallet is created on verification.
await oms.wallet.startEmailAuth({ email: 'user@example.com' })

const result = await oms.wallet.completeEmailAuth({ code: '123456' })

console.log('Wallet address:', result.walletAddress)
The SDK handles the full OTP flow. No additional backend is required for email OTP.

Checking sign-in state

if (oms.wallet.session.walletAddress) {
  console.log('Signed in:', oms.wallet.session.walletAddress)
} else {
  console.log('Not signed in')
}