Getting an EIP-1193 provider
All of Privy’sConnectedWallet
objects export a standard EIP-1193 provider object. This allows your app to request signatures and transactions from the wallet, using familiar JSON-RPC requests like personal_sign
or eth_sendTransaction
.
EIP-1193, also known as the Ethereum JavaScript API, is
a standardized interface for how applications can request information, signatures, and
transactions from a connected wallet.
- use the wallet’s EIP-1193 provider to send JSON-RPC requests to the wallet directly
- pass the wallet to a library like
viem
,ethers
, orwagmi
- for the embedded wallet specifically, use Privy’s native
signMessage
andsendTransaction
methods to customize the signature and transaction prompts for users
ConnectedWallet
object’s getEthereumProvider
method:
wagmi
or viem
.