@defillama/sdk 5.0.235 → 5.0.238
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/ChainApi.d.ts +23 -1
- package/build/ChainApi.js +13 -0
- package/build/abi/tron.js +7 -1
- package/build/chains/algorand.d.ts +277 -0
- package/build/chains/algorand.js +618 -0
- package/build/chains/aptos.d.ts +230 -0
- package/build/chains/aptos.js +612 -0
- package/build/chains/cardano.d.ts +242 -0
- package/build/chains/cardano.js +407 -0
- package/build/chains/cosmos.d.ts +252 -0
- package/build/chains/cosmos.js +618 -0
- package/build/chains/icp.d.ts +235 -0
- package/build/chains/icp.js +1040 -0
- package/build/chains/index.d.ts +23 -0
- package/build/chains/index.js +59 -0
- package/build/chains/near.d.ts +192 -0
- package/build/chains/near.js +446 -0
- package/build/chains/rpc.d.ts +125 -0
- package/build/chains/rpc.js +326 -0
- package/build/chains/starknet.d.ts +205 -0
- package/build/chains/starknet.js +884 -0
- package/build/chains/stellar.d.ts +410 -0
- package/build/chains/stellar.js +1082 -0
- package/build/chains/substrate.d.ts +333 -0
- package/build/chains/substrate.js +1042 -0
- package/build/chains/sui.d.ts +365 -0
- package/build/chains/sui.js +1135 -0
- package/build/chains/svm.d.ts +340 -0
- package/build/chains/svm.js +760 -0
- package/build/chains/tezos.d.ts +225 -0
- package/build/chains/tezos.js +412 -0
- package/build/chains/ton.d.ts +353 -0
- package/build/chains/ton.js +788 -0
- package/build/chains/tron.d.ts +45 -0
- package/build/chains/tron.js +110 -0
- package/build/chains/utxo.d.ts +202 -0
- package/build/chains/utxo.js +592 -0
- package/build/chains/xrpl.d.ts +179 -0
- package/build/chains/xrpl.js +467 -0
- package/build/index.d.ts +2 -1
- package/build/index.js +3 -1
- package/build/providers.json +1 -1
- package/build/util/LlamaProvider.js +2 -0
- package/build/util/blocks.js +292 -84
- package/build/util/chainUtils/data.json +80 -0
- package/build/util/chainUtils/index.d.ts +1 -0
- package/build/util/chainUtils/index.js +23 -0
- package/build/util/coins.js +14 -3
- package/build/util/common.js +6 -4
- package/build/util/computeTVL.js +1 -1
- package/build/util/cosmos.d.ts +1 -11
- package/build/util/cosmos.js +6 -66
- package/build/util/env.d.ts +1 -0
- package/build/util/env.js +18 -0
- package/build/util/indexer.compatibility.d.ts +6 -0
- package/build/util/indexer.compatibility.js +64 -0
- package/build/util/indexer.d.ts +24 -2
- package/build/util/indexer.js +333 -294
- package/build/util/indexerSql.d.ts +8 -1
- package/build/util/indexerSql.js +53 -22
- package/build/util/logs.d.ts +3 -0
- package/build/util/logs.decode.shared.js +5 -4
- package/build/util/logs.js +57 -26
- package/build/util/transactions.d.ts +23 -1
- package/build/util/updateChainLabels.d.ts +1 -0
- package/build/util/updateChainLabels.js +5 -0
- package/build/util/updateProviderList.js +40 -18
- package/package.json +20 -7
- package/README.md +0 -41
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
"chainKeyToChainLabelMap": {
|
|
3
3
|
"0g": "0G",
|
|
4
4
|
"Ethereum": "Ethereum",
|
|
5
|
+
"ab_chain": "AB Chain",
|
|
5
6
|
"abstract": "Abstract",
|
|
6
7
|
"acala": "Acala",
|
|
7
8
|
"ace": "Endurance",
|
|
@@ -24,7 +25,9 @@
|
|
|
24
25
|
"alphasec": "AlphaSec",
|
|
25
26
|
"althea": "Althea",
|
|
26
27
|
"alv": "ALV",
|
|
28
|
+
"amadeus": "Amadeus",
|
|
27
29
|
"ancient8": "Ancient8",
|
|
30
|
+
"andromeda": "Andromeda",
|
|
28
31
|
"anubi": "Anubis",
|
|
29
32
|
"ao": "AO",
|
|
30
33
|
"ap3x": "Apex Fusion",
|
|
@@ -39,11 +42,13 @@
|
|
|
39
42
|
"artela": "Artela",
|
|
40
43
|
"arweave": "Arweave",
|
|
41
44
|
"assetchain": "Asset Chain",
|
|
45
|
+
"assetmantle": "AssetMantle",
|
|
42
46
|
"astar": "Astar",
|
|
43
47
|
"astrzk": "Astar zkEVM",
|
|
44
48
|
"aura": "Aura Network",
|
|
45
49
|
"aurora": "Aurora",
|
|
46
50
|
"avax": "Avalanche",
|
|
51
|
+
"axelar": "Axelar",
|
|
47
52
|
"axiome": "Axiome",
|
|
48
53
|
"b3": "B3",
|
|
49
54
|
"babylon": "Babylon Genesis",
|
|
@@ -99,6 +104,7 @@
|
|
|
99
104
|
"celo": "Celo",
|
|
100
105
|
"chainflip": "Chainflip",
|
|
101
106
|
"chainx": "BEVM",
|
|
107
|
+
"cheqd": "Cheqd",
|
|
102
108
|
"chia": "Chia",
|
|
103
109
|
"chihuahua": "Chihuahua",
|
|
104
110
|
"chromia": "Chromia",
|
|
@@ -114,28 +120,33 @@
|
|
|
114
120
|
"constellation": "Constellation",
|
|
115
121
|
"cookiechain": "CookieChain",
|
|
116
122
|
"core": "CORE",
|
|
123
|
+
"coreum": "Coreum",
|
|
117
124
|
"corn": "Corn",
|
|
118
125
|
"cosmos": "CosmosHub",
|
|
119
126
|
"coti": "Coti",
|
|
120
127
|
"crab": "Crab",
|
|
121
128
|
"crescent": "Crescent",
|
|
122
129
|
"cronos": "Cronos",
|
|
130
|
+
"cronos_pos_chain": "Cronos POS",
|
|
123
131
|
"cronos_zkevm": "Cronos zkEVM",
|
|
124
132
|
"cross": "CROSS",
|
|
125
133
|
"crossfi": "CrossFi",
|
|
126
134
|
"csc": "CSC",
|
|
127
135
|
"cube": "Cube",
|
|
136
|
+
"cudos": "Cudos",
|
|
128
137
|
"curio": "Curio",
|
|
129
138
|
"cyeth": "Cyber",
|
|
130
139
|
"dango": "Dango Mainnet",
|
|
131
140
|
"darwinia": "Darwinia",
|
|
132
141
|
"dash": "Dash",
|
|
133
142
|
"dchainmainnet": "DChain",
|
|
143
|
+
"decentr": "Decentr",
|
|
134
144
|
"defichain": "DefiChain",
|
|
135
145
|
"defichain_evm": "DeFiChain EVM",
|
|
136
146
|
"defiverse": "DeFiVerse",
|
|
137
147
|
"degen": "Degen",
|
|
138
148
|
"deri_chain": "Deri Chain",
|
|
149
|
+
"derive_v3": "Derive V3",
|
|
139
150
|
"dexalot": "Dexalot",
|
|
140
151
|
"dexit": "Dexit",
|
|
141
152
|
"dfio_meta_main": "Defi Oracle Meta",
|
|
@@ -198,6 +209,7 @@
|
|
|
198
209
|
"fluent": "Fluent",
|
|
199
210
|
"flynet": "Flynet",
|
|
200
211
|
"fogo": "Fogo",
|
|
212
|
+
"forma": "Forma",
|
|
201
213
|
"formnetwork": "Form Network",
|
|
202
214
|
"fraxtal": "Fraxtal",
|
|
203
215
|
"fsc": "FSC",
|
|
@@ -205,6 +217,7 @@
|
|
|
205
217
|
"fuel": "Fuel Ignition",
|
|
206
218
|
"fuel-ignition": "Fuel-ignition",
|
|
207
219
|
"functionx": "FunctionX",
|
|
220
|
+
"funki": "Funki",
|
|
208
221
|
"fuse": "Fuse",
|
|
209
222
|
"fusion": "Fusion",
|
|
210
223
|
"gala": "Gala",
|
|
@@ -214,6 +227,7 @@
|
|
|
214
227
|
"genshiro": "Genshiro",
|
|
215
228
|
"gensyn": "Gensyn",
|
|
216
229
|
"ggchain": "GGCHAIN",
|
|
230
|
+
"glue": "Glue",
|
|
217
231
|
"goat": "GOAT",
|
|
218
232
|
"gochain": "GoChain",
|
|
219
233
|
"godwoken": "Godwoken",
|
|
@@ -235,6 +249,7 @@
|
|
|
235
249
|
"hemi": "Hemi",
|
|
236
250
|
"hibachi": "Hibachi",
|
|
237
251
|
"hoo": "Hoo",
|
|
252
|
+
"horizen": "Horizen L3",
|
|
238
253
|
"horizen eon": "Horizen EON",
|
|
239
254
|
"hotstuff": "Hotstuff",
|
|
240
255
|
"hpb": "HPB",
|
|
@@ -250,6 +265,7 @@
|
|
|
250
265
|
"idex": "XCHAIN",
|
|
251
266
|
"igra": "Igra",
|
|
252
267
|
"immutablex": "Immutable X",
|
|
268
|
+
"impacthub": "Impact Hub",
|
|
253
269
|
"imx": "Immutable zkEVM",
|
|
254
270
|
"inertia": "Inertia",
|
|
255
271
|
"inevm": "inEVM",
|
|
@@ -262,8 +278,10 @@
|
|
|
262
278
|
"iota": "IOTA",
|
|
263
279
|
"iotaevm": "IOTA EVM",
|
|
264
280
|
"iotex": "IoTeX",
|
|
281
|
+
"iris": "IRISnet",
|
|
265
282
|
"irys_mainnet_beta": "Irys",
|
|
266
283
|
"islm": "HAQQ",
|
|
284
|
+
"jackal": "Jackal",
|
|
267
285
|
"jbc": "JBC",
|
|
268
286
|
"joc": "JOC",
|
|
269
287
|
"joltify": "Joltify",
|
|
@@ -290,6 +308,7 @@
|
|
|
290
308
|
"krown": "Krown Network",
|
|
291
309
|
"kujira": "Kujira",
|
|
292
310
|
"kusama": "Kusama",
|
|
311
|
+
"kyve": "KYVE",
|
|
293
312
|
"lac": "LaChain Network",
|
|
294
313
|
"lachain": "Lachain",
|
|
295
314
|
"lamden": "Lamden",
|
|
@@ -316,10 +335,12 @@
|
|
|
316
335
|
"massa": "Massa",
|
|
317
336
|
"matchain": "Matchain",
|
|
318
337
|
"mayachain": "Mayachain",
|
|
338
|
+
"medibloc": "MediBloc",
|
|
319
339
|
"meer": "MEER",
|
|
320
340
|
"megaeth": "MegaETH",
|
|
321
341
|
"merlin": "Merlin",
|
|
322
342
|
"meta": "Meta",
|
|
343
|
+
"metall2": "MetalL2",
|
|
323
344
|
"meter": "Meter",
|
|
324
345
|
"metis": "Metis",
|
|
325
346
|
"mezo": "Mezo",
|
|
@@ -367,15 +388,18 @@
|
|
|
367
388
|
"nova": "Nova Network",
|
|
368
389
|
"nuls": "Nuls",
|
|
369
390
|
"numbers": "Numbers",
|
|
391
|
+
"nym": "Nym",
|
|
370
392
|
"oas": "Oasys",
|
|
371
393
|
"oasis": "Oasis Emerald",
|
|
372
394
|
"obyte": "Obyte",
|
|
373
395
|
"occ": "EDU Chain",
|
|
396
|
+
"octra": "Octra",
|
|
374
397
|
"odyssey": "Odyssey",
|
|
375
398
|
"off_chain": "Off Chain",
|
|
376
399
|
"ogpu": "OpenGPU",
|
|
377
400
|
"okexchain": "OKTChain",
|
|
378
401
|
"omax": "Omax",
|
|
402
|
+
"omniflix": "OmniFlix",
|
|
379
403
|
"ontology": "Ontology",
|
|
380
404
|
"ontology_evm": "OntologyEVM",
|
|
381
405
|
"onus": "Onus",
|
|
@@ -393,9 +417,11 @@
|
|
|
393
417
|
"paradex": "Paradex",
|
|
394
418
|
"parallel": "Parallel",
|
|
395
419
|
"parex": "Parex",
|
|
420
|
+
"passage": "Passage",
|
|
396
421
|
"peaq": "Peaq",
|
|
397
422
|
"pearl": "Pearl",
|
|
398
423
|
"pendulum": "Pendulum",
|
|
424
|
+
"pentagonchain": "Pentagon Chain",
|
|
399
425
|
"penumbra": "Penumbra",
|
|
400
426
|
"pepu": "Pepu",
|
|
401
427
|
"perennial": "Perennial",
|
|
@@ -435,6 +461,7 @@
|
|
|
435
461
|
"rari": "Rari",
|
|
436
462
|
"rbn": "Redbelly",
|
|
437
463
|
"real": "re.al",
|
|
464
|
+
"realio": "Realio",
|
|
438
465
|
"redstone": "Redstone",
|
|
439
466
|
"reef": "Reef",
|
|
440
467
|
"regen": "Regen",
|
|
@@ -464,7 +491,10 @@
|
|
|
464
491
|
"seda": "Seda",
|
|
465
492
|
"sei": "Sei",
|
|
466
493
|
"seleman": "SELEMAN",
|
|
494
|
+
"sentinel": "Sentinel",
|
|
495
|
+
"sge": "SGE",
|
|
467
496
|
"shape": "Shape",
|
|
497
|
+
"shentu": "Shentu",
|
|
468
498
|
"shibarium": "Shibarium",
|
|
469
499
|
"shiden": "Shiden",
|
|
470
500
|
"shido": "Shido",
|
|
@@ -485,6 +515,7 @@
|
|
|
485
515
|
"soon_bsc": "svmBNB",
|
|
486
516
|
"sophon": "Sophon",
|
|
487
517
|
"sora": "Sora",
|
|
518
|
+
"source": "Source",
|
|
488
519
|
"space_and_time": "Space and Time",
|
|
489
520
|
"spark": "Spark",
|
|
490
521
|
"spn": "Superposition",
|
|
@@ -561,6 +592,7 @@
|
|
|
561
592
|
"wemix": "WEMIX3.0",
|
|
562
593
|
"winr": "WINR Chain",
|
|
563
594
|
"witnet": "Witnet",
|
|
595
|
+
"wormchain": "Wormchain",
|
|
564
596
|
"xai": "Xai",
|
|
565
597
|
"xdai": "Gnosis",
|
|
566
598
|
"xdaiarb": "XdaiArb",
|
|
@@ -593,6 +625,7 @@
|
|
|
593
625
|
"chainLabelsToKeyMap": {
|
|
594
626
|
"0G": "0g",
|
|
595
627
|
"AB": "new",
|
|
628
|
+
"AB Chain": "ab_chain",
|
|
596
629
|
"ADI": "adi",
|
|
597
630
|
"AFX L1": "afx",
|
|
598
631
|
"AILayer": "ailayer",
|
|
@@ -614,7 +647,9 @@
|
|
|
614
647
|
"Allora": "allora",
|
|
615
648
|
"AlphaSec": "alphasec",
|
|
616
649
|
"Althea": "althea",
|
|
650
|
+
"Amadeus": "amadeus",
|
|
617
651
|
"Ancient8": "ancient8",
|
|
652
|
+
"Andromeda": "andromeda",
|
|
618
653
|
"Anubis": "anubi",
|
|
619
654
|
"ApeChain": "apechain",
|
|
620
655
|
"Apex Fusion": "ap3x",
|
|
@@ -629,11 +664,13 @@
|
|
|
629
664
|
"Artela": "artela",
|
|
630
665
|
"Arweave": "arweave",
|
|
631
666
|
"Asset Chain": "assetchain",
|
|
667
|
+
"AssetMantle": "assetmantle",
|
|
632
668
|
"Astar": "astar",
|
|
633
669
|
"Astar zkEVM": "astrzk",
|
|
634
670
|
"Aura Network": "aura",
|
|
635
671
|
"Aurora": "aurora",
|
|
636
672
|
"Avalanche": "avax",
|
|
673
|
+
"Axelar": "axelar",
|
|
637
674
|
"Axiome": "axiome",
|
|
638
675
|
"B3": "b3",
|
|
639
676
|
"BCHyper": "bcypher",
|
|
@@ -695,6 +732,7 @@
|
|
|
695
732
|
"Celestia": "celestia",
|
|
696
733
|
"Celo": "celo",
|
|
697
734
|
"Chainflip": "chainflip",
|
|
735
|
+
"Cheqd": "cheqd",
|
|
698
736
|
"Chia": "chia",
|
|
699
737
|
"Chihuahua": "chihuahua",
|
|
700
738
|
"Chiliz": "chz",
|
|
@@ -707,6 +745,7 @@
|
|
|
707
745
|
"Conflux": "conflux",
|
|
708
746
|
"Constellation": "constellation",
|
|
709
747
|
"CookieChain": "cookiechain",
|
|
748
|
+
"Coreum": "coreum",
|
|
710
749
|
"Corn": "corn",
|
|
711
750
|
"Cosmos": "cosmos",
|
|
712
751
|
"CosmosHub": "cosmos",
|
|
@@ -714,9 +753,11 @@
|
|
|
714
753
|
"Crab": "crab",
|
|
715
754
|
"Crescent": "crescent",
|
|
716
755
|
"Cronos": "cronos",
|
|
756
|
+
"Cronos POS": "cronos_pos_chain",
|
|
717
757
|
"Cronos zkEVM": "cronos_zkevm",
|
|
718
758
|
"CrossFi": "crossfi",
|
|
719
759
|
"Cube": "cube",
|
|
760
|
+
"Cudos": "cudos",
|
|
720
761
|
"Curio": "curio",
|
|
721
762
|
"Cyber": "cyeth",
|
|
722
763
|
"DChain": "dchainmainnet",
|
|
@@ -730,11 +771,13 @@
|
|
|
730
771
|
"Data Network": "sty",
|
|
731
772
|
"DeFiChain EVM": "defichain_evm",
|
|
732
773
|
"DeFiVerse": "defiverse",
|
|
774
|
+
"Decentr": "decentr",
|
|
733
775
|
"Defi Oracle Meta": "dfio_meta_main",
|
|
734
776
|
"DefiChain": "defichain",
|
|
735
777
|
"Degen": "degen",
|
|
736
778
|
"Deri Chain": "deri_chain",
|
|
737
779
|
"Derive Chain": "lyra",
|
|
780
|
+
"Derive V3": "derive_v3",
|
|
738
781
|
"Dexalot": "dexalot",
|
|
739
782
|
"Dexit": "dexit",
|
|
740
783
|
"Doge": "doge",
|
|
@@ -793,10 +836,12 @@
|
|
|
793
836
|
"Flynet": "flynet",
|
|
794
837
|
"Fogo": "fogo",
|
|
795
838
|
"Form Network": "formnetwork",
|
|
839
|
+
"Forma": "forma",
|
|
796
840
|
"Fraxtal": "fraxtal",
|
|
797
841
|
"Fuel": "fuel",
|
|
798
842
|
"Fuel Ignition": "fuel",
|
|
799
843
|
"FunctionX": "functionx",
|
|
844
|
+
"Funki": "funki",
|
|
800
845
|
"Fuse": "fuse",
|
|
801
846
|
"Fusion": "fusion",
|
|
802
847
|
"GANchain": "gan",
|
|
@@ -809,6 +854,7 @@
|
|
|
809
854
|
"Genesys": "genesys",
|
|
810
855
|
"Genshiro": "genshiro",
|
|
811
856
|
"Gensyn": "gensyn",
|
|
857
|
+
"Glue": "glue",
|
|
812
858
|
"Gnosis": "xdai",
|
|
813
859
|
"GoChain": "gochain",
|
|
814
860
|
"Goat": "goat",
|
|
@@ -835,6 +881,7 @@
|
|
|
835
881
|
"Hibachi": "hibachi",
|
|
836
882
|
"Hoo": "hoo",
|
|
837
883
|
"Horizen EON": "eon",
|
|
884
|
+
"Horizen L3": "horizen",
|
|
838
885
|
"Hotstuff": "hotstuff",
|
|
839
886
|
"Hydra": "hydra",
|
|
840
887
|
"Hydra Chain": "hydragon",
|
|
@@ -847,10 +894,12 @@
|
|
|
847
894
|
"INRI": "inri",
|
|
848
895
|
"IOTA": "iota",
|
|
849
896
|
"IOTA EVM": "iotaevm",
|
|
897
|
+
"IRISnet": "iris",
|
|
850
898
|
"Icon": "icon",
|
|
851
899
|
"Igra": "igra",
|
|
852
900
|
"Immutable X": "immutablex",
|
|
853
901
|
"Immutable zkEVM": "imx",
|
|
902
|
+
"Impact Hub": "impacthub",
|
|
854
903
|
"Inertia": "inertia",
|
|
855
904
|
"Initia": "initia",
|
|
856
905
|
"Injective": "injective",
|
|
@@ -861,12 +910,14 @@
|
|
|
861
910
|
"Irys": "irys_mainnet_beta",
|
|
862
911
|
"JBC": "jbc",
|
|
863
912
|
"JOC": "joc",
|
|
913
|
+
"Jackal": "jackal",
|
|
864
914
|
"Joltify": "joltify",
|
|
865
915
|
"Juno": "juno",
|
|
866
916
|
"Jupnet": "jupnet",
|
|
867
917
|
"K2": "karak",
|
|
868
918
|
"KCC": "kcc",
|
|
869
919
|
"KUB": "bitkub",
|
|
920
|
+
"KYVE": "kyve",
|
|
870
921
|
"Kadena": "kadena",
|
|
871
922
|
"Kaia": "klaytn",
|
|
872
923
|
"Kalshi": "kalshi",
|
|
@@ -919,10 +970,12 @@
|
|
|
919
970
|
"Massa": "massa",
|
|
920
971
|
"Matchain": "matchain",
|
|
921
972
|
"Mayachain": "mayachain",
|
|
973
|
+
"MediBloc": "medibloc",
|
|
922
974
|
"MegaETH": "megaeth",
|
|
923
975
|
"MemeCore": "m",
|
|
924
976
|
"Merlin": "merlin",
|
|
925
977
|
"Meta": "meta",
|
|
978
|
+
"MetalL2": "metall2",
|
|
926
979
|
"Meter": "meter",
|
|
927
980
|
"Metis": "metis",
|
|
928
981
|
"Mezo": "mezo",
|
|
@@ -971,6 +1024,7 @@
|
|
|
971
1024
|
"Nova Network": "nova",
|
|
972
1025
|
"Nuls": "nuls",
|
|
973
1026
|
"Numbers": "numbers",
|
|
1027
|
+
"Nym": "nym",
|
|
974
1028
|
"OKExChain": "okexchain",
|
|
975
1029
|
"OKTChain": "okexchain",
|
|
976
1030
|
"OKXChain": "okexchain",
|
|
@@ -982,9 +1036,11 @@
|
|
|
982
1036
|
"Oasis Sapphire": "sapphire",
|
|
983
1037
|
"Oasys": "oas",
|
|
984
1038
|
"Obyte": "obyte",
|
|
1039
|
+
"Octra": "octra",
|
|
985
1040
|
"Odyssey": "odyssey",
|
|
986
1041
|
"Off Chain": "off_chain",
|
|
987
1042
|
"Omax": "omax",
|
|
1043
|
+
"OmniFlix": "omniflix",
|
|
988
1044
|
"Ontology": "ontology",
|
|
989
1045
|
"OntologyEVM": "ontology_evm",
|
|
990
1046
|
"Onus": "onus",
|
|
@@ -1004,10 +1060,12 @@
|
|
|
1004
1060
|
"Paradex": "paradex",
|
|
1005
1061
|
"Parallel": "parallel",
|
|
1006
1062
|
"Parex": "parex",
|
|
1063
|
+
"Passage": "passage",
|
|
1007
1064
|
"Peaq": "peaq",
|
|
1008
1065
|
"Pearl": "pearl",
|
|
1009
1066
|
"Pego": "pg",
|
|
1010
1067
|
"Pendulum": "pendulum",
|
|
1068
|
+
"Pentagon Chain": "pentagonchain",
|
|
1011
1069
|
"Penumbra": "penumbra",
|
|
1012
1070
|
"Pepu": "pepu",
|
|
1013
1071
|
"Perennial": "perennial",
|
|
@@ -1055,6 +1113,7 @@
|
|
|
1055
1113
|
"Rari": "rari",
|
|
1056
1114
|
"Ravencoin": "rvn",
|
|
1057
1115
|
"Rayls": "rls",
|
|
1116
|
+
"Realio": "realio",
|
|
1058
1117
|
"Redbelly": "rbn",
|
|
1059
1118
|
"Redstone": "redstone",
|
|
1060
1119
|
"Reef": "reef",
|
|
@@ -1069,6 +1128,7 @@
|
|
|
1069
1128
|
"Rootstock": "rsk",
|
|
1070
1129
|
"Rubin": "rubin",
|
|
1071
1130
|
"SELEMAN": "seleman",
|
|
1131
|
+
"SGE": "sge",
|
|
1072
1132
|
"SKALE": "skale",
|
|
1073
1133
|
"SKALE Europa": "europa",
|
|
1074
1134
|
"SX Network": "sx",
|
|
@@ -1084,8 +1144,10 @@
|
|
|
1084
1144
|
"Secret": "secret",
|
|
1085
1145
|
"Seda": "seda",
|
|
1086
1146
|
"Sei": "sei",
|
|
1147
|
+
"Sentinel": "sentinel",
|
|
1087
1148
|
"Sentrix": "srx",
|
|
1088
1149
|
"Shape": "shape",
|
|
1150
|
+
"Shentu": "shentu",
|
|
1089
1151
|
"Shibarium": "shibarium",
|
|
1090
1152
|
"Shiden": "shiden",
|
|
1091
1153
|
"Shido": "shido",
|
|
@@ -1102,6 +1164,7 @@
|
|
|
1102
1164
|
"Soon Network": "soon",
|
|
1103
1165
|
"Sophon": "sophon",
|
|
1104
1166
|
"Sora": "sora",
|
|
1167
|
+
"Source": "source",
|
|
1105
1168
|
"Space and Time": "space_and_time",
|
|
1106
1169
|
"Spark": "spark",
|
|
1107
1170
|
"Stable": "stable",
|
|
@@ -1182,6 +1245,7 @@
|
|
|
1182
1245
|
"Wax": "wax",
|
|
1183
1246
|
"Witnet": "witnet",
|
|
1184
1247
|
"World Chain": "wc",
|
|
1248
|
+
"Wormchain": "wormchain",
|
|
1185
1249
|
"X Layer": "xlayer",
|
|
1186
1250
|
"XCHAIN": "idex",
|
|
1187
1251
|
"XDC": "xdc",
|
|
@@ -1240,26 +1304,32 @@
|
|
|
1240
1304
|
"bouncebit": "2026-08-24",
|
|
1241
1305
|
"btnx": "2026-07-09",
|
|
1242
1306
|
"callisto": "2026-07-01",
|
|
1307
|
+
"canto": "2026-08-10",
|
|
1243
1308
|
"capx": "2026-09-03",
|
|
1244
1309
|
"chainx": "2026-01-20",
|
|
1310
|
+
"clv": "2025-11-22",
|
|
1245
1311
|
"corn": "2026-06-30",
|
|
1246
1312
|
"crab": "2026-01-01",
|
|
1247
1313
|
"crossfi": "2026-09-09",
|
|
1314
|
+
"csc": "2026-09-29",
|
|
1248
1315
|
"cube": "2026-06-24",
|
|
1249
1316
|
"curio": "2026-06-24",
|
|
1250
1317
|
"dchainmainnet": "2026-06-24",
|
|
1251
1318
|
"degen": "2026-08-31",
|
|
1252
1319
|
"dexit": "2024-01-20",
|
|
1320
|
+
"dfk": "2026-08-28",
|
|
1253
1321
|
"dfs": "2026-06-24",
|
|
1254
1322
|
"dogechain": "2026-08-08",
|
|
1255
1323
|
"duckchain": "2026-07-20",
|
|
1256
1324
|
"echelon": "2023-10-20",
|
|
1257
1325
|
"elys": "2025-12-29",
|
|
1326
|
+
"embr": "2026-06-01",
|
|
1258
1327
|
"enuls": "2026-03-25",
|
|
1259
1328
|
"eon": "2026-02-12",
|
|
1260
1329
|
"eos_evm": "2026-02-12",
|
|
1261
1330
|
"eteria": "2026-08-03",
|
|
1262
1331
|
"eventum": "2026-07-01",
|
|
1332
|
+
"everscale": "2026-09-29",
|
|
1263
1333
|
"evmos": "2026-05-18",
|
|
1264
1334
|
"fhe": "2026-06-01",
|
|
1265
1335
|
"findora": "2026-09-03",
|
|
@@ -1281,10 +1351,12 @@
|
|
|
1281
1351
|
"inevm": "2026-04-08",
|
|
1282
1352
|
"inri": "2026-08-03",
|
|
1283
1353
|
"interlay": "2026-07-22",
|
|
1354
|
+
"jbc": "2026-09-01",
|
|
1284
1355
|
"kadena": "2026-02-12",
|
|
1285
1356
|
"kardia": "2026-01-20",
|
|
1286
1357
|
"kinto": "2026-03-06",
|
|
1287
1358
|
"kintsugi": "2026-07-22",
|
|
1359
|
+
"kopi": "2026-05-16",
|
|
1288
1360
|
"kroma": "2026-01-20",
|
|
1289
1361
|
"kujira": "2026-08-03",
|
|
1290
1362
|
"loop": "2026-08-03",
|
|
@@ -1299,19 +1371,23 @@
|
|
|
1299
1371
|
"moonriver": "2026-07-31",
|
|
1300
1372
|
"mxczkevm": "2026-09-01",
|
|
1301
1373
|
"nahmii": "2026-06-30",
|
|
1374
|
+
"neon_evm": "2026-10-01",
|
|
1302
1375
|
"neutron": "2026-07-01",
|
|
1303
1376
|
"nos": "2026-06-24",
|
|
1304
1377
|
"nova": "2026-08-03",
|
|
1305
1378
|
"nuls": "2026-03-25",
|
|
1306
1379
|
"odyssey": "2026-09-02",
|
|
1307
1380
|
"onus": "2026-06-05",
|
|
1381
|
+
"pacaswap": "2026-10-01",
|
|
1308
1382
|
"parex": "2026-08-12",
|
|
1383
|
+
"perennial": "2026-06-30",
|
|
1309
1384
|
"planq": "2026-06-05",
|
|
1310
1385
|
"plume": "2026-02-12",
|
|
1311
1386
|
"polygon_zkevm": "2026-07-01",
|
|
1312
1387
|
"polynomial": "2026-02-13",
|
|
1313
1388
|
"pryzm": "2026-02-09",
|
|
1314
1389
|
"qom": "2026-01-20",
|
|
1390
|
+
"quicksilver": "2026-08-01",
|
|
1315
1391
|
"rari": "2026-06-14",
|
|
1316
1392
|
"real": "2026-02-12",
|
|
1317
1393
|
"redstone": "2026-05-18",
|
|
@@ -1321,11 +1397,14 @@
|
|
|
1321
1397
|
"rss3_vsl": "2026-09-03",
|
|
1322
1398
|
"saakuru": "2026-03-16",
|
|
1323
1399
|
"saga": "2026-02-16",
|
|
1400
|
+
"secret": "2026-09-01",
|
|
1401
|
+
"shimmer_evm": "2026-09-30",
|
|
1324
1402
|
"sifchain": "2026-09-01",
|
|
1325
1403
|
"soon_base": "2026-05-25",
|
|
1326
1404
|
"spn": "2026-09-08",
|
|
1327
1405
|
"srx": "2026-08-03",
|
|
1328
1406
|
"stargaze": "2026-06-01",
|
|
1407
|
+
"step": "2026-08-21",
|
|
1329
1408
|
"svm": "2026-01-09",
|
|
1330
1409
|
"swellchain": "2026-06-23",
|
|
1331
1410
|
"sx": "2026-04-23",
|
|
@@ -1333,6 +1412,7 @@
|
|
|
1333
1412
|
"tenet": "2026-04-22",
|
|
1334
1413
|
"thundercore": "2026-09-01",
|
|
1335
1414
|
"titan": "2026-05-05",
|
|
1415
|
+
"tombchain": "2026-09-19",
|
|
1336
1416
|
"ubiq": "2023-01-01",
|
|
1337
1417
|
"umee": "2026-07-10",
|
|
1338
1418
|
"vision": "2026-02-20",
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { chainKeyToChainLabelMap, chainLabelsToKeyMap } from './data.json';
|
|
2
2
|
export { chainKeyToChainLabelMap, chainLabelsToKeyMap, };
|
|
3
3
|
export declare function updateData(): Promise<void>;
|
|
4
|
+
export declare function updateChainLabels(): Promise<void>;
|
|
4
5
|
export declare const sluggifyString: (name: string) => string;
|
|
5
6
|
export declare function getSluggifiedChainLabel(label: string): string;
|
|
6
7
|
export declare function getChainKeyFromLabel(label: string): string;
|
|
@@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.sluggifyString = exports.chainLabelsToKeyMap = exports.chainKeyToChainLabelMap = void 0;
|
|
7
7
|
exports.updateData = updateData;
|
|
8
|
+
exports.updateChainLabels = updateChainLabels;
|
|
8
9
|
exports.getSluggifiedChainLabel = getSluggifiedChainLabel;
|
|
9
10
|
exports.getChainKeyFromLabel = getChainKeyFromLabel;
|
|
10
11
|
exports.getChainLabelFromKey = getChainLabelFromKey;
|
|
@@ -39,6 +40,10 @@ async function updateData() {
|
|
|
39
40
|
continue;
|
|
40
41
|
const key = getChainKeyFromLabel(label);
|
|
41
42
|
data_json_1.deadChains[key] = deadFrom;
|
|
43
|
+
if (!deadChainsSet.has(key)) {
|
|
44
|
+
deadChainsSet.add(key);
|
|
45
|
+
deadChainsArray.push(key);
|
|
46
|
+
}
|
|
42
47
|
}
|
|
43
48
|
// Save to data.json file
|
|
44
49
|
const dataFilePath = path_1.default.join(__dirname, 'data.json');
|
|
@@ -52,6 +57,24 @@ async function updateData() {
|
|
|
52
57
|
console.error('Error updating chain data:', error);
|
|
53
58
|
}
|
|
54
59
|
}
|
|
60
|
+
// runs updateData and sanity checks that the mappings only grew
|
|
61
|
+
async function updateChainLabels() {
|
|
62
|
+
const chainKeyLabelMapCountBefore = Object.keys(data_json_1.chainKeyToChainLabelMap).length;
|
|
63
|
+
const chainLabelsKeyMapCountBefore = Object.keys(data_json_1.chainLabelsToKeyMap).length;
|
|
64
|
+
await updateData();
|
|
65
|
+
const chainKeyLabelMapCountAfter = Object.keys(data_json_1.chainKeyToChainLabelMap).length;
|
|
66
|
+
const chainLabelsKeyMapCountAfter = Object.keys(data_json_1.chainLabelsToKeyMap).length;
|
|
67
|
+
if (chainKeyLabelMapCountAfter > chainKeyLabelMapCountBefore) {
|
|
68
|
+
console.log(`Updated chainKeyToChainLabelMap: ${chainKeyLabelMapCountBefore} -> ${chainKeyLabelMapCountAfter}`);
|
|
69
|
+
}
|
|
70
|
+
if (chainLabelsKeyMapCountAfter > chainLabelsKeyMapCountBefore) {
|
|
71
|
+
console.log(`Updated chainLabelsToKeyMap: ${chainLabelsKeyMapCountBefore} -> ${chainLabelsKeyMapCountAfter}`);
|
|
72
|
+
}
|
|
73
|
+
if (chainKeyLabelMapCountAfter < chainKeyLabelMapCountBefore)
|
|
74
|
+
throw new Error('chainKeyToChainLabelMap count decreased, please investigate');
|
|
75
|
+
if (chainLabelsKeyMapCountAfter < chainLabelsKeyMapCountBefore)
|
|
76
|
+
throw new Error('chainLabelsToKeyMap count decreased, please investigate');
|
|
77
|
+
}
|
|
55
78
|
const sluggifyString = (name) => name.toLowerCase().split(" ").join("-").split("'").join("");
|
|
56
79
|
exports.sluggifyString = sluggifyString;
|
|
57
80
|
function sortJSONData(jsonData) {
|
package/build/util/coins.js
CHANGED
|
@@ -52,14 +52,19 @@ async function fetchWithProFallback(body, subRoute) {
|
|
|
52
52
|
params: { source: "internal", apikey: coinsApiKey },
|
|
53
53
|
}));
|
|
54
54
|
}
|
|
55
|
-
const
|
|
56
|
-
|
|
55
|
+
const nowCacheTTL = 1000 * 60 * 30; // 30 minutes, matches priceUpdateTime in computeTVL
|
|
56
|
+
let lastNowCacheClear = +Date.now();
|
|
57
|
+
function seedNowPriceCache() {
|
|
58
|
+
return {
|
|
57
59
|
"coingecko:tether": {
|
|
58
60
|
price: 1,
|
|
59
61
|
symbol: "USDT",
|
|
60
62
|
timestamp: Math.floor(Date.now() / 1e3 + 3600), // an hour from script start time
|
|
61
63
|
},
|
|
62
|
-
}
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
const priceCacheAll = {
|
|
67
|
+
now: seedNowPriceCache()
|
|
63
68
|
};
|
|
64
69
|
const mcapCacheAll = {};
|
|
65
70
|
async function getPrices(readKeys, timestamp) {
|
|
@@ -68,6 +73,12 @@ async function getPrices(readKeys, timestamp) {
|
|
|
68
73
|
async function getPricesData(readKeys, timestamp, dataType) {
|
|
69
74
|
if (!readKeys.length)
|
|
70
75
|
return {};
|
|
76
|
+
// expire the "now" caches so current prices are never served older than nowCacheTTL
|
|
77
|
+
if (+Date.now() - lastNowCacheClear > nowCacheTTL) {
|
|
78
|
+
lastNowCacheClear = +Date.now();
|
|
79
|
+
priceCacheAll.now = seedNowPriceCache();
|
|
80
|
+
delete mcapCacheAll.now;
|
|
81
|
+
}
|
|
71
82
|
const cacheAllObject = dataType === "price" ? priceCacheAll : mcapCacheAll;
|
|
72
83
|
const subRoute = dataType === "price" ? "prices" : "mcaps";
|
|
73
84
|
const aggregatedRes = {};
|
package/build/util/common.js
CHANGED
|
@@ -76,7 +76,10 @@ function convertToBigInt(value) {
|
|
|
76
76
|
let final;
|
|
77
77
|
let exponent = +e;
|
|
78
78
|
if (exponent >= 0) {
|
|
79
|
-
|
|
79
|
+
const decimals = decimal || '';
|
|
80
|
+
final = exponent >= decimals.length
|
|
81
|
+
? lead + decimals + '0'.repeat(exponent - decimals.length)
|
|
82
|
+
: lead + decimals.slice(0, exponent);
|
|
80
83
|
}
|
|
81
84
|
else {
|
|
82
85
|
// NOTE: unforutenately BigInt doesn't support negative exponents, so this ends up being 0
|
|
@@ -174,10 +177,9 @@ function sumChainTvls(chainTvls) {
|
|
|
174
177
|
function getUniqueAddresses(addresses, chain) {
|
|
175
178
|
if (!addresses.length)
|
|
176
179
|
return [];
|
|
177
|
-
const
|
|
178
|
-
const toLowerCase = !isTronAddress;
|
|
180
|
+
const isTronChain = chain === 'tron';
|
|
179
181
|
const set = {};
|
|
180
|
-
addresses.forEach(i => set[
|
|
182
|
+
addresses.forEach(i => set[isTronChain && i.includes('T') ? i : i.toLowerCase()] = true);
|
|
181
183
|
return Object.keys(set);
|
|
182
184
|
}
|
|
183
185
|
function getProviderUrl(provider) {
|
package/build/util/computeTVL.js
CHANGED
|
@@ -6,7 +6,7 @@ const generalUtil_1 = require("../generalUtil");
|
|
|
6
6
|
const coins_1 = require("./coins");
|
|
7
7
|
const currentPriceCache = {};
|
|
8
8
|
const priceCaches = {};
|
|
9
|
-
let lastPriceUpdate =
|
|
9
|
+
let lastPriceUpdate = +Date.now();
|
|
10
10
|
const confidenceThreshold = 0.5;
|
|
11
11
|
const priceUpdateTime = 1000 * 60 * 30; // 30 minutes
|
|
12
12
|
async function computeTVL(balances, timestamp, { debug = false } = {}) {
|
package/build/util/cosmos.d.ts
CHANGED
|
@@ -1,11 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
export declare function getCosmosBlock(block?: number | string, chain?: string): Promise<{
|
|
3
|
-
number: number;
|
|
4
|
-
timestamp: number;
|
|
5
|
-
}>;
|
|
6
|
-
export declare function getCosmosProvider(chain: string): {
|
|
7
|
-
getBlock: (block?: number | string) => Promise<{
|
|
8
|
-
number: number;
|
|
9
|
-
timestamp: number;
|
|
10
|
-
}>;
|
|
11
|
-
};
|
|
1
|
+
export { isCosmosChain, getCosmosBlock, getCosmosProvider } from "../chains/cosmos";
|