This page will contain an exhaustive list of all functions we can call using the SDK.

If you want to take a look at the SDK code in more detail then you can check these functions out here on Github.

Function NameDescription
supportedNetworks()Returns which networks this version of the SDK currently supports.
destroy()Destroys the SDK object.
signMessage()Signs a message using the Etherspot wallet.
createSession(dto: CreateSessionDto = )Creates a session for the initialised SDK.
getCounterFactualAddress()Gets the address of the Etherspot wallet created.
estimate(gasDetails?: TransactionGasInfoForUserOp)Returns the estimated amount of gas a transaction will cost.
totalGasEstimated(userOp: UserOperationStruct)Returns the estimated amount of gas a batch of transactions will cost.
getGasFee()Returns the current gas fee for the network.
send(userOp: UserOperationStruct)Sends a struct of signed UserOps to the bundler.
getNativeBalance()Returns the native token amount of the Etherspot wallet.
getUserOpReceipt(userOpHash: string)Returns the receipt of a UserOp processed by the bundler.
getUserOpHash(userOp: UserOperationStruct)Returns the hash of a UserOp processed by the bundler.
addUserOpsToBatch(tx: UserOpsRequest)Adds a UserOp to the batch before sending.
clearUserOpsFromBatch()]()Clears the batch.
getAccountContract()]()Returns the Etherspot smart contract for the Etherspot smart wallet.
getFiatOnRamp(params: OnRamperDto = )Links a user to the OnRamper widget based off of parameters passed in.