Owners sign requests to the Privy API to take actions on a resource, like a wallet or a policy. Follow the guide below to learn how to sign requests to the Privy API.

If the desired resource has a user owner, make sure to request the user key before signing requests with it.

Privy’s NodeJS SDK automatically handles signing requests with your provided key. You can specify with key to sign with using the updateAuthorizationKey method of the Privy client.

Pass the base-64 encoded private key of your user key or authorization key into the Privy client’s updateAuthorizationKey method:

privy.updateAuthorizationKey('insert-base64-encoded-private-key')

The Privy client will now automatically sign requests to the Privy API with the provided key. You can simply use the privy.walletApi.ethereum.* and privy.walletApi.solana.* interfaces to take actions with wallets, and the SDK will automatically sign requests under the hood.