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

Commit

Permalink
Added VIPER token
Browse files Browse the repository at this point in the history
  • Loading branch information
snekper committed Jan 15, 2024
1 parent 5187049 commit ed7877e
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ import sundaeFetcher from "./tokens/sundae";
import tedyFetcher from "./tokens/tedy";
import trtlFetcher from "./tokens/trtl";
import utilFetcher from "./tokens/util";
import viperFetcher from "./tokens/viper";
import vnmFetcher from "./tokens/vnm";
import vyfiFetcher from "./tokens/vyfi";
import wmtFetcher from "./tokens/wmt";
Expand Down Expand Up @@ -266,4 +267,6 @@ export const supplyFetchers: Record<string, SupplyFetcher> = {
gokeyFetcher,
b166a1047a8cd275bf0a50201ece3d4f0b4da300094ffcc668a6f4084b49545550:
kitupFetcher,
caff93803e51c7b97bf79146790bfa3feb0d0b856ef16113b391b9975649504552:
viperFetcher,
};
23 changes: 23 additions & 0 deletions src/tokens/viper.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import { defaultFetcherOptions, SupplyFetcher } from "../types";
import { getAmountInAddresses, getBlockFrostInstance } from "../utils";

const VIPER =
"caff93803e51c7b97bf79146790bfa3feb0d0b856ef16113b391b9975649504552";

const fetcher: SupplyFetcher = async (options = defaultFetcherOptions) => {
const blockFrost = getBlockFrostInstance(options);
const total = 76_715_880_000;
const treasuryRaw = await getAmountInAddresses(blockFrost, VIPER, [
"addr1q8hcfzrpjde5geldv4a2lx9njms24f5afge2pgryd7avueaejeq5ph79pnsgh798h05ffe08a0ueq6rtxpxrx8ntxq8sjksh9n", // airdrop_2
"addr1qydndhsnzlhxtzazl5y4jaup40kk0ucv3njhdjrt5pspan97qptktvzfzy40dnc6544xpfckwlf8kkentendpql7z89qlcp444", // airdrop_3
"addr1q9knde3r2wvhk8fjajchlfuh52k2jc2df65m9ymnxv4v85fkymz384ls0rwxwzx74xh4xc5adfrmhp9lr5m7p8gzmljq0s30ne", // devwallet
]);

const treasury = Number(treasuryRaw);
return {
circulating: (total - treasury).toString(),
total: total.toString(),
};
};

export default fetcher;

0 comments on commit ed7877e

Please sign in to comment.