@circle-fin/bridge-kit 1.5.0 → 1.6.1
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/CHANGELOG.md +34 -0
- package/QUICKSTART.md +6 -6
- package/README.md +110 -13
- package/chains.cjs +544 -4
- package/chains.d.ts +205 -4
- package/chains.mjs +544 -4
- package/index.cjs +4578 -1649
- package/index.d.ts +5112 -2352
- package/index.mjs +4533 -1654
- package/package.json +4 -3
package/chains.cjs
CHANGED
|
@@ -95,6 +95,122 @@ var Blockchain;
|
|
|
95
95
|
Blockchain["ZKSync_Era"] = "ZKSync_Era";
|
|
96
96
|
Blockchain["ZKSync_Sepolia"] = "ZKSync_Sepolia";
|
|
97
97
|
})(Blockchain || (Blockchain = {}));
|
|
98
|
+
/**
|
|
99
|
+
* Enum representing the subset of {@link Blockchain} that supports swap operations.
|
|
100
|
+
*
|
|
101
|
+
* This enum provides compile-time type safety for swap chain selection,
|
|
102
|
+
* ensuring only supported chains are available in IDE autocomplete
|
|
103
|
+
* when building swap parameters.
|
|
104
|
+
*
|
|
105
|
+
* @remarks
|
|
106
|
+
* Unlike the full {@link Blockchain} enum, SwapChain only includes networks
|
|
107
|
+
* where the swap functionality is actively supported by the library.
|
|
108
|
+
* Using this enum prevents runtime errors from attempting unsupported
|
|
109
|
+
* cross-chain swaps.
|
|
110
|
+
*
|
|
111
|
+
* Currently supports:
|
|
112
|
+
* - Ethereum mainnet
|
|
113
|
+
* - Base mainnet
|
|
114
|
+
* - Polygon mainnet
|
|
115
|
+
* - Solana mainnet
|
|
116
|
+
*
|
|
117
|
+
* @example
|
|
118
|
+
* ```typescript
|
|
119
|
+
* import { SwapChain, swap, createSwapKitContext } from '@circle-fin/swap-kit'
|
|
120
|
+
* import { createViemAdapterFromPrivateKey } from '@circle-fin/adapter-viem-v2'
|
|
121
|
+
*
|
|
122
|
+
* const context = createSwapKitContext()
|
|
123
|
+
* const adapter = createViemAdapterFromPrivateKey({
|
|
124
|
+
* privateKey: process.env.PRIVATE_KEY
|
|
125
|
+
* })
|
|
126
|
+
*
|
|
127
|
+
* // ✅ Autocomplete shows only swap-supported chains
|
|
128
|
+
* const result = await swap(context, {
|
|
129
|
+
* from: {
|
|
130
|
+
* adapter,
|
|
131
|
+
* chain: SwapChain.Ethereum // Autocomplete: Ethereum, Base, Polygon, Solana
|
|
132
|
+
* },
|
|
133
|
+
* tokenIn: 'USDC',
|
|
134
|
+
* tokenOut: 'USDT',
|
|
135
|
+
* amount: '100.0'
|
|
136
|
+
* })
|
|
137
|
+
* ```
|
|
138
|
+
*
|
|
139
|
+
* @example
|
|
140
|
+
* ```typescript
|
|
141
|
+
* // String literals also work (constrained to SwapChain values)
|
|
142
|
+
* const result = await swap(context, {
|
|
143
|
+
* from: {
|
|
144
|
+
* adapter,
|
|
145
|
+
* chain: 'Ethereum' // ✅ Only SwapChain strings allowed
|
|
146
|
+
* },
|
|
147
|
+
* tokenIn: 'USDC',
|
|
148
|
+
* tokenOut: 'NATIVE',
|
|
149
|
+
* amount: '50.0'
|
|
150
|
+
* })
|
|
151
|
+
*
|
|
152
|
+
* // ❌ TypeScript error - Sui not in SwapChain enum
|
|
153
|
+
* const invalidResult = await swap(context, {
|
|
154
|
+
* from: {
|
|
155
|
+
* adapter,
|
|
156
|
+
* chain: 'Sui' // Compile-time error!
|
|
157
|
+
* },
|
|
158
|
+
* tokenIn: 'USDC',
|
|
159
|
+
* tokenOut: 'USDT',
|
|
160
|
+
* amount: '100.0'
|
|
161
|
+
* })
|
|
162
|
+
* ```
|
|
163
|
+
*/
|
|
164
|
+
/**
|
|
165
|
+
* Enum representing chains that support same-chain swaps through the Swap Kit.
|
|
166
|
+
*
|
|
167
|
+
* Unlike the full {@link Blockchain} enum, SwapChain includes only mainnet
|
|
168
|
+
* networks where adapter contracts are deployed (CCTPv2 support).
|
|
169
|
+
*
|
|
170
|
+
* Dynamic validation via {@link isSwapSupportedChain} ensures chains
|
|
171
|
+
* automatically work when adapter contracts and supported tokens are deployed.
|
|
172
|
+
*
|
|
173
|
+
* @example
|
|
174
|
+
* ```typescript
|
|
175
|
+
* import { SwapChain } from '@core/chains'
|
|
176
|
+
* import { swap } from '@circle-fin/swap-kit'
|
|
177
|
+
*
|
|
178
|
+
* const result = await swap(context, {
|
|
179
|
+
* from: {
|
|
180
|
+
* adapter,
|
|
181
|
+
* chain: SwapChain.Arbitrum // Now supported!
|
|
182
|
+
* },
|
|
183
|
+
* tokenIn: 'USDC',
|
|
184
|
+
* tokenOut: 'WETH',
|
|
185
|
+
* amount: '100.0'
|
|
186
|
+
* })
|
|
187
|
+
* ```
|
|
188
|
+
*
|
|
189
|
+
* @see {@link isSwapSupportedChain} for runtime validation
|
|
190
|
+
* @see {@link getSwapSupportedChains} for all supported chains
|
|
191
|
+
*/
|
|
192
|
+
var SwapChain;
|
|
193
|
+
(function (SwapChain) {
|
|
194
|
+
// Original 4 chains
|
|
195
|
+
SwapChain["Ethereum"] = "Ethereum";
|
|
196
|
+
SwapChain["Base"] = "Base";
|
|
197
|
+
SwapChain["Polygon"] = "Polygon";
|
|
198
|
+
SwapChain["Solana"] = "Solana";
|
|
199
|
+
// Additional supported chains
|
|
200
|
+
SwapChain["Arbitrum"] = "Arbitrum";
|
|
201
|
+
SwapChain["Optimism"] = "Optimism";
|
|
202
|
+
SwapChain["Avalanche"] = "Avalanche";
|
|
203
|
+
SwapChain["Linea"] = "Linea";
|
|
204
|
+
SwapChain["Ink"] = "Ink";
|
|
205
|
+
SwapChain["World_Chain"] = "World_Chain";
|
|
206
|
+
SwapChain["Unichain"] = "Unichain";
|
|
207
|
+
SwapChain["Plume"] = "Plume";
|
|
208
|
+
SwapChain["Sei"] = "Sei";
|
|
209
|
+
SwapChain["Sonic"] = "Sonic";
|
|
210
|
+
SwapChain["XDC"] = "XDC";
|
|
211
|
+
SwapChain["HyperEVM"] = "HyperEVM";
|
|
212
|
+
SwapChain["Monad"] = "Monad";
|
|
213
|
+
})(SwapChain || (SwapChain = {}));
|
|
98
214
|
// -----------------------------------------------------------------------------
|
|
99
215
|
// Bridge Chain Enum (CCTPv2 Supported Chains)
|
|
100
216
|
// -----------------------------------------------------------------------------
|
|
@@ -246,6 +362,7 @@ defineChain({
|
|
|
246
362
|
rpcEndpoints: ['https://mainnet-api.algonode.cloud'],
|
|
247
363
|
eurcAddress: null,
|
|
248
364
|
usdcAddress: '31566704',
|
|
365
|
+
usdtAddress: null,
|
|
249
366
|
cctp: null,
|
|
250
367
|
});
|
|
251
368
|
|
|
@@ -269,6 +386,7 @@ defineChain({
|
|
|
269
386
|
rpcEndpoints: ['https://testnet-api.algonode.cloud'],
|
|
270
387
|
eurcAddress: null,
|
|
271
388
|
usdcAddress: '10458941',
|
|
389
|
+
usdtAddress: null,
|
|
272
390
|
cctp: null,
|
|
273
391
|
});
|
|
274
392
|
|
|
@@ -292,6 +410,7 @@ defineChain({
|
|
|
292
410
|
rpcEndpoints: ['https://fullnode.mainnet.aptoslabs.com/v1'],
|
|
293
411
|
eurcAddress: null,
|
|
294
412
|
usdcAddress: '0xbae207659db88bea0cbead6da0ed00aac12edcdda169e591cd41c94180b46f3b',
|
|
413
|
+
usdtAddress: '0x357b0b74bc833e95a115ad22604854d6b0fca151cecd94111770e5d6ffc9dc2b',
|
|
295
414
|
cctp: {
|
|
296
415
|
domain: 9,
|
|
297
416
|
contracts: {
|
|
@@ -302,6 +421,10 @@ defineChain({
|
|
|
302
421
|
confirmations: 1,
|
|
303
422
|
},
|
|
304
423
|
},
|
|
424
|
+
forwarderSupported: {
|
|
425
|
+
source: false,
|
|
426
|
+
destination: false,
|
|
427
|
+
},
|
|
305
428
|
},
|
|
306
429
|
});
|
|
307
430
|
|
|
@@ -325,6 +448,7 @@ defineChain({
|
|
|
325
448
|
rpcEndpoints: ['https://fullnode.testnet.aptoslabs.com/v1'],
|
|
326
449
|
eurcAddress: null,
|
|
327
450
|
usdcAddress: '0x69091fbab5f7d635ee7ac5098cf0c1efbe31d68fec0f2cd565e8d168daf52832',
|
|
451
|
+
usdtAddress: null,
|
|
328
452
|
cctp: {
|
|
329
453
|
domain: 9,
|
|
330
454
|
contracts: {
|
|
@@ -335,9 +459,128 @@ defineChain({
|
|
|
335
459
|
confirmations: 1,
|
|
336
460
|
},
|
|
337
461
|
},
|
|
462
|
+
forwarderSupported: {
|
|
463
|
+
source: false,
|
|
464
|
+
destination: false,
|
|
465
|
+
},
|
|
338
466
|
},
|
|
339
467
|
});
|
|
340
468
|
|
|
469
|
+
/**
|
|
470
|
+
* Complete swap token registry - single source of truth for all swap-supported tokens.
|
|
471
|
+
*
|
|
472
|
+
* @remarks
|
|
473
|
+
* All packages should import from this registry for swap operations.
|
|
474
|
+
* Adding a new swap token requires updating only this registry.
|
|
475
|
+
*
|
|
476
|
+
* The NATIVE token is handled separately as it resolves dynamically based on chain.
|
|
477
|
+
*
|
|
478
|
+
* @example
|
|
479
|
+
* ```typescript
|
|
480
|
+
* import { SWAP_TOKEN_REGISTRY } from '@core/chains'
|
|
481
|
+
*
|
|
482
|
+
* // Get token decimals
|
|
483
|
+
* const decimals = SWAP_TOKEN_REGISTRY.USDC.decimals // 6
|
|
484
|
+
*
|
|
485
|
+
* // Check if token is stablecoin
|
|
486
|
+
* const isStable = SWAP_TOKEN_REGISTRY.DAI.category === 'stablecoin' // true
|
|
487
|
+
* ```
|
|
488
|
+
*/
|
|
489
|
+
const SWAP_TOKEN_REGISTRY = {
|
|
490
|
+
// ============================================================================
|
|
491
|
+
// Stablecoins (6 decimals)
|
|
492
|
+
// ============================================================================
|
|
493
|
+
USDC: {
|
|
494
|
+
symbol: 'USDC',
|
|
495
|
+
decimals: 6,
|
|
496
|
+
category: 'stablecoin',
|
|
497
|
+
description: 'USD Coin',
|
|
498
|
+
},
|
|
499
|
+
EURC: {
|
|
500
|
+
symbol: 'EURC',
|
|
501
|
+
decimals: 6,
|
|
502
|
+
category: 'stablecoin',
|
|
503
|
+
description: 'Euro Coin',
|
|
504
|
+
},
|
|
505
|
+
USDT: {
|
|
506
|
+
symbol: 'USDT',
|
|
507
|
+
decimals: 6,
|
|
508
|
+
category: 'stablecoin',
|
|
509
|
+
description: 'Tether USD',
|
|
510
|
+
},
|
|
511
|
+
PYUSD: {
|
|
512
|
+
symbol: 'PYUSD',
|
|
513
|
+
decimals: 6,
|
|
514
|
+
category: 'stablecoin',
|
|
515
|
+
description: 'PayPal USD',
|
|
516
|
+
},
|
|
517
|
+
// ============================================================================
|
|
518
|
+
// Stablecoins (18 decimals)
|
|
519
|
+
// ============================================================================
|
|
520
|
+
DAI: {
|
|
521
|
+
symbol: 'DAI',
|
|
522
|
+
decimals: 18,
|
|
523
|
+
category: 'stablecoin',
|
|
524
|
+
description: 'MakerDAO stablecoin',
|
|
525
|
+
},
|
|
526
|
+
USDE: {
|
|
527
|
+
symbol: 'USDE',
|
|
528
|
+
decimals: 18,
|
|
529
|
+
category: 'stablecoin',
|
|
530
|
+
description: 'Ethena USD (synthetic dollar)',
|
|
531
|
+
},
|
|
532
|
+
// ============================================================================
|
|
533
|
+
// Wrapped Tokens
|
|
534
|
+
// ============================================================================
|
|
535
|
+
WBTC: {
|
|
536
|
+
symbol: 'WBTC',
|
|
537
|
+
decimals: 8,
|
|
538
|
+
category: 'wrapped',
|
|
539
|
+
description: 'Wrapped Bitcoin',
|
|
540
|
+
},
|
|
541
|
+
WETH: {
|
|
542
|
+
symbol: 'WETH',
|
|
543
|
+
decimals: 18,
|
|
544
|
+
category: 'wrapped',
|
|
545
|
+
description: 'Wrapped Ethereum',
|
|
546
|
+
},
|
|
547
|
+
WSOL: {
|
|
548
|
+
symbol: 'WSOL',
|
|
549
|
+
decimals: 9,
|
|
550
|
+
category: 'wrapped',
|
|
551
|
+
description: 'Wrapped Solana',
|
|
552
|
+
},
|
|
553
|
+
WAVAX: {
|
|
554
|
+
symbol: 'WAVAX',
|
|
555
|
+
decimals: 18,
|
|
556
|
+
category: 'wrapped',
|
|
557
|
+
description: 'Wrapped Avalanche',
|
|
558
|
+
},
|
|
559
|
+
WPOL: {
|
|
560
|
+
symbol: 'WPOL',
|
|
561
|
+
decimals: 18,
|
|
562
|
+
category: 'wrapped',
|
|
563
|
+
description: 'Wrapped Polygon',
|
|
564
|
+
},
|
|
565
|
+
};
|
|
566
|
+
/**
|
|
567
|
+
* Special NATIVE token constant for swap operations.
|
|
568
|
+
*
|
|
569
|
+
* @remarks
|
|
570
|
+
* NATIVE is handled separately from SWAP_TOKEN_REGISTRY because it resolves
|
|
571
|
+
* dynamically based on the chain (ETH on Ethereum, SOL on Solana, etc.).
|
|
572
|
+
* Its decimals are chain-specific.
|
|
573
|
+
*/
|
|
574
|
+
const NATIVE_TOKEN = 'NATIVE';
|
|
575
|
+
/**
|
|
576
|
+
* Array of all supported swap token symbols including NATIVE.
|
|
577
|
+
* Useful for iteration, validation, and filtering.
|
|
578
|
+
*/
|
|
579
|
+
[
|
|
580
|
+
...Object.keys(SWAP_TOKEN_REGISTRY),
|
|
581
|
+
NATIVE_TOKEN,
|
|
582
|
+
];
|
|
583
|
+
|
|
341
584
|
/**
|
|
342
585
|
* The bridge contract address for EVM testnet networks.
|
|
343
586
|
*
|
|
@@ -354,6 +597,13 @@ const BRIDGE_CONTRACT_EVM_TESTNET = '0xC5567a5E3370d4DBfB0540025078e283e36A363d'
|
|
|
354
597
|
* USDC transfers on live networks.
|
|
355
598
|
*/
|
|
356
599
|
const BRIDGE_CONTRACT_EVM_MAINNET = '0xB3FA262d0fB521cc93bE83d87b322b8A23DAf3F0';
|
|
600
|
+
/**
|
|
601
|
+
* The adapter contract address for EVM mainnet networks.
|
|
602
|
+
*
|
|
603
|
+
* This contract serves as an adapter for integrating with various protocols
|
|
604
|
+
* on EVM-compatible chains. Use this address for mainnet adapter integrations.
|
|
605
|
+
*/
|
|
606
|
+
const ADAPTER_CONTRACT_EVM_MAINNET = '0x7FB8c7260b63934d8da38aF902f87ae6e284a845';
|
|
357
607
|
|
|
358
608
|
/**
|
|
359
609
|
* Arc Testnet chain definition
|
|
@@ -383,6 +633,7 @@ const ArcTestnet = defineChain({
|
|
|
383
633
|
rpcEndpoints: ['https://rpc.testnet.arc.network/'],
|
|
384
634
|
eurcAddress: '0x89B50855Aa3bE2F677cD6303Cec089B5F319D72a',
|
|
385
635
|
usdcAddress: '0x3600000000000000000000000000000000000000',
|
|
636
|
+
usdtAddress: null,
|
|
386
637
|
cctp: {
|
|
387
638
|
domain: 26,
|
|
388
639
|
contracts: {
|
|
@@ -394,6 +645,10 @@ const ArcTestnet = defineChain({
|
|
|
394
645
|
fastConfirmations: 1,
|
|
395
646
|
},
|
|
396
647
|
},
|
|
648
|
+
forwarderSupported: {
|
|
649
|
+
source: true,
|
|
650
|
+
destination: true,
|
|
651
|
+
},
|
|
397
652
|
},
|
|
398
653
|
kitContracts: {
|
|
399
654
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -421,6 +676,7 @@ const Arbitrum = defineChain({
|
|
|
421
676
|
rpcEndpoints: ['https://arb1.arbitrum.io/rpc'],
|
|
422
677
|
eurcAddress: null,
|
|
423
678
|
usdcAddress: '0xaf88d065e77c8cc2239327c5edb3a432268e5831',
|
|
679
|
+
usdtAddress: null,
|
|
424
680
|
cctp: {
|
|
425
681
|
domain: 3,
|
|
426
682
|
contracts: {
|
|
@@ -438,9 +694,14 @@ const Arbitrum = defineChain({
|
|
|
438
694
|
fastConfirmations: 1,
|
|
439
695
|
},
|
|
440
696
|
},
|
|
697
|
+
forwarderSupported: {
|
|
698
|
+
source: true,
|
|
699
|
+
destination: true,
|
|
700
|
+
},
|
|
441
701
|
},
|
|
442
702
|
kitContracts: {
|
|
443
703
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
704
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
444
705
|
},
|
|
445
706
|
});
|
|
446
707
|
|
|
@@ -465,6 +726,7 @@ const ArbitrumSepolia = defineChain({
|
|
|
465
726
|
rpcEndpoints: ['https://sepolia-rollup.arbitrum.io/rpc'],
|
|
466
727
|
eurcAddress: null,
|
|
467
728
|
usdcAddress: '0x75faf114eafb1BDbe2F0316DF893fd58CE46AA4d',
|
|
729
|
+
usdtAddress: null,
|
|
468
730
|
cctp: {
|
|
469
731
|
domain: 3,
|
|
470
732
|
contracts: {
|
|
@@ -482,6 +744,10 @@ const ArbitrumSepolia = defineChain({
|
|
|
482
744
|
fastConfirmations: 1,
|
|
483
745
|
},
|
|
484
746
|
},
|
|
747
|
+
forwarderSupported: {
|
|
748
|
+
source: true,
|
|
749
|
+
destination: true,
|
|
750
|
+
},
|
|
485
751
|
},
|
|
486
752
|
kitContracts: {
|
|
487
753
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -509,6 +775,7 @@ const Avalanche = defineChain({
|
|
|
509
775
|
rpcEndpoints: ['https://api.avax.network/ext/bc/C/rpc'],
|
|
510
776
|
eurcAddress: '0xc891eb4cbdeff6e073e859e987815ed1505c2acd',
|
|
511
777
|
usdcAddress: '0xB97EF9Ef8734C71904D8002F8b6Bc66Dd9c48a6E',
|
|
778
|
+
usdtAddress: '0x9702230a8ea53601f5cd2dc00fdbc13d4df4a8c7',
|
|
512
779
|
cctp: {
|
|
513
780
|
domain: 1,
|
|
514
781
|
contracts: {
|
|
@@ -526,9 +793,14 @@ const Avalanche = defineChain({
|
|
|
526
793
|
fastConfirmations: 1,
|
|
527
794
|
},
|
|
528
795
|
},
|
|
796
|
+
forwarderSupported: {
|
|
797
|
+
source: true,
|
|
798
|
+
destination: true,
|
|
799
|
+
},
|
|
529
800
|
},
|
|
530
801
|
kitContracts: {
|
|
531
802
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
803
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
532
804
|
},
|
|
533
805
|
});
|
|
534
806
|
|
|
@@ -552,6 +824,7 @@ const AvalancheFuji = defineChain({
|
|
|
552
824
|
explorerUrl: 'https://subnets-test.avax.network/c-chain/tx/{hash}',
|
|
553
825
|
eurcAddress: '0x5e44db7996c682e92a960b65ac713a54ad815c6b',
|
|
554
826
|
usdcAddress: '0x5425890298aed601595a70ab815c96711a31bc65',
|
|
827
|
+
usdtAddress: null,
|
|
555
828
|
cctp: {
|
|
556
829
|
domain: 1,
|
|
557
830
|
contracts: {
|
|
@@ -569,6 +842,10 @@ const AvalancheFuji = defineChain({
|
|
|
569
842
|
fastConfirmations: 1,
|
|
570
843
|
},
|
|
571
844
|
},
|
|
845
|
+
forwarderSupported: {
|
|
846
|
+
source: true,
|
|
847
|
+
destination: true,
|
|
848
|
+
},
|
|
572
849
|
},
|
|
573
850
|
rpcEndpoints: ['https://api.avax-test.network/ext/bc/C/rpc'],
|
|
574
851
|
kitContracts: {
|
|
@@ -597,6 +874,7 @@ const Base = defineChain({
|
|
|
597
874
|
rpcEndpoints: ['https://mainnet.base.org', 'https://base.publicnode.com'],
|
|
598
875
|
eurcAddress: '0x60a3e35cc302bfa44cb288bc5a4f316fdb1adb42',
|
|
599
876
|
usdcAddress: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913',
|
|
877
|
+
usdtAddress: null,
|
|
600
878
|
cctp: {
|
|
601
879
|
domain: 6,
|
|
602
880
|
contracts: {
|
|
@@ -614,9 +892,14 @@ const Base = defineChain({
|
|
|
614
892
|
fastConfirmations: 1,
|
|
615
893
|
},
|
|
616
894
|
},
|
|
895
|
+
forwarderSupported: {
|
|
896
|
+
source: true,
|
|
897
|
+
destination: true,
|
|
898
|
+
},
|
|
617
899
|
},
|
|
618
900
|
kitContracts: {
|
|
619
901
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
902
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
620
903
|
},
|
|
621
904
|
});
|
|
622
905
|
|
|
@@ -641,6 +924,7 @@ const BaseSepolia = defineChain({
|
|
|
641
924
|
rpcEndpoints: ['https://sepolia.base.org'],
|
|
642
925
|
eurcAddress: '0x808456652fdb597867f38412077A9182bf77359F',
|
|
643
926
|
usdcAddress: '0x036CbD53842c5426634e7929541eC2318f3dCF7e',
|
|
927
|
+
usdtAddress: null,
|
|
644
928
|
cctp: {
|
|
645
929
|
domain: 6,
|
|
646
930
|
contracts: {
|
|
@@ -658,6 +942,10 @@ const BaseSepolia = defineChain({
|
|
|
658
942
|
fastConfirmations: 1,
|
|
659
943
|
},
|
|
660
944
|
},
|
|
945
|
+
forwarderSupported: {
|
|
946
|
+
source: true,
|
|
947
|
+
destination: true,
|
|
948
|
+
},
|
|
661
949
|
},
|
|
662
950
|
kitContracts: {
|
|
663
951
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -685,6 +973,7 @@ defineChain({
|
|
|
685
973
|
rpcEndpoints: ['https://forno.celo.org'],
|
|
686
974
|
eurcAddress: null,
|
|
687
975
|
usdcAddress: '0xcebA9300f2b948710d2653dD7B07f33A8B32118C',
|
|
976
|
+
usdtAddress: '0x48065fbBE25f71C9282ddf5e1cD6D6A887483D5e',
|
|
688
977
|
cctp: null,
|
|
689
978
|
});
|
|
690
979
|
|
|
@@ -709,6 +998,7 @@ defineChain({
|
|
|
709
998
|
rpcEndpoints: ['https://alfajores-forno.celo-testnet.org'],
|
|
710
999
|
eurcAddress: null,
|
|
711
1000
|
usdcAddress: '0x2F25deB3848C207fc8E0c34035B3Ba7fC157602B',
|
|
1001
|
+
usdtAddress: null,
|
|
712
1002
|
cctp: null,
|
|
713
1003
|
});
|
|
714
1004
|
|
|
@@ -733,6 +1023,7 @@ const Codex = defineChain({
|
|
|
733
1023
|
rpcEndpoints: ['https://rpc.codex.xyz'],
|
|
734
1024
|
eurcAddress: null,
|
|
735
1025
|
usdcAddress: '0xd996633a415985DBd7D6D12f4A4343E31f5037cf',
|
|
1026
|
+
usdtAddress: null,
|
|
736
1027
|
cctp: {
|
|
737
1028
|
domain: 12,
|
|
738
1029
|
contracts: {
|
|
@@ -744,6 +1035,10 @@ const Codex = defineChain({
|
|
|
744
1035
|
fastConfirmations: 1,
|
|
745
1036
|
},
|
|
746
1037
|
},
|
|
1038
|
+
forwarderSupported: {
|
|
1039
|
+
source: true,
|
|
1040
|
+
destination: false,
|
|
1041
|
+
},
|
|
747
1042
|
},
|
|
748
1043
|
kitContracts: {
|
|
749
1044
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
@@ -771,6 +1066,7 @@ const CodexTestnet = defineChain({
|
|
|
771
1066
|
rpcEndpoints: ['https://rpc.codex-stg.xyz'],
|
|
772
1067
|
eurcAddress: null,
|
|
773
1068
|
usdcAddress: '0x6d7f141b6819C2c9CC2f818e6ad549E7Ca090F8f',
|
|
1069
|
+
usdtAddress: null,
|
|
774
1070
|
cctp: {
|
|
775
1071
|
domain: 12,
|
|
776
1072
|
contracts: {
|
|
@@ -782,6 +1078,10 @@ const CodexTestnet = defineChain({
|
|
|
782
1078
|
fastConfirmations: 1,
|
|
783
1079
|
},
|
|
784
1080
|
},
|
|
1081
|
+
forwarderSupported: {
|
|
1082
|
+
source: true,
|
|
1083
|
+
destination: false,
|
|
1084
|
+
},
|
|
785
1085
|
},
|
|
786
1086
|
kitContracts: {
|
|
787
1087
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -809,6 +1109,7 @@ const Ethereum = defineChain({
|
|
|
809
1109
|
rpcEndpoints: ['https://eth.merkle.io', 'https://ethereum.publicnode.com'],
|
|
810
1110
|
eurcAddress: '0x1aBaEA1f7C830bD89Acc67eC4af516284b1bC33c',
|
|
811
1111
|
usdcAddress: '0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48',
|
|
1112
|
+
usdtAddress: '0xdac17f958d2ee523a2206206994597c13d831ec7',
|
|
812
1113
|
cctp: {
|
|
813
1114
|
domain: 0,
|
|
814
1115
|
contracts: {
|
|
@@ -826,9 +1127,14 @@ const Ethereum = defineChain({
|
|
|
826
1127
|
fastConfirmations: 2,
|
|
827
1128
|
},
|
|
828
1129
|
},
|
|
1130
|
+
forwarderSupported: {
|
|
1131
|
+
source: true,
|
|
1132
|
+
destination: true,
|
|
1133
|
+
},
|
|
829
1134
|
},
|
|
830
1135
|
kitContracts: {
|
|
831
1136
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
1137
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
832
1138
|
},
|
|
833
1139
|
});
|
|
834
1140
|
|
|
@@ -853,6 +1159,7 @@ const EthereumSepolia = defineChain({
|
|
|
853
1159
|
rpcEndpoints: ['https://sepolia.drpc.org'],
|
|
854
1160
|
eurcAddress: '0x08210F9170F89Ab7658F0B5E3fF39b0E03C594D4',
|
|
855
1161
|
usdcAddress: '0x1c7D4B196Cb0C7B01d743Fbc6116a902379C7238',
|
|
1162
|
+
usdtAddress: null,
|
|
856
1163
|
cctp: {
|
|
857
1164
|
domain: 0,
|
|
858
1165
|
contracts: {
|
|
@@ -870,6 +1177,10 @@ const EthereumSepolia = defineChain({
|
|
|
870
1177
|
fastConfirmations: 2,
|
|
871
1178
|
},
|
|
872
1179
|
},
|
|
1180
|
+
forwarderSupported: {
|
|
1181
|
+
source: true,
|
|
1182
|
+
destination: true,
|
|
1183
|
+
},
|
|
873
1184
|
},
|
|
874
1185
|
kitContracts: {
|
|
875
1186
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -896,6 +1207,7 @@ defineChain({
|
|
|
896
1207
|
rpcEndpoints: ['https://mainnet.hashio.io/api'],
|
|
897
1208
|
eurcAddress: null,
|
|
898
1209
|
usdcAddress: '0.0.456858',
|
|
1210
|
+
usdtAddress: null,
|
|
899
1211
|
cctp: null,
|
|
900
1212
|
});
|
|
901
1213
|
|
|
@@ -919,6 +1231,7 @@ defineChain({
|
|
|
919
1231
|
rpcEndpoints: ['https://testnet.hashio.io/api'],
|
|
920
1232
|
eurcAddress: null,
|
|
921
1233
|
usdcAddress: '0.0.429274',
|
|
1234
|
+
usdtAddress: null,
|
|
922
1235
|
cctp: null,
|
|
923
1236
|
});
|
|
924
1237
|
|
|
@@ -945,6 +1258,7 @@ const HyperEVM = defineChain({
|
|
|
945
1258
|
rpcEndpoints: ['https://rpc.hyperliquid.xyz/evm'],
|
|
946
1259
|
eurcAddress: null,
|
|
947
1260
|
usdcAddress: '0xb88339CB7199b77E23DB6E890353E22632Ba630f',
|
|
1261
|
+
usdtAddress: null,
|
|
948
1262
|
cctp: {
|
|
949
1263
|
domain: 19,
|
|
950
1264
|
contracts: {
|
|
@@ -956,9 +1270,14 @@ const HyperEVM = defineChain({
|
|
|
956
1270
|
fastConfirmations: 1,
|
|
957
1271
|
},
|
|
958
1272
|
},
|
|
1273
|
+
forwarderSupported: {
|
|
1274
|
+
source: true,
|
|
1275
|
+
destination: true,
|
|
1276
|
+
},
|
|
959
1277
|
},
|
|
960
1278
|
kitContracts: {
|
|
961
1279
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
1280
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
962
1281
|
},
|
|
963
1282
|
});
|
|
964
1283
|
|
|
@@ -984,6 +1303,7 @@ const HyperEVMTestnet = defineChain({
|
|
|
984
1303
|
rpcEndpoints: ['https://rpc.hyperliquid-testnet.xyz/evm'],
|
|
985
1304
|
eurcAddress: null,
|
|
986
1305
|
usdcAddress: '0x2B3370eE501B4a559b57D449569354196457D8Ab',
|
|
1306
|
+
usdtAddress: null,
|
|
987
1307
|
cctp: {
|
|
988
1308
|
domain: 19,
|
|
989
1309
|
contracts: {
|
|
@@ -995,6 +1315,10 @@ const HyperEVMTestnet = defineChain({
|
|
|
995
1315
|
fastConfirmations: 1,
|
|
996
1316
|
},
|
|
997
1317
|
},
|
|
1318
|
+
forwarderSupported: {
|
|
1319
|
+
source: true,
|
|
1320
|
+
destination: true,
|
|
1321
|
+
},
|
|
998
1322
|
},
|
|
999
1323
|
kitContracts: {
|
|
1000
1324
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1027,6 +1351,7 @@ const Ink = defineChain({
|
|
|
1027
1351
|
],
|
|
1028
1352
|
eurcAddress: null,
|
|
1029
1353
|
usdcAddress: '0x2D270e6886d130D724215A266106e6832161EAEd',
|
|
1354
|
+
usdtAddress: null,
|
|
1030
1355
|
cctp: {
|
|
1031
1356
|
domain: 21,
|
|
1032
1357
|
contracts: {
|
|
@@ -1038,9 +1363,14 @@ const Ink = defineChain({
|
|
|
1038
1363
|
fastConfirmations: 1,
|
|
1039
1364
|
},
|
|
1040
1365
|
},
|
|
1366
|
+
forwarderSupported: {
|
|
1367
|
+
source: true,
|
|
1368
|
+
destination: true,
|
|
1369
|
+
},
|
|
1041
1370
|
},
|
|
1042
1371
|
kitContracts: {
|
|
1043
1372
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
1373
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
1044
1374
|
},
|
|
1045
1375
|
});
|
|
1046
1376
|
|
|
@@ -1069,6 +1399,7 @@ const InkTestnet = defineChain({
|
|
|
1069
1399
|
],
|
|
1070
1400
|
eurcAddress: null,
|
|
1071
1401
|
usdcAddress: '0xFabab97dCE620294D2B0b0e46C68964e326300Ac',
|
|
1402
|
+
usdtAddress: null,
|
|
1072
1403
|
cctp: {
|
|
1073
1404
|
domain: 21,
|
|
1074
1405
|
contracts: {
|
|
@@ -1080,6 +1411,10 @@ const InkTestnet = defineChain({
|
|
|
1080
1411
|
fastConfirmations: 1,
|
|
1081
1412
|
},
|
|
1082
1413
|
},
|
|
1414
|
+
forwarderSupported: {
|
|
1415
|
+
source: true,
|
|
1416
|
+
destination: true,
|
|
1417
|
+
},
|
|
1083
1418
|
},
|
|
1084
1419
|
kitContracts: {
|
|
1085
1420
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1107,6 +1442,7 @@ const Linea = defineChain({
|
|
|
1107
1442
|
rpcEndpoints: ['https://rpc.linea.build'],
|
|
1108
1443
|
eurcAddress: null,
|
|
1109
1444
|
usdcAddress: '0x176211869ca2b568f2a7d4ee941e073a821ee1ff',
|
|
1445
|
+
usdtAddress: null,
|
|
1110
1446
|
cctp: {
|
|
1111
1447
|
domain: 11,
|
|
1112
1448
|
contracts: {
|
|
@@ -1118,9 +1454,14 @@ const Linea = defineChain({
|
|
|
1118
1454
|
fastConfirmations: 1,
|
|
1119
1455
|
},
|
|
1120
1456
|
},
|
|
1457
|
+
forwarderSupported: {
|
|
1458
|
+
source: true,
|
|
1459
|
+
destination: true,
|
|
1460
|
+
},
|
|
1121
1461
|
},
|
|
1122
1462
|
kitContracts: {
|
|
1123
1463
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
1464
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
1124
1465
|
},
|
|
1125
1466
|
});
|
|
1126
1467
|
|
|
@@ -1145,6 +1486,7 @@ const LineaSepolia = defineChain({
|
|
|
1145
1486
|
rpcEndpoints: ['https://rpc.sepolia.linea.build'],
|
|
1146
1487
|
eurcAddress: null,
|
|
1147
1488
|
usdcAddress: '0xfece4462d57bd51a6a552365a011b95f0e16d9b7',
|
|
1489
|
+
usdtAddress: null,
|
|
1148
1490
|
cctp: {
|
|
1149
1491
|
domain: 11,
|
|
1150
1492
|
contracts: {
|
|
@@ -1156,6 +1498,10 @@ const LineaSepolia = defineChain({
|
|
|
1156
1498
|
fastConfirmations: 1,
|
|
1157
1499
|
},
|
|
1158
1500
|
},
|
|
1501
|
+
forwarderSupported: {
|
|
1502
|
+
source: true,
|
|
1503
|
+
destination: true,
|
|
1504
|
+
},
|
|
1159
1505
|
},
|
|
1160
1506
|
kitContracts: {
|
|
1161
1507
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1185,6 +1531,7 @@ const Monad = defineChain({
|
|
|
1185
1531
|
rpcEndpoints: ['https://rpc.monad.xyz'],
|
|
1186
1532
|
eurcAddress: null,
|
|
1187
1533
|
usdcAddress: '0x754704Bc059F8C67012fEd69BC8A327a5aafb603',
|
|
1534
|
+
usdtAddress: null,
|
|
1188
1535
|
cctp: {
|
|
1189
1536
|
domain: 15,
|
|
1190
1537
|
contracts: {
|
|
@@ -1196,9 +1543,14 @@ const Monad = defineChain({
|
|
|
1196
1543
|
fastConfirmations: 1,
|
|
1197
1544
|
},
|
|
1198
1545
|
},
|
|
1546
|
+
forwarderSupported: {
|
|
1547
|
+
source: true,
|
|
1548
|
+
destination: true,
|
|
1549
|
+
},
|
|
1199
1550
|
},
|
|
1200
1551
|
kitContracts: {
|
|
1201
1552
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
1553
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
1202
1554
|
},
|
|
1203
1555
|
});
|
|
1204
1556
|
|
|
@@ -1225,6 +1577,7 @@ const MonadTestnet = defineChain({
|
|
|
1225
1577
|
rpcEndpoints: ['https://testnet-rpc.monad.xyz'],
|
|
1226
1578
|
eurcAddress: null,
|
|
1227
1579
|
usdcAddress: '0x534b2f3A21130d7a60830c2Df862319e593943A3',
|
|
1580
|
+
usdtAddress: null,
|
|
1228
1581
|
cctp: {
|
|
1229
1582
|
domain: 15,
|
|
1230
1583
|
contracts: {
|
|
@@ -1236,6 +1589,10 @@ const MonadTestnet = defineChain({
|
|
|
1236
1589
|
fastConfirmations: 1,
|
|
1237
1590
|
},
|
|
1238
1591
|
},
|
|
1592
|
+
forwarderSupported: {
|
|
1593
|
+
source: true,
|
|
1594
|
+
destination: true,
|
|
1595
|
+
},
|
|
1239
1596
|
},
|
|
1240
1597
|
kitContracts: {
|
|
1241
1598
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1262,6 +1619,7 @@ defineChain({
|
|
|
1262
1619
|
rpcEndpoints: ['https://eth-rpc.mainnet.near.org'],
|
|
1263
1620
|
eurcAddress: null,
|
|
1264
1621
|
usdcAddress: '17208628f84f5d6ad33f0da3bbbeb27ffcb398eac501a31bd6ad2011e36133a1',
|
|
1622
|
+
usdtAddress: 'usdt.tether-token.near',
|
|
1265
1623
|
cctp: null,
|
|
1266
1624
|
});
|
|
1267
1625
|
|
|
@@ -1285,6 +1643,7 @@ defineChain({
|
|
|
1285
1643
|
rpcEndpoints: ['https://eth-rpc.testnet.near.org'],
|
|
1286
1644
|
eurcAddress: null,
|
|
1287
1645
|
usdcAddress: '3e2210e1184b45b64c8a434c0a7e7b23cc04ea7eb7a6c3c32520d03d4afcb8af',
|
|
1646
|
+
usdtAddress: null,
|
|
1288
1647
|
cctp: null,
|
|
1289
1648
|
});
|
|
1290
1649
|
|
|
@@ -1308,6 +1667,7 @@ defineChain({
|
|
|
1308
1667
|
rpcEndpoints: ['https://noble-rpc.polkachu.com'],
|
|
1309
1668
|
eurcAddress: null,
|
|
1310
1669
|
usdcAddress: 'uusdc',
|
|
1670
|
+
usdtAddress: null,
|
|
1311
1671
|
cctp: {
|
|
1312
1672
|
domain: 4,
|
|
1313
1673
|
contracts: {
|
|
@@ -1317,6 +1677,10 @@ defineChain({
|
|
|
1317
1677
|
confirmations: 1,
|
|
1318
1678
|
},
|
|
1319
1679
|
},
|
|
1680
|
+
forwarderSupported: {
|
|
1681
|
+
source: false,
|
|
1682
|
+
destination: false,
|
|
1683
|
+
},
|
|
1320
1684
|
},
|
|
1321
1685
|
});
|
|
1322
1686
|
|
|
@@ -1340,6 +1704,7 @@ defineChain({
|
|
|
1340
1704
|
rpcEndpoints: ['https://noble-testnet-rpc.polkachu.com'],
|
|
1341
1705
|
eurcAddress: null,
|
|
1342
1706
|
usdcAddress: 'uusdc',
|
|
1707
|
+
usdtAddress: null,
|
|
1343
1708
|
cctp: {
|
|
1344
1709
|
domain: 4,
|
|
1345
1710
|
contracts: {
|
|
@@ -1349,6 +1714,10 @@ defineChain({
|
|
|
1349
1714
|
confirmations: 1,
|
|
1350
1715
|
},
|
|
1351
1716
|
},
|
|
1717
|
+
forwarderSupported: {
|
|
1718
|
+
source: false,
|
|
1719
|
+
destination: false,
|
|
1720
|
+
},
|
|
1352
1721
|
},
|
|
1353
1722
|
});
|
|
1354
1723
|
|
|
@@ -1373,6 +1742,7 @@ const Optimism = defineChain({
|
|
|
1373
1742
|
rpcEndpoints: ['https://mainnet.optimism.io'],
|
|
1374
1743
|
eurcAddress: null,
|
|
1375
1744
|
usdcAddress: '0x0b2c639c533813f4aa9d7837caf62653d097ff85',
|
|
1745
|
+
usdtAddress: null,
|
|
1376
1746
|
cctp: {
|
|
1377
1747
|
domain: 2,
|
|
1378
1748
|
contracts: {
|
|
@@ -1390,9 +1760,14 @@ const Optimism = defineChain({
|
|
|
1390
1760
|
fastConfirmations: 1,
|
|
1391
1761
|
},
|
|
1392
1762
|
},
|
|
1763
|
+
forwarderSupported: {
|
|
1764
|
+
source: true,
|
|
1765
|
+
destination: true,
|
|
1766
|
+
},
|
|
1393
1767
|
},
|
|
1394
1768
|
kitContracts: {
|
|
1395
1769
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
1770
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
1396
1771
|
},
|
|
1397
1772
|
});
|
|
1398
1773
|
|
|
@@ -1417,6 +1792,7 @@ const OptimismSepolia = defineChain({
|
|
|
1417
1792
|
rpcEndpoints: ['https://sepolia.optimism.io'],
|
|
1418
1793
|
eurcAddress: null,
|
|
1419
1794
|
usdcAddress: '0x5fd84259d66Cd46123540766Be93DFE6D43130D7',
|
|
1795
|
+
usdtAddress: null,
|
|
1420
1796
|
cctp: {
|
|
1421
1797
|
domain: 2,
|
|
1422
1798
|
contracts: {
|
|
@@ -1434,6 +1810,10 @@ const OptimismSepolia = defineChain({
|
|
|
1434
1810
|
fastConfirmations: 1,
|
|
1435
1811
|
},
|
|
1436
1812
|
},
|
|
1813
|
+
forwarderSupported: {
|
|
1814
|
+
source: true,
|
|
1815
|
+
destination: true,
|
|
1816
|
+
},
|
|
1437
1817
|
},
|
|
1438
1818
|
kitContracts: {
|
|
1439
1819
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1463,6 +1843,7 @@ const Plume = defineChain({
|
|
|
1463
1843
|
rpcEndpoints: ['https://rpc.plume.org'],
|
|
1464
1844
|
eurcAddress: null,
|
|
1465
1845
|
usdcAddress: '0x222365EF19F7947e5484218551B56bb3965Aa7aF',
|
|
1846
|
+
usdtAddress: null,
|
|
1466
1847
|
cctp: {
|
|
1467
1848
|
domain: 22,
|
|
1468
1849
|
contracts: {
|
|
@@ -1474,9 +1855,14 @@ const Plume = defineChain({
|
|
|
1474
1855
|
fastConfirmations: 1,
|
|
1475
1856
|
},
|
|
1476
1857
|
},
|
|
1858
|
+
forwarderSupported: {
|
|
1859
|
+
source: true,
|
|
1860
|
+
destination: false,
|
|
1861
|
+
},
|
|
1477
1862
|
},
|
|
1478
1863
|
kitContracts: {
|
|
1479
1864
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
1865
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
1480
1866
|
},
|
|
1481
1867
|
});
|
|
1482
1868
|
|
|
@@ -1502,6 +1888,7 @@ const PlumeTestnet = defineChain({
|
|
|
1502
1888
|
rpcEndpoints: ['https://testnet-rpc.plume.org'],
|
|
1503
1889
|
eurcAddress: null,
|
|
1504
1890
|
usdcAddress: '0xcB5f30e335672893c7eb944B374c196392C19D18',
|
|
1891
|
+
usdtAddress: null,
|
|
1505
1892
|
cctp: {
|
|
1506
1893
|
domain: 22,
|
|
1507
1894
|
contracts: {
|
|
@@ -1513,6 +1900,10 @@ const PlumeTestnet = defineChain({
|
|
|
1513
1900
|
fastConfirmations: 1,
|
|
1514
1901
|
},
|
|
1515
1902
|
},
|
|
1903
|
+
forwarderSupported: {
|
|
1904
|
+
source: true,
|
|
1905
|
+
destination: false,
|
|
1906
|
+
},
|
|
1516
1907
|
},
|
|
1517
1908
|
kitContracts: {
|
|
1518
1909
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1539,6 +1930,7 @@ defineChain({
|
|
|
1539
1930
|
rpcEndpoints: ['https://asset-hub-polkadot-rpc.n.dwellir.com'],
|
|
1540
1931
|
eurcAddress: null,
|
|
1541
1932
|
usdcAddress: '1337',
|
|
1933
|
+
usdtAddress: '1984',
|
|
1542
1934
|
cctp: null,
|
|
1543
1935
|
});
|
|
1544
1936
|
|
|
@@ -1562,6 +1954,7 @@ defineChain({
|
|
|
1562
1954
|
rpcEndpoints: ['https://westmint-rpc.polkadot.io'],
|
|
1563
1955
|
eurcAddress: null,
|
|
1564
1956
|
usdcAddress: 'Asset ID 31337',
|
|
1957
|
+
usdtAddress: null,
|
|
1565
1958
|
cctp: null,
|
|
1566
1959
|
});
|
|
1567
1960
|
|
|
@@ -1583,9 +1976,10 @@ const Polygon = defineChain({
|
|
|
1583
1976
|
chainId: 137,
|
|
1584
1977
|
isTestnet: false,
|
|
1585
1978
|
explorerUrl: 'https://polygonscan.com/tx/{hash}',
|
|
1586
|
-
rpcEndpoints: ['https://polygon
|
|
1979
|
+
rpcEndpoints: ['https://polygon.publicnode.com', 'https://polygon.drpc.org'],
|
|
1587
1980
|
eurcAddress: null,
|
|
1588
1981
|
usdcAddress: '0x3c499c542cef5e3811e1192ce70d8cc03d5c3359',
|
|
1982
|
+
usdtAddress: null,
|
|
1589
1983
|
cctp: {
|
|
1590
1984
|
domain: 7,
|
|
1591
1985
|
contracts: {
|
|
@@ -1603,9 +1997,14 @@ const Polygon = defineChain({
|
|
|
1603
1997
|
fastConfirmations: 13,
|
|
1604
1998
|
},
|
|
1605
1999
|
},
|
|
2000
|
+
forwarderSupported: {
|
|
2001
|
+
source: true,
|
|
2002
|
+
destination: true,
|
|
2003
|
+
},
|
|
1606
2004
|
},
|
|
1607
2005
|
kitContracts: {
|
|
1608
2006
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
2007
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
1609
2008
|
},
|
|
1610
2009
|
});
|
|
1611
2010
|
|
|
@@ -1630,6 +2029,7 @@ const PolygonAmoy = defineChain({
|
|
|
1630
2029
|
rpcEndpoints: ['https://rpc-amoy.polygon.technology'],
|
|
1631
2030
|
eurcAddress: null,
|
|
1632
2031
|
usdcAddress: '0x41e94eb019c0762f9bfcf9fb1e58725bfb0e7582',
|
|
2032
|
+
usdtAddress: null,
|
|
1633
2033
|
cctp: {
|
|
1634
2034
|
domain: 7,
|
|
1635
2035
|
contracts: {
|
|
@@ -1647,6 +2047,10 @@ const PolygonAmoy = defineChain({
|
|
|
1647
2047
|
fastConfirmations: 13,
|
|
1648
2048
|
},
|
|
1649
2049
|
},
|
|
2050
|
+
forwarderSupported: {
|
|
2051
|
+
source: true,
|
|
2052
|
+
destination: true,
|
|
2053
|
+
},
|
|
1650
2054
|
},
|
|
1651
2055
|
kitContracts: {
|
|
1652
2056
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1676,6 +2080,7 @@ const Sei = defineChain({
|
|
|
1676
2080
|
rpcEndpoints: ['https://evm-rpc.sei-apis.com'],
|
|
1677
2081
|
eurcAddress: null,
|
|
1678
2082
|
usdcAddress: '0xe15fC38F6D8c56aF07bbCBe3BAf5708A2Bf42392',
|
|
2083
|
+
usdtAddress: null,
|
|
1679
2084
|
cctp: {
|
|
1680
2085
|
domain: 16,
|
|
1681
2086
|
contracts: {
|
|
@@ -1687,9 +2092,14 @@ const Sei = defineChain({
|
|
|
1687
2092
|
fastConfirmations: 1,
|
|
1688
2093
|
},
|
|
1689
2094
|
},
|
|
2095
|
+
forwarderSupported: {
|
|
2096
|
+
source: true,
|
|
2097
|
+
destination: true,
|
|
2098
|
+
},
|
|
1690
2099
|
},
|
|
1691
2100
|
kitContracts: {
|
|
1692
2101
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
2102
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
1693
2103
|
},
|
|
1694
2104
|
});
|
|
1695
2105
|
|
|
@@ -1715,6 +2125,7 @@ const SeiTestnet = defineChain({
|
|
|
1715
2125
|
rpcEndpoints: ['https://evm-rpc-testnet.sei-apis.com'],
|
|
1716
2126
|
eurcAddress: null,
|
|
1717
2127
|
usdcAddress: '0x4fCF1784B31630811181f670Aea7A7bEF803eaED',
|
|
2128
|
+
usdtAddress: null,
|
|
1718
2129
|
cctp: {
|
|
1719
2130
|
domain: 16,
|
|
1720
2131
|
contracts: {
|
|
@@ -1726,6 +2137,10 @@ const SeiTestnet = defineChain({
|
|
|
1726
2137
|
fastConfirmations: 1,
|
|
1727
2138
|
},
|
|
1728
2139
|
},
|
|
2140
|
+
forwarderSupported: {
|
|
2141
|
+
source: true,
|
|
2142
|
+
destination: true,
|
|
2143
|
+
},
|
|
1729
2144
|
},
|
|
1730
2145
|
kitContracts: {
|
|
1731
2146
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1753,6 +2168,7 @@ const Sonic = defineChain({
|
|
|
1753
2168
|
rpcEndpoints: ['https://rpc.soniclabs.com'],
|
|
1754
2169
|
eurcAddress: null,
|
|
1755
2170
|
usdcAddress: '0x29219dd400f2Bf60E5a23d13Be72B486D4038894',
|
|
2171
|
+
usdtAddress: null,
|
|
1756
2172
|
cctp: {
|
|
1757
2173
|
domain: 13,
|
|
1758
2174
|
contracts: {
|
|
@@ -1764,9 +2180,14 @@ const Sonic = defineChain({
|
|
|
1764
2180
|
fastConfirmations: 1,
|
|
1765
2181
|
},
|
|
1766
2182
|
},
|
|
2183
|
+
forwarderSupported: {
|
|
2184
|
+
source: true,
|
|
2185
|
+
destination: true,
|
|
2186
|
+
},
|
|
1767
2187
|
},
|
|
1768
2188
|
kitContracts: {
|
|
1769
2189
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
2190
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
1770
2191
|
},
|
|
1771
2192
|
});
|
|
1772
2193
|
|
|
@@ -1791,6 +2212,7 @@ const SonicTestnet = defineChain({
|
|
|
1791
2212
|
rpcEndpoints: ['https://rpc.testnet.soniclabs.com'],
|
|
1792
2213
|
eurcAddress: null,
|
|
1793
2214
|
usdcAddress: '0x0BA304580ee7c9a980CF72e55f5Ed2E9fd30Bc51',
|
|
2215
|
+
usdtAddress: null,
|
|
1794
2216
|
cctp: {
|
|
1795
2217
|
domain: 13,
|
|
1796
2218
|
contracts: {
|
|
@@ -1802,6 +2224,10 @@ const SonicTestnet = defineChain({
|
|
|
1802
2224
|
fastConfirmations: 1,
|
|
1803
2225
|
},
|
|
1804
2226
|
},
|
|
2227
|
+
forwarderSupported: {
|
|
2228
|
+
source: true,
|
|
2229
|
+
destination: true,
|
|
2230
|
+
},
|
|
1805
2231
|
},
|
|
1806
2232
|
kitContracts: {
|
|
1807
2233
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -1828,6 +2254,7 @@ const Solana = defineChain({
|
|
|
1828
2254
|
rpcEndpoints: ['https://api.mainnet-beta.solana.com'],
|
|
1829
2255
|
eurcAddress: 'HzwqbKZw8HxMN6bF2yFZNrht3c2iXXzpKcFu7uBEDKtr',
|
|
1830
2256
|
usdcAddress: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v',
|
|
2257
|
+
usdtAddress: 'Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB',
|
|
1831
2258
|
cctp: {
|
|
1832
2259
|
domain: 5,
|
|
1833
2260
|
contracts: {
|
|
@@ -1845,6 +2272,10 @@ const Solana = defineChain({
|
|
|
1845
2272
|
fastConfirmations: 3,
|
|
1846
2273
|
},
|
|
1847
2274
|
},
|
|
2275
|
+
forwarderSupported: {
|
|
2276
|
+
source: true,
|
|
2277
|
+
destination: false,
|
|
2278
|
+
},
|
|
1848
2279
|
},
|
|
1849
2280
|
kitContracts: {
|
|
1850
2281
|
bridge: 'DFaauJEjmiHkPs1JG89A4p95hDWi9m9SAEERY1LQJiC3',
|
|
@@ -1870,6 +2301,7 @@ const SolanaDevnet = defineChain({
|
|
|
1870
2301
|
explorerUrl: 'https://solscan.io/tx/{hash}?cluster=devnet',
|
|
1871
2302
|
eurcAddress: 'HzwqbKZw8HxMN6bF2yFZNrht3c2iXXzpKcFu7uBEDKtr',
|
|
1872
2303
|
usdcAddress: '4zMMC9srt5Ri5X14GAgXhaHii3GnPAEERYPJgZJDncDU',
|
|
2304
|
+
usdtAddress: null,
|
|
1873
2305
|
cctp: {
|
|
1874
2306
|
domain: 5,
|
|
1875
2307
|
contracts: {
|
|
@@ -1887,6 +2319,10 @@ const SolanaDevnet = defineChain({
|
|
|
1887
2319
|
fastConfirmations: 3,
|
|
1888
2320
|
},
|
|
1889
2321
|
},
|
|
2322
|
+
forwarderSupported: {
|
|
2323
|
+
source: true,
|
|
2324
|
+
destination: false,
|
|
2325
|
+
},
|
|
1890
2326
|
},
|
|
1891
2327
|
kitContracts: {
|
|
1892
2328
|
bridge: 'DFaauJEjmiHkPs1JG89A4p95hDWi9m9SAEERY1LQJiC3',
|
|
@@ -1914,6 +2350,7 @@ defineChain({
|
|
|
1914
2350
|
rpcEndpoints: ['https://horizon.stellar.org'],
|
|
1915
2351
|
eurcAddress: 'EURC-GDHU6WRG4IEQXM5NZ4BMPKOXHW76MZM4Y2IEMFDVXBSDP6SJY4ITNPP2',
|
|
1916
2352
|
usdcAddress: 'USDC-GA5ZSEJYB37JRC5AVCIA5MOP4RHTM335X2KGX3IHOJAPP5RE34K4KZVN',
|
|
2353
|
+
usdtAddress: null,
|
|
1917
2354
|
cctp: null,
|
|
1918
2355
|
});
|
|
1919
2356
|
|
|
@@ -1937,6 +2374,7 @@ defineChain({
|
|
|
1937
2374
|
rpcEndpoints: ['https://horizon-testnet.stellar.org'],
|
|
1938
2375
|
eurcAddress: 'EURC-GB3Q6QDZYTHWT7E5PVS3W7FUT5GVAFC5KSZFFLPU25GO7VTC3NM2ZTVO',
|
|
1939
2376
|
usdcAddress: 'USDC-GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5',
|
|
2377
|
+
usdtAddress: null,
|
|
1940
2378
|
cctp: null,
|
|
1941
2379
|
});
|
|
1942
2380
|
|
|
@@ -1960,6 +2398,7 @@ defineChain({
|
|
|
1960
2398
|
rpcEndpoints: ['https://fullnode.mainnet.sui.io'],
|
|
1961
2399
|
eurcAddress: null,
|
|
1962
2400
|
usdcAddress: '0xdba34672e30cb065b1f93e3ab55318768fd6fef66c15942c9f7cb846e2f900e7::usdc::USDC',
|
|
2401
|
+
usdtAddress: null,
|
|
1963
2402
|
cctp: {
|
|
1964
2403
|
domain: 8,
|
|
1965
2404
|
contracts: {
|
|
@@ -1970,6 +2409,10 @@ defineChain({
|
|
|
1970
2409
|
confirmations: 1,
|
|
1971
2410
|
},
|
|
1972
2411
|
},
|
|
2412
|
+
forwarderSupported: {
|
|
2413
|
+
source: false,
|
|
2414
|
+
destination: false,
|
|
2415
|
+
},
|
|
1973
2416
|
},
|
|
1974
2417
|
});
|
|
1975
2418
|
|
|
@@ -1993,6 +2436,7 @@ defineChain({
|
|
|
1993
2436
|
rpcEndpoints: ['https://fullnode.testnet.sui.io'],
|
|
1994
2437
|
eurcAddress: null,
|
|
1995
2438
|
usdcAddress: '0xa1ec7fc00a6f40db9693ad1415d0c193ad3906494428cf252621037bd7117e29::usdc::USDC',
|
|
2439
|
+
usdtAddress: null,
|
|
1996
2440
|
cctp: {
|
|
1997
2441
|
domain: 8,
|
|
1998
2442
|
contracts: {
|
|
@@ -2003,6 +2447,10 @@ defineChain({
|
|
|
2003
2447
|
confirmations: 1,
|
|
2004
2448
|
},
|
|
2005
2449
|
},
|
|
2450
|
+
forwarderSupported: {
|
|
2451
|
+
source: false,
|
|
2452
|
+
destination: false,
|
|
2453
|
+
},
|
|
2006
2454
|
},
|
|
2007
2455
|
});
|
|
2008
2456
|
|
|
@@ -2024,9 +2472,10 @@ const Unichain = defineChain({
|
|
|
2024
2472
|
chainId: 130,
|
|
2025
2473
|
isTestnet: false,
|
|
2026
2474
|
explorerUrl: 'https://unichain.blockscout.com/tx/{hash}',
|
|
2027
|
-
rpcEndpoints: ['https://
|
|
2475
|
+
rpcEndpoints: ['https://mainnet.unichain.org'],
|
|
2028
2476
|
eurcAddress: null,
|
|
2029
2477
|
usdcAddress: '0x078D782b760474a361dDA0AF3839290b0EF57AD6',
|
|
2478
|
+
usdtAddress: null,
|
|
2030
2479
|
cctp: {
|
|
2031
2480
|
domain: 10,
|
|
2032
2481
|
contracts: {
|
|
@@ -2044,9 +2493,14 @@ const Unichain = defineChain({
|
|
|
2044
2493
|
fastConfirmations: 1,
|
|
2045
2494
|
},
|
|
2046
2495
|
},
|
|
2496
|
+
forwarderSupported: {
|
|
2497
|
+
source: true,
|
|
2498
|
+
destination: true,
|
|
2499
|
+
},
|
|
2047
2500
|
},
|
|
2048
2501
|
kitContracts: {
|
|
2049
2502
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
2503
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
2050
2504
|
},
|
|
2051
2505
|
});
|
|
2052
2506
|
|
|
@@ -2071,6 +2525,7 @@ const UnichainSepolia = defineChain({
|
|
|
2071
2525
|
rpcEndpoints: ['https://sepolia.unichain.org'],
|
|
2072
2526
|
eurcAddress: null,
|
|
2073
2527
|
usdcAddress: '0x31d0220469e10c4E71834a79b1f276d740d3768F',
|
|
2528
|
+
usdtAddress: null,
|
|
2074
2529
|
cctp: {
|
|
2075
2530
|
domain: 10,
|
|
2076
2531
|
contracts: {
|
|
@@ -2088,6 +2543,10 @@ const UnichainSepolia = defineChain({
|
|
|
2088
2543
|
fastConfirmations: 1,
|
|
2089
2544
|
},
|
|
2090
2545
|
},
|
|
2546
|
+
forwarderSupported: {
|
|
2547
|
+
source: true,
|
|
2548
|
+
destination: true,
|
|
2549
|
+
},
|
|
2091
2550
|
},
|
|
2092
2551
|
kitContracts: {
|
|
2093
2552
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -2114,7 +2573,8 @@ const WorldChain = defineChain({
|
|
|
2114
2573
|
explorerUrl: 'https://worldscan.org/tx/{hash}',
|
|
2115
2574
|
rpcEndpoints: ['https://worldchain-mainnet.g.alchemy.com/public'],
|
|
2116
2575
|
eurcAddress: null,
|
|
2117
|
-
usdcAddress: '
|
|
2576
|
+
usdcAddress: '0x79A02482A880bCE3F13e09Da970dC34db4CD24d1',
|
|
2577
|
+
usdtAddress: null,
|
|
2118
2578
|
cctp: {
|
|
2119
2579
|
domain: 14,
|
|
2120
2580
|
contracts: {
|
|
@@ -2126,9 +2586,14 @@ const WorldChain = defineChain({
|
|
|
2126
2586
|
fastConfirmations: 1,
|
|
2127
2587
|
},
|
|
2128
2588
|
},
|
|
2589
|
+
forwarderSupported: {
|
|
2590
|
+
source: true,
|
|
2591
|
+
destination: true,
|
|
2592
|
+
},
|
|
2129
2593
|
},
|
|
2130
2594
|
kitContracts: {
|
|
2131
2595
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
2596
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
2132
2597
|
},
|
|
2133
2598
|
});
|
|
2134
2599
|
|
|
@@ -2156,6 +2621,7 @@ const WorldChainSepolia = defineChain({
|
|
|
2156
2621
|
],
|
|
2157
2622
|
eurcAddress: null,
|
|
2158
2623
|
usdcAddress: '0x66145f38cBAC35Ca6F1Dfb4914dF98F1614aeA88',
|
|
2624
|
+
usdtAddress: null,
|
|
2159
2625
|
cctp: {
|
|
2160
2626
|
domain: 14,
|
|
2161
2627
|
contracts: {
|
|
@@ -2167,6 +2633,10 @@ const WorldChainSepolia = defineChain({
|
|
|
2167
2633
|
fastConfirmations: 1,
|
|
2168
2634
|
},
|
|
2169
2635
|
},
|
|
2636
|
+
forwarderSupported: {
|
|
2637
|
+
source: true,
|
|
2638
|
+
destination: true,
|
|
2639
|
+
},
|
|
2170
2640
|
},
|
|
2171
2641
|
kitContracts: {
|
|
2172
2642
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -2193,9 +2663,10 @@ const XDC = defineChain({
|
|
|
2193
2663
|
chainId: 50,
|
|
2194
2664
|
isTestnet: false,
|
|
2195
2665
|
explorerUrl: 'https://xdcscan.io/tx/{hash}',
|
|
2196
|
-
rpcEndpoints: ['https://erpc.xinfin.network'],
|
|
2666
|
+
rpcEndpoints: ['https://erpc.xdcrpc.com', 'https://erpc.xinfin.network'],
|
|
2197
2667
|
eurcAddress: null,
|
|
2198
2668
|
usdcAddress: '0xfA2958CB79b0491CC627c1557F441eF849Ca8eb1',
|
|
2669
|
+
usdtAddress: null,
|
|
2199
2670
|
cctp: {
|
|
2200
2671
|
domain: 18,
|
|
2201
2672
|
contracts: {
|
|
@@ -2207,9 +2678,14 @@ const XDC = defineChain({
|
|
|
2207
2678
|
fastConfirmations: 3,
|
|
2208
2679
|
},
|
|
2209
2680
|
},
|
|
2681
|
+
forwarderSupported: {
|
|
2682
|
+
source: true,
|
|
2683
|
+
destination: false,
|
|
2684
|
+
},
|
|
2210
2685
|
},
|
|
2211
2686
|
kitContracts: {
|
|
2212
2687
|
bridge: BRIDGE_CONTRACT_EVM_MAINNET,
|
|
2688
|
+
adapter: ADAPTER_CONTRACT_EVM_MAINNET,
|
|
2213
2689
|
},
|
|
2214
2690
|
});
|
|
2215
2691
|
|
|
@@ -2234,6 +2710,7 @@ const XDCApothem = defineChain({
|
|
|
2234
2710
|
rpcEndpoints: ['https://erpc.apothem.network'],
|
|
2235
2711
|
eurcAddress: null,
|
|
2236
2712
|
usdcAddress: '0xb5AB69F7bBada22B28e79C8FFAECe55eF1c771D4',
|
|
2713
|
+
usdtAddress: null,
|
|
2237
2714
|
cctp: {
|
|
2238
2715
|
domain: 18,
|
|
2239
2716
|
contracts: {
|
|
@@ -2245,6 +2722,10 @@ const XDCApothem = defineChain({
|
|
|
2245
2722
|
fastConfirmations: 1,
|
|
2246
2723
|
},
|
|
2247
2724
|
},
|
|
2725
|
+
forwarderSupported: {
|
|
2726
|
+
source: true,
|
|
2727
|
+
destination: false,
|
|
2728
|
+
},
|
|
2248
2729
|
},
|
|
2249
2730
|
kitContracts: {
|
|
2250
2731
|
bridge: BRIDGE_CONTRACT_EVM_TESTNET,
|
|
@@ -2272,6 +2753,7 @@ defineChain({
|
|
|
2272
2753
|
rpcEndpoints: ['https://mainnet.era.zksync.io'],
|
|
2273
2754
|
eurcAddress: null,
|
|
2274
2755
|
usdcAddress: '0x1d17CBcF0D6D143135aE902365D2E5e2A16538D4',
|
|
2756
|
+
usdtAddress: null,
|
|
2275
2757
|
cctp: null,
|
|
2276
2758
|
});
|
|
2277
2759
|
|
|
@@ -2296,6 +2778,7 @@ defineChain({
|
|
|
2296
2778
|
rpcEndpoints: ['https://sepolia.era.zksync.dev'],
|
|
2297
2779
|
eurcAddress: null,
|
|
2298
2780
|
usdcAddress: '0xAe045DE5638162fa134807Cb558E15A3F5A7F853',
|
|
2781
|
+
usdtAddress: null,
|
|
2299
2782
|
cctp: null,
|
|
2300
2783
|
});
|
|
2301
2784
|
|
|
@@ -2329,10 +2812,12 @@ const baseChainDefinitionSchema = zod.z.object({
|
|
|
2329
2812
|
rpcEndpoints: zod.z.array(zod.z.string()),
|
|
2330
2813
|
eurcAddress: zod.z.string().nullable(),
|
|
2331
2814
|
usdcAddress: zod.z.string().nullable(),
|
|
2815
|
+
usdtAddress: zod.z.string().nullable(),
|
|
2332
2816
|
cctp: zod.z.any().nullable(), // We'll accept any CCTP config structure
|
|
2333
2817
|
kitContracts: zod.z
|
|
2334
2818
|
.object({
|
|
2335
2819
|
bridge: zod.z.string().optional(),
|
|
2820
|
+
adapter: zod.z.string().optional(),
|
|
2336
2821
|
})
|
|
2337
2822
|
.optional(),
|
|
2338
2823
|
});
|
|
@@ -2447,6 +2932,29 @@ zod.z.union([
|
|
|
2447
2932
|
zod.z.nativeEnum(Blockchain),
|
|
2448
2933
|
chainDefinitionSchema,
|
|
2449
2934
|
]);
|
|
2935
|
+
/**
|
|
2936
|
+
* Zod schema for validating swap-specific chain identifiers.
|
|
2937
|
+
*
|
|
2938
|
+
* Validates chains based on:
|
|
2939
|
+
* - CCTPv2 support (adapter contract deployed)
|
|
2940
|
+
* - Mainnet only (no testnets)
|
|
2941
|
+
* - At least one supported token available
|
|
2942
|
+
*
|
|
2943
|
+
*/
|
|
2944
|
+
zod.z.union([
|
|
2945
|
+
// String blockchain identifier (accepts SwapChain enum values)
|
|
2946
|
+
zod.z.string().refine((val) => val in SwapChain, (val) => ({
|
|
2947
|
+
message: `"${val}" is not a supported swap chain. ` +
|
|
2948
|
+
`Supported chains: ${Object.values(SwapChain).join(', ')}`,
|
|
2949
|
+
})),
|
|
2950
|
+
// SwapChain enum
|
|
2951
|
+
zod.z.nativeEnum(SwapChain),
|
|
2952
|
+
// ChainDefinition object (checks if chain.chain is in SwapChain)
|
|
2953
|
+
chainDefinitionSchema.refine((chain) => chain.chain in SwapChain, (chain) => ({
|
|
2954
|
+
message: `"${chain.chain}" is not a supported swap chain. ` +
|
|
2955
|
+
`Supported chains: ${Object.values(SwapChain).join(', ')}`,
|
|
2956
|
+
})),
|
|
2957
|
+
]);
|
|
2450
2958
|
/**
|
|
2451
2959
|
* Zod schema for validating bridge chain identifiers.
|
|
2452
2960
|
*
|
|
@@ -2486,6 +2994,38 @@ zod.z.union([
|
|
|
2486
2994
|
})),
|
|
2487
2995
|
]);
|
|
2488
2996
|
|
|
2997
|
+
/**
|
|
2998
|
+
* @packageDocumentation
|
|
2999
|
+
* @module SwapTokenSchemas
|
|
3000
|
+
*
|
|
3001
|
+
* Zod validation schemas for supported swap tokens.
|
|
3002
|
+
*/
|
|
3003
|
+
// Internal enum used after input normalization.
|
|
3004
|
+
const swapTokenEnumSchema = zod.z.enum([
|
|
3005
|
+
...Object.keys(SWAP_TOKEN_REGISTRY),
|
|
3006
|
+
NATIVE_TOKEN,
|
|
3007
|
+
]);
|
|
3008
|
+
/**
|
|
3009
|
+
* Zod schema for validating supported swap token symbols.
|
|
3010
|
+
*
|
|
3011
|
+
* Accepts any token symbol from the SWAP_TOKEN_REGISTRY plus NATIVE.
|
|
3012
|
+
* Input matching is case-insensitive and normalized to uppercase.
|
|
3013
|
+
*
|
|
3014
|
+
* @example
|
|
3015
|
+
* ```typescript
|
|
3016
|
+
* import { supportedSwapTokenSchema } from '@core/chains'
|
|
3017
|
+
*
|
|
3018
|
+
* const result = supportedSwapTokenSchema.safeParse('USDC')
|
|
3019
|
+
* if (result.success) {
|
|
3020
|
+
* console.log('Valid swap token:', result.data)
|
|
3021
|
+
* }
|
|
3022
|
+
* ```
|
|
3023
|
+
*/
|
|
3024
|
+
zod.z
|
|
3025
|
+
.string()
|
|
3026
|
+
.transform((value) => value.toUpperCase())
|
|
3027
|
+
.pipe(swapTokenEnumSchema);
|
|
3028
|
+
|
|
2489
3029
|
exports.Arbitrum = Arbitrum;
|
|
2490
3030
|
exports.ArbitrumSepolia = ArbitrumSepolia;
|
|
2491
3031
|
exports.ArcTestnet = ArcTestnet;
|