Interacting with Your Tanssi Substrate Network Using SubWallet¶
Introduction¶
Developers and users of Tanssi-powered Substrate networks have a variety of options when it comes to wallets. SubWallet is a comprehensive Web3 wallet that natively supports Substrate (Polkadot) and Ethereum accounts. This tutorial centers on the Substrate API, but you can check out a similar tutorial for interacting with SubWallet using the Ethereum API.
The SubWallet wallet browser extension can be downloaded for all supported browsers, including Chrome, Brave, Firefox, and MS Edge. SubWallet also has a mobile app for both iOS and Android, but that is beyond the scope of this guide. A complete online asset dashboard is accessible at web.subwallet.app.
This guide takes you through all the necessary steps, from installing SubWallet to setting up a wallet, connecting it to your Tanssi Substrate network, and sending funds.
Creating Your First Substrate Account¶
First, download and install the SubWallet extension. Creating a new account will generate a seed phrase that can derive multiple Ethereum and Substrate accounts. By default, SubWallet will generate a single Ethereum and a single Substrate account, but you can easily derive more from the same seed phrase. Click Create a new account to get started.
On the following screen, you'll be prompted to create a password to secure your new wallet.
You'll then be prompted to back up your seed phrase. This is an important step, especially because you have the option to later derive additional accounts from this seed phrase.
Note
You should never share your seed phrase (mnemonic) or private key with anyone. This gives them direct access to your funds. This guide is for educational purposes only.
Importing an Existing Substrate Account¶
Of course, you can import an existing Substrate account into SubWallet. To get started, take the following steps:
- Press the All accounts button at the top
- Press the Import account icon
On the following screen, select the method by which you would like to import the existing account. If you're importing a Substrate account, you can choose from the seed phrase, Polkadot.js (JSON), or QR code options.
On the following screen, you'll be able to provide the relevant seed phrase, JSON file, or QR code, and you can begin using your new account right away.
Connecting SubWallet to the Tanssi Dancebox TestNet¶
SubWallet comes pre-configured with support for the Tanssi Dancebox TestNet, but it may not be enabled by default. You just need to head to the Manage networks page to toggle it on. Remember that the Tanssi Dancebox TestNet itself is the Substrate-based network that orchestrates and manages the launch of Tanssi-powered networks. To configure your SubWallet to work with Dancebox, press the More Options icon in the upper left corner. Then click Manage networks and take the following steps:
- Search for
Dancebox
- Toggle the slider on to enable support for Dancebox
If you have a balance of Dancebox tokens, you'll see your account balance on the homepage of the SubWallet wallet. By default, all balances are hidden in SubWallet, but if you press the eye icon, you can toggle balance visibility.
Connecting SubWallet to Your Substrate Network¶
To configure SubWallet for your Substrate network, press the More Options icon in the upper left corner. Then click Manage networks. Press the + icon. On the following page, you'll then be prompted to enter the network details for your Tanssi network. For demonstration purposes, the Tanssi Dancebox Parachain is used here, but you can substitute these details for your own Tanssi network. To add your Tanssi network to SubWallet, take the following steps:
- Paste in the WSS URL of your Tanssi network. Other parameters like the parachain ID and token decimals may be auto-populated
- Provide a name for your Tanssi network
- Press Save
Connecting to Polkadot.js¶
To connect your Tanssi Substrate network to Polkadot.js Apps, first head to Polkadot.js Apps. In this example, Polkadot.js Apps is connected to the Dancebox TestNet, but you can point Polkadot.js to your Tanssi network by clicking on the network dropdown and filling in the WSS endpoint of your Tanssi network in the custom endpoint field.
The SubWallet extension will prompt you to select the accounts you'd like to use with Polkadot.js Apps. If it doesn't automatically pop up, you can open the SubWallet extension and click on the Connected icon next to your account at the top. To configure SubWallet to correctly interface with your Tanssi network on Polkadot.js Apps, you should take the following steps:
- Select the Substrate account(s) that you'd like to use with Polkadot.js Apps
- Press Connect
Your SubWallet wallet is now connected to Polkadot.js Apps. After refreshing Polkadot.js Apps, you should see your SubWallet account in the Accounts page of Polkadot.js Apps underneath the extension heading.
Sending a Transaction¶
To send a transaction through the Substrate API, click Send next to your account on Polkadot.js Apps. Then, take the following steps:
- Input the send to address
- Enter the amount
- Press Make Transfer and confirm the transaction in the resulting Polkadot.js pop-up
- Press View Details if you'd like to inspect the contents of the transaction
- Press Approve to submit the transaction
You can also send a transaction through the Substrate API directly from the SubWallet extension without using Polkadot.js Apps. To do so, press the Send icon and take the following steps:
- Specify the asset to send
- Specify the destination chain (in this case, the same chain that you're sending from)
- Enter the destination address
- Enter the number of tokens to send
- Look over the transaction details, then press Transfer and subsequently Approve
This guide focused specifically on configuring SubWallet to work with your Tanssi Substrate network, but SubWallet is also a full-featured wallet for EVM accounts. Under the Ethereum API section, you'll find a similar guide for configuring SubWallet for use with your Tanssi EVM network.
| Created: October 19, 2023