Aarc is a set of tools built to simplify the use of smart accounts.Etherspot’s infrastructure is included within this tooling and available to use within it.In this tutorial we’ll learn how to use an Etherspot smart account with the Aarc SDK.We’ll setup the Smart Account in two steps using Aarc SDK:
Fetch the Smart Account address for the EOA.
Deploy and transfer native funds to the Smart Account.
Here, we provide the WALLET_TYPE.ETHERSPOT to fetch the Smart Account addresses associated with the EOA.
In the response, we will see the addresses associated with the EOA for Etherspot’s Smart Accounts.
No Smart Account may be deployed, so it will only generate and return the Smart Account address,
mentioning its deployment status and the walletIndex.
Deploy the Smart Account.
To deploy the smart account, use aarcSDK.transferNativeAndDeploy this will take a few parameters, as shown below.
deploymentWalletIndex and receiver can be fetched from the above response.
amount should be in hex string, which can be easily done by usingBigNumbers from ethers.