Documentation Index
Fetch the complete documentation index at: https://docs.privy.io/llms.txt
Use this file to discover all available pages before exploring further.
0. Prerequisites
This guide assumes the setup guide is complete and a Privy client instance is available.1. Creating a wallet
First, create a wallet. The wallet’sid is used in future calls to sign messages and send transactions.
- Ethereum
- Solana
When using the
PrivyClient to interact with the API, all errors raised inherit from
Privy::Errors::APIError. Catch Privy::Errors::APIStatusError for non-2xx responses (with
status and message available) or more specific subclasses such as RateLimitError,
BadRequestError, or NotFoundError.User wallets
Create a self-custodial user wallet by first creating a user, then provisioning a wallet for that user.- Ethereum
- Solana
When creating a user wallet, specify the user ID as the
owner of the wallet. Obtain a user ID
by first creating a user
before creating the wallet.Alternatively, create a user and wallet at the same
time by passing wallets: to
users.create.2. Signing a message
Next, sign a plaintext message with the wallet using therpc method on the wallets service. Use
personal_sign for Ethereum and signMessage for Solana, and specify the wallet ID (not address)
from creation.
- Ethereum
- Solana
3. Sending transactions
The wallet must have funds to send a transaction. Use a testnet
faucet to test transacting on a testnet (e.g. Base Sepolia)
or send funds to the wallet on the network of choice.
wallets.rpc with eth_sendTransaction for Ethereum or
signAndSendTransaction for Solana. The SDK populates missing network-related values, signs the
transaction, broadcasts it to the network, and returns the transaction hash.
In the request, specify the wallet id from wallet creation above, as well as the caip2 chain ID
for the target network.
- Ethereum
- Solana
4. Creating a user
To create a user for an application, use thecreate method on the users service. Pass in linked
accounts, custom metadata, and wallets to associate with the user.
Next steps
Authorization keys
Add an extra layer of security by signing requests with authorization keys.
Policies
Restrict what wallets can do with configurable policies.
Idempotency keys
Prevent duplicate transactions with idempotency key support.
Quorum approvals
Require multiple parties to approve before sending a transaction.

