diff --git a/src/index.ts b/src/index.ts index a7ce86fb..0bc22522 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,3 +1,4 @@ +import fetFetcher from "./tokens/fet"; import aadaFetcher from "./tokens/aada"; import agcFetcher from "./tokens/agc"; import agixFetcher from "./tokens/agix"; @@ -100,6 +101,8 @@ export const supplyFetchers: Record = { vyfiFetcher, a0028f350aaabe0545fdcb56b039bfb08e4bb4d8c4d7c3c7d481c235484f534b59: hoskyFetcher, + 815418a1b078a259e678ecccc9d7eac7648d10b88f6f75ce2db8a25aa: + fetFetcher, dda5fdb1002f7389b33e036b6afee82a8189becb6cba852e8b79b4fb0014df1047454e53: gensFetcher, fbae99b8679369079a7f6f0da14a2cf1c2d6bfd3afdf3a96a64ab67a0014df1047454e5358: diff --git a/src/tokens/fet.ts b/src/tokens/fet.ts new file mode 100644 index 00000000..adfcc7b7 --- /dev/null +++ b/src/tokens/fet.ts @@ -0,0 +1,26 @@ +import { defaultFetcherOptions, SupplyFetcher } from "../types"; +import { getAmountInAddresses, getBlockFrostInstance } from "../utils"; + +const FET = + "815418a1b078a259e678ecccc9d7eac7648d10b88f6f75ce2db8a25a"; + +const fetcher: SupplyFetcher = async (options = defaultFetcherOptions) => { + const blockFrost = getBlockFrostInstance(options); + const total = 2e8; + const treasuryRaw = await getAmountInAddresses(blockFrost, FET, [ + "stake1uyyxjvthz4udwdrzr9pkkudpylasg99ufdzu7gpdfckxf2s5peell", // DEX funds + "stake1ux94pdq42nwx0g24ea3myjcnd8tvl354ku4ygedtgm7sfgc2hugz9", // Reserve funds + "stake1uxerycuwj09h2n6wydjp4vk936la23p9dvn37ezlkmdl5ycq38hr4", // Development funds + "stake1uypwcfxvg7uyzkyeue8fglq6fx7uxmampr2ahylyy4rg38cvky2pr", // Fraction Estate funds + "stake1ux7pa94sgkzd0yawsu9e9ddj0vr07psyezksfek24m9wn2qtjf62u", // Marketing funds + "stake1u8qzt94vyvfvvs4qan02axtfwj2hz4dcqefpehara5rdh4q6h9xka", // Founder - Daniel Johnsen + "stake1uy74mhj5x3jdf8d9446xcwrw723pvqelksxwwxu5c6t799qcnww0q", // Charity funds + ]); + const treasury = Number(treasuryRaw); + return { + circulating: (total - treasury).toString(), + total: total.toString(), + }; +}; + +export default fetcher; \ No newline at end of file