Skip to main content

WalletNamespace

Wallet namespace that provides unified wallet operations

Methods

FunctionDescription
createSmartWallet()Create a new smart wallet
createSigner()Create a viem LocalAccount signer from the hosted wallet
toActionsWallet()Convert a hosted wallet to an Actions wallet
getSmartWallet()Get an existing smart wallet with a provided signer

createSmartWallet()

Create a new smart wallet Parameters:
ParameterTypeDescription
paramsCreateSmartWalletOptionsSmart wallet creation parameters
params.ownersArray of owners for the smart wallet (addresses or WebAuthn public keys)
params.signerLocal account used for signing transactions (must be in owners array)
params.nonceOptional nonce for smart wallet address generation (defaults to 0)
params.deploymentChainIdsOptional chain IDs to deploy the wallet to.
If not provided, the wallet will be deployed to all supported chains.
Returns: Promise resolving to deployment result containing:
  • wallet: The created SmartWallet instance
  • deployments: Array of deployment results with chainId, receipt, success flag, and error
Throws: Error if signer is not included in the owners array

createSigner()

Create a viem LocalAccount signer from the hosted wallet Parameters:
ParameterTypeDescription
paramsTToActionsMap[THostedProviderType]Configuration for the signer
Returns: Promise resolving to a viem LocalAccount with the hosted wallet as the signer backend

toActionsWallet()

Convert a hosted wallet to an Actions wallet Parameters:
ParameterTypeDescription
paramsTToActionsMap[THostedProviderType]Parameters for converting a hosted wallet to an Actions wallet
params.walletIdUnique identifier for the hosted wallet
params.addressEthereum address of the hosted wallet
Returns: Promise resolving to the Actions wallet instance

getSmartWallet()

Get an existing smart wallet with a provided signer Parameters:
ParameterTypeDescription
signerLocal account to use for signing transactions on the smart wallet
getWalletParamsWallet retrieval parameters
getWalletParams.deploymentOwnersArray of original deployment owners for smart wallet address calculation. Required if walletAddress not provided. Must match the exact owners array used during wallet deployment.
getWalletParams.signerOwnerIndexCurrent index of the signer in the smart wallet’s current owners array (used for transaction signing). Defaults to 0 if not specified. This may differ from the original deployment index if owners have been modified.
getWalletParams.walletAddressOptional explicit smart wallet address (skips address calculation)
getWalletParams.nonceOptional nonce used during smart wallet creation
Returns: Promise resolving to the smart wallet instance with the provided signer Throws: Error if neither walletAddress nor deploymentOwners provided

Wallet

Base actions wallet class

Namespaces

NamespaceTypeDescription
lendWalletLendNamespace<BaseLendConfig>Lend namespace with all lending operations

Properties

PropertyTypeDescription
addressAddressGet the address of this actions wallet
signerLocalAccountGet a signer for this actions wallet

Methods

FunctionDescription
getBalance()Get asset balances across all supported chains
send()Send a transaction using this actions wallet
sendBatch()Send a batch of transactions using this actions wallet

getBalance()

Get asset balances across all supported chains Returns: Promise resolving to array of token balances with chain breakdown

send()

Send a transaction using this actions wallet Parameters:
ParameterTypeDescription
transactionDataTransactionDataThe transaction data to execute
chainIdSupportedChainIdTarget blockchain chain ID
Returns: Promise resolving to the transaction hash

sendBatch()

Send a batch of transactions using this actions wallet Parameters:
ParameterTypeDescription
transactionDataTransactionData[]The transaction data to execute
chainIdSupportedChainIdTarget blockchain chain ID
Returns: Promise resolving to the transaction hash