Skip to content

teddy-cash/stats

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Slurper

Slurps data from different places.

  • Covalenthq for historic event log data. Uses Elixir to query APIs
  • On-chain data via Nodejs + Ethers.js for circulating supply

Pushes static data in out/ to netlify site api.teddy.cash via netlify-cli.

Setup

On a VM install asdf with asdf plugin for node, yarn, elixir, erlang.

# install netlify-cli
yarn install
npx netlify login
npx netlify site (just api.teddy.cash)

# setup elixir
cd elixir
asdf install
mix deps.get

# setup node
cd node
yarn install

Then update the static data:

# in this order..
# out/v1/circulating-supply
# - is read out by elixir to generate final report.
# - is used by coingecko to update circulating supply

# Generate circulating supply:
cd node
node src/circulating-supply.js > out/v1/circulating-supply

cd elixir
mix teddy.apr
# updates out/data.json

Then deploy to netlify:

npx netlify deploy --dir=out/ --prod

OR do it all in one task!

yarn run deploy

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published