Requesting signatures
Wallets provisioned for session signers can be used to transact and sign messages on behalf of a user from your server. To get started, configure the NodeJS SDK or the REST API. This is how your application will make requests to the Privy API to sign transactions on behalf of users. The signing key you configured in the dashboard is the authorization signing key used to produce authorization signatures when submitting requests. Once you have configured the NodeJS SDK or REST API, your application can send or sign transactions from a users wallet. Follow the NodeJS or REST API guides in theUsing wallets
section to learn more about signing requests with wallets.
Getting wallets
From your server, you can query Privy to determine what wallets have been provisioned session signers by a given user to allow your app to take actions on their behalf.Use the Privy client’s To get a list of the user’s wallets with session signers, first find all of the user’s embedded wallets from the user’s linked accounts. Filter the This constitutes the user’s wallets with session signers. Wallets with session signers will always have the
getUser
method to get the user object for your user. As a parameter to this method, pass the user’s DID as a string
:user.linkedAccounts
array for wallet entries with type: 'wallet'
and delegated: true
:delegated
flag set to true
.For wallets included in this array, your app may make requests to Privy to execute actions on behalf of the user.