This starter project will get you started with everything you need to begin building a custom Subquery project for Acala/Karura. For more general information on Subquery check out their docs here.
Make sure you have the pre-requisite software installed by following the directions here.
- Clone this repo and install the dependencies by running
yarn
in the project directory - Update the custom type definitions for Acala, Karura, and Mandala in the
project.yaml
by runningyarn update-types
- Generate the schema types for use in your handlers by running
yarn codegen
- Build the project by running
yarn build
- Start the prooject by running
docker-compose pull && docker-compose up
Open your browser and head to http://localhost:3000
.
Write the following query into the query editor and press play. If you see data pop up on the right side then you're all set up!
query {
balanceTransferSummaries(first: 10) {
nodes {
id
totalTransferIn
avgTransferIn
totalTransferOut
avgTransferOut
}
}
}