Wallets created through Privy can either be used directly from a user’s device or from a server. To allow wallets created on user devices to be used from the server, follow the guide below.

To provision a session signer for a user’s wallets, use the delegateWallet method from the useHeadlessDelegatedActions hook:

type delegateWallet = ({address: string, chainType: 'ethereum' | 'solana'}) => Promise<void>

Usage

import {useHeadlessDelegatedActions} from '@privy-io/react-auth';
const {delegateWallet} = useHeadlessDelegatedActions();

Parameters

The delegateWallet method accepts a params object with the following fields:

address
string

Address of the embedded wallet to delegate.

chainType
'ethereum' | 'solana'

Chain type of the embedded wallet to delegate.

In addition to a full whitelabel experience, Privy also offers a default UI component to prompt users to delegate their wallet and add a session signer. Learn more