Skip to content
This repository has been archived by the owner on Dec 16, 2024. It is now read-only.

gokey #201

Closed
wants to merge 7 commits into from
Closed

gokey #201

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import bankFetcher from "./tokens/bank";
import bookFetcher from "./tokens/book";
import bubbleFetcher from "./tokens/bubble";
import c3Fetcher from "./tokens/c3";
import c4Fetcher from "./tokens/c4";
import cblpFetcher from "./tokens/cblp";
import cbtcFetcher from "./tokens/cbtc";
import cgiFetcher from "./tokens/cgi";
Expand Down Expand Up @@ -247,4 +248,5 @@ export const supplyFetchers: Record<string, SupplyFetcher> = {
nebulaFetcher,
bbd0ec94cf9ccc1407b3dbc66bfbbff82ea49718ae4e3dceb817125f24574f524b:
workFetcher,
a00fdf4fb9ab6c8c2bd1533a2f14855edf12aed5ecbf96d4b5f5b9394334: c4Fetcher,
};
32 changes: 32 additions & 0 deletions src/tokens/gokey.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
import { defaultFetcherOptions, SupplyFetcher } from "../types";
import { getAmountInAddresses, getBlockFrostInstance } from "../utils";

const GOKEY =
"c7dcfa416c127f630b263c7e0fe0564430cfa9c56bba43e1a37c6915474f4b4559";

const fetcher: SupplyFetcher = async (options = defaultFetcherOptions) => {
const blockFrost = getBlockFrostInstance(options);
const total = 4_500_000_000n;

const treasury = await getAmountInAddresses(blockFrost, GOKEY, [
"addr1wyehg40jpn90q6dsy9njxk8aek4xzqhg2shjyagnu6jzmsgvh30fu", // DripDropz
"stake1u8ffzkegp8h48mare3g3ntf3xmjce3jqptsdtj38ee3yh3c9t4uum", // TosiDrop
"addr1w8yk5vaq6rq3jgn84xurqjgy030j937dfpuu6m5tmkmpukst7amql", // Vyfi Farm
"addr1w8t7zc55cjc83lf7rhxam205vmf2arqttj37jpynuamjnxsk60vzs", // Vyfi Vault
"stake1u9f9v0z5zzlldgx58n8tklphu8mf7h4jvp2j2gddluemnssjfnkzz", // Minswap Farm
"addr1qyfpy8cqj4w9a7d44kg6hstqp5434f8m00hn4ymkgxgy2u4nskrrn9f56q03kvyt40u3r5vafmtjlh7zgvtlhgxzqjssq5hya9", // GoKey Community
"addr1qxsg35syleg2ysd7evgfjr8n753q7a49mu3nufgvgek07cpj5mu7h7n5ev343wprlueglj4fsuwat0nr23j5yfk3xhxqncy8hg", // GoKey DAO Treasury
"addr1qxmmh0g9cahu43zxdz27nav2e09y0mzfkevmxd9gv528lvhnclsdfjp3wdaw82zgly788jzdu54d7suqzan6x6spkdaste4q5t", // GoKey DEX Liquidity
"addr1qxj5ay8gcadlr5xgg3vsv68nrkq6vu3neyt2yy7lse3k3wkde9cvrey7ud9k485qqjjtltx8yszjmy8zjnmy7l4p2ahsp3g4d5", // GoKey ISPO
"addr1qxfhz6gy4rsd9pz3esn9mcgf6q3qkf3mkadqkdavpl4jkuenvmraumhjhzcqfm6al7cky7d9yyd6prdrvh7734zygxds06sf6e", // GoKey Partnerships
"addr1q8f6gn0fkeum3ukurzet8c5l34mmsqnflfljt6t2fcuhpunfn685c58vmdy4el29njklah5xprzq0358dta4c0l5j9rsqcq5sx", // GoKey Public Sale
"addr1q8q34p3pyrwlya5v5qrfahyxyh4nwrdtx74dptqhdv7dznmu6vhergtud4tkhvdtac9tucyju8uhhvk8dyanckmudqssg2axkg", // GoKey Team / Advisors
]);

return {
circulating: (total - treasury).toString(),
total: total.toString(),
};
};

export default fetcher;