@rhinestone/1auth version 0.10.2.
Read the active account
Read the selected address without opening a connection dialog. Disable signing and transaction actions when no account is connected.wallet.ts
Sign a message
Callpersonal_sign with a hex-encoded message and the selected address:
eth_signTypedData_v4 or viem’s signTypedData action through the same provider.
Send a transaction
Switch to the intended chain before submitting. This example sends ETH on Base; the external account needs enough ETH for both the transfer and gas.waitForTransactionReceipt action.
Batch transactions
For external accounts, the 1auth provider implementswallet_sendCalls as sequential transactions, not an atomic batch. Users may see multiple approval prompts, and earlier transactions can succeed even if a later one fails.
The external-wallet wallet_getCallsStatus response is not proof of onchain confirmation. Track transaction receipts when your application needs final settlement status.
Switch wallets and reconnect
Callwallet_connect again from your wallet-switching UI:
eth_accounts can report a remembered address, but it does not verify that the external connection is usable. Offer an explicit reconnect action when needed.
If you use createOneAuthConnection with your own picker, call connection.connect() instead. Host-provided external wallet connections are memory-only; your wallet integration must reconnect them after a reload.
Disconnect
createOneAuthConnection, use connection.disconnect() and clear any additional connection state owned by your wallet integration.