fetch
in JavaScript.axios
in JavaScript. You need to install axios
using npm install axios --save
in the terminal first.page
and limit
to do the pagination and set the limitation.
To get data printed, run command node <filename>.js
in the terminal. In this case, the return data looks as follows. Note that since this API only returns unsorted token holders, query result may vary every time. If you want to get the top token holders, you can try another API called getTopTokenHolders.