Skip to main content

UserWallet class

Connect and Interact with a user wallet

Example

const balance = await sdk.wallet.balance();

Constructors

ConstructorModifiersDescription
(constructor)(network, options)Constructs a new instance of the UserWallet class

Properties

PropertyModifiersTypeDescription
eventsEventEmitter<UserWalletEvents, any>

Methods

MethodModifiersDescription
balance(currencyAddress)Fetch the native or ERC20 token balance of this wallet
connect(network)
getAddress()Get the currently connected address
recoverAddress(message, signature)Recover the signing address from a signed message
sendRawTransaction(transactionRequest)Send a raw transaction to the blockchain from the connected wallet
sign(message)Sign any message with the connected wallet private key
signTypedData(domain, types, message)Sign a typed data structure (EIP712) with the connected wallet private key
transfer(to, amount, currencyAddress)Transfer native or ERC20 tokens from this wallet to another wallet

Signature:

export declare class UserWallet