Skip to content
AxentroPublic

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

2 watching

Forks

Latest commit

 

History

14 Commits

Folders and files

Repository files navigation

Axentrojs

Axentro wallet and transactions using js/typescript

Create a wallet

import {StandardWallet, Network} from 'axentrojs';

const wallet = StandardWallet.create(Network.mainnet);
console.log(wallet.address());

Import/export a wallet from wif

import {StandardWallet} from 'axentrojs';

const wallet = StandardWallet.importFromWif("...");
console.log(wallet.address());
console.log(wallet.exportToWif());

Sign a transaction

import {StandardWallet} from 'axentrojs';

const wallet = StandardWallet.importFromWif("...");
wallet.signTransaction({...}, 0);
wallet.address();

Create a hd wallet

import {HdWallet, Network} from 'axentrojs';

const wallet = HdWallet.create(Network.mainnet);
wallet.signTransaction({...}, 0);
wallet.address();

Send token

import {StandardWallet, AxentroNode} from 'axentrojs';

const node = new AxentroNode('https://testnet.axentro.io/api/v1');
const wallet = StandardWallet.importFromWif("...");
// send 1 AXNT to address
const tx = wallet.createAndSignTransaction(100000000, "address");
await node.broadcastTransaction(tx);

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

2 watching

Forks

Releases

Packages

Contributors

Languages