thirdweb in-app wallet
Connector for thirdweb in-app wallets.
Import
ts
import { inAppWallet } from '@wagmi/connectors'
Usage
ts
import { createConfig, http } from '@wagmi/core'
import { mainnet, sepolia } from '@wagmi/core/chains'
import { inAppWallet } from '@wagmi/connectors'
import { createThirdwebClient } from 'thirdweb'
const client = createThirdwebClient({ clientId: "..." })
export const config = createConfig({
chains: [mainnet, sepolia],
connectors: [inAppWallet({ client, strategy: "google" })],
transports: {
[mainnet.id]: http(),
[sepolia.id]: http(),
},
})
Parameters
ts
import { type InAppWalletConnectionOptions } from 'thirdweb/wallets'
Check out the thirdweb developer portal for more info.
client
The ThirdwebClient
instance to use for authentication.
ts
import { inAppWallet } from '@wagmi/connectors'
import { createThirdwebClient } from 'thirdweb'
const connector = inAppWallet({
client: createThirdwebClient({ clientId: "..." }),
strategy: "google",
})
strategy
The strategy to use for authentication, options include "email"
, "phone"
, "google"
, "github"
. "discord"
and more.
ts
import { inAppWallet } from '@wagmi/connectors'
const connector = inAppWallet({
client,
strategy: "google",
})
Some strategies can have additional required parameters, check out the thirdweb developer portal for more info.