Skip to main content
Version: 0.4

The End to End Guide For Transferring AVT between accounts on the AVN

This guide will walk you through successfully submitting a transaction to the AVN and verifying the state of the transaction.

The first thing we need to do is ensure that you have npm installed. You'll find instructions on how to do this here. You'll also find instructions on how to install the avn-api library. Once that'S done, the next step is to set up your Substrate uri (SURI) as an environmental variable here. Setting your environment variable makes things easier going forward.

Note, all transactions on the AVN must be paid for using AVT, so going forward it's important for you to have some AVT in your account. Uniswap is currently the best way to purchase AVT and this page provides instructions on how to get some. Note: You need 100 AVT in your account to use the API. The AVT needs to be lifted (moved) to the Aventus Network, and there are also instructions for that too here

Once you have some AVT in your account, of which you can check your account balance here, let's get to the exciting bit, submitting a transaction to the AVN. For this guide, we'll show a simple transaction submitting 10 AVT from one account to another.

const AvnApi = require("avn-api");
const GATEWAY = "<node_url>"; //Replace the node_url with the url received from Aventus.
const api = new AvnApi(GATEWAY);

// The AvN address of the relayer you will be using, as supplied by Aventus:
const AVN_RELAYER = "5FbUQ...";

// The AvN address of the account set as SURI in your environment:
const MY_ACCOUNT = "5Gv8Y...";

// The AvN address of the recipient account.
const RECIPIENT_ACCOUNT = "5ab310...";
async function main() {
const sender = MY_ACCOUNT;
const recipient = RECIPIENT_ACCOUNT;
const amount = "10";
const requestId = await api.send.transferAvt(

(async () => {
await main();

Expected Transaction Submission Output

Congratulations! You've now successfully submitted a transaction to the AVN.

State of the Transaction

To query the AVN on the state of the transaction:

let status = await api.poll.requestState(requestId);
console.log(`Current status: ${status}`);

Expected State Output

Current status: Processed