Quick Start
Dappetizer is a framework for building Tezos indexer apps using TypeScript (or JavaScript). Its main strength is its versatility - it can be used to rapidly develop a simple smart contract indexer or collect particular block data, but also to index data from the entire blockchain or compose multiple indexers.
Before you start, you will need the following:
- SQLite CLI (to check the stored data). If you want to use Dappetizer with PostgreSQL, please also check our PostgreSQL guide to learn more.
For this example, we will create a simple app that tracks registrations of new domain names in Tezos Domains. Start by creating a new folder:
mkdir dappetizer-quickstart
cd dappetizer-quickstart
Install Dappetizer itself:
npm install @tezos-dappetizer/cli
npx dappetizer init --contractName=TezosDomains KT191reDVKrLxU9rjTSxg53wRqj6zh8pnHgr
- Indexers which can act on new contract calls or whole blocks. An indexer is automatically created for you when you run
dappetizer init
- The database entities that will be used by the indexers to store data.
TypeScript
src/entities.ts
import { commonDbColumns } from '@tezos-dappetizer/database';
import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm';