Node Package Manager (npm) is required to start using this API. You can install npm here. Installing nodejs will automatically install npm.
📄️ Account Generation
On this page, we'll cover how to generate a new account on the AVN.
There are two networks you can interact with Mainnet and Testnet. The testnet is designed to be an environment where you can test your code before deploying it on the mainnet; the mainnet is for production ready code as it has real world effects.
Before running any script with the avn-api, let's set your AvN mnemonic or secret seed generated via the accounts page. There are two ways you can set this:
Now that we have the API installed, we can initialise the API. There are two ways to initialise the API:
Only required if using JSON-RPC
📄️ Set up Complete
Now, let's test our setup and verify that we query blockchain successfully: