Getting started
The Token metadata API is a microservice with hard dependencies on other Stacks blockchain components. Before you start, you'll need to have access to the following:
- A fully synchronized Stacks node
- A fully synchronized instance of the Stacks Blockchain API running in
default
orwrite-only
mode, with its Postgres database exposed for new connections. A read-only DB replica is also acceptable - A local writeable Postgres database for token metadata storage
Run service
This section helps you to initiate the service by following the steps below.
Clone the repository by using the following command:
git clone https://github.com/hirosystems/token-metadata-api.git
Create a
.env
file and specify the appropriate values to configure access to the Stacks API database, the Token metadata API local database, and the Stacks node RPC interface. Seeenv.ts
for all available configuration options.Build the app (NodeJS v18+ is required)
npm install
npm run buildStart the service
npm run start