Skip to main content
Version: 0.2

Transfer AVT

Transfer an amount of AVT from the sender account to the destination account.

await api.send.transferAvt(
avnRelayerAddress,
senderAddress,
recipientAddress,
amount
);
info

This operation uses a relayer account that the sender authorizes to submit the transfer transaction.
Contact us here to request a relayer address.

Example

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

const avnRelayerAddress = "5Fb...yTh"; //Please, request from Aventus.
const senderAddress = "bDB...9MH";
const recipientAddress = "5DA...gxV";
const amount = "123400000";

async function main() {
await api.init();

const result = await api.send.transferAvt(
avnRelayerAddress,
senderAddress,
recipientAddress,
amount
);
// Returns a request id
console.log(result);
}

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

You have now successfully submitted a transaction to the AVN.

Expected Output

f1710fe7-141f-43c1-b1bb-6ec33d9b3e9a