From 9a28e2742d5bde4981a631774c5fce1587dfdcd5 Mon Sep 17 00:00:00 2001 From: Robert Pieter van Leeuwen Date: Mon, 11 Dec 2023 12:15:27 +0100 Subject: [PATCH 1/3] coinecta circulating --- src/tokens/cnct.ts | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 src/tokens/cnct.ts diff --git a/src/tokens/cnct.ts b/src/tokens/cnct.ts new file mode 100644 index 00000000..dda2a63e --- /dev/null +++ b/src/tokens/cnct.ts @@ -0,0 +1,21 @@ +import { defaultFetcherOptions, SupplyFetcher } from "../types"; +import { getAmountInAddresses, getBlockFrostInstance } from "../utils"; + +const CNCT = + "c27600f3aff3d94043464a33786429b78e6ab9df5e1d23b774acb34c434e4354"; + +const fetcher: SupplyFetcher = async (options = defaultFetcherOptions) => { + const blockFrost = getBlockFrostInstance(options); + const total = 80_000_000; + const treasuryRaw = await getAmountInAddresses(blockFrost, CNCT, [ + "addr1qy0yswstqah6zwxvd5csh0gyty80pcpfqf0ghe24n798r07hdz6r6fp6z96rgh8dvu6yjx8smmany40anu8264r0ek3ssujtw9", + ]); + + const treasury = Number(treasuryRaw) / 10_000; + return { + circulating: (total - treasury).toString(), + total: total.toString(), + }; +}; + +export default fetcher; From 616f0ac5be234849361924c339f9575ff44b57de Mon Sep 17 00:00:00 2001 From: Robert Pieter van Leeuwen Date: Mon, 11 Dec 2023 12:31:10 +0100 Subject: [PATCH 2/3] add cnct to index --- src/index.ts | 2 ++ src/tokens/cnct.ts | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/index.ts b/src/index.ts index 441acc56..8b018d8c 100644 --- a/src/index.ts +++ b/src/index.ts @@ -14,6 +14,7 @@ import cgiFetcher from "./tokens/cgi"; import chryFetcher from "./tokens/chry"; import clapFetcher from "./tokens/clap"; import clayFetcher from "./tokens/clay"; +import cnctFetcher from "./tokens/cnct"; import cnetaFetcher from "./tokens/cneta"; import copiFetcher from "./tokens/copi"; import cswapFetcher from "./tokens/cswap"; @@ -249,4 +250,5 @@ export const supplyFetchers: Record = { bbd0ec94cf9ccc1407b3dbc66bfbbff82ea49718ae4e3dceb817125f24574f524b: workFetcher, a00fdf4fb9ab6c8c2bd1533a2f14855edf12aed5ecbf96d4b5f5b9394334: c4Fetcher, + c27600f3aff3d94043464a33786429b78e6ab9df5e1d23b774acb34c434e4354: cnctFetcher, }; diff --git a/src/tokens/cnct.ts b/src/tokens/cnct.ts index dda2a63e..f9ed95fe 100644 --- a/src/tokens/cnct.ts +++ b/src/tokens/cnct.ts @@ -4,7 +4,7 @@ import { getAmountInAddresses, getBlockFrostInstance } from "../utils"; const CNCT = "c27600f3aff3d94043464a33786429b78e6ab9df5e1d23b774acb34c434e4354"; -const fetcher: SupplyFetcher = async (options = defaultFetcherOptions) => { +const cnctFetcher: SupplyFetcher = async (options = defaultFetcherOptions) => { const blockFrost = getBlockFrostInstance(options); const total = 80_000_000; const treasuryRaw = await getAmountInAddresses(blockFrost, CNCT, [ @@ -18,4 +18,4 @@ const fetcher: SupplyFetcher = async (options = defaultFetcherOptions) => { }; }; -export default fetcher; +export default cnctFetcher; From 4fb27ebeb484358237ee7ddffa1671c14094136e Mon Sep 17 00:00:00 2001 From: Clark Alesna Date: Thu, 4 Jan 2024 05:57:23 +0800 Subject: [PATCH 3/3] Update CNCT treasury addresses --- src/tokens/cnct.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/tokens/cnct.ts b/src/tokens/cnct.ts index f9ed95fe..e5bdfbe7 100644 --- a/src/tokens/cnct.ts +++ b/src/tokens/cnct.ts @@ -1,16 +1,17 @@ import { defaultFetcherOptions, SupplyFetcher } from "../types"; import { getAmountInAddresses, getBlockFrostInstance } from "../utils"; -const CNCT = - "c27600f3aff3d94043464a33786429b78e6ab9df5e1d23b774acb34c434e4354"; +const CNCT = "c27600f3aff3d94043464a33786429b78e6ab9df5e1d23b774acb34c434e4354"; const cnctFetcher: SupplyFetcher = async (options = defaultFetcherOptions) => { const blockFrost = getBlockFrostInstance(options); const total = 80_000_000; const treasuryRaw = await getAmountInAddresses(blockFrost, CNCT, [ - "addr1qy0yswstqah6zwxvd5csh0gyty80pcpfqf0ghe24n798r07hdz6r6fp6z96rgh8dvu6yjx8smmany40anu8264r0ek3ssujtw9", + "addr1q874njfl5kfdq5ruxj7ldz0xvsmqp8384hf4uqgser2pxsdh5gwrx54ucvssczqhjkragat8uumre3jzd27gw9jjl8zqmemg23", + "addr1qxmgww3pjvtyn8tunqjw4cjtzvmekz77w4kcnlp58jfjd5hl43gkvjqmkap89s2gwzdyaxdny0xurnj45rw8dmvmvvnst7nncw", + "addr1qx8uxd42nw04m0as8q5m54ks4mzyrxwzc594pyyjchx4phskdgdxqv7fjkjsukdqf6yhmkvhte2p97zs6t2wut4kmmpqh07a0h", + "addr1qym9rx77npken66a56scj06eugwln7dk6276slspmfj8fyr90fuc3s5kkmugy33v5rx8hepaew00wgna67ddw2pkrs6s53cnud", ]); - const treasury = Number(treasuryRaw) / 10_000; return { circulating: (total - treasury).toString(),