easysnap

EOS token snapshot tool

Usage no npm install needed!

<script type="module">
  import easysnap from 'https://cdn.skypack.dev/easysnap';
</script>

README

easysnap

EOS token snapshot tool

Install

$ sudo npm install -g easysnap

How to use

$ easysnap --code "eosio.token"

Javascript

import { snapshot } from "easysnap"

snapshot("eosio.token", 43000000).then(accounts => {
    for (const account of accounts) {
        console.log(account)
    }
})

Configure

Define your environment variables or create a .env file

.env

DFUSE_API_KEY="<API KEY>"
EOSIO_ENDPOINT="https://eos.greymass.com"
DFUSE_ENDPOINT="https://mainnet.eos.dfuse.io"
TOKEN_CODE="eosio.token"
TOKEN_TABLE="accounts"
BLOCK_NUMBER=42300000

CLI

$ easysnap --help

Usage: easysnap.ts [options]

EOS token snapshot tool

Options:
  -V, --version                    output the version number
  -c, --code <string>              token code
  -b, --block_num [number]         block number
  -m, --min_balance [number]       mininum token balance
  -o, --out [string]               filepath to save csv/json
  -e, --exclude_accounts [string]  exclude accounts (default: "")
  -u, --url [string]               http/https URL where nodeos is running
  --dfuse_api_key [string]         dfuse.io API key
  --eosdac [false]                 use eosDAC active members
  --json [false]                   save as JSON file
  --headers [false]                allow csv headers
  -h, --help                       output usage information

Examples:
  $ easysnap --code "eosio.token"