Token API Quickstart
A new developer’s guide to using the Token API and getting token information. Query Token data using alchemy-web3 (recommended) or fetch.
How to Query the Token API
Fetch
You can easily interact with Alchemy’s Token API using simple fetch requests. No additional dependencies required with Node.js 18+.
Usage
shell
And then paste the following code snippet into the file:
token-api-script.js
From your command line, you can execute the script with:
shell
You should see output like this:
shell
Usage
token-api-javascript-scripts/fetch-script.js at main · alchemyplatform/token-api-javascript-scripts
shell
and then paste the following code snippet into the file to explore the getNFTs
method:=
fetch-script.js
From your command line, you can execute the script with:
shell
Your output should look like the following:
json