@snowbridge/registry 0.4.0 → 0.4.1-beta.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/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/dist/local_e2e_bridge_info.g.d.ts +141 -0
- package/dist/local_e2e_bridge_info.g.d.ts.map +1 -0
- package/dist/local_e2e_bridge_info.g.js +142 -0
- package/dist/paseo_sepolia_bridge_info.g.d.ts +8 -7
- package/dist/paseo_sepolia_bridge_info.g.d.ts.map +1 -1
- package/dist/paseo_sepolia_bridge_info.g.js +8 -7
- package/dist/polkadot_mainnet_bridge_info.g.d.ts +187 -33
- package/dist/polkadot_mainnet_bridge_info.g.d.ts.map +1 -1
- package/dist/polkadot_mainnet_bridge_info.g.js +223 -33
- package/dist/transfers.d.ts.map +1 -1
- package/dist/transfers.js +57 -38
- package/dist/westend_sepolia_bridge_info.g.d.ts +102 -14
- package/dist/westend_sepolia_bridge_info.g.d.ts.map +1 -1
- package/dist/westend_sepolia_bridge_info.g.js +125 -14
- package/package.json +6 -6
- package/scripts/buildRegistry.ts +170 -35
- package/src/index.ts +4 -1
- package/src/local_e2e_bridge_info.g.ts +140 -0
- package/src/paseo_sepolia_bridge_info.g.ts +8 -7
- package/src/polkadot_mainnet_bridge_info.g.ts +223 -33
- package/src/transfers.ts +50 -35
- package/src/westend_sepolia_bridge_info.g.ts +125 -14
|
@@ -7,13 +7,15 @@ const registry = {
|
|
|
7
7
|
beaconApiUrl: "https://lodestar-mainnet.chainsafe.io",
|
|
8
8
|
ethereumChains: {
|
|
9
9
|
"1": "https://ethereum-rpc.publicnode.com",
|
|
10
|
+
"10": "https://optimism-rpc.publicnode.com",
|
|
10
11
|
"1284": "https://rpc.api.moonbeam.network",
|
|
11
12
|
"8453": "https://base-rpc.publicnode.com",
|
|
13
|
+
"42161": "https://arbitrum-one-rpc.publicnode.com",
|
|
12
14
|
},
|
|
13
15
|
relaychainUrl: "https://polkadot-rpc.n.dwellir.com",
|
|
14
16
|
parachains: {
|
|
15
|
-
"1000": "wss://asset-hub-
|
|
16
|
-
"1002": "
|
|
17
|
+
"1000": "wss://polkadot-asset-hub-rpc.polkadot.io",
|
|
18
|
+
"1002": "wss://polkadot-bridge-hub-rpc.polkadot.io",
|
|
17
19
|
"2000": "wss://acala-rpc-0.aca-api.network",
|
|
18
20
|
"2004": "wss://moonbeam.ibp.network",
|
|
19
21
|
"2030": "wss://bifrost-polkadot.ibp.network",
|
|
@@ -22,11 +24,11 @@ const registry = {
|
|
|
22
24
|
"3369": "wss://polkadot-mythos-rpc.polkadot.io",
|
|
23
25
|
},
|
|
24
26
|
gatewayContract: "0x27ca963c279c93801941e1eb8799c23f407d68e7",
|
|
25
|
-
beefyContract: "
|
|
27
|
+
beefyContract: "0x1817874feab3ce053d0f40abc23870db35c2affc",
|
|
26
28
|
assetHubParaId: 1000,
|
|
27
29
|
bridgeHubParaId: 1002,
|
|
28
30
|
v2_parachains: [1000],
|
|
29
|
-
indexerGraphQlUrl: "https://snowbridge.
|
|
31
|
+
indexerGraphQlUrl: "https://subsquid.snowbridge.network/graphql",
|
|
30
32
|
kusama: {
|
|
31
33
|
assetHubParaId: 1000,
|
|
32
34
|
bridgeHubParaId: 1002,
|
|
@@ -45,14 +47,30 @@ const registry = {
|
|
|
45
47
|
},
|
|
46
48
|
l2Bridge: {
|
|
47
49
|
acrossAPIUrl: "https://app.across.to/api",
|
|
48
|
-
l1AdapterAddress: "
|
|
49
|
-
l1HandlerAddress: "
|
|
50
|
+
l1AdapterAddress: "0xd3b11c36404b092645522b682832fcdee07d2668",
|
|
51
|
+
l1HandlerAddress: "0x924a9f036260ddd5808007e1aa95f08ed08aa569",
|
|
50
52
|
l1FeeTokenAddress: "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
51
|
-
l1SwapQuoterAddress: "
|
|
52
|
-
l1SwapRouterAddress: "
|
|
53
|
+
l1SwapQuoterAddress: "0x61ffe014ba17989e743c5f6cb21bf9697530b21e",
|
|
54
|
+
l1SwapRouterAddress: "0xe592427a0aece92de3edee1f18e0157c05861564",
|
|
53
55
|
l2Chains: {
|
|
56
|
+
"10": {
|
|
57
|
+
adapterAddress: "0x836895ad176235dfe9c59b3df56c7579d90ea338",
|
|
58
|
+
feeTokenAddress: "0x4200000000000000000000000000000000000006",
|
|
59
|
+
swapRoutes: [
|
|
60
|
+
{
|
|
61
|
+
inputToken: "0x4200000000000000000000000000000000000006",
|
|
62
|
+
outputToken: "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
63
|
+
swapFee: 0,
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
inputToken: "0x0b2c639c533813f4aa9d7837caf62653d097ff85",
|
|
67
|
+
outputToken: "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
68
|
+
swapFee: 500,
|
|
69
|
+
},
|
|
70
|
+
],
|
|
71
|
+
},
|
|
54
72
|
"8453": {
|
|
55
|
-
adapterAddress: "
|
|
73
|
+
adapterAddress: "0x07fe4e7340976fc873b74bafe3c3e5b0e01f3665",
|
|
56
74
|
feeTokenAddress: "0x4200000000000000000000000000000000000006",
|
|
57
75
|
swapRoutes: [
|
|
58
76
|
{
|
|
@@ -61,8 +79,24 @@ const registry = {
|
|
|
61
79
|
swapFee: 0,
|
|
62
80
|
},
|
|
63
81
|
{
|
|
64
|
-
inputToken: "
|
|
65
|
-
outputToken: "
|
|
82
|
+
inputToken: "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
|
|
83
|
+
outputToken: "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
84
|
+
swapFee: 500,
|
|
85
|
+
},
|
|
86
|
+
],
|
|
87
|
+
},
|
|
88
|
+
"42161": {
|
|
89
|
+
adapterAddress: "0x836895ad176235dfe9c59b3df56c7579d90ea338",
|
|
90
|
+
feeTokenAddress: "0x82af49447d8a07e3bd95bd0d56f35241523fbab1",
|
|
91
|
+
swapRoutes: [
|
|
92
|
+
{
|
|
93
|
+
inputToken: "0x82af49447d8a07e3bd95bd0d56f35241523fbab1",
|
|
94
|
+
outputToken: "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
95
|
+
swapFee: 0,
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
inputToken: "0xaf88d065e77c8cc2239327c5edb3a432268e5831",
|
|
99
|
+
outputToken: "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
66
100
|
swapFee: 500,
|
|
67
101
|
},
|
|
68
102
|
],
|
|
@@ -435,9 +469,99 @@ const registry = {
|
|
|
435
469
|
"0x7fc66500c84a76ad7e9c93437bfc5ac33e2ddae9",
|
|
436
470
|
],
|
|
437
471
|
},
|
|
472
|
+
{
|
|
473
|
+
from: {
|
|
474
|
+
kind: "polkadot",
|
|
475
|
+
id: 1000,
|
|
476
|
+
},
|
|
477
|
+
to: {
|
|
478
|
+
kind: "ethereum_l2",
|
|
479
|
+
id: 10,
|
|
480
|
+
},
|
|
481
|
+
assets: [
|
|
482
|
+
"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
483
|
+
"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
484
|
+
"0x0000000000000000000000000000000000000000",
|
|
485
|
+
],
|
|
486
|
+
},
|
|
487
|
+
{
|
|
488
|
+
from: {
|
|
489
|
+
kind: "ethereum_l2",
|
|
490
|
+
id: 10,
|
|
491
|
+
},
|
|
492
|
+
to: {
|
|
493
|
+
kind: "polkadot",
|
|
494
|
+
id: 1000,
|
|
495
|
+
},
|
|
496
|
+
assets: [
|
|
497
|
+
"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
498
|
+
"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
499
|
+
"0x0000000000000000000000000000000000000000",
|
|
500
|
+
],
|
|
501
|
+
},
|
|
502
|
+
{
|
|
503
|
+
from: {
|
|
504
|
+
kind: "polkadot",
|
|
505
|
+
id: 1000,
|
|
506
|
+
},
|
|
507
|
+
to: {
|
|
508
|
+
kind: "ethereum_l2",
|
|
509
|
+
id: 8453,
|
|
510
|
+
},
|
|
511
|
+
assets: [
|
|
512
|
+
"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
513
|
+
"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
514
|
+
"0x0000000000000000000000000000000000000000",
|
|
515
|
+
],
|
|
516
|
+
},
|
|
517
|
+
{
|
|
518
|
+
from: {
|
|
519
|
+
kind: "ethereum_l2",
|
|
520
|
+
id: 8453,
|
|
521
|
+
},
|
|
522
|
+
to: {
|
|
523
|
+
kind: "polkadot",
|
|
524
|
+
id: 1000,
|
|
525
|
+
},
|
|
526
|
+
assets: [
|
|
527
|
+
"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
528
|
+
"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
529
|
+
"0x0000000000000000000000000000000000000000",
|
|
530
|
+
],
|
|
531
|
+
},
|
|
532
|
+
{
|
|
533
|
+
from: {
|
|
534
|
+
kind: "polkadot",
|
|
535
|
+
id: 1000,
|
|
536
|
+
},
|
|
537
|
+
to: {
|
|
538
|
+
kind: "ethereum_l2",
|
|
539
|
+
id: 42161,
|
|
540
|
+
},
|
|
541
|
+
assets: [
|
|
542
|
+
"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
543
|
+
"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
544
|
+
"0x0000000000000000000000000000000000000000",
|
|
545
|
+
],
|
|
546
|
+
},
|
|
547
|
+
{
|
|
548
|
+
from: {
|
|
549
|
+
kind: "ethereum_l2",
|
|
550
|
+
id: 42161,
|
|
551
|
+
},
|
|
552
|
+
to: {
|
|
553
|
+
kind: "polkadot",
|
|
554
|
+
id: 1000,
|
|
555
|
+
},
|
|
556
|
+
assets: [
|
|
557
|
+
"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
558
|
+
"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
559
|
+
"0x0000000000000000000000000000000000000000",
|
|
560
|
+
],
|
|
561
|
+
},
|
|
438
562
|
],
|
|
439
563
|
registry: {
|
|
440
|
-
timestamp: "2026-
|
|
564
|
+
timestamp: "2026-03-27T09:55:18.302Z",
|
|
441
565
|
environment: "polkadot_mainnet",
|
|
442
566
|
ethChainId: 1,
|
|
443
567
|
gatewayAddress: "0x27ca963c279c93801941e1eb8799c23f407d68e7",
|
|
@@ -451,7 +575,7 @@ const registry = {
|
|
|
451
575
|
accountType: "AccountId32",
|
|
452
576
|
name: "Polkadot",
|
|
453
577
|
specName: "polkadot",
|
|
454
|
-
specVersion:
|
|
578
|
+
specVersion: 2001001,
|
|
455
579
|
},
|
|
456
580
|
bridgeHub: {
|
|
457
581
|
tokenSymbols: "DOT",
|
|
@@ -461,12 +585,13 @@ const registry = {
|
|
|
461
585
|
accountType: "AccountId32",
|
|
462
586
|
name: "Polkadot BridgeHub",
|
|
463
587
|
specName: "bridge-hub-polkadot",
|
|
464
|
-
specVersion:
|
|
588
|
+
specVersion: 2001001,
|
|
465
589
|
},
|
|
466
590
|
ethereumChains: {
|
|
467
591
|
ethereum_1: {
|
|
468
592
|
kind: "ethereum",
|
|
469
593
|
id: 1,
|
|
594
|
+
name: "mainnet",
|
|
470
595
|
assets: {
|
|
471
596
|
"0x9d39a5de30e57443bff2a8307a4256c8797a3497": {
|
|
472
597
|
token: "0x9d39a5de30e57443bff2a8307a4256c8797a3497",
|
|
@@ -737,6 +862,38 @@ const registry = {
|
|
|
737
862
|
key: "ethereum_1",
|
|
738
863
|
baseDeliveryGas: 120000n,
|
|
739
864
|
},
|
|
865
|
+
ethereum_l2_10: {
|
|
866
|
+
kind: "ethereum_l2",
|
|
867
|
+
id: 10,
|
|
868
|
+
name: "optimism",
|
|
869
|
+
assets: {
|
|
870
|
+
"0x4200000000000000000000000000000000000006": {
|
|
871
|
+
token: "0x4200000000000000000000000000000000000006",
|
|
872
|
+
name: "Wrapped Ether",
|
|
873
|
+
symbol: "WETH",
|
|
874
|
+
decimals: 18,
|
|
875
|
+
swapTokenAddress: "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
876
|
+
swapFee: 0,
|
|
877
|
+
},
|
|
878
|
+
"0x0b2c639c533813f4aa9d7837caf62653d097ff85": {
|
|
879
|
+
token: "0x0b2c639c533813f4aa9d7837caf62653d097ff85",
|
|
880
|
+
name: "USD Coin",
|
|
881
|
+
symbol: "USDC",
|
|
882
|
+
decimals: 6,
|
|
883
|
+
swapTokenAddress: "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
884
|
+
swapFee: 500,
|
|
885
|
+
},
|
|
886
|
+
"0x0000000000000000000000000000000000000000": {
|
|
887
|
+
token: "0x0000000000000000000000000000000000000000",
|
|
888
|
+
name: "Ether",
|
|
889
|
+
symbol: "Ether",
|
|
890
|
+
decimals: 18,
|
|
891
|
+
swapTokenAddress: "0x0000000000000000000000000000000000000000",
|
|
892
|
+
swapFee: 0,
|
|
893
|
+
},
|
|
894
|
+
},
|
|
895
|
+
key: "ethereum_l2_10",
|
|
896
|
+
},
|
|
740
897
|
ethereum_1284: {
|
|
741
898
|
kind: "ethereum",
|
|
742
899
|
id: 1284,
|
|
@@ -807,6 +964,7 @@ const registry = {
|
|
|
807
964
|
ethereum_l2_8453: {
|
|
808
965
|
kind: "ethereum_l2",
|
|
809
966
|
id: 8453,
|
|
967
|
+
name: "base",
|
|
810
968
|
assets: {
|
|
811
969
|
"0x4200000000000000000000000000000000000006": {
|
|
812
970
|
token: "0x4200000000000000000000000000000000000006",
|
|
@@ -816,12 +974,12 @@ const registry = {
|
|
|
816
974
|
swapTokenAddress: "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
817
975
|
swapFee: 0,
|
|
818
976
|
},
|
|
819
|
-
"
|
|
820
|
-
token: "
|
|
977
|
+
"0x833589fcd6edb6e08f4c7c32d4f71b54bda02913": {
|
|
978
|
+
token: "0x833589fcd6edb6e08f4c7c32d4f71b54bda02913",
|
|
821
979
|
name: "USD Coin",
|
|
822
980
|
symbol: "USDC",
|
|
823
981
|
decimals: 6,
|
|
824
|
-
swapTokenAddress: "
|
|
982
|
+
swapTokenAddress: "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
825
983
|
swapFee: 500,
|
|
826
984
|
},
|
|
827
985
|
"0x0000000000000000000000000000000000000000": {
|
|
@@ -835,6 +993,38 @@ const registry = {
|
|
|
835
993
|
},
|
|
836
994
|
key: "ethereum_l2_8453",
|
|
837
995
|
},
|
|
996
|
+
ethereum_l2_42161: {
|
|
997
|
+
kind: "ethereum_l2",
|
|
998
|
+
id: 42161,
|
|
999
|
+
name: "arbitrum",
|
|
1000
|
+
assets: {
|
|
1001
|
+
"0x82af49447d8a07e3bd95bd0d56f35241523fbab1": {
|
|
1002
|
+
token: "0x82af49447d8a07e3bd95bd0d56f35241523fbab1",
|
|
1003
|
+
name: "Wrapped Ether",
|
|
1004
|
+
symbol: "WETH",
|
|
1005
|
+
decimals: 18,
|
|
1006
|
+
swapTokenAddress: "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
|
|
1007
|
+
swapFee: 0,
|
|
1008
|
+
},
|
|
1009
|
+
"0xaf88d065e77c8cc2239327c5edb3a432268e5831": {
|
|
1010
|
+
token: "0xaf88d065e77c8cc2239327c5edb3a432268e5831",
|
|
1011
|
+
name: "USD Coin",
|
|
1012
|
+
symbol: "USDC",
|
|
1013
|
+
decimals: 6,
|
|
1014
|
+
swapTokenAddress: "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",
|
|
1015
|
+
swapFee: 500,
|
|
1016
|
+
},
|
|
1017
|
+
"0x0000000000000000000000000000000000000000": {
|
|
1018
|
+
token: "0x0000000000000000000000000000000000000000",
|
|
1019
|
+
name: "Ether",
|
|
1020
|
+
symbol: "Ether",
|
|
1021
|
+
decimals: 18,
|
|
1022
|
+
swapTokenAddress: "0x0000000000000000000000000000000000000000",
|
|
1023
|
+
swapFee: 0,
|
|
1024
|
+
},
|
|
1025
|
+
},
|
|
1026
|
+
key: "ethereum_l2_42161",
|
|
1027
|
+
},
|
|
838
1028
|
},
|
|
839
1029
|
parachains: {
|
|
840
1030
|
polkadot_1000: {
|
|
@@ -861,7 +1051,7 @@ const registry = {
|
|
|
861
1051
|
accountType: "AccountId32",
|
|
862
1052
|
name: "Polkadot Asset Hub",
|
|
863
1053
|
specName: "statemint",
|
|
864
|
-
specVersion:
|
|
1054
|
+
specVersion: 2001001,
|
|
865
1055
|
},
|
|
866
1056
|
assets: {
|
|
867
1057
|
"0x9d39a5de30e57443bff2a8307a4256c8797a3497": {
|
|
@@ -1478,7 +1668,7 @@ const registry = {
|
|
|
1478
1668
|
accountType: "AccountId32",
|
|
1479
1669
|
name: "Acala",
|
|
1480
1670
|
specName: "acala",
|
|
1481
|
-
specVersion:
|
|
1671
|
+
specVersion: 2350,
|
|
1482
1672
|
},
|
|
1483
1673
|
assets: {
|
|
1484
1674
|
"0x0000000000000000000000000000000000000000": {
|
|
@@ -1490,7 +1680,7 @@ const registry = {
|
|
|
1490
1680
|
isSufficient: false,
|
|
1491
1681
|
},
|
|
1492
1682
|
},
|
|
1493
|
-
estimatedExecutionFeeDOT:
|
|
1683
|
+
estimatedExecutionFeeDOT: 484934n,
|
|
1494
1684
|
estimatedDeliveryFeeDOT: 307100000n,
|
|
1495
1685
|
},
|
|
1496
1686
|
polkadot_2004: {
|
|
@@ -1518,7 +1708,7 @@ const registry = {
|
|
|
1518
1708
|
evmChainId: 1284,
|
|
1519
1709
|
name: "Moonbeam",
|
|
1520
1710
|
specName: "moonbeam",
|
|
1521
|
-
specVersion:
|
|
1711
|
+
specVersion: 4103,
|
|
1522
1712
|
},
|
|
1523
1713
|
xcDOT: "0xffffffff1fcacbd218edc0eba20fc2308c778080",
|
|
1524
1714
|
assets: {
|
|
@@ -1614,7 +1804,7 @@ const registry = {
|
|
|
1614
1804
|
evmChainId: 996,
|
|
1615
1805
|
name: "Bifrost Polkadot",
|
|
1616
1806
|
specName: "bifrost_polkadot",
|
|
1617
|
-
specVersion:
|
|
1807
|
+
specVersion: 23003,
|
|
1618
1808
|
},
|
|
1619
1809
|
assets: {
|
|
1620
1810
|
"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2": {
|
|
@@ -1634,7 +1824,7 @@ const registry = {
|
|
|
1634
1824
|
isSufficient: false,
|
|
1635
1825
|
},
|
|
1636
1826
|
},
|
|
1637
|
-
estimatedExecutionFeeDOT:
|
|
1827
|
+
estimatedExecutionFeeDOT: 54689726n,
|
|
1638
1828
|
estimatedDeliveryFeeDOT: 307100000n,
|
|
1639
1829
|
},
|
|
1640
1830
|
polkadot_2034: {
|
|
@@ -1647,10 +1837,10 @@ const registry = {
|
|
|
1647
1837
|
hasTxPaymentApi: true,
|
|
1648
1838
|
hasDryRunRpc: true,
|
|
1649
1839
|
hasDotBalance: true,
|
|
1650
|
-
hasEthBalance:
|
|
1840
|
+
hasEthBalance: true,
|
|
1651
1841
|
hasXcmPaymentApi: true,
|
|
1652
|
-
supportsAliasOrigin:
|
|
1653
|
-
xcmVersion: "
|
|
1842
|
+
supportsAliasOrigin: true,
|
|
1843
|
+
xcmVersion: "v5",
|
|
1654
1844
|
supportsV2: false,
|
|
1655
1845
|
},
|
|
1656
1846
|
info: {
|
|
@@ -1662,7 +1852,7 @@ const registry = {
|
|
|
1662
1852
|
evmChainId: 222222,
|
|
1663
1853
|
name: "Hydration",
|
|
1664
1854
|
specName: "hydradx",
|
|
1665
|
-
specVersion:
|
|
1855
|
+
specVersion: 398,
|
|
1666
1856
|
},
|
|
1667
1857
|
assets: {
|
|
1668
1858
|
"0x45804880de22913dafe09f4980848ece6ecbaf78": {
|
|
@@ -1818,7 +2008,7 @@ const registry = {
|
|
|
1818
2008
|
isSufficient: true,
|
|
1819
2009
|
},
|
|
1820
2010
|
},
|
|
1821
|
-
estimatedExecutionFeeDOT:
|
|
2011
|
+
estimatedExecutionFeeDOT: 1169428n,
|
|
1822
2012
|
estimatedDeliveryFeeDOT: 307100000n,
|
|
1823
2013
|
},
|
|
1824
2014
|
polkadot_2043: {
|
|
@@ -1871,9 +2061,9 @@ const registry = {
|
|
|
1871
2061
|
hasDryRunRpc: true,
|
|
1872
2062
|
hasDotBalance: false,
|
|
1873
2063
|
hasEthBalance: false,
|
|
1874
|
-
hasXcmPaymentApi:
|
|
1875
|
-
supportsAliasOrigin:
|
|
1876
|
-
xcmVersion: "
|
|
2064
|
+
hasXcmPaymentApi: true,
|
|
2065
|
+
supportsAliasOrigin: true,
|
|
2066
|
+
xcmVersion: "v5",
|
|
1877
2067
|
supportsV2: false,
|
|
1878
2068
|
},
|
|
1879
2069
|
info: {
|
|
@@ -1884,7 +2074,7 @@ const registry = {
|
|
|
1884
2074
|
accountType: "AccountId20",
|
|
1885
2075
|
name: "Mythos",
|
|
1886
2076
|
specName: "mythos",
|
|
1887
|
-
specVersion:
|
|
2077
|
+
specVersion: 1021,
|
|
1888
2078
|
},
|
|
1889
2079
|
assets: {
|
|
1890
2080
|
"0xba41ddf06b7ffd89d1267b5a93bfef2424eb2003": {
|
|
@@ -1926,7 +2116,7 @@ const registry = {
|
|
|
1926
2116
|
accountType: "AccountId32",
|
|
1927
2117
|
name: "Kusama Asset Hub",
|
|
1928
2118
|
specName: "statemine",
|
|
1929
|
-
specVersion:
|
|
2119
|
+
specVersion: 2001000,
|
|
1930
2120
|
},
|
|
1931
2121
|
assets: {
|
|
1932
2122
|
"0x9d39a5de30e57443bff2a8307a4256c8797a3497": {
|
package/dist/transfers.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"transfers.d.ts","sourceRoot":"","sources":["../src/transfers.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,aAAa,EACb,gBAAgB,EAChB,MAAM,EAGN,OAAO,EACP,aAAa,EAChB,MAAM,wBAAwB,CAAA;AAE/B,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,aAAa,EAAE,KAAK,EAAE,OAAO,GAAG,gBAAgB,
|
|
1
|
+
{"version":3,"file":"transfers.d.ts","sourceRoot":"","sources":["../src/transfers.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,aAAa,EACb,gBAAgB,EAChB,MAAM,EAGN,OAAO,EACP,aAAa,EAChB,MAAM,wBAAwB,CAAA;AAE/B,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,aAAa,EAAE,KAAK,EAAE,OAAO,GAAG,gBAAgB,CA6D7F;AAED,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,SAAS,aAAa,EAAE,GAAG,MAAM,EAAE,CAuB/E"}
|
package/dist/transfers.js
CHANGED
|
@@ -3,53 +3,72 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.getTransferLocation = getTransferLocation;
|
|
4
4
|
exports.getTransferLocations = getTransferLocations;
|
|
5
5
|
function getTransferLocation(registry, chain) {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
parachain
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
kind: ethChain.kind,
|
|
32
|
-
id: ethChain.id,
|
|
33
|
-
key: ethChain.key,
|
|
34
|
-
name: "Ethereum",
|
|
35
|
-
ethChain,
|
|
6
|
+
switch (chain.kind) {
|
|
7
|
+
case "kusama": {
|
|
8
|
+
if (!registry.kusama)
|
|
9
|
+
throw Error(`Kusama not configured.`);
|
|
10
|
+
const key = `${chain.kind}_${chain.id}`;
|
|
11
|
+
const parachain = registry.kusama.parachains[key];
|
|
12
|
+
if (!parachain)
|
|
13
|
+
throw Error(`Cannot find chain ${key}`);
|
|
14
|
+
return {
|
|
15
|
+
id: parachain.id,
|
|
16
|
+
kind: parachain.kind,
|
|
17
|
+
key: parachain.key,
|
|
18
|
+
parachain,
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
case "polkadot": {
|
|
22
|
+
const key = `${chain.kind}_${chain.id}`;
|
|
23
|
+
const parachain = registry.parachains[key];
|
|
24
|
+
if (!parachain)
|
|
25
|
+
throw Error(`Cannot find chain ${key}`);
|
|
26
|
+
return {
|
|
27
|
+
id: parachain.id,
|
|
28
|
+
kind: parachain.kind,
|
|
29
|
+
key: parachain.key,
|
|
30
|
+
parachain,
|
|
36
31
|
};
|
|
37
32
|
}
|
|
38
|
-
|
|
39
|
-
const
|
|
40
|
-
|
|
33
|
+
case "ethereum": {
|
|
34
|
+
const key = `${chain.kind}_${chain.id}`;
|
|
35
|
+
const ethChain = registry.ethereumChains[key];
|
|
36
|
+
if (!ethChain)
|
|
37
|
+
throw Error(`Cannot find chain ${key}`);
|
|
38
|
+
if (!ethChain.evmParachainId) {
|
|
39
|
+
return {
|
|
40
|
+
kind: ethChain.kind,
|
|
41
|
+
id: ethChain.id,
|
|
42
|
+
key: ethChain.key,
|
|
43
|
+
ethChain,
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
else {
|
|
47
|
+
const evmChain = registry.parachains[`polkadot_${ethChain.evmParachainId}`];
|
|
48
|
+
return {
|
|
49
|
+
kind: ethChain.kind,
|
|
50
|
+
id: ethChain.id,
|
|
51
|
+
key: ethChain.key,
|
|
52
|
+
ethChain,
|
|
53
|
+
parachain: evmChain,
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
case "ethereum_l2": {
|
|
58
|
+
const key = `${chain.kind}_${chain.id}`;
|
|
59
|
+
const ethChain = registry.ethereumChains[key];
|
|
60
|
+
if (!ethChain)
|
|
61
|
+
throw Error(`Cannot find chain ${key}`);
|
|
62
|
+
return {
|
|
41
63
|
kind: ethChain.kind,
|
|
42
64
|
id: ethChain.id,
|
|
43
65
|
key: ethChain.key,
|
|
44
|
-
name: `${evmChain.info.name} (EVM)`,
|
|
45
66
|
ethChain,
|
|
46
|
-
parachain: evmChain,
|
|
47
67
|
};
|
|
48
68
|
}
|
|
69
|
+
default:
|
|
70
|
+
throw Error(`Unknown ${chain.kind} chain ${chain.id}.`);
|
|
49
71
|
}
|
|
50
|
-
if (location === null)
|
|
51
|
-
throw Error(`Unknown ${chain.kind} chain ${chain.id}.`);
|
|
52
|
-
return location;
|
|
53
72
|
}
|
|
54
73
|
function getTransferLocations(routes) {
|
|
55
74
|
let sources = [];
|