mirror of
https://github.com/rssnyder/coingecko-cache
synced 2026-06-30 16:10:27 -05:00
No description
- Go 98.3%
- Makefile 1.7%
|
|
||
|---|---|---|
| .github/workflows | ||
| .gitignore | ||
| coingecko-cache.service | ||
| data.go | ||
| go.mod | ||
| go.sum | ||
| main.go | ||
| Makefile | ||
| README.md | ||
coingecko-cache
+--------------------+
|discord-stock-ticker|-----\
| |--\ ---------\
+--------------------+ -----\ ---------\
--> +-----+ ----> +---------+
|redis| |coingecko|
--> +-----+ ----> +---------+
+----------------+ -----/ ---------/
|coingecko-cache |--/ ---------/
| |-----/
+----------------+
a cache system for avoiding coingecko rate limits for crypto prices. uses the coins/markets endpoint documented here.
items are stored in redis under the keys <coin id>#<attribute>. requires you have a redis server running locally on port 6379.
stores info on the top 100 coins by market cap.
build
make build-<linux/osx>
run
-db int
redis db to use
-expiry int
number of seconds to keep entries in the cache (default 60)
-frequency int
seconds between updates (default 1)
-hostname string
connection address for redis (default "localhost:6379")
-pages int
number of pages (100 coin each) to pull from (default 1)
-password string
redis password
+ any additional args for coins to fetch individually
make run
install
make install
