@talismn/chaindata-provider 1.3.4 → 1.3.5

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.
Files changed (59) hide show
  1. package/dist/index.d.mts +4167 -0
  2. package/dist/index.d.ts +4167 -0
  3. package/dist/index.js +7181 -0
  4. package/dist/index.js.map +1 -0
  5. package/dist/index.mjs +7047 -0
  6. package/dist/index.mjs.map +1 -0
  7. package/package.json +25 -27
  8. package/dist/declarations/src/chaindata/index.d.ts +0 -6
  9. package/dist/declarations/src/chaindata/miniMetadata.d.ts +0 -17
  10. package/dist/declarations/src/chaindata/networks/DotNetwork.d.ts +0 -87
  11. package/dist/declarations/src/chaindata/networks/EthNetwork.d.ts +0 -52
  12. package/dist/declarations/src/chaindata/networks/Network.d.ts +0 -131
  13. package/dist/declarations/src/chaindata/networks/NetworkBase.d.ts +0 -21
  14. package/dist/declarations/src/chaindata/networks/SolNetwork.d.ts +0 -35
  15. package/dist/declarations/src/chaindata/networks/index.d.ts +0 -5
  16. package/dist/declarations/src/chaindata/shared/EthereumAddress.d.ts +0 -3
  17. package/dist/declarations/src/chaindata/shared/HexString.d.ts +0 -3
  18. package/dist/declarations/src/chaindata/shared/SolanaAddress.d.ts +0 -3
  19. package/dist/declarations/src/chaindata/shared/index.d.ts +0 -3
  20. package/dist/declarations/src/chaindata/tokens/EvmErc20Token.d.ts +0 -30
  21. package/dist/declarations/src/chaindata/tokens/EvmNativeToken.d.ts +0 -28
  22. package/dist/declarations/src/chaindata/tokens/EvmUniswapV2Token.d.ts +0 -39
  23. package/dist/declarations/src/chaindata/tokens/SolNativeToken.d.ts +0 -28
  24. package/dist/declarations/src/chaindata/tokens/SolSplToken.d.ts +0 -30
  25. package/dist/declarations/src/chaindata/tokens/SubstrateAssetsToken.d.ts +0 -33
  26. package/dist/declarations/src/chaindata/tokens/SubstrateDTaoToken.d.ts +0 -34
  27. package/dist/declarations/src/chaindata/tokens/SubstrateForeignAssetsToken.d.ts +0 -32
  28. package/dist/declarations/src/chaindata/tokens/SubstrateHydrationToken.d.ts +0 -36
  29. package/dist/declarations/src/chaindata/tokens/SubstrateNativeToken.d.ts +0 -31
  30. package/dist/declarations/src/chaindata/tokens/SubstratePsp22Token.d.ts +0 -30
  31. package/dist/declarations/src/chaindata/tokens/SubstrateTokensToken.d.ts +0 -32
  32. package/dist/declarations/src/chaindata/tokens/Token.d.ts +0 -797
  33. package/dist/declarations/src/chaindata/tokens/TokenBase.d.ts +0 -14
  34. package/dist/declarations/src/chaindata/tokens/index.d.ts +0 -14
  35. package/dist/declarations/src/chaindata/tokens/utils.d.ts +0 -1
  36. package/dist/declarations/src/chaindata/utils.d.ts +0 -428
  37. package/dist/declarations/src/constants.d.ts +0 -10
  38. package/dist/declarations/src/getBlockExplorerUrls.d.ts +0 -23
  39. package/dist/declarations/src/index.d.ts +0 -11
  40. package/dist/declarations/src/legacy/Chain.d.ts +0 -91
  41. package/dist/declarations/src/legacy/EvmNetwork.d.ts +0 -64
  42. package/dist/declarations/src/legacy/TalismanChaindataDatabase.d.ts +0 -13
  43. package/dist/declarations/src/log.d.ts +0 -2
  44. package/dist/declarations/src/provider/ChaindataProvider.d.ts +0 -601
  45. package/dist/declarations/src/provider/ChaindataProviderInterface.d.ts +0 -30
  46. package/dist/declarations/src/state/combinedChaindata.d.ts +0 -11
  47. package/dist/declarations/src/state/defaultChaindata.d.ts +0 -322
  48. package/dist/declarations/src/state/githubChaindata.d.ts +0 -321
  49. package/dist/declarations/src/state/net.d.ts +0 -321
  50. package/dist/declarations/src/state/oldDb.d.ts +0 -1
  51. package/dist/declarations/src/state/schema.d.ts +0 -1406
  52. package/dist/declarations/src/upgrades/2024-01-25-upgradeAddIsDefaultToExistingChains.d.ts +0 -2
  53. package/dist/declarations/src/upgrades/2024-01-25-upgradeRemoveSymbolFromNativeTokenId.d.ts +0 -2
  54. package/dist/declarations/src/util.d.ts +0 -9
  55. package/dist/talismn-chaindata-provider.cjs.d.ts +0 -1
  56. package/dist/talismn-chaindata-provider.cjs.dev.js +0 -7078
  57. package/dist/talismn-chaindata-provider.cjs.js +0 -7
  58. package/dist/talismn-chaindata-provider.cjs.prod.js +0 -7078
  59. package/dist/talismn-chaindata-provider.esm.js +0 -6961
@@ -0,0 +1,4167 @@
1
+ import z, { z as z$1 } from 'zod/v4';
2
+ import { Dexie } from 'dexie';
3
+ import { Observable, ReplaySubject } from 'rxjs';
4
+
5
+ declare const AnyMiniMetadataSchema: z.ZodObject<{
6
+ /** The DB id for this metadata */
7
+ id: z.ZodString;
8
+ /** The balance module which created this miniMetadata */
9
+ source: z.ZodString;
10
+ /** The chain this miniMetadata came from */
11
+ chainId: z.ZodString;
12
+ /** The chain specVersion which this miniMetadata is valid for */
13
+ specVersion: z.ZodUInt32;
14
+ /** the version of the balances library used to craft the mini metadata */
15
+ version: z.ZodString;
16
+ /** The miniMetadata encoded as a hex string */
17
+ data: z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
18
+ extra: z.ZodNullable<z.ZodAny>;
19
+ }, z.core.$strict>;
20
+ type AnyMiniMetadata = z.infer<typeof AnyMiniMetadataSchema>;
21
+
22
+ declare const DotNetworkBalancesConfigSchema: z.ZodObject<{
23
+ "substrate-native": z.ZodOptional<z.ZodObject<{
24
+ disable: z.ZodOptional<z.ZodBoolean>;
25
+ }, z.core.$strip>>;
26
+ "substrate-assets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
27
+ "substrate-psp22": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
28
+ "substrate-tokens": z.ZodOptional<z.ZodObject<{
29
+ palletId: z.ZodOptional<z.ZodString>;
30
+ }, z.core.$strip>>;
31
+ "substrate-foreignassets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
32
+ "substrate-hydration": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
33
+ "substrate-dtao": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
34
+ }, z.core.$strict>;
35
+ type DotNetworkBalancesConfig = z.infer<typeof DotNetworkBalancesConfigSchema>;
36
+ declare const DotNetworkTopologySchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
37
+ type: z.ZodLiteral<"standalone">;
38
+ }, z.core.$strict>, z.ZodObject<{
39
+ type: z.ZodLiteral<"relay">;
40
+ }, z.core.$strict>, z.ZodObject<{
41
+ type: z.ZodLiteral<"parachain">;
42
+ relayId: z.ZodString;
43
+ paraId: z.ZodNumber;
44
+ }, z.core.$strict>]>;
45
+ declare const DotNetworkSchema: z.ZodObject<{
46
+ id: z.ZodString;
47
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
48
+ isDefault: z.ZodOptional<z.ZodBoolean>;
49
+ forceScan: z.ZodOptional<z.ZodBoolean>;
50
+ name: z.ZodString;
51
+ logo: z.ZodOptional<z.ZodString>;
52
+ nativeTokenId: z.ZodString;
53
+ nativeCurrency: z.ZodObject<{
54
+ decimals: z.ZodUInt32;
55
+ symbol: z.ZodString;
56
+ name: z.ZodString;
57
+ coingeckoId: z.ZodOptional<z.ZodString>;
58
+ mirrorOf: z.ZodOptional<z.ZodString>;
59
+ logo: z.ZodOptional<z.ZodString>;
60
+ }, z.core.$strict>;
61
+ themeColor: z.ZodOptional<z.ZodString>;
62
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
63
+ genesisHash: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
64
+ platform: z.ZodLiteral<"polkadot">;
65
+ chainName: z.ZodString;
66
+ specName: z.ZodString;
67
+ specVersion: z.ZodUInt32;
68
+ account: z.ZodEnum<{
69
+ secp256k1: "secp256k1";
70
+ "*25519": "*25519";
71
+ }>;
72
+ chainspecQrUrl: z.ZodOptional<z.ZodString>;
73
+ latestMetadataQrUrl: z.ZodOptional<z.ZodString>;
74
+ prefix: z.ZodNumber;
75
+ oldPrefix: z.ZodOptional<z.ZodNumber>;
76
+ rpcs: z.ZodArray<z.ZodURL>;
77
+ registryTypes: z.ZodOptional<z.ZodAny>;
78
+ signedExtensions: z.ZodOptional<z.ZodAny>;
79
+ hasCheckMetadataHash: z.ZodOptional<z.ZodBoolean>;
80
+ hasExtrinsicSignatureTypePrefix: z.ZodOptional<z.ZodBoolean>;
81
+ isUnknownFeeToken: z.ZodOptional<z.ZodBoolean>;
82
+ topology: z.ZodDiscriminatedUnion<[z.ZodObject<{
83
+ type: z.ZodLiteral<"standalone">;
84
+ }, z.core.$strict>, z.ZodObject<{
85
+ type: z.ZodLiteral<"relay">;
86
+ }, z.core.$strict>, z.ZodObject<{
87
+ type: z.ZodLiteral<"parachain">;
88
+ relayId: z.ZodString;
89
+ paraId: z.ZodNumber;
90
+ }, z.core.$strict>]>;
91
+ balancesConfig: z.ZodOptional<z.ZodObject<{
92
+ "substrate-native": z.ZodOptional<z.ZodObject<{
93
+ disable: z.ZodOptional<z.ZodBoolean>;
94
+ }, z.core.$strip>>;
95
+ "substrate-assets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
96
+ "substrate-psp22": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
97
+ "substrate-tokens": z.ZodOptional<z.ZodObject<{
98
+ palletId: z.ZodOptional<z.ZodString>;
99
+ }, z.core.$strip>>;
100
+ "substrate-foreignassets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
101
+ "substrate-hydration": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
102
+ "substrate-dtao": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
103
+ }, z.core.$strict>>;
104
+ }, z.core.$strict>;
105
+ type DotNetwork = z.infer<typeof DotNetworkSchema>;
106
+ type DotNetworkId = DotNetwork["id"];
107
+ type DotNetworkList = Record<DotNetworkId, DotNetwork>;
108
+
109
+ declare const EthNetworkBalancesConfigSchema: z.ZodObject<{
110
+ "evm-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
111
+ "evm-erc20": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
112
+ "evm-uniswapv2": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
113
+ }, z.core.$strict>;
114
+ type EthNetworkBalancesConfig = z.infer<typeof EthNetworkBalancesConfigSchema>;
115
+ declare const EthNetworkSchema: z.ZodObject<{
116
+ id: z.ZodString;
117
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
118
+ isDefault: z.ZodOptional<z.ZodBoolean>;
119
+ forceScan: z.ZodOptional<z.ZodBoolean>;
120
+ name: z.ZodString;
121
+ logo: z.ZodOptional<z.ZodString>;
122
+ nativeTokenId: z.ZodString;
123
+ nativeCurrency: z.ZodObject<{
124
+ decimals: z.ZodUInt32;
125
+ symbol: z.ZodString;
126
+ name: z.ZodString;
127
+ coingeckoId: z.ZodOptional<z.ZodString>;
128
+ mirrorOf: z.ZodOptional<z.ZodString>;
129
+ logo: z.ZodOptional<z.ZodString>;
130
+ }, z.core.$strict>;
131
+ themeColor: z.ZodOptional<z.ZodString>;
132
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
133
+ platform: z.ZodLiteral<"ethereum">;
134
+ substrateChainId: z.ZodOptional<z.ZodString>;
135
+ preserveGasEstimate: z.ZodOptional<z.ZodBoolean>;
136
+ rpcs: z.ZodArray<z.ZodURL>;
137
+ feeType: z.ZodOptional<z.ZodEnum<{
138
+ legacy: "legacy";
139
+ "eip-1559": "eip-1559";
140
+ }>>;
141
+ l2FeeType: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
142
+ type: z.ZodLiteral<"op-stack">;
143
+ }, z.core.$strict>, z.ZodObject<{
144
+ type: z.ZodLiteral<"scroll">;
145
+ l1GasPriceOracle: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
146
+ }, z.core.$strict>]>>;
147
+ contracts: z.ZodOptional<z.ZodObject<{
148
+ Erc20Aggregator: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
149
+ Multicall3: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
150
+ }, z.core.$strict>>;
151
+ balancesConfig: z.ZodOptional<z.ZodObject<{
152
+ "evm-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
153
+ "evm-erc20": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
154
+ "evm-uniswapv2": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
155
+ }, z.core.$strict>>;
156
+ }, z.core.$strict>;
157
+ type EthNetwork = z.infer<typeof EthNetworkSchema>;
158
+ type EthNetworkId = EthNetwork["id"];
159
+ type EthNetworkList = Record<EthNetworkId, EthNetwork>;
160
+
161
+ declare const NetworkSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
162
+ id: z.ZodString;
163
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
164
+ isDefault: z.ZodOptional<z.ZodBoolean>;
165
+ forceScan: z.ZodOptional<z.ZodBoolean>;
166
+ name: z.ZodString;
167
+ logo: z.ZodOptional<z.ZodString>;
168
+ nativeTokenId: z.ZodString;
169
+ nativeCurrency: z.ZodObject<{
170
+ decimals: z.ZodUInt32;
171
+ symbol: z.ZodString;
172
+ name: z.ZodString;
173
+ coingeckoId: z.ZodOptional<z.ZodString>;
174
+ mirrorOf: z.ZodOptional<z.ZodString>;
175
+ logo: z.ZodOptional<z.ZodString>;
176
+ }, z.core.$strict>;
177
+ themeColor: z.ZodOptional<z.ZodString>;
178
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
179
+ genesisHash: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
180
+ platform: z.ZodLiteral<"polkadot">;
181
+ chainName: z.ZodString;
182
+ specName: z.ZodString;
183
+ specVersion: z.ZodUInt32;
184
+ account: z.ZodEnum<{
185
+ secp256k1: "secp256k1";
186
+ "*25519": "*25519";
187
+ }>;
188
+ chainspecQrUrl: z.ZodOptional<z.ZodString>;
189
+ latestMetadataQrUrl: z.ZodOptional<z.ZodString>;
190
+ prefix: z.ZodNumber;
191
+ oldPrefix: z.ZodOptional<z.ZodNumber>;
192
+ rpcs: z.ZodArray<z.ZodURL>;
193
+ registryTypes: z.ZodOptional<z.ZodAny>;
194
+ signedExtensions: z.ZodOptional<z.ZodAny>;
195
+ hasCheckMetadataHash: z.ZodOptional<z.ZodBoolean>;
196
+ hasExtrinsicSignatureTypePrefix: z.ZodOptional<z.ZodBoolean>;
197
+ isUnknownFeeToken: z.ZodOptional<z.ZodBoolean>;
198
+ topology: z.ZodDiscriminatedUnion<[z.ZodObject<{
199
+ type: z.ZodLiteral<"standalone">;
200
+ }, z.core.$strict>, z.ZodObject<{
201
+ type: z.ZodLiteral<"relay">;
202
+ }, z.core.$strict>, z.ZodObject<{
203
+ type: z.ZodLiteral<"parachain">;
204
+ relayId: z.ZodString;
205
+ paraId: z.ZodNumber;
206
+ }, z.core.$strict>]>;
207
+ balancesConfig: z.ZodOptional<z.ZodObject<{
208
+ "substrate-native": z.ZodOptional<z.ZodObject<{
209
+ disable: z.ZodOptional<z.ZodBoolean>;
210
+ }, z.core.$strip>>;
211
+ "substrate-assets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
212
+ "substrate-psp22": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
213
+ "substrate-tokens": z.ZodOptional<z.ZodObject<{
214
+ palletId: z.ZodOptional<z.ZodString>;
215
+ }, z.core.$strip>>;
216
+ "substrate-foreignassets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
217
+ "substrate-hydration": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
218
+ "substrate-dtao": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
219
+ }, z.core.$strict>>;
220
+ }, z.core.$strict>, z.ZodObject<{
221
+ id: z.ZodString;
222
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
223
+ isDefault: z.ZodOptional<z.ZodBoolean>;
224
+ forceScan: z.ZodOptional<z.ZodBoolean>;
225
+ name: z.ZodString;
226
+ logo: z.ZodOptional<z.ZodString>;
227
+ nativeTokenId: z.ZodString;
228
+ nativeCurrency: z.ZodObject<{
229
+ decimals: z.ZodUInt32;
230
+ symbol: z.ZodString;
231
+ name: z.ZodString;
232
+ coingeckoId: z.ZodOptional<z.ZodString>;
233
+ mirrorOf: z.ZodOptional<z.ZodString>;
234
+ logo: z.ZodOptional<z.ZodString>;
235
+ }, z.core.$strict>;
236
+ themeColor: z.ZodOptional<z.ZodString>;
237
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
238
+ platform: z.ZodLiteral<"ethereum">;
239
+ substrateChainId: z.ZodOptional<z.ZodString>;
240
+ preserveGasEstimate: z.ZodOptional<z.ZodBoolean>;
241
+ rpcs: z.ZodArray<z.ZodURL>;
242
+ feeType: z.ZodOptional<z.ZodEnum<{
243
+ legacy: "legacy";
244
+ "eip-1559": "eip-1559";
245
+ }>>;
246
+ l2FeeType: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
247
+ type: z.ZodLiteral<"op-stack">;
248
+ }, z.core.$strict>, z.ZodObject<{
249
+ type: z.ZodLiteral<"scroll">;
250
+ l1GasPriceOracle: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
251
+ }, z.core.$strict>]>>;
252
+ contracts: z.ZodOptional<z.ZodObject<{
253
+ Erc20Aggregator: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
254
+ Multicall3: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
255
+ }, z.core.$strict>>;
256
+ balancesConfig: z.ZodOptional<z.ZodObject<{
257
+ "evm-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
258
+ "evm-erc20": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
259
+ "evm-uniswapv2": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
260
+ }, z.core.$strict>>;
261
+ }, z.core.$strict>, z.ZodObject<{
262
+ id: z.ZodString;
263
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
264
+ isDefault: z.ZodOptional<z.ZodBoolean>;
265
+ forceScan: z.ZodOptional<z.ZodBoolean>;
266
+ name: z.ZodString;
267
+ logo: z.ZodOptional<z.ZodString>;
268
+ nativeTokenId: z.ZodString;
269
+ nativeCurrency: z.ZodObject<{
270
+ decimals: z.ZodUInt32;
271
+ symbol: z.ZodString;
272
+ name: z.ZodString;
273
+ coingeckoId: z.ZodOptional<z.ZodString>;
274
+ mirrorOf: z.ZodOptional<z.ZodString>;
275
+ logo: z.ZodOptional<z.ZodString>;
276
+ }, z.core.$strict>;
277
+ themeColor: z.ZodOptional<z.ZodString>;
278
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
279
+ platform: z.ZodLiteral<"solana">;
280
+ genesisHash: z.ZodString;
281
+ rpcs: z.ZodArray<z.ZodURL>;
282
+ balancesConfig: z.ZodOptional<z.ZodObject<{
283
+ "sol-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
284
+ "sol-spl": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
285
+ }, z.core.$strict>>;
286
+ }, z.core.$strict>]>;
287
+ type Network = z.infer<typeof NetworkSchema>;
288
+ type NetworkId = Network["id"];
289
+ type NetworkPlatform = Network["platform"];
290
+ type NetworkList = Record<NetworkId, Network>;
291
+
292
+ declare const NetworkBaseSchema: z$1.ZodObject<{
293
+ id: z$1.ZodString;
294
+ isTestnet: z$1.ZodOptional<z$1.ZodBoolean>;
295
+ isDefault: z$1.ZodOptional<z$1.ZodBoolean>;
296
+ forceScan: z$1.ZodOptional<z$1.ZodBoolean>;
297
+ name: z$1.ZodString;
298
+ logo: z$1.ZodOptional<z$1.ZodString>;
299
+ nativeTokenId: z$1.ZodString;
300
+ nativeCurrency: z$1.ZodObject<{
301
+ decimals: z$1.ZodUInt32;
302
+ symbol: z$1.ZodString;
303
+ name: z$1.ZodString;
304
+ coingeckoId: z$1.ZodOptional<z$1.ZodString>;
305
+ mirrorOf: z$1.ZodOptional<z$1.ZodString>;
306
+ logo: z$1.ZodOptional<z$1.ZodString>;
307
+ }, z$1.core.$strict>;
308
+ themeColor: z$1.ZodOptional<z$1.ZodString>;
309
+ blockExplorerUrls: z$1.ZodDefault<z$1.ZodArray<z$1.ZodURL>>;
310
+ }, z$1.core.$strict>;
311
+ type NetworkBase = z$1.infer<typeof NetworkBaseSchema>;
312
+
313
+ declare const SolNetworkBalancesConfigSchema: z.ZodObject<{
314
+ "sol-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
315
+ "sol-spl": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
316
+ }, z.core.$strict>;
317
+ type SolNetworkBalancesConfig = z.infer<typeof SolNetworkBalancesConfigSchema>;
318
+ declare const SolNetworkSchema: z.ZodObject<{
319
+ id: z.ZodString;
320
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
321
+ isDefault: z.ZodOptional<z.ZodBoolean>;
322
+ forceScan: z.ZodOptional<z.ZodBoolean>;
323
+ name: z.ZodString;
324
+ logo: z.ZodOptional<z.ZodString>;
325
+ nativeTokenId: z.ZodString;
326
+ nativeCurrency: z.ZodObject<{
327
+ decimals: z.ZodUInt32;
328
+ symbol: z.ZodString;
329
+ name: z.ZodString;
330
+ coingeckoId: z.ZodOptional<z.ZodString>;
331
+ mirrorOf: z.ZodOptional<z.ZodString>;
332
+ logo: z.ZodOptional<z.ZodString>;
333
+ }, z.core.$strict>;
334
+ themeColor: z.ZodOptional<z.ZodString>;
335
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
336
+ platform: z.ZodLiteral<"solana">;
337
+ genesisHash: z.ZodString;
338
+ rpcs: z.ZodArray<z.ZodURL>;
339
+ balancesConfig: z.ZodOptional<z.ZodObject<{
340
+ "sol-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
341
+ "sol-spl": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
342
+ }, z.core.$strict>>;
343
+ }, z.core.$strict>;
344
+ type SolNetwork = z.infer<typeof SolNetworkSchema>;
345
+ type SolNetworkId = SolNetwork["id"];
346
+ type SolNetworkList = Record<SolNetworkId, SolNetwork>;
347
+
348
+ declare const EthereumAddressSchema: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
349
+ type EthereumAddress = z.infer<typeof EthereumAddressSchema>;
350
+
351
+ declare const HexStringSchema: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
352
+ type HexString = z.infer<typeof HexStringSchema>;
353
+
354
+ declare const SolanaAddressSchema: z.ZodString;
355
+ type SolanaAddress = z.infer<typeof SolanaAddressSchema>;
356
+
357
+ declare const TOKEN_TYPE$b = "evm-native";
358
+ declare const EvmNativeTokenSchema: z.ZodObject<{
359
+ id: z.ZodString;
360
+ networkId: z.ZodString;
361
+ isDefault: z.ZodOptional<z.ZodBoolean>;
362
+ decimals: z.ZodInt;
363
+ symbol: z.ZodString;
364
+ name: z.ZodOptional<z.ZodString>;
365
+ logo: z.ZodOptional<z.ZodString>;
366
+ coingeckoId: z.ZodOptional<z.ZodString>;
367
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
368
+ mirrorOf: z.ZodOptional<z.ZodString>;
369
+ type: z.ZodLiteral<"evm-native">;
370
+ platform: z.ZodLiteral<"ethereum">;
371
+ }, z.core.$strict>;
372
+ type EvmNativeToken = z.infer<typeof EvmNativeTokenSchema>;
373
+ declare const EvmNativeBalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
374
+ type EvmNativeBalancesConfig = z.infer<typeof EvmNativeBalancesConfigSchema>;
375
+ type EvmNativeTokenIdSpecs = {
376
+ type: typeof TOKEN_TYPE$b;
377
+ networkId: NetworkId;
378
+ };
379
+ declare const evmNativeTokenId: (networkId: NetworkId) => string;
380
+ declare const parseEvmNativeTokenId: (tokenId: TokenId) => EvmNativeTokenIdSpecs;
381
+
382
+ declare const TOKEN_TYPE$a = "evm-uniswapv2";
383
+ declare const EvmUniswapV2TokenSchema: z.ZodObject<{
384
+ id: z.ZodString;
385
+ networkId: z.ZodString;
386
+ isDefault: z.ZodOptional<z.ZodBoolean>;
387
+ decimals: z.ZodInt;
388
+ symbol: z.ZodString;
389
+ name: z.ZodOptional<z.ZodString>;
390
+ logo: z.ZodOptional<z.ZodString>;
391
+ coingeckoId: z.ZodOptional<z.ZodString>;
392
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
393
+ mirrorOf: z.ZodOptional<z.ZodString>;
394
+ type: z.ZodLiteral<"evm-uniswapv2">;
395
+ platform: z.ZodLiteral<"ethereum">;
396
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
397
+ isCustom: z.ZodOptional<z.ZodBoolean>;
398
+ symbol0: z.ZodString;
399
+ symbol1: z.ZodString;
400
+ decimals0: z.ZodInt;
401
+ decimals1: z.ZodInt;
402
+ tokenAddress0: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
403
+ tokenAddress1: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
404
+ coingeckoId0: z.ZodOptional<z.ZodString>;
405
+ coingeckoId1: z.ZodOptional<z.ZodString>;
406
+ }, z.core.$strict>;
407
+ type EvmUniswapV2Token = z.infer<typeof EvmUniswapV2TokenSchema>;
408
+ declare const EvmUniswapV2BalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
409
+ type EvmUniswapV2BalancesConfig = z.infer<typeof EvmUniswapV2BalancesConfigSchema>;
410
+ type EvmUniswapV2TokenIdSpecs = {
411
+ type: typeof TOKEN_TYPE$a;
412
+ networkId: NetworkId;
413
+ contractAddress: `0x${string}`;
414
+ };
415
+ declare const evmUniswapV2TokenId: (networkId: NetworkId, contractAddress: EvmUniswapV2Token["contractAddress"]) => string;
416
+ declare const parseEvmUniswapV2TokenId: (tokenId: TokenId) => EvmUniswapV2TokenIdSpecs;
417
+
418
+ declare const TOKEN_TYPE$9 = "sol-native";
419
+ declare const SolNativeTokenSchema: z.ZodObject<{
420
+ id: z.ZodString;
421
+ networkId: z.ZodString;
422
+ isDefault: z.ZodOptional<z.ZodBoolean>;
423
+ decimals: z.ZodInt;
424
+ symbol: z.ZodString;
425
+ name: z.ZodOptional<z.ZodString>;
426
+ logo: z.ZodOptional<z.ZodString>;
427
+ coingeckoId: z.ZodOptional<z.ZodString>;
428
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
429
+ mirrorOf: z.ZodOptional<z.ZodString>;
430
+ type: z.ZodLiteral<"sol-native">;
431
+ platform: z.ZodLiteral<"solana">;
432
+ }, z.core.$strict>;
433
+ type SolNativeToken = z.infer<typeof SolNativeTokenSchema>;
434
+ declare const SolNativeBalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
435
+ type SolNativeBalancesConfig = z.infer<typeof SolNativeBalancesConfigSchema>;
436
+ type SolNativeTokenIdSpecs = {
437
+ type: typeof TOKEN_TYPE$9;
438
+ networkId: SolNetworkId;
439
+ };
440
+ declare const solNativeTokenId: (networkId: SolNetworkId) => string;
441
+ declare const parseSolNativeTokenId: (tokenId: TokenId) => SolNativeTokenIdSpecs;
442
+
443
+ declare const TOKEN_TYPE$8 = "sol-spl";
444
+ declare const SolSplTokenSchema: z.ZodObject<{
445
+ id: z.ZodString;
446
+ networkId: z.ZodString;
447
+ isDefault: z.ZodOptional<z.ZodBoolean>;
448
+ decimals: z.ZodInt;
449
+ symbol: z.ZodString;
450
+ name: z.ZodOptional<z.ZodString>;
451
+ logo: z.ZodOptional<z.ZodString>;
452
+ coingeckoId: z.ZodOptional<z.ZodString>;
453
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
454
+ mirrorOf: z.ZodOptional<z.ZodString>;
455
+ type: z.ZodLiteral<"sol-spl">;
456
+ platform: z.ZodLiteral<"solana">;
457
+ mintAddress: z.ZodString;
458
+ }, z.core.$strict>;
459
+ type SolSplToken = z.infer<typeof SolSplTokenSchema>;
460
+ declare const SolSplBalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
461
+ type SolSplBalancesConfig = z.infer<typeof SolSplBalancesConfigSchema>;
462
+ type SolSplTokenIdSpecs = {
463
+ type: typeof TOKEN_TYPE$8;
464
+ networkId: SolNetworkId;
465
+ mintAddress: string;
466
+ };
467
+ declare const solSplTokenId: (networkId: string, mintAddress: string) => string;
468
+ declare const parseSolSplTokenId: (tokenId: TokenId) => SolSplTokenIdSpecs;
469
+
470
+ declare const TOKEN_TYPE$7 = "substrate-assets";
471
+ declare const SubAssetsTokenSchema: z.ZodObject<{
472
+ id: z.ZodString;
473
+ networkId: z.ZodString;
474
+ isDefault: z.ZodOptional<z.ZodBoolean>;
475
+ decimals: z.ZodInt;
476
+ symbol: z.ZodString;
477
+ name: z.ZodOptional<z.ZodString>;
478
+ logo: z.ZodOptional<z.ZodString>;
479
+ coingeckoId: z.ZodOptional<z.ZodString>;
480
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
481
+ mirrorOf: z.ZodOptional<z.ZodString>;
482
+ type: z.ZodLiteral<"substrate-assets">;
483
+ platform: z.ZodLiteral<"polkadot">;
484
+ assetId: z.ZodPipe<z.ZodUnion<readonly [z.ZodUInt32, z.ZodString]>, z.ZodTransform<string, string | number>>;
485
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
486
+ isSufficient: z.ZodBoolean;
487
+ existentialDeposit: z.ZodString;
488
+ }, z.core.$strict>;
489
+ type SubAssetsToken = z.infer<typeof SubAssetsTokenSchema>;
490
+ declare const SubAssetsBalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
491
+ type SubAssetsBalancesConfig = z.infer<typeof SubAssetsBalancesConfigSchema>;
492
+ type SubAssetTokenIdSpecs = {
493
+ type: typeof TOKEN_TYPE$7;
494
+ networkId: NetworkId;
495
+ assetId: string;
496
+ };
497
+ declare const subAssetTokenId: (networkId: NetworkId, assetId: string) => string;
498
+ declare const parseSubAssetTokenId: (tokenId: TokenId) => SubAssetTokenIdSpecs;
499
+
500
+ declare const TOKEN_TYPE$6 = "substrate-dtao";
501
+ declare const SubDTaoTokenSchema: z.ZodObject<{
502
+ id: z.ZodString;
503
+ networkId: z.ZodString;
504
+ isDefault: z.ZodOptional<z.ZodBoolean>;
505
+ decimals: z.ZodInt;
506
+ symbol: z.ZodString;
507
+ name: z.ZodOptional<z.ZodString>;
508
+ logo: z.ZodOptional<z.ZodString>;
509
+ coingeckoId: z.ZodOptional<z.ZodString>;
510
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
511
+ mirrorOf: z.ZodOptional<z.ZodString>;
512
+ type: z.ZodLiteral<"substrate-dtao">;
513
+ platform: z.ZodLiteral<"polkadot">;
514
+ netuid: z.ZodNumber;
515
+ subnetName: z.ZodOptional<z.ZodString>;
516
+ hotkey: z.ZodOptional<z.ZodString>;
517
+ isTransferable: z.ZodDefault<z.ZodBoolean>;
518
+ }, z.core.$strict>;
519
+ type SubDTaoToken = z.infer<typeof SubDTaoTokenSchema>;
520
+ declare const SubDTaoBalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
521
+ type SubDTaoBalancesConfig = z.infer<typeof SubDTaoBalancesConfigSchema>;
522
+ type SubDTaoTokenIdSpecs = {
523
+ type: typeof TOKEN_TYPE$6;
524
+ networkId: NetworkId;
525
+ netuid: number;
526
+ hotkey?: string;
527
+ };
528
+ declare const subDTaoTokenId: (networkId: NetworkId, subnetId: number, hotkey?: string) => string;
529
+ declare const parseSubDTaoTokenId: (tokenId: TokenId) => SubDTaoTokenIdSpecs;
530
+
531
+ declare const TOKEN_TYPE$5 = "substrate-foreignassets";
532
+ declare const SubForeignAssetsTokenSchema: z.ZodObject<{
533
+ id: z.ZodString;
534
+ networkId: z.ZodString;
535
+ isDefault: z.ZodOptional<z.ZodBoolean>;
536
+ decimals: z.ZodInt;
537
+ symbol: z.ZodString;
538
+ name: z.ZodOptional<z.ZodString>;
539
+ logo: z.ZodOptional<z.ZodString>;
540
+ coingeckoId: z.ZodOptional<z.ZodString>;
541
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
542
+ mirrorOf: z.ZodOptional<z.ZodString>;
543
+ type: z.ZodLiteral<"substrate-foreignassets">;
544
+ platform: z.ZodLiteral<"polkadot">;
545
+ onChainId: z.ZodString;
546
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
547
+ isSufficient: z.ZodBoolean;
548
+ existentialDeposit: z.ZodString;
549
+ }, z.core.$strict>;
550
+ type SubForeignAssetsToken = z.infer<typeof SubForeignAssetsTokenSchema>;
551
+ declare const SubForeignAssetsBalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
552
+ type SubForeignAssetsBalancesConfig = z.infer<typeof SubForeignAssetsBalancesConfigSchema>;
553
+ type ForeignAssetsTokenIdSpecs = {
554
+ type: typeof TOKEN_TYPE$5;
555
+ networkId: NetworkId;
556
+ onChainId: string;
557
+ };
558
+ declare const subForeignAssetTokenId: (networkId: NetworkId, onChainId: string) => string;
559
+ declare const parseSubForeignAssetTokenId: (tokenId: TokenId) => ForeignAssetsTokenIdSpecs;
560
+
561
+ declare const TOKEN_TYPE$4 = "substrate-hydration";
562
+ declare const SubHydrationTokenSchema: z.ZodObject<{
563
+ id: z.ZodString;
564
+ networkId: z.ZodString;
565
+ isDefault: z.ZodOptional<z.ZodBoolean>;
566
+ decimals: z.ZodInt;
567
+ symbol: z.ZodString;
568
+ name: z.ZodOptional<z.ZodString>;
569
+ logo: z.ZodOptional<z.ZodString>;
570
+ coingeckoId: z.ZodOptional<z.ZodString>;
571
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
572
+ mirrorOf: z.ZodOptional<z.ZodString>;
573
+ type: z.ZodLiteral<"substrate-hydration">;
574
+ platform: z.ZodLiteral<"polkadot">;
575
+ onChainId: z.ZodUInt32;
576
+ assetType: z.ZodEnum<{
577
+ Token: "Token";
578
+ Erc20: "Erc20";
579
+ External: "External";
580
+ }>;
581
+ isSufficient: z.ZodBoolean;
582
+ existentialDeposit: z.ZodString;
583
+ }, z.core.$strict>;
584
+ type SubHydrationToken = z.infer<typeof SubHydrationTokenSchema>;
585
+ declare const SubHydrationBalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
586
+ type SubHydrationBalancesConfig = z.infer<typeof SubHydrationBalancesConfigSchema>;
587
+ type SubHydrationTokenIdSpecs = {
588
+ type: typeof TOKEN_TYPE$4;
589
+ networkId: NetworkId;
590
+ onChainId: number;
591
+ };
592
+ declare const subHydrationTokenId: (networkId: NetworkId, onChainId: number) => string;
593
+ declare const parseSubHydrationTokenId: (tokenId: string) => SubHydrationTokenIdSpecs;
594
+
595
+ declare const TOKEN_TYPE$3 = "substrate-native";
596
+ declare const SubNativeTokenSchema: z.ZodObject<{
597
+ id: z.ZodString;
598
+ networkId: z.ZodString;
599
+ isDefault: z.ZodOptional<z.ZodBoolean>;
600
+ decimals: z.ZodInt;
601
+ symbol: z.ZodString;
602
+ name: z.ZodOptional<z.ZodString>;
603
+ logo: z.ZodOptional<z.ZodString>;
604
+ coingeckoId: z.ZodOptional<z.ZodString>;
605
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
606
+ mirrorOf: z.ZodOptional<z.ZodString>;
607
+ type: z.ZodLiteral<"substrate-native">;
608
+ platform: z.ZodLiteral<"polkadot">;
609
+ existentialDeposit: z.ZodString;
610
+ }, z.core.$strict>;
611
+ type SubNativeToken = z.infer<typeof SubNativeTokenSchema>;
612
+ declare const SubNativeBalancesConfigSchema: z.ZodObject<{
613
+ disable: z.ZodOptional<z.ZodBoolean>;
614
+ }, z.core.$strip>;
615
+ type SubNativeBalancesConfig = z.infer<typeof SubNativeBalancesConfigSchema>;
616
+ type SubNativeTokenIdSpecs = {
617
+ type: typeof TOKEN_TYPE$3;
618
+ networkId: NetworkId;
619
+ };
620
+ declare const subNativeTokenId: (networkId: NetworkId) => string;
621
+ declare const parseSubNativeTokenId: (tokenId: TokenId) => SubNativeTokenIdSpecs;
622
+
623
+ declare const TOKEN_TYPE$2 = "substrate-psp22";
624
+ declare const SubPsp22TokenSchema: z.ZodObject<{
625
+ id: z.ZodString;
626
+ networkId: z.ZodString;
627
+ isDefault: z.ZodOptional<z.ZodBoolean>;
628
+ decimals: z.ZodInt;
629
+ symbol: z.ZodString;
630
+ name: z.ZodOptional<z.ZodString>;
631
+ logo: z.ZodOptional<z.ZodString>;
632
+ coingeckoId: z.ZodOptional<z.ZodString>;
633
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
634
+ mirrorOf: z.ZodOptional<z.ZodString>;
635
+ type: z.ZodLiteral<"substrate-psp22">;
636
+ platform: z.ZodLiteral<"polkadot">;
637
+ contractAddress: z.ZodString;
638
+ }, z.core.$strict>;
639
+ type SubPsp22Token = z.infer<typeof SubPsp22TokenSchema>;
640
+ declare const SubPsp22BalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
641
+ type SubPsp22BalancesConfig = z.infer<typeof SubPsp22BalancesConfigSchema>;
642
+ type SubPsp22TokenIdSpecs = {
643
+ type: typeof TOKEN_TYPE$2;
644
+ networkId: NetworkId;
645
+ contractAddress: string;
646
+ };
647
+ declare const subPsp22TokenId: (networkId: NetworkId, contractAddress: string) => string;
648
+ declare const parseSubPsp22TokenId: (tokenId: TokenId) => SubPsp22TokenIdSpecs;
649
+
650
+ declare const TOKEN_TYPE$1 = "substrate-tokens";
651
+ declare const SubTokensTokenSchema: z.ZodObject<{
652
+ id: z.ZodString;
653
+ networkId: z.ZodString;
654
+ isDefault: z.ZodOptional<z.ZodBoolean>;
655
+ decimals: z.ZodInt;
656
+ symbol: z.ZodString;
657
+ name: z.ZodOptional<z.ZodString>;
658
+ logo: z.ZodOptional<z.ZodString>;
659
+ coingeckoId: z.ZodOptional<z.ZodString>;
660
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
661
+ mirrorOf: z.ZodOptional<z.ZodString>;
662
+ type: z.ZodLiteral<"substrate-tokens">;
663
+ platform: z.ZodLiteral<"polkadot">;
664
+ onChainId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
665
+ existentialDeposit: z.ZodString;
666
+ }, z.core.$strict>;
667
+ type SubTokensToken = z.infer<typeof SubTokensTokenSchema>;
668
+ declare const SubTokensBalancesConfigSchema: z.ZodObject<{
669
+ palletId: z.ZodOptional<z.ZodString>;
670
+ }, z.core.$strip>;
671
+ type SubTokensBalancesConfig = z.infer<typeof SubTokensBalancesConfigSchema>;
672
+ type SubTokensTokenIdSpecs = {
673
+ type: typeof TOKEN_TYPE$1;
674
+ networkId: NetworkId;
675
+ onChainId: string;
676
+ };
677
+ declare const subTokensTokenId: (networkId: NetworkId, onChainId: string | number) => string;
678
+ declare const parseSubTokensTokenId: (tokenId: string) => SubTokensTokenIdSpecs;
679
+
680
+ /**
681
+ * The `Token` sum type, which is a union of all of the possible `TokenTypes`.
682
+ */
683
+ declare const TokenSchemaBase: z.ZodDiscriminatedUnion<[z.ZodObject<{
684
+ id: z.ZodString;
685
+ networkId: z.ZodString;
686
+ isDefault: z.ZodOptional<z.ZodBoolean>;
687
+ decimals: z.ZodInt;
688
+ symbol: z.ZodString;
689
+ name: z.ZodOptional<z.ZodString>;
690
+ logo: z.ZodOptional<z.ZodString>;
691
+ coingeckoId: z.ZodOptional<z.ZodString>;
692
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
693
+ mirrorOf: z.ZodOptional<z.ZodString>;
694
+ type: z.ZodLiteral<"evm-erc20">;
695
+ platform: z.ZodLiteral<"ethereum">;
696
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
697
+ }, z.core.$strict>, z.ZodObject<{
698
+ id: z.ZodString;
699
+ networkId: z.ZodString;
700
+ isDefault: z.ZodOptional<z.ZodBoolean>;
701
+ decimals: z.ZodInt;
702
+ symbol: z.ZodString;
703
+ name: z.ZodOptional<z.ZodString>;
704
+ logo: z.ZodOptional<z.ZodString>;
705
+ coingeckoId: z.ZodOptional<z.ZodString>;
706
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
707
+ mirrorOf: z.ZodOptional<z.ZodString>;
708
+ type: z.ZodLiteral<"evm-native">;
709
+ platform: z.ZodLiteral<"ethereum">;
710
+ }, z.core.$strict>, z.ZodObject<{
711
+ id: z.ZodString;
712
+ networkId: z.ZodString;
713
+ isDefault: z.ZodOptional<z.ZodBoolean>;
714
+ decimals: z.ZodInt;
715
+ symbol: z.ZodString;
716
+ name: z.ZodOptional<z.ZodString>;
717
+ logo: z.ZodOptional<z.ZodString>;
718
+ coingeckoId: z.ZodOptional<z.ZodString>;
719
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
720
+ mirrorOf: z.ZodOptional<z.ZodString>;
721
+ type: z.ZodLiteral<"evm-uniswapv2">;
722
+ platform: z.ZodLiteral<"ethereum">;
723
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
724
+ isCustom: z.ZodOptional<z.ZodBoolean>;
725
+ symbol0: z.ZodString;
726
+ symbol1: z.ZodString;
727
+ decimals0: z.ZodInt;
728
+ decimals1: z.ZodInt;
729
+ tokenAddress0: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
730
+ tokenAddress1: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
731
+ coingeckoId0: z.ZodOptional<z.ZodString>;
732
+ coingeckoId1: z.ZodOptional<z.ZodString>;
733
+ }, z.core.$strict>, z.ZodObject<{
734
+ id: z.ZodString;
735
+ networkId: z.ZodString;
736
+ isDefault: z.ZodOptional<z.ZodBoolean>;
737
+ decimals: z.ZodInt;
738
+ symbol: z.ZodString;
739
+ name: z.ZodOptional<z.ZodString>;
740
+ logo: z.ZodOptional<z.ZodString>;
741
+ coingeckoId: z.ZodOptional<z.ZodString>;
742
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
743
+ mirrorOf: z.ZodOptional<z.ZodString>;
744
+ type: z.ZodLiteral<"substrate-assets">;
745
+ platform: z.ZodLiteral<"polkadot">;
746
+ assetId: z.ZodPipe<z.ZodUnion<readonly [z.ZodUInt32, z.ZodString]>, z.ZodTransform<string, string | number>>;
747
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
748
+ isSufficient: z.ZodBoolean;
749
+ existentialDeposit: z.ZodString;
750
+ }, z.core.$strict>, z.ZodObject<{
751
+ id: z.ZodString;
752
+ networkId: z.ZodString;
753
+ isDefault: z.ZodOptional<z.ZodBoolean>;
754
+ decimals: z.ZodInt;
755
+ symbol: z.ZodString;
756
+ name: z.ZodOptional<z.ZodString>;
757
+ logo: z.ZodOptional<z.ZodString>;
758
+ coingeckoId: z.ZodOptional<z.ZodString>;
759
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
760
+ mirrorOf: z.ZodOptional<z.ZodString>;
761
+ type: z.ZodLiteral<"substrate-dtao">;
762
+ platform: z.ZodLiteral<"polkadot">;
763
+ netuid: z.ZodNumber;
764
+ subnetName: z.ZodOptional<z.ZodString>;
765
+ hotkey: z.ZodOptional<z.ZodString>;
766
+ isTransferable: z.ZodDefault<z.ZodBoolean>;
767
+ }, z.core.$strict>, z.ZodObject<{
768
+ id: z.ZodString;
769
+ networkId: z.ZodString;
770
+ isDefault: z.ZodOptional<z.ZodBoolean>;
771
+ decimals: z.ZodInt;
772
+ symbol: z.ZodString;
773
+ name: z.ZodOptional<z.ZodString>;
774
+ logo: z.ZodOptional<z.ZodString>;
775
+ coingeckoId: z.ZodOptional<z.ZodString>;
776
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
777
+ mirrorOf: z.ZodOptional<z.ZodString>;
778
+ type: z.ZodLiteral<"substrate-foreignassets">;
779
+ platform: z.ZodLiteral<"polkadot">;
780
+ onChainId: z.ZodString;
781
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
782
+ isSufficient: z.ZodBoolean;
783
+ existentialDeposit: z.ZodString;
784
+ }, z.core.$strict>, z.ZodObject<{
785
+ id: z.ZodString;
786
+ networkId: z.ZodString;
787
+ isDefault: z.ZodOptional<z.ZodBoolean>;
788
+ decimals: z.ZodInt;
789
+ symbol: z.ZodString;
790
+ name: z.ZodOptional<z.ZodString>;
791
+ logo: z.ZodOptional<z.ZodString>;
792
+ coingeckoId: z.ZodOptional<z.ZodString>;
793
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
794
+ mirrorOf: z.ZodOptional<z.ZodString>;
795
+ type: z.ZodLiteral<"substrate-native">;
796
+ platform: z.ZodLiteral<"polkadot">;
797
+ existentialDeposit: z.ZodString;
798
+ }, z.core.$strict>, z.ZodObject<{
799
+ id: z.ZodString;
800
+ networkId: z.ZodString;
801
+ isDefault: z.ZodOptional<z.ZodBoolean>;
802
+ decimals: z.ZodInt;
803
+ symbol: z.ZodString;
804
+ name: z.ZodOptional<z.ZodString>;
805
+ logo: z.ZodOptional<z.ZodString>;
806
+ coingeckoId: z.ZodOptional<z.ZodString>;
807
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
808
+ mirrorOf: z.ZodOptional<z.ZodString>;
809
+ type: z.ZodLiteral<"substrate-psp22">;
810
+ platform: z.ZodLiteral<"polkadot">;
811
+ contractAddress: z.ZodString;
812
+ }, z.core.$strict>, z.ZodObject<{
813
+ id: z.ZodString;
814
+ networkId: z.ZodString;
815
+ isDefault: z.ZodOptional<z.ZodBoolean>;
816
+ decimals: z.ZodInt;
817
+ symbol: z.ZodString;
818
+ name: z.ZodOptional<z.ZodString>;
819
+ logo: z.ZodOptional<z.ZodString>;
820
+ coingeckoId: z.ZodOptional<z.ZodString>;
821
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
822
+ mirrorOf: z.ZodOptional<z.ZodString>;
823
+ type: z.ZodLiteral<"substrate-tokens">;
824
+ platform: z.ZodLiteral<"polkadot">;
825
+ onChainId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
826
+ existentialDeposit: z.ZodString;
827
+ }, z.core.$strict>, z.ZodObject<{
828
+ id: z.ZodString;
829
+ networkId: z.ZodString;
830
+ isDefault: z.ZodOptional<z.ZodBoolean>;
831
+ decimals: z.ZodInt;
832
+ symbol: z.ZodString;
833
+ name: z.ZodOptional<z.ZodString>;
834
+ logo: z.ZodOptional<z.ZodString>;
835
+ coingeckoId: z.ZodOptional<z.ZodString>;
836
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
837
+ mirrorOf: z.ZodOptional<z.ZodString>;
838
+ type: z.ZodLiteral<"substrate-hydration">;
839
+ platform: z.ZodLiteral<"polkadot">;
840
+ onChainId: z.ZodUInt32;
841
+ assetType: z.ZodEnum<{
842
+ Token: "Token";
843
+ Erc20: "Erc20";
844
+ External: "External";
845
+ }>;
846
+ isSufficient: z.ZodBoolean;
847
+ existentialDeposit: z.ZodString;
848
+ }, z.core.$strict>, z.ZodObject<{
849
+ id: z.ZodString;
850
+ networkId: z.ZodString;
851
+ isDefault: z.ZodOptional<z.ZodBoolean>;
852
+ decimals: z.ZodInt;
853
+ symbol: z.ZodString;
854
+ name: z.ZodOptional<z.ZodString>;
855
+ logo: z.ZodOptional<z.ZodString>;
856
+ coingeckoId: z.ZodOptional<z.ZodString>;
857
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
858
+ mirrorOf: z.ZodOptional<z.ZodString>;
859
+ type: z.ZodLiteral<"sol-native">;
860
+ platform: z.ZodLiteral<"solana">;
861
+ }, z.core.$strict>, z.ZodObject<{
862
+ id: z.ZodString;
863
+ networkId: z.ZodString;
864
+ isDefault: z.ZodOptional<z.ZodBoolean>;
865
+ decimals: z.ZodInt;
866
+ symbol: z.ZodString;
867
+ name: z.ZodOptional<z.ZodString>;
868
+ logo: z.ZodOptional<z.ZodString>;
869
+ coingeckoId: z.ZodOptional<z.ZodString>;
870
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
871
+ mirrorOf: z.ZodOptional<z.ZodString>;
872
+ type: z.ZodLiteral<"sol-spl">;
873
+ platform: z.ZodLiteral<"solana">;
874
+ mintAddress: z.ZodString;
875
+ }, z.core.$strict>]>;
876
+ declare const TokenTypeSchema: z.ZodEnum<{
877
+ "evm-native": "evm-native";
878
+ "substrate-native": "substrate-native";
879
+ "substrate-assets": "substrate-assets";
880
+ "substrate-psp22": "substrate-psp22";
881
+ "substrate-tokens": "substrate-tokens";
882
+ "substrate-foreignassets": "substrate-foreignassets";
883
+ "substrate-hydration": "substrate-hydration";
884
+ "substrate-dtao": "substrate-dtao";
885
+ "evm-erc20": "evm-erc20";
886
+ "evm-uniswapv2": "evm-uniswapv2";
887
+ "sol-native": "sol-native";
888
+ "sol-spl": "sol-spl";
889
+ }>;
890
+ type Token = z.infer<typeof TokenSchemaBase>;
891
+ type TokenId = Token["id"];
892
+ type TokenList = Record<TokenId, Token>;
893
+ type TokenType = z.infer<typeof TokenTypeSchema>;
894
+ type TokenIdSpecs<T extends TokenType> = T extends "evm-erc20" ? EvmErc20TokenIdSpecs : T extends "evm-native" ? EvmNativeTokenIdSpecs : T extends "evm-uniswapv2" ? EvmUniswapV2TokenIdSpecs : T extends "substrate-assets" ? SubAssetTokenIdSpecs : T extends "substrate-dtao" ? SubDTaoTokenIdSpecs : T extends "substrate-foreignassets" ? ForeignAssetsTokenIdSpecs : T extends "substrate-native" ? SubNativeTokenIdSpecs : T extends "substrate-psp22" ? SubPsp22TokenIdSpecs : T extends "substrate-tokens" ? SubTokensTokenIdSpecs : T extends "substrate-hydration" ? SubHydrationToken : T extends "sol-native" ? SolNativeToken : T extends "sol-spl" ? SolSplToken : never;
895
+ declare const TokenSchema: z.ZodPipe<z.ZodDiscriminatedUnion<[z.ZodObject<{
896
+ id: z.ZodString;
897
+ networkId: z.ZodString;
898
+ isDefault: z.ZodOptional<z.ZodBoolean>;
899
+ decimals: z.ZodInt;
900
+ symbol: z.ZodString;
901
+ name: z.ZodOptional<z.ZodString>;
902
+ logo: z.ZodOptional<z.ZodString>;
903
+ coingeckoId: z.ZodOptional<z.ZodString>;
904
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
905
+ mirrorOf: z.ZodOptional<z.ZodString>;
906
+ type: z.ZodLiteral<"evm-erc20">;
907
+ platform: z.ZodLiteral<"ethereum">;
908
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
909
+ }, z.core.$strict>, z.ZodObject<{
910
+ id: z.ZodString;
911
+ networkId: z.ZodString;
912
+ isDefault: z.ZodOptional<z.ZodBoolean>;
913
+ decimals: z.ZodInt;
914
+ symbol: z.ZodString;
915
+ name: z.ZodOptional<z.ZodString>;
916
+ logo: z.ZodOptional<z.ZodString>;
917
+ coingeckoId: z.ZodOptional<z.ZodString>;
918
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
919
+ mirrorOf: z.ZodOptional<z.ZodString>;
920
+ type: z.ZodLiteral<"evm-native">;
921
+ platform: z.ZodLiteral<"ethereum">;
922
+ }, z.core.$strict>, z.ZodObject<{
923
+ id: z.ZodString;
924
+ networkId: z.ZodString;
925
+ isDefault: z.ZodOptional<z.ZodBoolean>;
926
+ decimals: z.ZodInt;
927
+ symbol: z.ZodString;
928
+ name: z.ZodOptional<z.ZodString>;
929
+ logo: z.ZodOptional<z.ZodString>;
930
+ coingeckoId: z.ZodOptional<z.ZodString>;
931
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
932
+ mirrorOf: z.ZodOptional<z.ZodString>;
933
+ type: z.ZodLiteral<"evm-uniswapv2">;
934
+ platform: z.ZodLiteral<"ethereum">;
935
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
936
+ isCustom: z.ZodOptional<z.ZodBoolean>;
937
+ symbol0: z.ZodString;
938
+ symbol1: z.ZodString;
939
+ decimals0: z.ZodInt;
940
+ decimals1: z.ZodInt;
941
+ tokenAddress0: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
942
+ tokenAddress1: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
943
+ coingeckoId0: z.ZodOptional<z.ZodString>;
944
+ coingeckoId1: z.ZodOptional<z.ZodString>;
945
+ }, z.core.$strict>, z.ZodObject<{
946
+ id: z.ZodString;
947
+ networkId: z.ZodString;
948
+ isDefault: z.ZodOptional<z.ZodBoolean>;
949
+ decimals: z.ZodInt;
950
+ symbol: z.ZodString;
951
+ name: z.ZodOptional<z.ZodString>;
952
+ logo: z.ZodOptional<z.ZodString>;
953
+ coingeckoId: z.ZodOptional<z.ZodString>;
954
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
955
+ mirrorOf: z.ZodOptional<z.ZodString>;
956
+ type: z.ZodLiteral<"substrate-assets">;
957
+ platform: z.ZodLiteral<"polkadot">;
958
+ assetId: z.ZodPipe<z.ZodUnion<readonly [z.ZodUInt32, z.ZodString]>, z.ZodTransform<string, string | number>>;
959
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
960
+ isSufficient: z.ZodBoolean;
961
+ existentialDeposit: z.ZodString;
962
+ }, z.core.$strict>, z.ZodObject<{
963
+ id: z.ZodString;
964
+ networkId: z.ZodString;
965
+ isDefault: z.ZodOptional<z.ZodBoolean>;
966
+ decimals: z.ZodInt;
967
+ symbol: z.ZodString;
968
+ name: z.ZodOptional<z.ZodString>;
969
+ logo: z.ZodOptional<z.ZodString>;
970
+ coingeckoId: z.ZodOptional<z.ZodString>;
971
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
972
+ mirrorOf: z.ZodOptional<z.ZodString>;
973
+ type: z.ZodLiteral<"substrate-dtao">;
974
+ platform: z.ZodLiteral<"polkadot">;
975
+ netuid: z.ZodNumber;
976
+ subnetName: z.ZodOptional<z.ZodString>;
977
+ hotkey: z.ZodOptional<z.ZodString>;
978
+ isTransferable: z.ZodDefault<z.ZodBoolean>;
979
+ }, z.core.$strict>, z.ZodObject<{
980
+ id: z.ZodString;
981
+ networkId: z.ZodString;
982
+ isDefault: z.ZodOptional<z.ZodBoolean>;
983
+ decimals: z.ZodInt;
984
+ symbol: z.ZodString;
985
+ name: z.ZodOptional<z.ZodString>;
986
+ logo: z.ZodOptional<z.ZodString>;
987
+ coingeckoId: z.ZodOptional<z.ZodString>;
988
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
989
+ mirrorOf: z.ZodOptional<z.ZodString>;
990
+ type: z.ZodLiteral<"substrate-foreignassets">;
991
+ platform: z.ZodLiteral<"polkadot">;
992
+ onChainId: z.ZodString;
993
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
994
+ isSufficient: z.ZodBoolean;
995
+ existentialDeposit: z.ZodString;
996
+ }, z.core.$strict>, z.ZodObject<{
997
+ id: z.ZodString;
998
+ networkId: z.ZodString;
999
+ isDefault: z.ZodOptional<z.ZodBoolean>;
1000
+ decimals: z.ZodInt;
1001
+ symbol: z.ZodString;
1002
+ name: z.ZodOptional<z.ZodString>;
1003
+ logo: z.ZodOptional<z.ZodString>;
1004
+ coingeckoId: z.ZodOptional<z.ZodString>;
1005
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
1006
+ mirrorOf: z.ZodOptional<z.ZodString>;
1007
+ type: z.ZodLiteral<"substrate-native">;
1008
+ platform: z.ZodLiteral<"polkadot">;
1009
+ existentialDeposit: z.ZodString;
1010
+ }, z.core.$strict>, z.ZodObject<{
1011
+ id: z.ZodString;
1012
+ networkId: z.ZodString;
1013
+ isDefault: z.ZodOptional<z.ZodBoolean>;
1014
+ decimals: z.ZodInt;
1015
+ symbol: z.ZodString;
1016
+ name: z.ZodOptional<z.ZodString>;
1017
+ logo: z.ZodOptional<z.ZodString>;
1018
+ coingeckoId: z.ZodOptional<z.ZodString>;
1019
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
1020
+ mirrorOf: z.ZodOptional<z.ZodString>;
1021
+ type: z.ZodLiteral<"substrate-psp22">;
1022
+ platform: z.ZodLiteral<"polkadot">;
1023
+ contractAddress: z.ZodString;
1024
+ }, z.core.$strict>, z.ZodObject<{
1025
+ id: z.ZodString;
1026
+ networkId: z.ZodString;
1027
+ isDefault: z.ZodOptional<z.ZodBoolean>;
1028
+ decimals: z.ZodInt;
1029
+ symbol: z.ZodString;
1030
+ name: z.ZodOptional<z.ZodString>;
1031
+ logo: z.ZodOptional<z.ZodString>;
1032
+ coingeckoId: z.ZodOptional<z.ZodString>;
1033
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
1034
+ mirrorOf: z.ZodOptional<z.ZodString>;
1035
+ type: z.ZodLiteral<"substrate-tokens">;
1036
+ platform: z.ZodLiteral<"polkadot">;
1037
+ onChainId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
1038
+ existentialDeposit: z.ZodString;
1039
+ }, z.core.$strict>, z.ZodObject<{
1040
+ id: z.ZodString;
1041
+ networkId: z.ZodString;
1042
+ isDefault: z.ZodOptional<z.ZodBoolean>;
1043
+ decimals: z.ZodInt;
1044
+ symbol: z.ZodString;
1045
+ name: z.ZodOptional<z.ZodString>;
1046
+ logo: z.ZodOptional<z.ZodString>;
1047
+ coingeckoId: z.ZodOptional<z.ZodString>;
1048
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
1049
+ mirrorOf: z.ZodOptional<z.ZodString>;
1050
+ type: z.ZodLiteral<"substrate-hydration">;
1051
+ platform: z.ZodLiteral<"polkadot">;
1052
+ onChainId: z.ZodUInt32;
1053
+ assetType: z.ZodEnum<{
1054
+ Token: "Token";
1055
+ Erc20: "Erc20";
1056
+ External: "External";
1057
+ }>;
1058
+ isSufficient: z.ZodBoolean;
1059
+ existentialDeposit: z.ZodString;
1060
+ }, z.core.$strict>, z.ZodObject<{
1061
+ id: z.ZodString;
1062
+ networkId: z.ZodString;
1063
+ isDefault: z.ZodOptional<z.ZodBoolean>;
1064
+ decimals: z.ZodInt;
1065
+ symbol: z.ZodString;
1066
+ name: z.ZodOptional<z.ZodString>;
1067
+ logo: z.ZodOptional<z.ZodString>;
1068
+ coingeckoId: z.ZodOptional<z.ZodString>;
1069
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
1070
+ mirrorOf: z.ZodOptional<z.ZodString>;
1071
+ type: z.ZodLiteral<"sol-native">;
1072
+ platform: z.ZodLiteral<"solana">;
1073
+ }, z.core.$strict>, z.ZodObject<{
1074
+ id: z.ZodString;
1075
+ networkId: z.ZodString;
1076
+ isDefault: z.ZodOptional<z.ZodBoolean>;
1077
+ decimals: z.ZodInt;
1078
+ symbol: z.ZodString;
1079
+ name: z.ZodOptional<z.ZodString>;
1080
+ logo: z.ZodOptional<z.ZodString>;
1081
+ coingeckoId: z.ZodOptional<z.ZodString>;
1082
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
1083
+ mirrorOf: z.ZodOptional<z.ZodString>;
1084
+ type: z.ZodLiteral<"sol-spl">;
1085
+ platform: z.ZodLiteral<"solana">;
1086
+ mintAddress: z.ZodString;
1087
+ }, z.core.$strict>]>, z.ZodTransform<{
1088
+ id: string;
1089
+ networkId: string;
1090
+ decimals: number;
1091
+ symbol: string;
1092
+ type: "evm-native";
1093
+ platform: "ethereum";
1094
+ isDefault?: boolean | undefined;
1095
+ name?: string | undefined;
1096
+ logo?: string | undefined;
1097
+ coingeckoId?: string | undefined;
1098
+ noDiscovery?: boolean | undefined;
1099
+ mirrorOf?: string | undefined;
1100
+ } | {
1101
+ id: string;
1102
+ networkId: string;
1103
+ decimals: number;
1104
+ symbol: string;
1105
+ type: "evm-erc20";
1106
+ platform: "ethereum";
1107
+ contractAddress: `0x${string}`;
1108
+ isDefault?: boolean | undefined;
1109
+ name?: string | undefined;
1110
+ logo?: string | undefined;
1111
+ coingeckoId?: string | undefined;
1112
+ noDiscovery?: boolean | undefined;
1113
+ mirrorOf?: string | undefined;
1114
+ } | {
1115
+ id: string;
1116
+ networkId: string;
1117
+ decimals: number;
1118
+ symbol: string;
1119
+ type: "evm-uniswapv2";
1120
+ platform: "ethereum";
1121
+ contractAddress: `0x${string}`;
1122
+ symbol0: string;
1123
+ symbol1: string;
1124
+ decimals0: number;
1125
+ decimals1: number;
1126
+ tokenAddress0: `0x${string}`;
1127
+ tokenAddress1: `0x${string}`;
1128
+ isDefault?: boolean | undefined;
1129
+ name?: string | undefined;
1130
+ logo?: string | undefined;
1131
+ coingeckoId?: string | undefined;
1132
+ noDiscovery?: boolean | undefined;
1133
+ mirrorOf?: string | undefined;
1134
+ isCustom?: boolean | undefined;
1135
+ coingeckoId0?: string | undefined;
1136
+ coingeckoId1?: string | undefined;
1137
+ } | {
1138
+ id: string;
1139
+ networkId: string;
1140
+ decimals: number;
1141
+ symbol: string;
1142
+ type: "substrate-assets";
1143
+ platform: "polkadot";
1144
+ assetId: string;
1145
+ isSufficient: boolean;
1146
+ existentialDeposit: string;
1147
+ isDefault?: boolean | undefined;
1148
+ name?: string | undefined;
1149
+ logo?: string | undefined;
1150
+ coingeckoId?: string | undefined;
1151
+ noDiscovery?: boolean | undefined;
1152
+ mirrorOf?: string | undefined;
1153
+ isFrozen?: boolean | undefined;
1154
+ } | {
1155
+ id: string;
1156
+ networkId: string;
1157
+ decimals: number;
1158
+ symbol: string;
1159
+ type: "substrate-dtao";
1160
+ platform: "polkadot";
1161
+ netuid: number;
1162
+ isTransferable: boolean;
1163
+ isDefault?: boolean | undefined;
1164
+ name?: string | undefined;
1165
+ logo?: string | undefined;
1166
+ coingeckoId?: string | undefined;
1167
+ noDiscovery?: boolean | undefined;
1168
+ mirrorOf?: string | undefined;
1169
+ subnetName?: string | undefined;
1170
+ hotkey?: string | undefined;
1171
+ } | {
1172
+ id: string;
1173
+ networkId: string;
1174
+ decimals: number;
1175
+ symbol: string;
1176
+ type: "substrate-foreignassets";
1177
+ platform: "polkadot";
1178
+ onChainId: string;
1179
+ isSufficient: boolean;
1180
+ existentialDeposit: string;
1181
+ isDefault?: boolean | undefined;
1182
+ name?: string | undefined;
1183
+ logo?: string | undefined;
1184
+ coingeckoId?: string | undefined;
1185
+ noDiscovery?: boolean | undefined;
1186
+ mirrorOf?: string | undefined;
1187
+ isFrozen?: boolean | undefined;
1188
+ } | {
1189
+ id: string;
1190
+ networkId: string;
1191
+ decimals: number;
1192
+ symbol: string;
1193
+ type: "substrate-native";
1194
+ platform: "polkadot";
1195
+ existentialDeposit: string;
1196
+ isDefault?: boolean | undefined;
1197
+ name?: string | undefined;
1198
+ logo?: string | undefined;
1199
+ coingeckoId?: string | undefined;
1200
+ noDiscovery?: boolean | undefined;
1201
+ mirrorOf?: string | undefined;
1202
+ } | {
1203
+ id: string;
1204
+ networkId: string;
1205
+ decimals: number;
1206
+ symbol: string;
1207
+ type: "substrate-psp22";
1208
+ platform: "polkadot";
1209
+ contractAddress: string;
1210
+ isDefault?: boolean | undefined;
1211
+ name?: string | undefined;
1212
+ logo?: string | undefined;
1213
+ coingeckoId?: string | undefined;
1214
+ noDiscovery?: boolean | undefined;
1215
+ mirrorOf?: string | undefined;
1216
+ } | {
1217
+ id: string;
1218
+ networkId: string;
1219
+ decimals: number;
1220
+ symbol: string;
1221
+ type: "substrate-tokens";
1222
+ platform: "polkadot";
1223
+ onChainId: string | number;
1224
+ existentialDeposit: string;
1225
+ isDefault?: boolean | undefined;
1226
+ name?: string | undefined;
1227
+ logo?: string | undefined;
1228
+ coingeckoId?: string | undefined;
1229
+ noDiscovery?: boolean | undefined;
1230
+ mirrorOf?: string | undefined;
1231
+ } | {
1232
+ id: string;
1233
+ networkId: string;
1234
+ decimals: number;
1235
+ symbol: string;
1236
+ type: "substrate-hydration";
1237
+ platform: "polkadot";
1238
+ onChainId: number;
1239
+ assetType: "Token" | "Erc20" | "External";
1240
+ isSufficient: boolean;
1241
+ existentialDeposit: string;
1242
+ isDefault?: boolean | undefined;
1243
+ name?: string | undefined;
1244
+ logo?: string | undefined;
1245
+ coingeckoId?: string | undefined;
1246
+ noDiscovery?: boolean | undefined;
1247
+ mirrorOf?: string | undefined;
1248
+ } | {
1249
+ id: string;
1250
+ networkId: string;
1251
+ decimals: number;
1252
+ symbol: string;
1253
+ type: "sol-native";
1254
+ platform: "solana";
1255
+ isDefault?: boolean | undefined;
1256
+ name?: string | undefined;
1257
+ logo?: string | undefined;
1258
+ coingeckoId?: string | undefined;
1259
+ noDiscovery?: boolean | undefined;
1260
+ mirrorOf?: string | undefined;
1261
+ } | {
1262
+ id: string;
1263
+ networkId: string;
1264
+ decimals: number;
1265
+ symbol: string;
1266
+ type: "sol-spl";
1267
+ platform: "solana";
1268
+ mintAddress: string;
1269
+ isDefault?: boolean | undefined;
1270
+ name?: string | undefined;
1271
+ logo?: string | undefined;
1272
+ coingeckoId?: string | undefined;
1273
+ noDiscovery?: boolean | undefined;
1274
+ mirrorOf?: string | undefined;
1275
+ }, {
1276
+ id: string;
1277
+ networkId: string;
1278
+ decimals: number;
1279
+ symbol: string;
1280
+ type: "evm-native";
1281
+ platform: "ethereum";
1282
+ isDefault?: boolean | undefined;
1283
+ name?: string | undefined;
1284
+ logo?: string | undefined;
1285
+ coingeckoId?: string | undefined;
1286
+ noDiscovery?: boolean | undefined;
1287
+ mirrorOf?: string | undefined;
1288
+ } | {
1289
+ id: string;
1290
+ networkId: string;
1291
+ decimals: number;
1292
+ symbol: string;
1293
+ type: "evm-erc20";
1294
+ platform: "ethereum";
1295
+ contractAddress: `0x${string}`;
1296
+ isDefault?: boolean | undefined;
1297
+ name?: string | undefined;
1298
+ logo?: string | undefined;
1299
+ coingeckoId?: string | undefined;
1300
+ noDiscovery?: boolean | undefined;
1301
+ mirrorOf?: string | undefined;
1302
+ } | {
1303
+ id: string;
1304
+ networkId: string;
1305
+ decimals: number;
1306
+ symbol: string;
1307
+ type: "evm-uniswapv2";
1308
+ platform: "ethereum";
1309
+ contractAddress: `0x${string}`;
1310
+ symbol0: string;
1311
+ symbol1: string;
1312
+ decimals0: number;
1313
+ decimals1: number;
1314
+ tokenAddress0: `0x${string}`;
1315
+ tokenAddress1: `0x${string}`;
1316
+ isDefault?: boolean | undefined;
1317
+ name?: string | undefined;
1318
+ logo?: string | undefined;
1319
+ coingeckoId?: string | undefined;
1320
+ noDiscovery?: boolean | undefined;
1321
+ mirrorOf?: string | undefined;
1322
+ isCustom?: boolean | undefined;
1323
+ coingeckoId0?: string | undefined;
1324
+ coingeckoId1?: string | undefined;
1325
+ } | {
1326
+ id: string;
1327
+ networkId: string;
1328
+ decimals: number;
1329
+ symbol: string;
1330
+ type: "substrate-assets";
1331
+ platform: "polkadot";
1332
+ assetId: string;
1333
+ isSufficient: boolean;
1334
+ existentialDeposit: string;
1335
+ isDefault?: boolean | undefined;
1336
+ name?: string | undefined;
1337
+ logo?: string | undefined;
1338
+ coingeckoId?: string | undefined;
1339
+ noDiscovery?: boolean | undefined;
1340
+ mirrorOf?: string | undefined;
1341
+ isFrozen?: boolean | undefined;
1342
+ } | {
1343
+ id: string;
1344
+ networkId: string;
1345
+ decimals: number;
1346
+ symbol: string;
1347
+ type: "substrate-dtao";
1348
+ platform: "polkadot";
1349
+ netuid: number;
1350
+ isTransferable: boolean;
1351
+ isDefault?: boolean | undefined;
1352
+ name?: string | undefined;
1353
+ logo?: string | undefined;
1354
+ coingeckoId?: string | undefined;
1355
+ noDiscovery?: boolean | undefined;
1356
+ mirrorOf?: string | undefined;
1357
+ subnetName?: string | undefined;
1358
+ hotkey?: string | undefined;
1359
+ } | {
1360
+ id: string;
1361
+ networkId: string;
1362
+ decimals: number;
1363
+ symbol: string;
1364
+ type: "substrate-foreignassets";
1365
+ platform: "polkadot";
1366
+ onChainId: string;
1367
+ isSufficient: boolean;
1368
+ existentialDeposit: string;
1369
+ isDefault?: boolean | undefined;
1370
+ name?: string | undefined;
1371
+ logo?: string | undefined;
1372
+ coingeckoId?: string | undefined;
1373
+ noDiscovery?: boolean | undefined;
1374
+ mirrorOf?: string | undefined;
1375
+ isFrozen?: boolean | undefined;
1376
+ } | {
1377
+ id: string;
1378
+ networkId: string;
1379
+ decimals: number;
1380
+ symbol: string;
1381
+ type: "substrate-native";
1382
+ platform: "polkadot";
1383
+ existentialDeposit: string;
1384
+ isDefault?: boolean | undefined;
1385
+ name?: string | undefined;
1386
+ logo?: string | undefined;
1387
+ coingeckoId?: string | undefined;
1388
+ noDiscovery?: boolean | undefined;
1389
+ mirrorOf?: string | undefined;
1390
+ } | {
1391
+ id: string;
1392
+ networkId: string;
1393
+ decimals: number;
1394
+ symbol: string;
1395
+ type: "substrate-psp22";
1396
+ platform: "polkadot";
1397
+ contractAddress: string;
1398
+ isDefault?: boolean | undefined;
1399
+ name?: string | undefined;
1400
+ logo?: string | undefined;
1401
+ coingeckoId?: string | undefined;
1402
+ noDiscovery?: boolean | undefined;
1403
+ mirrorOf?: string | undefined;
1404
+ } | {
1405
+ id: string;
1406
+ networkId: string;
1407
+ decimals: number;
1408
+ symbol: string;
1409
+ type: "substrate-tokens";
1410
+ platform: "polkadot";
1411
+ onChainId: string | number;
1412
+ existentialDeposit: string;
1413
+ isDefault?: boolean | undefined;
1414
+ name?: string | undefined;
1415
+ logo?: string | undefined;
1416
+ coingeckoId?: string | undefined;
1417
+ noDiscovery?: boolean | undefined;
1418
+ mirrorOf?: string | undefined;
1419
+ } | {
1420
+ id: string;
1421
+ networkId: string;
1422
+ decimals: number;
1423
+ symbol: string;
1424
+ type: "substrate-hydration";
1425
+ platform: "polkadot";
1426
+ onChainId: number;
1427
+ assetType: "Token" | "Erc20" | "External";
1428
+ isSufficient: boolean;
1429
+ existentialDeposit: string;
1430
+ isDefault?: boolean | undefined;
1431
+ name?: string | undefined;
1432
+ logo?: string | undefined;
1433
+ coingeckoId?: string | undefined;
1434
+ noDiscovery?: boolean | undefined;
1435
+ mirrorOf?: string | undefined;
1436
+ } | {
1437
+ id: string;
1438
+ networkId: string;
1439
+ decimals: number;
1440
+ symbol: string;
1441
+ type: "sol-native";
1442
+ platform: "solana";
1443
+ isDefault?: boolean | undefined;
1444
+ name?: string | undefined;
1445
+ logo?: string | undefined;
1446
+ coingeckoId?: string | undefined;
1447
+ noDiscovery?: boolean | undefined;
1448
+ mirrorOf?: string | undefined;
1449
+ } | {
1450
+ id: string;
1451
+ networkId: string;
1452
+ decimals: number;
1453
+ symbol: string;
1454
+ type: "sol-spl";
1455
+ platform: "solana";
1456
+ mintAddress: string;
1457
+ isDefault?: boolean | undefined;
1458
+ name?: string | undefined;
1459
+ logo?: string | undefined;
1460
+ coingeckoId?: string | undefined;
1461
+ noDiscovery?: boolean | undefined;
1462
+ mirrorOf?: string | undefined;
1463
+ }>>;
1464
+
1465
+ declare const TOKEN_TYPE = "evm-erc20";
1466
+ declare const EvmErc20TokenSchema: z.ZodObject<{
1467
+ id: z.ZodString;
1468
+ networkId: z.ZodString;
1469
+ isDefault: z.ZodOptional<z.ZodBoolean>;
1470
+ decimals: z.ZodInt;
1471
+ symbol: z.ZodString;
1472
+ name: z.ZodOptional<z.ZodString>;
1473
+ logo: z.ZodOptional<z.ZodString>;
1474
+ coingeckoId: z.ZodOptional<z.ZodString>;
1475
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
1476
+ mirrorOf: z.ZodOptional<z.ZodString>;
1477
+ type: z.ZodLiteral<"evm-erc20">;
1478
+ platform: z.ZodLiteral<"ethereum">;
1479
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
1480
+ }, z.core.$strict>;
1481
+ type EvmErc20Token = z.infer<typeof EvmErc20TokenSchema>;
1482
+ declare const EvmErc20BalancesConfigSchema: z.ZodObject<{}, z.core.$strict>;
1483
+ type EvmErc20BalancesConfig = z.infer<typeof EvmErc20BalancesConfigSchema>;
1484
+ type EvmErc20TokenIdSpecs = {
1485
+ type: typeof TOKEN_TYPE;
1486
+ networkId: NetworkId;
1487
+ contractAddress: `0x${string}`;
1488
+ };
1489
+ declare const evmErc20TokenId: (networkId: string, contractAddress: `0x${string}`) => string;
1490
+ declare const parseEvmErc20TokenId: (tokenId: TokenId) => EvmErc20TokenIdSpecs;
1491
+
1492
+ declare const TokenBaseSchema: z.ZodObject<{
1493
+ id: z.ZodString;
1494
+ networkId: z.ZodString;
1495
+ isDefault: z.ZodOptional<z.ZodBoolean>;
1496
+ decimals: z.ZodInt;
1497
+ symbol: z.ZodString;
1498
+ name: z.ZodOptional<z.ZodString>;
1499
+ logo: z.ZodOptional<z.ZodString>;
1500
+ coingeckoId: z.ZodOptional<z.ZodString>;
1501
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
1502
+ mirrorOf: z.ZodOptional<z.ZodString>;
1503
+ }, z.core.$strict>;
1504
+ type TokenBase = z.infer<typeof TokenBaseSchema>;
1505
+
1506
+ type NetworkOfPlatform<P extends NetworkPlatform> = Extract<Network, {
1507
+ platform: P;
1508
+ }>;
1509
+ declare const isNetworkOfPlatform: <P extends NetworkPlatform>(network: Network | null | undefined, platform: P) => network is Extract<Network, {
1510
+ platform: P;
1511
+ }>;
1512
+ declare const isNetworkInPlatforms: <P extends NetworkPlatform[]>(network: Network | null | undefined, platforms: P) => network is NetworkOfPlatform<P[number]>;
1513
+ declare const isNetworkDot: (network: Network | null | undefined) => network is {
1514
+ id: string;
1515
+ name: string;
1516
+ nativeTokenId: string;
1517
+ nativeCurrency: {
1518
+ decimals: number;
1519
+ symbol: string;
1520
+ name: string;
1521
+ coingeckoId?: string | undefined;
1522
+ mirrorOf?: string | undefined;
1523
+ logo?: string | undefined;
1524
+ };
1525
+ blockExplorerUrls: string[];
1526
+ genesisHash: `0x${string}`;
1527
+ platform: "polkadot";
1528
+ chainName: string;
1529
+ specName: string;
1530
+ specVersion: number;
1531
+ account: "secp256k1" | "*25519";
1532
+ prefix: number;
1533
+ rpcs: string[];
1534
+ topology: {
1535
+ type: "standalone";
1536
+ } | {
1537
+ type: "relay";
1538
+ } | {
1539
+ type: "parachain";
1540
+ relayId: string;
1541
+ paraId: number;
1542
+ };
1543
+ isTestnet?: boolean | undefined;
1544
+ isDefault?: boolean | undefined;
1545
+ forceScan?: boolean | undefined;
1546
+ logo?: string | undefined;
1547
+ themeColor?: string | undefined;
1548
+ chainspecQrUrl?: string | undefined;
1549
+ latestMetadataQrUrl?: string | undefined;
1550
+ oldPrefix?: number | undefined;
1551
+ registryTypes?: any;
1552
+ signedExtensions?: any;
1553
+ hasCheckMetadataHash?: boolean | undefined;
1554
+ hasExtrinsicSignatureTypePrefix?: boolean | undefined;
1555
+ isUnknownFeeToken?: boolean | undefined;
1556
+ balancesConfig?: {
1557
+ "substrate-native"?: {
1558
+ disable?: boolean | undefined;
1559
+ } | undefined;
1560
+ "substrate-assets"?: Record<string, never> | undefined;
1561
+ "substrate-psp22"?: Record<string, never> | undefined;
1562
+ "substrate-tokens"?: {
1563
+ palletId?: string | undefined;
1564
+ } | undefined;
1565
+ "substrate-foreignassets"?: Record<string, never> | undefined;
1566
+ "substrate-hydration"?: Record<string, never> | undefined;
1567
+ "substrate-dtao"?: Record<string, never> | undefined;
1568
+ } | undefined;
1569
+ };
1570
+ declare const isNetworkEth: (network: Network | null | undefined) => network is {
1571
+ id: string;
1572
+ name: string;
1573
+ nativeTokenId: string;
1574
+ nativeCurrency: {
1575
+ decimals: number;
1576
+ symbol: string;
1577
+ name: string;
1578
+ coingeckoId?: string | undefined;
1579
+ mirrorOf?: string | undefined;
1580
+ logo?: string | undefined;
1581
+ };
1582
+ blockExplorerUrls: string[];
1583
+ platform: "ethereum";
1584
+ rpcs: string[];
1585
+ isTestnet?: boolean | undefined;
1586
+ isDefault?: boolean | undefined;
1587
+ forceScan?: boolean | undefined;
1588
+ logo?: string | undefined;
1589
+ themeColor?: string | undefined;
1590
+ substrateChainId?: string | undefined;
1591
+ preserveGasEstimate?: boolean | undefined;
1592
+ feeType?: "legacy" | "eip-1559" | undefined;
1593
+ l2FeeType?: {
1594
+ type: "op-stack";
1595
+ } | {
1596
+ type: "scroll";
1597
+ l1GasPriceOracle: `0x${string}`;
1598
+ } | undefined;
1599
+ contracts?: {
1600
+ Erc20Aggregator?: `0x${string}` | undefined;
1601
+ Multicall3?: `0x${string}` | undefined;
1602
+ } | undefined;
1603
+ balancesConfig?: {
1604
+ "evm-native"?: Record<string, never> | undefined;
1605
+ "evm-erc20"?: Record<string, never> | undefined;
1606
+ "evm-uniswapv2"?: Record<string, never> | undefined;
1607
+ } | undefined;
1608
+ };
1609
+ declare const isNetworkSol: (network: Network | null | undefined) => network is {
1610
+ id: string;
1611
+ name: string;
1612
+ nativeTokenId: string;
1613
+ nativeCurrency: {
1614
+ decimals: number;
1615
+ symbol: string;
1616
+ name: string;
1617
+ coingeckoId?: string | undefined;
1618
+ mirrorOf?: string | undefined;
1619
+ logo?: string | undefined;
1620
+ };
1621
+ blockExplorerUrls: string[];
1622
+ platform: "solana";
1623
+ genesisHash: string;
1624
+ rpcs: string[];
1625
+ isTestnet?: boolean | undefined;
1626
+ isDefault?: boolean | undefined;
1627
+ forceScan?: boolean | undefined;
1628
+ logo?: string | undefined;
1629
+ themeColor?: string | undefined;
1630
+ balancesConfig?: {
1631
+ "sol-native"?: Record<string, never> | undefined;
1632
+ "sol-spl"?: Record<string, never> | undefined;
1633
+ } | undefined;
1634
+ };
1635
+ declare const getNetworkGenesisHash: <Net extends Network, Res = Net extends DotNetwork ? DotNetwork["genesisHash"] : undefined>(network: Net | null | undefined) => Res;
1636
+ type TokenOfType<T extends TokenType> = Extract<Token, {
1637
+ type: T;
1638
+ }>;
1639
+ type TokenOfPlatform<P extends NetworkPlatform> = Extract<Token, {
1640
+ platform: P;
1641
+ }>;
1642
+ type DotToken = TokenOfPlatform<"polkadot">;
1643
+ type EthToken = TokenOfPlatform<"ethereum">;
1644
+ type SolToken = TokenOfPlatform<"solana">;
1645
+ declare const isTokenOfPlatform: <P extends NetworkPlatform>(token: Token | null | undefined, platform: P) => token is TokenOfPlatform<P>;
1646
+ declare const isTokenEth: (token: Token | null | undefined) => token is TokenOfPlatform<"ethereum">;
1647
+ declare const isTokenDot: (token: Token | null | undefined) => token is TokenOfPlatform<"polkadot">;
1648
+ declare const isTokenSol: (token: Token | null | undefined) => token is TokenOfPlatform<"solana">;
1649
+ declare const isTokenNeedExistentialDeposit: (token: Token) => token is {
1650
+ id: string;
1651
+ networkId: string;
1652
+ decimals: number;
1653
+ symbol: string;
1654
+ type: "substrate-assets";
1655
+ platform: "polkadot";
1656
+ assetId: string;
1657
+ isSufficient: boolean;
1658
+ existentialDeposit: string;
1659
+ isDefault?: boolean | undefined;
1660
+ name?: string | undefined;
1661
+ logo?: string | undefined;
1662
+ coingeckoId?: string | undefined;
1663
+ noDiscovery?: boolean | undefined;
1664
+ mirrorOf?: string | undefined;
1665
+ isFrozen?: boolean | undefined;
1666
+ } | {
1667
+ id: string;
1668
+ networkId: string;
1669
+ decimals: number;
1670
+ symbol: string;
1671
+ type: "substrate-foreignassets";
1672
+ platform: "polkadot";
1673
+ onChainId: string;
1674
+ isSufficient: boolean;
1675
+ existentialDeposit: string;
1676
+ isDefault?: boolean | undefined;
1677
+ name?: string | undefined;
1678
+ logo?: string | undefined;
1679
+ coingeckoId?: string | undefined;
1680
+ noDiscovery?: boolean | undefined;
1681
+ mirrorOf?: string | undefined;
1682
+ isFrozen?: boolean | undefined;
1683
+ } | {
1684
+ id: string;
1685
+ networkId: string;
1686
+ decimals: number;
1687
+ symbol: string;
1688
+ type: "substrate-native";
1689
+ platform: "polkadot";
1690
+ existentialDeposit: string;
1691
+ isDefault?: boolean | undefined;
1692
+ name?: string | undefined;
1693
+ logo?: string | undefined;
1694
+ coingeckoId?: string | undefined;
1695
+ noDiscovery?: boolean | undefined;
1696
+ mirrorOf?: string | undefined;
1697
+ } | {
1698
+ id: string;
1699
+ networkId: string;
1700
+ decimals: number;
1701
+ symbol: string;
1702
+ type: "substrate-tokens";
1703
+ platform: "polkadot";
1704
+ onChainId: string | number;
1705
+ existentialDeposit: string;
1706
+ isDefault?: boolean | undefined;
1707
+ name?: string | undefined;
1708
+ logo?: string | undefined;
1709
+ coingeckoId?: string | undefined;
1710
+ noDiscovery?: boolean | undefined;
1711
+ mirrorOf?: string | undefined;
1712
+ } | {
1713
+ id: string;
1714
+ networkId: string;
1715
+ decimals: number;
1716
+ symbol: string;
1717
+ type: "substrate-hydration";
1718
+ platform: "polkadot";
1719
+ onChainId: number;
1720
+ assetType: "Token" | "Erc20" | "External";
1721
+ isSufficient: boolean;
1722
+ existentialDeposit: string;
1723
+ isDefault?: boolean | undefined;
1724
+ name?: string | undefined;
1725
+ logo?: string | undefined;
1726
+ coingeckoId?: string | undefined;
1727
+ noDiscovery?: boolean | undefined;
1728
+ mirrorOf?: string | undefined;
1729
+ };
1730
+ declare const isTokenOfType: <T extends TokenType>(token: Token | null | undefined, type: T) => token is TokenOfType<T>;
1731
+ declare const isTokenInTypes: <T extends TokenType[]>(token: Token | null | undefined, types: T) => token is TokenOfType<T[number]>;
1732
+ declare const isTokenSubNative: (token: Token | null | undefined) => token is {
1733
+ id: string;
1734
+ networkId: string;
1735
+ decimals: number;
1736
+ symbol: string;
1737
+ type: "substrate-native";
1738
+ platform: "polkadot";
1739
+ existentialDeposit: string;
1740
+ isDefault?: boolean | undefined;
1741
+ name?: string | undefined;
1742
+ logo?: string | undefined;
1743
+ coingeckoId?: string | undefined;
1744
+ noDiscovery?: boolean | undefined;
1745
+ mirrorOf?: string | undefined;
1746
+ };
1747
+ declare const isTokenSubAssets: (token: Token | null | undefined) => token is {
1748
+ id: string;
1749
+ networkId: string;
1750
+ decimals: number;
1751
+ symbol: string;
1752
+ type: "substrate-assets";
1753
+ platform: "polkadot";
1754
+ assetId: string;
1755
+ isSufficient: boolean;
1756
+ existentialDeposit: string;
1757
+ isDefault?: boolean | undefined;
1758
+ name?: string | undefined;
1759
+ logo?: string | undefined;
1760
+ coingeckoId?: string | undefined;
1761
+ noDiscovery?: boolean | undefined;
1762
+ mirrorOf?: string | undefined;
1763
+ isFrozen?: boolean | undefined;
1764
+ };
1765
+ declare const isTokenSubDTao: (token: Token | null | undefined) => token is {
1766
+ id: string;
1767
+ networkId: string;
1768
+ decimals: number;
1769
+ symbol: string;
1770
+ type: "substrate-dtao";
1771
+ platform: "polkadot";
1772
+ netuid: number;
1773
+ isTransferable: boolean;
1774
+ isDefault?: boolean | undefined;
1775
+ name?: string | undefined;
1776
+ logo?: string | undefined;
1777
+ coingeckoId?: string | undefined;
1778
+ noDiscovery?: boolean | undefined;
1779
+ mirrorOf?: string | undefined;
1780
+ subnetName?: string | undefined;
1781
+ hotkey?: string | undefined;
1782
+ };
1783
+ declare const isTokenSubForeignAssets: (token: Token | null | undefined) => token is {
1784
+ id: string;
1785
+ networkId: string;
1786
+ decimals: number;
1787
+ symbol: string;
1788
+ type: "substrate-foreignassets";
1789
+ platform: "polkadot";
1790
+ onChainId: string;
1791
+ isSufficient: boolean;
1792
+ existentialDeposit: string;
1793
+ isDefault?: boolean | undefined;
1794
+ name?: string | undefined;
1795
+ logo?: string | undefined;
1796
+ coingeckoId?: string | undefined;
1797
+ noDiscovery?: boolean | undefined;
1798
+ mirrorOf?: string | undefined;
1799
+ isFrozen?: boolean | undefined;
1800
+ };
1801
+ declare const isTokenSubPsp22: (token: Token | null | undefined) => token is {
1802
+ id: string;
1803
+ networkId: string;
1804
+ decimals: number;
1805
+ symbol: string;
1806
+ type: "substrate-psp22";
1807
+ platform: "polkadot";
1808
+ contractAddress: string;
1809
+ isDefault?: boolean | undefined;
1810
+ name?: string | undefined;
1811
+ logo?: string | undefined;
1812
+ coingeckoId?: string | undefined;
1813
+ noDiscovery?: boolean | undefined;
1814
+ mirrorOf?: string | undefined;
1815
+ };
1816
+ declare const isTokenSubTokens: (token: Token | null | undefined) => token is {
1817
+ id: string;
1818
+ networkId: string;
1819
+ decimals: number;
1820
+ symbol: string;
1821
+ type: "substrate-tokens";
1822
+ platform: "polkadot";
1823
+ onChainId: string | number;
1824
+ existentialDeposit: string;
1825
+ isDefault?: boolean | undefined;
1826
+ name?: string | undefined;
1827
+ logo?: string | undefined;
1828
+ coingeckoId?: string | undefined;
1829
+ noDiscovery?: boolean | undefined;
1830
+ mirrorOf?: string | undefined;
1831
+ };
1832
+ declare const isTokenSubHydration: (token: Token | null | undefined) => token is {
1833
+ id: string;
1834
+ networkId: string;
1835
+ decimals: number;
1836
+ symbol: string;
1837
+ type: "substrate-hydration";
1838
+ platform: "polkadot";
1839
+ onChainId: number;
1840
+ assetType: "Token" | "Erc20" | "External";
1841
+ isSufficient: boolean;
1842
+ existentialDeposit: string;
1843
+ isDefault?: boolean | undefined;
1844
+ name?: string | undefined;
1845
+ logo?: string | undefined;
1846
+ coingeckoId?: string | undefined;
1847
+ noDiscovery?: boolean | undefined;
1848
+ mirrorOf?: string | undefined;
1849
+ };
1850
+ declare const isTokenEvmNative: (token: Token | null | undefined) => token is {
1851
+ id: string;
1852
+ networkId: string;
1853
+ decimals: number;
1854
+ symbol: string;
1855
+ type: "evm-native";
1856
+ platform: "ethereum";
1857
+ isDefault?: boolean | undefined;
1858
+ name?: string | undefined;
1859
+ logo?: string | undefined;
1860
+ coingeckoId?: string | undefined;
1861
+ noDiscovery?: boolean | undefined;
1862
+ mirrorOf?: string | undefined;
1863
+ };
1864
+ declare const isTokenEvmErc20: (token: Token | null | undefined) => token is {
1865
+ id: string;
1866
+ networkId: string;
1867
+ decimals: number;
1868
+ symbol: string;
1869
+ type: "evm-erc20";
1870
+ platform: "ethereum";
1871
+ contractAddress: `0x${string}`;
1872
+ isDefault?: boolean | undefined;
1873
+ name?: string | undefined;
1874
+ logo?: string | undefined;
1875
+ coingeckoId?: string | undefined;
1876
+ noDiscovery?: boolean | undefined;
1877
+ mirrorOf?: string | undefined;
1878
+ };
1879
+ declare const isTokenEvmUniswapV2: (token: Token | null | undefined) => token is {
1880
+ id: string;
1881
+ networkId: string;
1882
+ decimals: number;
1883
+ symbol: string;
1884
+ type: "evm-uniswapv2";
1885
+ platform: "ethereum";
1886
+ contractAddress: `0x${string}`;
1887
+ symbol0: string;
1888
+ symbol1: string;
1889
+ decimals0: number;
1890
+ decimals1: number;
1891
+ tokenAddress0: `0x${string}`;
1892
+ tokenAddress1: `0x${string}`;
1893
+ isDefault?: boolean | undefined;
1894
+ name?: string | undefined;
1895
+ logo?: string | undefined;
1896
+ coingeckoId?: string | undefined;
1897
+ noDiscovery?: boolean | undefined;
1898
+ mirrorOf?: string | undefined;
1899
+ isCustom?: boolean | undefined;
1900
+ coingeckoId0?: string | undefined;
1901
+ coingeckoId1?: string | undefined;
1902
+ };
1903
+ declare const isTokenSolSpl: (token: Token | null | undefined) => token is {
1904
+ id: string;
1905
+ networkId: string;
1906
+ decimals: number;
1907
+ symbol: string;
1908
+ type: "sol-spl";
1909
+ platform: "solana";
1910
+ mintAddress: string;
1911
+ isDefault?: boolean | undefined;
1912
+ name?: string | undefined;
1913
+ logo?: string | undefined;
1914
+ coingeckoId?: string | undefined;
1915
+ noDiscovery?: boolean | undefined;
1916
+ mirrorOf?: string | undefined;
1917
+ };
1918
+ declare const parseTokenId: <T extends TokenType>(tokenId: TokenId) => TokenIdSpecs<T>;
1919
+ declare const networkIdFromTokenId: (tokenId: TokenId) => Network["id"];
1920
+ declare const PLATFORM_NATIVE_TOKENS: {
1921
+ polkadot: "substrate-native";
1922
+ ethereum: "evm-native";
1923
+ solana: "sol-native";
1924
+ };
1925
+ type NativeTokenType<P extends NetworkPlatform = NetworkPlatform> = (typeof PLATFORM_NATIVE_TOKENS)[P];
1926
+ type NativeToken<P extends NetworkPlatform = NetworkPlatform> = Extract<Token, {
1927
+ type: NativeTokenType<P>;
1928
+ }>;
1929
+ declare const isNativeTokenType: <P extends NetworkPlatform = NetworkPlatform>(type: TokenType, platform?: P) => type is NativeTokenType<P>;
1930
+ declare const isNativeToken: <P extends NetworkPlatform = NetworkPlatform>(token: Token, platform?: P) => token is NativeToken<P>;
1931
+
1932
+ declare const MINIMETADATA_VERSION: string;
1933
+
1934
+ type BlockExplorerQuery = {
1935
+ type: "address";
1936
+ address: string;
1937
+ } | {
1938
+ type: "account";
1939
+ address: string;
1940
+ } | {
1941
+ type: "transaction";
1942
+ id: string;
1943
+ } | {
1944
+ type: "block";
1945
+ id: string | number | bigint;
1946
+ } | {
1947
+ type: "extrinsic";
1948
+ blockNumber: number | bigint;
1949
+ extrinsicIndex: number;
1950
+ } | {
1951
+ type: "extrinsic-unknown";
1952
+ hash: `0x${string}`;
1953
+ };
1954
+ declare const getBlockExplorerUrls: (network: Network, query: BlockExplorerQuery) => string[];
1955
+ declare const getBlockExplorerLabel: (blockExplorerUrl: string) => string;
1956
+
1957
+ /** @deprecated */
1958
+ type LegacyEvmNetworkId = string;
1959
+ /** @deprecated */
1960
+ type LegacyEvmNetwork = {
1961
+ id: LegacyEvmNetworkId;
1962
+ isTestnet: boolean;
1963
+ isDefault: boolean;
1964
+ forceScan: boolean;
1965
+ /** @deprecated */
1966
+ sortIndex: number | null;
1967
+ name: string | null;
1968
+ themeColor: string | null;
1969
+ logo: string | null;
1970
+ nativeToken: {
1971
+ id: TokenId;
1972
+ } | null;
1973
+ /** @deprecated tokens already reference their network */
1974
+ tokens: Array<{
1975
+ id: TokenId;
1976
+ }> | null;
1977
+ explorerUrl: string | null;
1978
+ rpcs: Array<EthereumRpc> | null;
1979
+ substrateChain: {
1980
+ id: LegacyChainId;
1981
+ } | null;
1982
+ /**
1983
+ * indicates whether gasEstimates must be used as-is for txs to be valid
1984
+ *
1985
+ * PolkadotVM: https://contracts.polkadot.io/differences_to_eth
1986
+ * Acala: https://evmdocs.acala.network/network/gas-parameters
1987
+ */
1988
+ preserveGasEstimate?: boolean;
1989
+ feeType?: "legacy" | "eip-1559";
1990
+ l2FeeType?: {
1991
+ type: "op-stack";
1992
+ } | {
1993
+ type: "scroll";
1994
+ l1GasPriceOracle: `0x${string}`;
1995
+ };
1996
+ balancesConfig: Array<BalancesConfigLegacy$1>;
1997
+ /** @deprecated has its own store now */
1998
+ balancesMetadata: Array<BalancesMetadataLegacy$1>;
1999
+ erc20aggregator?: `0x${string}`;
2000
+ };
2001
+ /** @deprecated */
2002
+ type LegacyCustomEvmNetwork = LegacyEvmNetwork & {
2003
+ isCustom: true;
2004
+ explorerUrls: string[];
2005
+ iconUrls: string[];
2006
+ };
2007
+ type EthereumRpc = {
2008
+ url: string;
2009
+ };
2010
+ type BalancesConfigLegacy$1 = {
2011
+ moduleType: string;
2012
+ moduleConfig: unknown;
2013
+ };
2014
+ type BalancesMetadataLegacy$1 = {
2015
+ moduleType: string;
2016
+ metadata: unknown;
2017
+ };
2018
+
2019
+ /** @deprecated use NetworkId */
2020
+ type LegacyChainId = string;
2021
+ /** @deprecated use DotNetwork */
2022
+ type LegacyChain = {
2023
+ id: LegacyChainId;
2024
+ isTestnet: boolean;
2025
+ isDefault: boolean;
2026
+ /** @deprecated */
2027
+ sortIndex: number | null;
2028
+ genesisHash: `0x${string}` | null;
2029
+ prefix: number | null;
2030
+ oldPrefix?: number;
2031
+ name: string | null;
2032
+ themeColor: string | null;
2033
+ logo: string | null;
2034
+ chainName: string | null;
2035
+ chainType: "Development" | "Local" | "Live" | {
2036
+ Custom: string;
2037
+ } | string | null;
2038
+ implName: string | null;
2039
+ specName: string | null;
2040
+ specVersion: string | null;
2041
+ nativeToken: {
2042
+ id: TokenId;
2043
+ } | null;
2044
+ tokens: Array<{
2045
+ id: TokenId;
2046
+ }> | null;
2047
+ account: string | null;
2048
+ subscanUrl: string | null;
2049
+ blockExplorerUrls: string[] | null;
2050
+ chainspecQrUrl: string | null;
2051
+ latestMetadataQrUrl: string | null;
2052
+ isUnknownFeeToken: boolean;
2053
+ feeToken: string | null;
2054
+ rpcs: Array<SubstrateRpc> | null;
2055
+ evmNetworks: Array<{
2056
+ id: LegacyEvmNetworkId;
2057
+ }>;
2058
+ parathreads: Array<Pick<LegacyChain, "id" | "paraId" | "name">> | null;
2059
+ paraId: number | null;
2060
+ relay: Pick<LegacyChain, "id"> | null;
2061
+ balancesConfig: Array<BalancesConfigLegacy>;
2062
+ /** @deprecated has its own store now */
2063
+ balancesMetadata: Array<BalancesMetadataLegacy>;
2064
+ /** Indicates if the chain has the `CheckMetadataHash` extension, enabling signing with the ledger generic app */
2065
+ hasCheckMetadataHash?: boolean;
2066
+ /**
2067
+ * Some chains require a 1-byte prefix on transaction signatures to indicate the signing algo used:
2068
+ *
2069
+ * - Ed25519: `0x00`
2070
+ * - Sr25519: `0x01`
2071
+ * - Ecdsa: `0x02`
2072
+ * - Ethereum: `0x03`
2073
+ *
2074
+ * Polkadot.js tries to auto-detect whether to add this prefix or not,
2075
+ * as part of the `GenericExtrinsicPayload.sign` method:
2076
+ * - https://github.com/polkadot-js/api/blob/778d79a/packages/types/src/extrinsic/v4/ExtrinsicPayload.ts#L37-L39
2077
+ * - https://github.com/polkadot-js/api/blob/778d79a/packages/types/src/extrinsic/v4/ExtrinsicPayload.ts#L122-L129
2078
+ *
2079
+ * However, on some chains this auto-detection results in either a false-positive or false-negative.
2080
+ *
2081
+ * By leveraging the generic extrinsic sign function from `@polkadot/types/extrinsic/util`:
2082
+ * - https://github.com/polkadot-js/api/blob/778d79a/packages/types/src/extrinsic/util.ts#L9-L15
2083
+ *
2084
+ * We can specify whether or not to include the signature prefix, based on the value of this `hasExtrinsicSignatureTypePrefix` property.
2085
+ */
2086
+ hasExtrinsicSignatureTypePrefix?: boolean;
2087
+ /** Custom types to be registered in the TypeRegistry */
2088
+ signedExtensions?: any;
2089
+ /** Custom signed extensions to be registered in the Metadata object */
2090
+ registryTypes?: any;
2091
+ };
2092
+ /** @deprecated use CustomDotNetwork */
2093
+ type LegacyCustomChain = LegacyChain & {
2094
+ isCustom: true;
2095
+ };
2096
+ type SubstrateRpc = {
2097
+ url: string;
2098
+ };
2099
+ type BalancesConfigLegacy = {
2100
+ moduleType: string;
2101
+ moduleConfig: unknown;
2102
+ };
2103
+ type BalancesMetadataLegacy = {
2104
+ moduleType: string;
2105
+ metadata: unknown;
2106
+ };
2107
+
2108
+ declare class TalismanChaindataDatabase extends Dexie {
2109
+ chains: Dexie.Table<LegacyChain | LegacyCustomChain, LegacyChainId>;
2110
+ evmNetworks: Dexie.Table<LegacyEvmNetwork | LegacyCustomEvmNetwork, LegacyEvmNetworkId>;
2111
+ tokens: Dexie.Table<Token, TokenId>;
2112
+ constructor();
2113
+ }
2114
+ /** @deprecated */
2115
+ declare const getChaindataDbV3: () => TalismanChaindataDatabase;
2116
+
2117
+ declare const ChaindataFileSchema: z.ZodObject<{
2118
+ networks: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
2119
+ id: z.ZodString;
2120
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
2121
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2122
+ forceScan: z.ZodOptional<z.ZodBoolean>;
2123
+ name: z.ZodString;
2124
+ logo: z.ZodOptional<z.ZodString>;
2125
+ nativeTokenId: z.ZodString;
2126
+ nativeCurrency: z.ZodObject<{
2127
+ decimals: z.ZodUInt32;
2128
+ symbol: z.ZodString;
2129
+ name: z.ZodString;
2130
+ coingeckoId: z.ZodOptional<z.ZodString>;
2131
+ mirrorOf: z.ZodOptional<z.ZodString>;
2132
+ logo: z.ZodOptional<z.ZodString>;
2133
+ }, z.core.$strict>;
2134
+ themeColor: z.ZodOptional<z.ZodString>;
2135
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
2136
+ genesisHash: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2137
+ platform: z.ZodLiteral<"polkadot">;
2138
+ chainName: z.ZodString;
2139
+ specName: z.ZodString;
2140
+ specVersion: z.ZodUInt32;
2141
+ account: z.ZodEnum<{
2142
+ secp256k1: "secp256k1";
2143
+ "*25519": "*25519";
2144
+ }>;
2145
+ chainspecQrUrl: z.ZodOptional<z.ZodString>;
2146
+ latestMetadataQrUrl: z.ZodOptional<z.ZodString>;
2147
+ prefix: z.ZodNumber;
2148
+ oldPrefix: z.ZodOptional<z.ZodNumber>;
2149
+ rpcs: z.ZodArray<z.ZodURL>;
2150
+ registryTypes: z.ZodOptional<z.ZodAny>;
2151
+ signedExtensions: z.ZodOptional<z.ZodAny>;
2152
+ hasCheckMetadataHash: z.ZodOptional<z.ZodBoolean>;
2153
+ hasExtrinsicSignatureTypePrefix: z.ZodOptional<z.ZodBoolean>;
2154
+ isUnknownFeeToken: z.ZodOptional<z.ZodBoolean>;
2155
+ topology: z.ZodDiscriminatedUnion<[z.ZodObject<{
2156
+ type: z.ZodLiteral<"standalone">;
2157
+ }, z.core.$strict>, z.ZodObject<{
2158
+ type: z.ZodLiteral<"relay">;
2159
+ }, z.core.$strict>, z.ZodObject<{
2160
+ type: z.ZodLiteral<"parachain">;
2161
+ relayId: z.ZodString;
2162
+ paraId: z.ZodNumber;
2163
+ }, z.core.$strict>]>;
2164
+ balancesConfig: z.ZodOptional<z.ZodObject<{
2165
+ "substrate-native": z.ZodOptional<z.ZodObject<{
2166
+ disable: z.ZodOptional<z.ZodBoolean>;
2167
+ }, z.core.$strip>>;
2168
+ "substrate-assets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2169
+ "substrate-psp22": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2170
+ "substrate-tokens": z.ZodOptional<z.ZodObject<{
2171
+ palletId: z.ZodOptional<z.ZodString>;
2172
+ }, z.core.$strip>>;
2173
+ "substrate-foreignassets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2174
+ "substrate-hydration": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2175
+ "substrate-dtao": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2176
+ }, z.core.$strict>>;
2177
+ }, z.core.$strict>, z.ZodObject<{
2178
+ id: z.ZodString;
2179
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
2180
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2181
+ forceScan: z.ZodOptional<z.ZodBoolean>;
2182
+ name: z.ZodString;
2183
+ logo: z.ZodOptional<z.ZodString>;
2184
+ nativeTokenId: z.ZodString;
2185
+ nativeCurrency: z.ZodObject<{
2186
+ decimals: z.ZodUInt32;
2187
+ symbol: z.ZodString;
2188
+ name: z.ZodString;
2189
+ coingeckoId: z.ZodOptional<z.ZodString>;
2190
+ mirrorOf: z.ZodOptional<z.ZodString>;
2191
+ logo: z.ZodOptional<z.ZodString>;
2192
+ }, z.core.$strict>;
2193
+ themeColor: z.ZodOptional<z.ZodString>;
2194
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
2195
+ platform: z.ZodLiteral<"ethereum">;
2196
+ substrateChainId: z.ZodOptional<z.ZodString>;
2197
+ preserveGasEstimate: z.ZodOptional<z.ZodBoolean>;
2198
+ rpcs: z.ZodArray<z.ZodURL>;
2199
+ feeType: z.ZodOptional<z.ZodEnum<{
2200
+ legacy: "legacy";
2201
+ "eip-1559": "eip-1559";
2202
+ }>>;
2203
+ l2FeeType: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
2204
+ type: z.ZodLiteral<"op-stack">;
2205
+ }, z.core.$strict>, z.ZodObject<{
2206
+ type: z.ZodLiteral<"scroll">;
2207
+ l1GasPriceOracle: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2208
+ }, z.core.$strict>]>>;
2209
+ contracts: z.ZodOptional<z.ZodObject<{
2210
+ Erc20Aggregator: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
2211
+ Multicall3: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
2212
+ }, z.core.$strict>>;
2213
+ balancesConfig: z.ZodOptional<z.ZodObject<{
2214
+ "evm-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2215
+ "evm-erc20": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2216
+ "evm-uniswapv2": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2217
+ }, z.core.$strict>>;
2218
+ }, z.core.$strict>, z.ZodObject<{
2219
+ id: z.ZodString;
2220
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
2221
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2222
+ forceScan: z.ZodOptional<z.ZodBoolean>;
2223
+ name: z.ZodString;
2224
+ logo: z.ZodOptional<z.ZodString>;
2225
+ nativeTokenId: z.ZodString;
2226
+ nativeCurrency: z.ZodObject<{
2227
+ decimals: z.ZodUInt32;
2228
+ symbol: z.ZodString;
2229
+ name: z.ZodString;
2230
+ coingeckoId: z.ZodOptional<z.ZodString>;
2231
+ mirrorOf: z.ZodOptional<z.ZodString>;
2232
+ logo: z.ZodOptional<z.ZodString>;
2233
+ }, z.core.$strict>;
2234
+ themeColor: z.ZodOptional<z.ZodString>;
2235
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
2236
+ platform: z.ZodLiteral<"solana">;
2237
+ genesisHash: z.ZodString;
2238
+ rpcs: z.ZodArray<z.ZodURL>;
2239
+ balancesConfig: z.ZodOptional<z.ZodObject<{
2240
+ "sol-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2241
+ "sol-spl": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2242
+ }, z.core.$strict>>;
2243
+ }, z.core.$strict>]>>;
2244
+ tokens: z.ZodArray<z.ZodPipe<z.ZodDiscriminatedUnion<[z.ZodObject<{
2245
+ id: z.ZodString;
2246
+ networkId: z.ZodString;
2247
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2248
+ decimals: z.ZodInt;
2249
+ symbol: z.ZodString;
2250
+ name: z.ZodOptional<z.ZodString>;
2251
+ logo: z.ZodOptional<z.ZodString>;
2252
+ coingeckoId: z.ZodOptional<z.ZodString>;
2253
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2254
+ mirrorOf: z.ZodOptional<z.ZodString>;
2255
+ type: z.ZodLiteral<"evm-erc20">;
2256
+ platform: z.ZodLiteral<"ethereum">;
2257
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2258
+ }, z.core.$strict>, z.ZodObject<{
2259
+ id: z.ZodString;
2260
+ networkId: z.ZodString;
2261
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2262
+ decimals: z.ZodInt;
2263
+ symbol: z.ZodString;
2264
+ name: z.ZodOptional<z.ZodString>;
2265
+ logo: z.ZodOptional<z.ZodString>;
2266
+ coingeckoId: z.ZodOptional<z.ZodString>;
2267
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2268
+ mirrorOf: z.ZodOptional<z.ZodString>;
2269
+ type: z.ZodLiteral<"evm-native">;
2270
+ platform: z.ZodLiteral<"ethereum">;
2271
+ }, z.core.$strict>, z.ZodObject<{
2272
+ id: z.ZodString;
2273
+ networkId: z.ZodString;
2274
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2275
+ decimals: z.ZodInt;
2276
+ symbol: z.ZodString;
2277
+ name: z.ZodOptional<z.ZodString>;
2278
+ logo: z.ZodOptional<z.ZodString>;
2279
+ coingeckoId: z.ZodOptional<z.ZodString>;
2280
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2281
+ mirrorOf: z.ZodOptional<z.ZodString>;
2282
+ type: z.ZodLiteral<"evm-uniswapv2">;
2283
+ platform: z.ZodLiteral<"ethereum">;
2284
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2285
+ isCustom: z.ZodOptional<z.ZodBoolean>;
2286
+ symbol0: z.ZodString;
2287
+ symbol1: z.ZodString;
2288
+ decimals0: z.ZodInt;
2289
+ decimals1: z.ZodInt;
2290
+ tokenAddress0: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2291
+ tokenAddress1: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2292
+ coingeckoId0: z.ZodOptional<z.ZodString>;
2293
+ coingeckoId1: z.ZodOptional<z.ZodString>;
2294
+ }, z.core.$strict>, z.ZodObject<{
2295
+ id: z.ZodString;
2296
+ networkId: z.ZodString;
2297
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2298
+ decimals: z.ZodInt;
2299
+ symbol: z.ZodString;
2300
+ name: z.ZodOptional<z.ZodString>;
2301
+ logo: z.ZodOptional<z.ZodString>;
2302
+ coingeckoId: z.ZodOptional<z.ZodString>;
2303
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2304
+ mirrorOf: z.ZodOptional<z.ZodString>;
2305
+ type: z.ZodLiteral<"substrate-assets">;
2306
+ platform: z.ZodLiteral<"polkadot">;
2307
+ assetId: z.ZodPipe<z.ZodUnion<readonly [z.ZodUInt32, z.ZodString]>, z.ZodTransform<string, string | number>>;
2308
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
2309
+ isSufficient: z.ZodBoolean;
2310
+ existentialDeposit: z.ZodString;
2311
+ }, z.core.$strict>, z.ZodObject<{
2312
+ id: z.ZodString;
2313
+ networkId: z.ZodString;
2314
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2315
+ decimals: z.ZodInt;
2316
+ symbol: z.ZodString;
2317
+ name: z.ZodOptional<z.ZodString>;
2318
+ logo: z.ZodOptional<z.ZodString>;
2319
+ coingeckoId: z.ZodOptional<z.ZodString>;
2320
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2321
+ mirrorOf: z.ZodOptional<z.ZodString>;
2322
+ type: z.ZodLiteral<"substrate-dtao">;
2323
+ platform: z.ZodLiteral<"polkadot">;
2324
+ netuid: z.ZodNumber;
2325
+ subnetName: z.ZodOptional<z.ZodString>;
2326
+ hotkey: z.ZodOptional<z.ZodString>;
2327
+ isTransferable: z.ZodDefault<z.ZodBoolean>;
2328
+ }, z.core.$strict>, z.ZodObject<{
2329
+ id: z.ZodString;
2330
+ networkId: z.ZodString;
2331
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2332
+ decimals: z.ZodInt;
2333
+ symbol: z.ZodString;
2334
+ name: z.ZodOptional<z.ZodString>;
2335
+ logo: z.ZodOptional<z.ZodString>;
2336
+ coingeckoId: z.ZodOptional<z.ZodString>;
2337
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2338
+ mirrorOf: z.ZodOptional<z.ZodString>;
2339
+ type: z.ZodLiteral<"substrate-foreignassets">;
2340
+ platform: z.ZodLiteral<"polkadot">;
2341
+ onChainId: z.ZodString;
2342
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
2343
+ isSufficient: z.ZodBoolean;
2344
+ existentialDeposit: z.ZodString;
2345
+ }, z.core.$strict>, z.ZodObject<{
2346
+ id: z.ZodString;
2347
+ networkId: z.ZodString;
2348
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2349
+ decimals: z.ZodInt;
2350
+ symbol: z.ZodString;
2351
+ name: z.ZodOptional<z.ZodString>;
2352
+ logo: z.ZodOptional<z.ZodString>;
2353
+ coingeckoId: z.ZodOptional<z.ZodString>;
2354
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2355
+ mirrorOf: z.ZodOptional<z.ZodString>;
2356
+ type: z.ZodLiteral<"substrate-native">;
2357
+ platform: z.ZodLiteral<"polkadot">;
2358
+ existentialDeposit: z.ZodString;
2359
+ }, z.core.$strict>, z.ZodObject<{
2360
+ id: z.ZodString;
2361
+ networkId: z.ZodString;
2362
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2363
+ decimals: z.ZodInt;
2364
+ symbol: z.ZodString;
2365
+ name: z.ZodOptional<z.ZodString>;
2366
+ logo: z.ZodOptional<z.ZodString>;
2367
+ coingeckoId: z.ZodOptional<z.ZodString>;
2368
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2369
+ mirrorOf: z.ZodOptional<z.ZodString>;
2370
+ type: z.ZodLiteral<"substrate-psp22">;
2371
+ platform: z.ZodLiteral<"polkadot">;
2372
+ contractAddress: z.ZodString;
2373
+ }, z.core.$strict>, z.ZodObject<{
2374
+ id: z.ZodString;
2375
+ networkId: z.ZodString;
2376
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2377
+ decimals: z.ZodInt;
2378
+ symbol: z.ZodString;
2379
+ name: z.ZodOptional<z.ZodString>;
2380
+ logo: z.ZodOptional<z.ZodString>;
2381
+ coingeckoId: z.ZodOptional<z.ZodString>;
2382
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2383
+ mirrorOf: z.ZodOptional<z.ZodString>;
2384
+ type: z.ZodLiteral<"substrate-tokens">;
2385
+ platform: z.ZodLiteral<"polkadot">;
2386
+ onChainId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
2387
+ existentialDeposit: z.ZodString;
2388
+ }, z.core.$strict>, z.ZodObject<{
2389
+ id: z.ZodString;
2390
+ networkId: z.ZodString;
2391
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2392
+ decimals: z.ZodInt;
2393
+ symbol: z.ZodString;
2394
+ name: z.ZodOptional<z.ZodString>;
2395
+ logo: z.ZodOptional<z.ZodString>;
2396
+ coingeckoId: z.ZodOptional<z.ZodString>;
2397
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2398
+ mirrorOf: z.ZodOptional<z.ZodString>;
2399
+ type: z.ZodLiteral<"substrate-hydration">;
2400
+ platform: z.ZodLiteral<"polkadot">;
2401
+ onChainId: z.ZodUInt32;
2402
+ assetType: z.ZodEnum<{
2403
+ Token: "Token";
2404
+ Erc20: "Erc20";
2405
+ External: "External";
2406
+ }>;
2407
+ isSufficient: z.ZodBoolean;
2408
+ existentialDeposit: z.ZodString;
2409
+ }, z.core.$strict>, z.ZodObject<{
2410
+ id: z.ZodString;
2411
+ networkId: z.ZodString;
2412
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2413
+ decimals: z.ZodInt;
2414
+ symbol: z.ZodString;
2415
+ name: z.ZodOptional<z.ZodString>;
2416
+ logo: z.ZodOptional<z.ZodString>;
2417
+ coingeckoId: z.ZodOptional<z.ZodString>;
2418
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2419
+ mirrorOf: z.ZodOptional<z.ZodString>;
2420
+ type: z.ZodLiteral<"sol-native">;
2421
+ platform: z.ZodLiteral<"solana">;
2422
+ }, z.core.$strict>, z.ZodObject<{
2423
+ id: z.ZodString;
2424
+ networkId: z.ZodString;
2425
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2426
+ decimals: z.ZodInt;
2427
+ symbol: z.ZodString;
2428
+ name: z.ZodOptional<z.ZodString>;
2429
+ logo: z.ZodOptional<z.ZodString>;
2430
+ coingeckoId: z.ZodOptional<z.ZodString>;
2431
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2432
+ mirrorOf: z.ZodOptional<z.ZodString>;
2433
+ type: z.ZodLiteral<"sol-spl">;
2434
+ platform: z.ZodLiteral<"solana">;
2435
+ mintAddress: z.ZodString;
2436
+ }, z.core.$strict>]>, z.ZodTransform<{
2437
+ id: string;
2438
+ networkId: string;
2439
+ decimals: number;
2440
+ symbol: string;
2441
+ type: "evm-native";
2442
+ platform: "ethereum";
2443
+ isDefault?: boolean | undefined;
2444
+ name?: string | undefined;
2445
+ logo?: string | undefined;
2446
+ coingeckoId?: string | undefined;
2447
+ noDiscovery?: boolean | undefined;
2448
+ mirrorOf?: string | undefined;
2449
+ } | {
2450
+ id: string;
2451
+ networkId: string;
2452
+ decimals: number;
2453
+ symbol: string;
2454
+ type: "evm-erc20";
2455
+ platform: "ethereum";
2456
+ contractAddress: `0x${string}`;
2457
+ isDefault?: boolean | undefined;
2458
+ name?: string | undefined;
2459
+ logo?: string | undefined;
2460
+ coingeckoId?: string | undefined;
2461
+ noDiscovery?: boolean | undefined;
2462
+ mirrorOf?: string | undefined;
2463
+ } | {
2464
+ id: string;
2465
+ networkId: string;
2466
+ decimals: number;
2467
+ symbol: string;
2468
+ type: "evm-uniswapv2";
2469
+ platform: "ethereum";
2470
+ contractAddress: `0x${string}`;
2471
+ symbol0: string;
2472
+ symbol1: string;
2473
+ decimals0: number;
2474
+ decimals1: number;
2475
+ tokenAddress0: `0x${string}`;
2476
+ tokenAddress1: `0x${string}`;
2477
+ isDefault?: boolean | undefined;
2478
+ name?: string | undefined;
2479
+ logo?: string | undefined;
2480
+ coingeckoId?: string | undefined;
2481
+ noDiscovery?: boolean | undefined;
2482
+ mirrorOf?: string | undefined;
2483
+ isCustom?: boolean | undefined;
2484
+ coingeckoId0?: string | undefined;
2485
+ coingeckoId1?: string | undefined;
2486
+ } | {
2487
+ id: string;
2488
+ networkId: string;
2489
+ decimals: number;
2490
+ symbol: string;
2491
+ type: "substrate-assets";
2492
+ platform: "polkadot";
2493
+ assetId: string;
2494
+ isSufficient: boolean;
2495
+ existentialDeposit: string;
2496
+ isDefault?: boolean | undefined;
2497
+ name?: string | undefined;
2498
+ logo?: string | undefined;
2499
+ coingeckoId?: string | undefined;
2500
+ noDiscovery?: boolean | undefined;
2501
+ mirrorOf?: string | undefined;
2502
+ isFrozen?: boolean | undefined;
2503
+ } | {
2504
+ id: string;
2505
+ networkId: string;
2506
+ decimals: number;
2507
+ symbol: string;
2508
+ type: "substrate-dtao";
2509
+ platform: "polkadot";
2510
+ netuid: number;
2511
+ isTransferable: boolean;
2512
+ isDefault?: boolean | undefined;
2513
+ name?: string | undefined;
2514
+ logo?: string | undefined;
2515
+ coingeckoId?: string | undefined;
2516
+ noDiscovery?: boolean | undefined;
2517
+ mirrorOf?: string | undefined;
2518
+ subnetName?: string | undefined;
2519
+ hotkey?: string | undefined;
2520
+ } | {
2521
+ id: string;
2522
+ networkId: string;
2523
+ decimals: number;
2524
+ symbol: string;
2525
+ type: "substrate-foreignassets";
2526
+ platform: "polkadot";
2527
+ onChainId: string;
2528
+ isSufficient: boolean;
2529
+ existentialDeposit: string;
2530
+ isDefault?: boolean | undefined;
2531
+ name?: string | undefined;
2532
+ logo?: string | undefined;
2533
+ coingeckoId?: string | undefined;
2534
+ noDiscovery?: boolean | undefined;
2535
+ mirrorOf?: string | undefined;
2536
+ isFrozen?: boolean | undefined;
2537
+ } | {
2538
+ id: string;
2539
+ networkId: string;
2540
+ decimals: number;
2541
+ symbol: string;
2542
+ type: "substrate-native";
2543
+ platform: "polkadot";
2544
+ existentialDeposit: string;
2545
+ isDefault?: boolean | undefined;
2546
+ name?: string | undefined;
2547
+ logo?: string | undefined;
2548
+ coingeckoId?: string | undefined;
2549
+ noDiscovery?: boolean | undefined;
2550
+ mirrorOf?: string | undefined;
2551
+ } | {
2552
+ id: string;
2553
+ networkId: string;
2554
+ decimals: number;
2555
+ symbol: string;
2556
+ type: "substrate-psp22";
2557
+ platform: "polkadot";
2558
+ contractAddress: string;
2559
+ isDefault?: boolean | undefined;
2560
+ name?: string | undefined;
2561
+ logo?: string | undefined;
2562
+ coingeckoId?: string | undefined;
2563
+ noDiscovery?: boolean | undefined;
2564
+ mirrorOf?: string | undefined;
2565
+ } | {
2566
+ id: string;
2567
+ networkId: string;
2568
+ decimals: number;
2569
+ symbol: string;
2570
+ type: "substrate-tokens";
2571
+ platform: "polkadot";
2572
+ onChainId: string | number;
2573
+ existentialDeposit: string;
2574
+ isDefault?: boolean | undefined;
2575
+ name?: string | undefined;
2576
+ logo?: string | undefined;
2577
+ coingeckoId?: string | undefined;
2578
+ noDiscovery?: boolean | undefined;
2579
+ mirrorOf?: string | undefined;
2580
+ } | {
2581
+ id: string;
2582
+ networkId: string;
2583
+ decimals: number;
2584
+ symbol: string;
2585
+ type: "substrate-hydration";
2586
+ platform: "polkadot";
2587
+ onChainId: number;
2588
+ assetType: "Token" | "Erc20" | "External";
2589
+ isSufficient: boolean;
2590
+ existentialDeposit: string;
2591
+ isDefault?: boolean | undefined;
2592
+ name?: string | undefined;
2593
+ logo?: string | undefined;
2594
+ coingeckoId?: string | undefined;
2595
+ noDiscovery?: boolean | undefined;
2596
+ mirrorOf?: string | undefined;
2597
+ } | {
2598
+ id: string;
2599
+ networkId: string;
2600
+ decimals: number;
2601
+ symbol: string;
2602
+ type: "sol-native";
2603
+ platform: "solana";
2604
+ isDefault?: boolean | undefined;
2605
+ name?: string | undefined;
2606
+ logo?: string | undefined;
2607
+ coingeckoId?: string | undefined;
2608
+ noDiscovery?: boolean | undefined;
2609
+ mirrorOf?: string | undefined;
2610
+ } | {
2611
+ id: string;
2612
+ networkId: string;
2613
+ decimals: number;
2614
+ symbol: string;
2615
+ type: "sol-spl";
2616
+ platform: "solana";
2617
+ mintAddress: string;
2618
+ isDefault?: boolean | undefined;
2619
+ name?: string | undefined;
2620
+ logo?: string | undefined;
2621
+ coingeckoId?: string | undefined;
2622
+ noDiscovery?: boolean | undefined;
2623
+ mirrorOf?: string | undefined;
2624
+ }, {
2625
+ id: string;
2626
+ networkId: string;
2627
+ decimals: number;
2628
+ symbol: string;
2629
+ type: "evm-native";
2630
+ platform: "ethereum";
2631
+ isDefault?: boolean | undefined;
2632
+ name?: string | undefined;
2633
+ logo?: string | undefined;
2634
+ coingeckoId?: string | undefined;
2635
+ noDiscovery?: boolean | undefined;
2636
+ mirrorOf?: string | undefined;
2637
+ } | {
2638
+ id: string;
2639
+ networkId: string;
2640
+ decimals: number;
2641
+ symbol: string;
2642
+ type: "evm-erc20";
2643
+ platform: "ethereum";
2644
+ contractAddress: `0x${string}`;
2645
+ isDefault?: boolean | undefined;
2646
+ name?: string | undefined;
2647
+ logo?: string | undefined;
2648
+ coingeckoId?: string | undefined;
2649
+ noDiscovery?: boolean | undefined;
2650
+ mirrorOf?: string | undefined;
2651
+ } | {
2652
+ id: string;
2653
+ networkId: string;
2654
+ decimals: number;
2655
+ symbol: string;
2656
+ type: "evm-uniswapv2";
2657
+ platform: "ethereum";
2658
+ contractAddress: `0x${string}`;
2659
+ symbol0: string;
2660
+ symbol1: string;
2661
+ decimals0: number;
2662
+ decimals1: number;
2663
+ tokenAddress0: `0x${string}`;
2664
+ tokenAddress1: `0x${string}`;
2665
+ isDefault?: boolean | undefined;
2666
+ name?: string | undefined;
2667
+ logo?: string | undefined;
2668
+ coingeckoId?: string | undefined;
2669
+ noDiscovery?: boolean | undefined;
2670
+ mirrorOf?: string | undefined;
2671
+ isCustom?: boolean | undefined;
2672
+ coingeckoId0?: string | undefined;
2673
+ coingeckoId1?: string | undefined;
2674
+ } | {
2675
+ id: string;
2676
+ networkId: string;
2677
+ decimals: number;
2678
+ symbol: string;
2679
+ type: "substrate-assets";
2680
+ platform: "polkadot";
2681
+ assetId: string;
2682
+ isSufficient: boolean;
2683
+ existentialDeposit: string;
2684
+ isDefault?: boolean | undefined;
2685
+ name?: string | undefined;
2686
+ logo?: string | undefined;
2687
+ coingeckoId?: string | undefined;
2688
+ noDiscovery?: boolean | undefined;
2689
+ mirrorOf?: string | undefined;
2690
+ isFrozen?: boolean | undefined;
2691
+ } | {
2692
+ id: string;
2693
+ networkId: string;
2694
+ decimals: number;
2695
+ symbol: string;
2696
+ type: "substrate-dtao";
2697
+ platform: "polkadot";
2698
+ netuid: number;
2699
+ isTransferable: boolean;
2700
+ isDefault?: boolean | undefined;
2701
+ name?: string | undefined;
2702
+ logo?: string | undefined;
2703
+ coingeckoId?: string | undefined;
2704
+ noDiscovery?: boolean | undefined;
2705
+ mirrorOf?: string | undefined;
2706
+ subnetName?: string | undefined;
2707
+ hotkey?: string | undefined;
2708
+ } | {
2709
+ id: string;
2710
+ networkId: string;
2711
+ decimals: number;
2712
+ symbol: string;
2713
+ type: "substrate-foreignassets";
2714
+ platform: "polkadot";
2715
+ onChainId: string;
2716
+ isSufficient: boolean;
2717
+ existentialDeposit: string;
2718
+ isDefault?: boolean | undefined;
2719
+ name?: string | undefined;
2720
+ logo?: string | undefined;
2721
+ coingeckoId?: string | undefined;
2722
+ noDiscovery?: boolean | undefined;
2723
+ mirrorOf?: string | undefined;
2724
+ isFrozen?: boolean | undefined;
2725
+ } | {
2726
+ id: string;
2727
+ networkId: string;
2728
+ decimals: number;
2729
+ symbol: string;
2730
+ type: "substrate-native";
2731
+ platform: "polkadot";
2732
+ existentialDeposit: string;
2733
+ isDefault?: boolean | undefined;
2734
+ name?: string | undefined;
2735
+ logo?: string | undefined;
2736
+ coingeckoId?: string | undefined;
2737
+ noDiscovery?: boolean | undefined;
2738
+ mirrorOf?: string | undefined;
2739
+ } | {
2740
+ id: string;
2741
+ networkId: string;
2742
+ decimals: number;
2743
+ symbol: string;
2744
+ type: "substrate-psp22";
2745
+ platform: "polkadot";
2746
+ contractAddress: string;
2747
+ isDefault?: boolean | undefined;
2748
+ name?: string | undefined;
2749
+ logo?: string | undefined;
2750
+ coingeckoId?: string | undefined;
2751
+ noDiscovery?: boolean | undefined;
2752
+ mirrorOf?: string | undefined;
2753
+ } | {
2754
+ id: string;
2755
+ networkId: string;
2756
+ decimals: number;
2757
+ symbol: string;
2758
+ type: "substrate-tokens";
2759
+ platform: "polkadot";
2760
+ onChainId: string | number;
2761
+ existentialDeposit: string;
2762
+ isDefault?: boolean | undefined;
2763
+ name?: string | undefined;
2764
+ logo?: string | undefined;
2765
+ coingeckoId?: string | undefined;
2766
+ noDiscovery?: boolean | undefined;
2767
+ mirrorOf?: string | undefined;
2768
+ } | {
2769
+ id: string;
2770
+ networkId: string;
2771
+ decimals: number;
2772
+ symbol: string;
2773
+ type: "substrate-hydration";
2774
+ platform: "polkadot";
2775
+ onChainId: number;
2776
+ assetType: "Token" | "Erc20" | "External";
2777
+ isSufficient: boolean;
2778
+ existentialDeposit: string;
2779
+ isDefault?: boolean | undefined;
2780
+ name?: string | undefined;
2781
+ logo?: string | undefined;
2782
+ coingeckoId?: string | undefined;
2783
+ noDiscovery?: boolean | undefined;
2784
+ mirrorOf?: string | undefined;
2785
+ } | {
2786
+ id: string;
2787
+ networkId: string;
2788
+ decimals: number;
2789
+ symbol: string;
2790
+ type: "sol-native";
2791
+ platform: "solana";
2792
+ isDefault?: boolean | undefined;
2793
+ name?: string | undefined;
2794
+ logo?: string | undefined;
2795
+ coingeckoId?: string | undefined;
2796
+ noDiscovery?: boolean | undefined;
2797
+ mirrorOf?: string | undefined;
2798
+ } | {
2799
+ id: string;
2800
+ networkId: string;
2801
+ decimals: number;
2802
+ symbol: string;
2803
+ type: "sol-spl";
2804
+ platform: "solana";
2805
+ mintAddress: string;
2806
+ isDefault?: boolean | undefined;
2807
+ name?: string | undefined;
2808
+ logo?: string | undefined;
2809
+ coingeckoId?: string | undefined;
2810
+ noDiscovery?: boolean | undefined;
2811
+ mirrorOf?: string | undefined;
2812
+ }>>>;
2813
+ miniMetadatas: z.ZodArray<z.ZodObject<{
2814
+ id: z.ZodString;
2815
+ source: z.ZodString;
2816
+ chainId: z.ZodString;
2817
+ specVersion: z.ZodUInt32;
2818
+ version: z.ZodString;
2819
+ data: z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
2820
+ extra: z.ZodNullable<z.ZodAny>;
2821
+ }, z.core.$strict>>;
2822
+ }, z.core.$strip>;
2823
+ type Chaindata = z.infer<typeof ChaindataFileSchema>;
2824
+ declare const CustomChaindataSchema: z.ZodObject<{
2825
+ networks: z.ZodOptional<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
2826
+ id: z.ZodString;
2827
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
2828
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2829
+ forceScan: z.ZodOptional<z.ZodBoolean>;
2830
+ name: z.ZodString;
2831
+ logo: z.ZodOptional<z.ZodString>;
2832
+ nativeTokenId: z.ZodString;
2833
+ nativeCurrency: z.ZodObject<{
2834
+ decimals: z.ZodUInt32;
2835
+ symbol: z.ZodString;
2836
+ name: z.ZodString;
2837
+ coingeckoId: z.ZodOptional<z.ZodString>;
2838
+ mirrorOf: z.ZodOptional<z.ZodString>;
2839
+ logo: z.ZodOptional<z.ZodString>;
2840
+ }, z.core.$strict>;
2841
+ themeColor: z.ZodOptional<z.ZodString>;
2842
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
2843
+ genesisHash: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2844
+ platform: z.ZodLiteral<"polkadot">;
2845
+ chainName: z.ZodString;
2846
+ specName: z.ZodString;
2847
+ specVersion: z.ZodUInt32;
2848
+ account: z.ZodEnum<{
2849
+ secp256k1: "secp256k1";
2850
+ "*25519": "*25519";
2851
+ }>;
2852
+ chainspecQrUrl: z.ZodOptional<z.ZodString>;
2853
+ latestMetadataQrUrl: z.ZodOptional<z.ZodString>;
2854
+ prefix: z.ZodNumber;
2855
+ oldPrefix: z.ZodOptional<z.ZodNumber>;
2856
+ rpcs: z.ZodArray<z.ZodURL>;
2857
+ registryTypes: z.ZodOptional<z.ZodAny>;
2858
+ signedExtensions: z.ZodOptional<z.ZodAny>;
2859
+ hasCheckMetadataHash: z.ZodOptional<z.ZodBoolean>;
2860
+ hasExtrinsicSignatureTypePrefix: z.ZodOptional<z.ZodBoolean>;
2861
+ isUnknownFeeToken: z.ZodOptional<z.ZodBoolean>;
2862
+ topology: z.ZodDiscriminatedUnion<[z.ZodObject<{
2863
+ type: z.ZodLiteral<"standalone">;
2864
+ }, z.core.$strict>, z.ZodObject<{
2865
+ type: z.ZodLiteral<"relay">;
2866
+ }, z.core.$strict>, z.ZodObject<{
2867
+ type: z.ZodLiteral<"parachain">;
2868
+ relayId: z.ZodString;
2869
+ paraId: z.ZodNumber;
2870
+ }, z.core.$strict>]>;
2871
+ balancesConfig: z.ZodOptional<z.ZodObject<{
2872
+ "substrate-native": z.ZodOptional<z.ZodObject<{
2873
+ disable: z.ZodOptional<z.ZodBoolean>;
2874
+ }, z.core.$strip>>;
2875
+ "substrate-assets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2876
+ "substrate-psp22": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2877
+ "substrate-tokens": z.ZodOptional<z.ZodObject<{
2878
+ palletId: z.ZodOptional<z.ZodString>;
2879
+ }, z.core.$strip>>;
2880
+ "substrate-foreignassets": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2881
+ "substrate-hydration": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2882
+ "substrate-dtao": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2883
+ }, z.core.$strict>>;
2884
+ }, z.core.$strict>, z.ZodObject<{
2885
+ id: z.ZodString;
2886
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
2887
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2888
+ forceScan: z.ZodOptional<z.ZodBoolean>;
2889
+ name: z.ZodString;
2890
+ logo: z.ZodOptional<z.ZodString>;
2891
+ nativeTokenId: z.ZodString;
2892
+ nativeCurrency: z.ZodObject<{
2893
+ decimals: z.ZodUInt32;
2894
+ symbol: z.ZodString;
2895
+ name: z.ZodString;
2896
+ coingeckoId: z.ZodOptional<z.ZodString>;
2897
+ mirrorOf: z.ZodOptional<z.ZodString>;
2898
+ logo: z.ZodOptional<z.ZodString>;
2899
+ }, z.core.$strict>;
2900
+ themeColor: z.ZodOptional<z.ZodString>;
2901
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
2902
+ platform: z.ZodLiteral<"ethereum">;
2903
+ substrateChainId: z.ZodOptional<z.ZodString>;
2904
+ preserveGasEstimate: z.ZodOptional<z.ZodBoolean>;
2905
+ rpcs: z.ZodArray<z.ZodURL>;
2906
+ feeType: z.ZodOptional<z.ZodEnum<{
2907
+ legacy: "legacy";
2908
+ "eip-1559": "eip-1559";
2909
+ }>>;
2910
+ l2FeeType: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
2911
+ type: z.ZodLiteral<"op-stack">;
2912
+ }, z.core.$strict>, z.ZodObject<{
2913
+ type: z.ZodLiteral<"scroll">;
2914
+ l1GasPriceOracle: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2915
+ }, z.core.$strict>]>>;
2916
+ contracts: z.ZodOptional<z.ZodObject<{
2917
+ Erc20Aggregator: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
2918
+ Multicall3: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>>;
2919
+ }, z.core.$strict>>;
2920
+ balancesConfig: z.ZodOptional<z.ZodObject<{
2921
+ "evm-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2922
+ "evm-erc20": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2923
+ "evm-uniswapv2": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2924
+ }, z.core.$strict>>;
2925
+ }, z.core.$strict>, z.ZodObject<{
2926
+ id: z.ZodString;
2927
+ isTestnet: z.ZodOptional<z.ZodBoolean>;
2928
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2929
+ forceScan: z.ZodOptional<z.ZodBoolean>;
2930
+ name: z.ZodString;
2931
+ logo: z.ZodOptional<z.ZodString>;
2932
+ nativeTokenId: z.ZodString;
2933
+ nativeCurrency: z.ZodObject<{
2934
+ decimals: z.ZodUInt32;
2935
+ symbol: z.ZodString;
2936
+ name: z.ZodString;
2937
+ coingeckoId: z.ZodOptional<z.ZodString>;
2938
+ mirrorOf: z.ZodOptional<z.ZodString>;
2939
+ logo: z.ZodOptional<z.ZodString>;
2940
+ }, z.core.$strict>;
2941
+ themeColor: z.ZodOptional<z.ZodString>;
2942
+ blockExplorerUrls: z.ZodDefault<z.ZodArray<z.ZodURL>>;
2943
+ platform: z.ZodLiteral<"solana">;
2944
+ genesisHash: z.ZodString;
2945
+ rpcs: z.ZodArray<z.ZodURL>;
2946
+ balancesConfig: z.ZodOptional<z.ZodObject<{
2947
+ "sol-native": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2948
+ "sol-spl": z.ZodOptional<z.ZodObject<{}, z.core.$strict>>;
2949
+ }, z.core.$strict>>;
2950
+ }, z.core.$strict>]>>>;
2951
+ tokens: z.ZodArray<z.ZodPipe<z.ZodDiscriminatedUnion<[z.ZodObject<{
2952
+ id: z.ZodString;
2953
+ networkId: z.ZodString;
2954
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2955
+ decimals: z.ZodInt;
2956
+ symbol: z.ZodString;
2957
+ name: z.ZodOptional<z.ZodString>;
2958
+ logo: z.ZodOptional<z.ZodString>;
2959
+ coingeckoId: z.ZodOptional<z.ZodString>;
2960
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2961
+ mirrorOf: z.ZodOptional<z.ZodString>;
2962
+ type: z.ZodLiteral<"evm-erc20">;
2963
+ platform: z.ZodLiteral<"ethereum">;
2964
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2965
+ }, z.core.$strict>, z.ZodObject<{
2966
+ id: z.ZodString;
2967
+ networkId: z.ZodString;
2968
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2969
+ decimals: z.ZodInt;
2970
+ symbol: z.ZodString;
2971
+ name: z.ZodOptional<z.ZodString>;
2972
+ logo: z.ZodOptional<z.ZodString>;
2973
+ coingeckoId: z.ZodOptional<z.ZodString>;
2974
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2975
+ mirrorOf: z.ZodOptional<z.ZodString>;
2976
+ type: z.ZodLiteral<"evm-native">;
2977
+ platform: z.ZodLiteral<"ethereum">;
2978
+ }, z.core.$strict>, z.ZodObject<{
2979
+ id: z.ZodString;
2980
+ networkId: z.ZodString;
2981
+ isDefault: z.ZodOptional<z.ZodBoolean>;
2982
+ decimals: z.ZodInt;
2983
+ symbol: z.ZodString;
2984
+ name: z.ZodOptional<z.ZodString>;
2985
+ logo: z.ZodOptional<z.ZodString>;
2986
+ coingeckoId: z.ZodOptional<z.ZodString>;
2987
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
2988
+ mirrorOf: z.ZodOptional<z.ZodString>;
2989
+ type: z.ZodLiteral<"evm-uniswapv2">;
2990
+ platform: z.ZodLiteral<"ethereum">;
2991
+ contractAddress: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2992
+ isCustom: z.ZodOptional<z.ZodBoolean>;
2993
+ symbol0: z.ZodString;
2994
+ symbol1: z.ZodString;
2995
+ decimals0: z.ZodInt;
2996
+ decimals1: z.ZodInt;
2997
+ tokenAddress0: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2998
+ tokenAddress1: z.ZodPipe<z.ZodString, z.ZodTransform<`0x${string}`, string>>;
2999
+ coingeckoId0: z.ZodOptional<z.ZodString>;
3000
+ coingeckoId1: z.ZodOptional<z.ZodString>;
3001
+ }, z.core.$strict>, z.ZodObject<{
3002
+ id: z.ZodString;
3003
+ networkId: z.ZodString;
3004
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3005
+ decimals: z.ZodInt;
3006
+ symbol: z.ZodString;
3007
+ name: z.ZodOptional<z.ZodString>;
3008
+ logo: z.ZodOptional<z.ZodString>;
3009
+ coingeckoId: z.ZodOptional<z.ZodString>;
3010
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3011
+ mirrorOf: z.ZodOptional<z.ZodString>;
3012
+ type: z.ZodLiteral<"substrate-assets">;
3013
+ platform: z.ZodLiteral<"polkadot">;
3014
+ assetId: z.ZodPipe<z.ZodUnion<readonly [z.ZodUInt32, z.ZodString]>, z.ZodTransform<string, string | number>>;
3015
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
3016
+ isSufficient: z.ZodBoolean;
3017
+ existentialDeposit: z.ZodString;
3018
+ }, z.core.$strict>, z.ZodObject<{
3019
+ id: z.ZodString;
3020
+ networkId: z.ZodString;
3021
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3022
+ decimals: z.ZodInt;
3023
+ symbol: z.ZodString;
3024
+ name: z.ZodOptional<z.ZodString>;
3025
+ logo: z.ZodOptional<z.ZodString>;
3026
+ coingeckoId: z.ZodOptional<z.ZodString>;
3027
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3028
+ mirrorOf: z.ZodOptional<z.ZodString>;
3029
+ type: z.ZodLiteral<"substrate-dtao">;
3030
+ platform: z.ZodLiteral<"polkadot">;
3031
+ netuid: z.ZodNumber;
3032
+ subnetName: z.ZodOptional<z.ZodString>;
3033
+ hotkey: z.ZodOptional<z.ZodString>;
3034
+ isTransferable: z.ZodDefault<z.ZodBoolean>;
3035
+ }, z.core.$strict>, z.ZodObject<{
3036
+ id: z.ZodString;
3037
+ networkId: z.ZodString;
3038
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3039
+ decimals: z.ZodInt;
3040
+ symbol: z.ZodString;
3041
+ name: z.ZodOptional<z.ZodString>;
3042
+ logo: z.ZodOptional<z.ZodString>;
3043
+ coingeckoId: z.ZodOptional<z.ZodString>;
3044
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3045
+ mirrorOf: z.ZodOptional<z.ZodString>;
3046
+ type: z.ZodLiteral<"substrate-foreignassets">;
3047
+ platform: z.ZodLiteral<"polkadot">;
3048
+ onChainId: z.ZodString;
3049
+ isFrozen: z.ZodOptional<z.ZodBoolean>;
3050
+ isSufficient: z.ZodBoolean;
3051
+ existentialDeposit: z.ZodString;
3052
+ }, z.core.$strict>, z.ZodObject<{
3053
+ id: z.ZodString;
3054
+ networkId: z.ZodString;
3055
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3056
+ decimals: z.ZodInt;
3057
+ symbol: z.ZodString;
3058
+ name: z.ZodOptional<z.ZodString>;
3059
+ logo: z.ZodOptional<z.ZodString>;
3060
+ coingeckoId: z.ZodOptional<z.ZodString>;
3061
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3062
+ mirrorOf: z.ZodOptional<z.ZodString>;
3063
+ type: z.ZodLiteral<"substrate-native">;
3064
+ platform: z.ZodLiteral<"polkadot">;
3065
+ existentialDeposit: z.ZodString;
3066
+ }, z.core.$strict>, z.ZodObject<{
3067
+ id: z.ZodString;
3068
+ networkId: z.ZodString;
3069
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3070
+ decimals: z.ZodInt;
3071
+ symbol: z.ZodString;
3072
+ name: z.ZodOptional<z.ZodString>;
3073
+ logo: z.ZodOptional<z.ZodString>;
3074
+ coingeckoId: z.ZodOptional<z.ZodString>;
3075
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3076
+ mirrorOf: z.ZodOptional<z.ZodString>;
3077
+ type: z.ZodLiteral<"substrate-psp22">;
3078
+ platform: z.ZodLiteral<"polkadot">;
3079
+ contractAddress: z.ZodString;
3080
+ }, z.core.$strict>, z.ZodObject<{
3081
+ id: z.ZodString;
3082
+ networkId: z.ZodString;
3083
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3084
+ decimals: z.ZodInt;
3085
+ symbol: z.ZodString;
3086
+ name: z.ZodOptional<z.ZodString>;
3087
+ logo: z.ZodOptional<z.ZodString>;
3088
+ coingeckoId: z.ZodOptional<z.ZodString>;
3089
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3090
+ mirrorOf: z.ZodOptional<z.ZodString>;
3091
+ type: z.ZodLiteral<"substrate-tokens">;
3092
+ platform: z.ZodLiteral<"polkadot">;
3093
+ onChainId: z.ZodUnion<readonly [z.ZodString, z.ZodNumber]>;
3094
+ existentialDeposit: z.ZodString;
3095
+ }, z.core.$strict>, z.ZodObject<{
3096
+ id: z.ZodString;
3097
+ networkId: z.ZodString;
3098
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3099
+ decimals: z.ZodInt;
3100
+ symbol: z.ZodString;
3101
+ name: z.ZodOptional<z.ZodString>;
3102
+ logo: z.ZodOptional<z.ZodString>;
3103
+ coingeckoId: z.ZodOptional<z.ZodString>;
3104
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3105
+ mirrorOf: z.ZodOptional<z.ZodString>;
3106
+ type: z.ZodLiteral<"substrate-hydration">;
3107
+ platform: z.ZodLiteral<"polkadot">;
3108
+ onChainId: z.ZodUInt32;
3109
+ assetType: z.ZodEnum<{
3110
+ Token: "Token";
3111
+ Erc20: "Erc20";
3112
+ External: "External";
3113
+ }>;
3114
+ isSufficient: z.ZodBoolean;
3115
+ existentialDeposit: z.ZodString;
3116
+ }, z.core.$strict>, z.ZodObject<{
3117
+ id: z.ZodString;
3118
+ networkId: z.ZodString;
3119
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3120
+ decimals: z.ZodInt;
3121
+ symbol: z.ZodString;
3122
+ name: z.ZodOptional<z.ZodString>;
3123
+ logo: z.ZodOptional<z.ZodString>;
3124
+ coingeckoId: z.ZodOptional<z.ZodString>;
3125
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3126
+ mirrorOf: z.ZodOptional<z.ZodString>;
3127
+ type: z.ZodLiteral<"sol-native">;
3128
+ platform: z.ZodLiteral<"solana">;
3129
+ }, z.core.$strict>, z.ZodObject<{
3130
+ id: z.ZodString;
3131
+ networkId: z.ZodString;
3132
+ isDefault: z.ZodOptional<z.ZodBoolean>;
3133
+ decimals: z.ZodInt;
3134
+ symbol: z.ZodString;
3135
+ name: z.ZodOptional<z.ZodString>;
3136
+ logo: z.ZodOptional<z.ZodString>;
3137
+ coingeckoId: z.ZodOptional<z.ZodString>;
3138
+ noDiscovery: z.ZodOptional<z.ZodBoolean>;
3139
+ mirrorOf: z.ZodOptional<z.ZodString>;
3140
+ type: z.ZodLiteral<"sol-spl">;
3141
+ platform: z.ZodLiteral<"solana">;
3142
+ mintAddress: z.ZodString;
3143
+ }, z.core.$strict>]>, z.ZodTransform<{
3144
+ id: string;
3145
+ networkId: string;
3146
+ decimals: number;
3147
+ symbol: string;
3148
+ type: "evm-native";
3149
+ platform: "ethereum";
3150
+ isDefault?: boolean | undefined;
3151
+ name?: string | undefined;
3152
+ logo?: string | undefined;
3153
+ coingeckoId?: string | undefined;
3154
+ noDiscovery?: boolean | undefined;
3155
+ mirrorOf?: string | undefined;
3156
+ } | {
3157
+ id: string;
3158
+ networkId: string;
3159
+ decimals: number;
3160
+ symbol: string;
3161
+ type: "evm-erc20";
3162
+ platform: "ethereum";
3163
+ contractAddress: `0x${string}`;
3164
+ isDefault?: boolean | undefined;
3165
+ name?: string | undefined;
3166
+ logo?: string | undefined;
3167
+ coingeckoId?: string | undefined;
3168
+ noDiscovery?: boolean | undefined;
3169
+ mirrorOf?: string | undefined;
3170
+ } | {
3171
+ id: string;
3172
+ networkId: string;
3173
+ decimals: number;
3174
+ symbol: string;
3175
+ type: "evm-uniswapv2";
3176
+ platform: "ethereum";
3177
+ contractAddress: `0x${string}`;
3178
+ symbol0: string;
3179
+ symbol1: string;
3180
+ decimals0: number;
3181
+ decimals1: number;
3182
+ tokenAddress0: `0x${string}`;
3183
+ tokenAddress1: `0x${string}`;
3184
+ isDefault?: boolean | undefined;
3185
+ name?: string | undefined;
3186
+ logo?: string | undefined;
3187
+ coingeckoId?: string | undefined;
3188
+ noDiscovery?: boolean | undefined;
3189
+ mirrorOf?: string | undefined;
3190
+ isCustom?: boolean | undefined;
3191
+ coingeckoId0?: string | undefined;
3192
+ coingeckoId1?: string | undefined;
3193
+ } | {
3194
+ id: string;
3195
+ networkId: string;
3196
+ decimals: number;
3197
+ symbol: string;
3198
+ type: "substrate-assets";
3199
+ platform: "polkadot";
3200
+ assetId: string;
3201
+ isSufficient: boolean;
3202
+ existentialDeposit: string;
3203
+ isDefault?: boolean | undefined;
3204
+ name?: string | undefined;
3205
+ logo?: string | undefined;
3206
+ coingeckoId?: string | undefined;
3207
+ noDiscovery?: boolean | undefined;
3208
+ mirrorOf?: string | undefined;
3209
+ isFrozen?: boolean | undefined;
3210
+ } | {
3211
+ id: string;
3212
+ networkId: string;
3213
+ decimals: number;
3214
+ symbol: string;
3215
+ type: "substrate-dtao";
3216
+ platform: "polkadot";
3217
+ netuid: number;
3218
+ isTransferable: boolean;
3219
+ isDefault?: boolean | undefined;
3220
+ name?: string | undefined;
3221
+ logo?: string | undefined;
3222
+ coingeckoId?: string | undefined;
3223
+ noDiscovery?: boolean | undefined;
3224
+ mirrorOf?: string | undefined;
3225
+ subnetName?: string | undefined;
3226
+ hotkey?: string | undefined;
3227
+ } | {
3228
+ id: string;
3229
+ networkId: string;
3230
+ decimals: number;
3231
+ symbol: string;
3232
+ type: "substrate-foreignassets";
3233
+ platform: "polkadot";
3234
+ onChainId: string;
3235
+ isSufficient: boolean;
3236
+ existentialDeposit: string;
3237
+ isDefault?: boolean | undefined;
3238
+ name?: string | undefined;
3239
+ logo?: string | undefined;
3240
+ coingeckoId?: string | undefined;
3241
+ noDiscovery?: boolean | undefined;
3242
+ mirrorOf?: string | undefined;
3243
+ isFrozen?: boolean | undefined;
3244
+ } | {
3245
+ id: string;
3246
+ networkId: string;
3247
+ decimals: number;
3248
+ symbol: string;
3249
+ type: "substrate-native";
3250
+ platform: "polkadot";
3251
+ existentialDeposit: string;
3252
+ isDefault?: boolean | undefined;
3253
+ name?: string | undefined;
3254
+ logo?: string | undefined;
3255
+ coingeckoId?: string | undefined;
3256
+ noDiscovery?: boolean | undefined;
3257
+ mirrorOf?: string | undefined;
3258
+ } | {
3259
+ id: string;
3260
+ networkId: string;
3261
+ decimals: number;
3262
+ symbol: string;
3263
+ type: "substrate-psp22";
3264
+ platform: "polkadot";
3265
+ contractAddress: string;
3266
+ isDefault?: boolean | undefined;
3267
+ name?: string | undefined;
3268
+ logo?: string | undefined;
3269
+ coingeckoId?: string | undefined;
3270
+ noDiscovery?: boolean | undefined;
3271
+ mirrorOf?: string | undefined;
3272
+ } | {
3273
+ id: string;
3274
+ networkId: string;
3275
+ decimals: number;
3276
+ symbol: string;
3277
+ type: "substrate-tokens";
3278
+ platform: "polkadot";
3279
+ onChainId: string | number;
3280
+ existentialDeposit: string;
3281
+ isDefault?: boolean | undefined;
3282
+ name?: string | undefined;
3283
+ logo?: string | undefined;
3284
+ coingeckoId?: string | undefined;
3285
+ noDiscovery?: boolean | undefined;
3286
+ mirrorOf?: string | undefined;
3287
+ } | {
3288
+ id: string;
3289
+ networkId: string;
3290
+ decimals: number;
3291
+ symbol: string;
3292
+ type: "substrate-hydration";
3293
+ platform: "polkadot";
3294
+ onChainId: number;
3295
+ assetType: "Token" | "Erc20" | "External";
3296
+ isSufficient: boolean;
3297
+ existentialDeposit: string;
3298
+ isDefault?: boolean | undefined;
3299
+ name?: string | undefined;
3300
+ logo?: string | undefined;
3301
+ coingeckoId?: string | undefined;
3302
+ noDiscovery?: boolean | undefined;
3303
+ mirrorOf?: string | undefined;
3304
+ } | {
3305
+ id: string;
3306
+ networkId: string;
3307
+ decimals: number;
3308
+ symbol: string;
3309
+ type: "sol-native";
3310
+ platform: "solana";
3311
+ isDefault?: boolean | undefined;
3312
+ name?: string | undefined;
3313
+ logo?: string | undefined;
3314
+ coingeckoId?: string | undefined;
3315
+ noDiscovery?: boolean | undefined;
3316
+ mirrorOf?: string | undefined;
3317
+ } | {
3318
+ id: string;
3319
+ networkId: string;
3320
+ decimals: number;
3321
+ symbol: string;
3322
+ type: "sol-spl";
3323
+ platform: "solana";
3324
+ mintAddress: string;
3325
+ isDefault?: boolean | undefined;
3326
+ name?: string | undefined;
3327
+ logo?: string | undefined;
3328
+ coingeckoId?: string | undefined;
3329
+ noDiscovery?: boolean | undefined;
3330
+ mirrorOf?: string | undefined;
3331
+ }, {
3332
+ id: string;
3333
+ networkId: string;
3334
+ decimals: number;
3335
+ symbol: string;
3336
+ type: "evm-native";
3337
+ platform: "ethereum";
3338
+ isDefault?: boolean | undefined;
3339
+ name?: string | undefined;
3340
+ logo?: string | undefined;
3341
+ coingeckoId?: string | undefined;
3342
+ noDiscovery?: boolean | undefined;
3343
+ mirrorOf?: string | undefined;
3344
+ } | {
3345
+ id: string;
3346
+ networkId: string;
3347
+ decimals: number;
3348
+ symbol: string;
3349
+ type: "evm-erc20";
3350
+ platform: "ethereum";
3351
+ contractAddress: `0x${string}`;
3352
+ isDefault?: boolean | undefined;
3353
+ name?: string | undefined;
3354
+ logo?: string | undefined;
3355
+ coingeckoId?: string | undefined;
3356
+ noDiscovery?: boolean | undefined;
3357
+ mirrorOf?: string | undefined;
3358
+ } | {
3359
+ id: string;
3360
+ networkId: string;
3361
+ decimals: number;
3362
+ symbol: string;
3363
+ type: "evm-uniswapv2";
3364
+ platform: "ethereum";
3365
+ contractAddress: `0x${string}`;
3366
+ symbol0: string;
3367
+ symbol1: string;
3368
+ decimals0: number;
3369
+ decimals1: number;
3370
+ tokenAddress0: `0x${string}`;
3371
+ tokenAddress1: `0x${string}`;
3372
+ isDefault?: boolean | undefined;
3373
+ name?: string | undefined;
3374
+ logo?: string | undefined;
3375
+ coingeckoId?: string | undefined;
3376
+ noDiscovery?: boolean | undefined;
3377
+ mirrorOf?: string | undefined;
3378
+ isCustom?: boolean | undefined;
3379
+ coingeckoId0?: string | undefined;
3380
+ coingeckoId1?: string | undefined;
3381
+ } | {
3382
+ id: string;
3383
+ networkId: string;
3384
+ decimals: number;
3385
+ symbol: string;
3386
+ type: "substrate-assets";
3387
+ platform: "polkadot";
3388
+ assetId: string;
3389
+ isSufficient: boolean;
3390
+ existentialDeposit: string;
3391
+ isDefault?: boolean | undefined;
3392
+ name?: string | undefined;
3393
+ logo?: string | undefined;
3394
+ coingeckoId?: string | undefined;
3395
+ noDiscovery?: boolean | undefined;
3396
+ mirrorOf?: string | undefined;
3397
+ isFrozen?: boolean | undefined;
3398
+ } | {
3399
+ id: string;
3400
+ networkId: string;
3401
+ decimals: number;
3402
+ symbol: string;
3403
+ type: "substrate-dtao";
3404
+ platform: "polkadot";
3405
+ netuid: number;
3406
+ isTransferable: boolean;
3407
+ isDefault?: boolean | undefined;
3408
+ name?: string | undefined;
3409
+ logo?: string | undefined;
3410
+ coingeckoId?: string | undefined;
3411
+ noDiscovery?: boolean | undefined;
3412
+ mirrorOf?: string | undefined;
3413
+ subnetName?: string | undefined;
3414
+ hotkey?: string | undefined;
3415
+ } | {
3416
+ id: string;
3417
+ networkId: string;
3418
+ decimals: number;
3419
+ symbol: string;
3420
+ type: "substrate-foreignassets";
3421
+ platform: "polkadot";
3422
+ onChainId: string;
3423
+ isSufficient: boolean;
3424
+ existentialDeposit: string;
3425
+ isDefault?: boolean | undefined;
3426
+ name?: string | undefined;
3427
+ logo?: string | undefined;
3428
+ coingeckoId?: string | undefined;
3429
+ noDiscovery?: boolean | undefined;
3430
+ mirrorOf?: string | undefined;
3431
+ isFrozen?: boolean | undefined;
3432
+ } | {
3433
+ id: string;
3434
+ networkId: string;
3435
+ decimals: number;
3436
+ symbol: string;
3437
+ type: "substrate-native";
3438
+ platform: "polkadot";
3439
+ existentialDeposit: string;
3440
+ isDefault?: boolean | undefined;
3441
+ name?: string | undefined;
3442
+ logo?: string | undefined;
3443
+ coingeckoId?: string | undefined;
3444
+ noDiscovery?: boolean | undefined;
3445
+ mirrorOf?: string | undefined;
3446
+ } | {
3447
+ id: string;
3448
+ networkId: string;
3449
+ decimals: number;
3450
+ symbol: string;
3451
+ type: "substrate-psp22";
3452
+ platform: "polkadot";
3453
+ contractAddress: string;
3454
+ isDefault?: boolean | undefined;
3455
+ name?: string | undefined;
3456
+ logo?: string | undefined;
3457
+ coingeckoId?: string | undefined;
3458
+ noDiscovery?: boolean | undefined;
3459
+ mirrorOf?: string | undefined;
3460
+ } | {
3461
+ id: string;
3462
+ networkId: string;
3463
+ decimals: number;
3464
+ symbol: string;
3465
+ type: "substrate-tokens";
3466
+ platform: "polkadot";
3467
+ onChainId: string | number;
3468
+ existentialDeposit: string;
3469
+ isDefault?: boolean | undefined;
3470
+ name?: string | undefined;
3471
+ logo?: string | undefined;
3472
+ coingeckoId?: string | undefined;
3473
+ noDiscovery?: boolean | undefined;
3474
+ mirrorOf?: string | undefined;
3475
+ } | {
3476
+ id: string;
3477
+ networkId: string;
3478
+ decimals: number;
3479
+ symbol: string;
3480
+ type: "substrate-hydration";
3481
+ platform: "polkadot";
3482
+ onChainId: number;
3483
+ assetType: "Token" | "Erc20" | "External";
3484
+ isSufficient: boolean;
3485
+ existentialDeposit: string;
3486
+ isDefault?: boolean | undefined;
3487
+ name?: string | undefined;
3488
+ logo?: string | undefined;
3489
+ coingeckoId?: string | undefined;
3490
+ noDiscovery?: boolean | undefined;
3491
+ mirrorOf?: string | undefined;
3492
+ } | {
3493
+ id: string;
3494
+ networkId: string;
3495
+ decimals: number;
3496
+ symbol: string;
3497
+ type: "sol-native";
3498
+ platform: "solana";
3499
+ isDefault?: boolean | undefined;
3500
+ name?: string | undefined;
3501
+ logo?: string | undefined;
3502
+ coingeckoId?: string | undefined;
3503
+ noDiscovery?: boolean | undefined;
3504
+ mirrorOf?: string | undefined;
3505
+ } | {
3506
+ id: string;
3507
+ networkId: string;
3508
+ decimals: number;
3509
+ symbol: string;
3510
+ type: "sol-spl";
3511
+ platform: "solana";
3512
+ mintAddress: string;
3513
+ isDefault?: boolean | undefined;
3514
+ name?: string | undefined;
3515
+ logo?: string | undefined;
3516
+ coingeckoId?: string | undefined;
3517
+ noDiscovery?: boolean | undefined;
3518
+ mirrorOf?: string | undefined;
3519
+ }>>>;
3520
+ }, z.core.$strict>;
3521
+ type CustomChaindata = z.infer<typeof CustomChaindataSchema>;
3522
+
3523
+ interface IChaindataNetworkProvider {
3524
+ networks$: Observable<Network[]>;
3525
+ getNetworks$<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(platform?: P): Observable<R[]>;
3526
+ getNetworks<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(platform?: P): Promise<R[]>;
3527
+ getNetworkIds$(platform?: NetworkPlatform): Observable<NetworkId[]>;
3528
+ getNetworkIds(platform?: NetworkPlatform): Promise<NetworkId[]>;
3529
+ getNetworksMapById$<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(platform?: P): Observable<Record<NetworkId, R>>;
3530
+ getNetworksMapById<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(platform?: P): Promise<Record<NetworkId, R>>;
3531
+ getNetworksMapByGenesisHash$(): Observable<Record<`0x${string}`, DotNetwork>>;
3532
+ getNetworksMapByGenesisHash(): Promise<Record<`0x${string}`, DotNetwork>>;
3533
+ getNetworkById$<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(networkId: NetworkId, platform?: P): Observable<R | null>;
3534
+ getNetworkById<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(networkId: NetworkId, platform?: P): Promise<R | null>;
3535
+ getNetworkByGenesisHash$(genesisHash: `0x${string}`): Observable<DotNetwork | null>;
3536
+ getNetworkByGenesisHash(genesisHash: `0x${string}`): Promise<DotNetwork | null>;
3537
+ }
3538
+ interface IChaindataTokenProvider {
3539
+ tokens$: Observable<Token[]>;
3540
+ getTokens$<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(type?: T): Observable<R[]>;
3541
+ getTokens<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(type?: T): Promise<R[]>;
3542
+ getTokenIds$(type?: TokenType): Observable<TokenId[]>;
3543
+ getTokenIds(type?: TokenType): Promise<TokenId[]>;
3544
+ getTokensMapById$<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(type?: T): Observable<Record<TokenId, R>>;
3545
+ getTokensMapById<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(type?: T): Promise<Record<TokenId, R>>;
3546
+ getTokenById$<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(tokenId: TokenId, type?: T): Observable<R | null>;
3547
+ getTokenById<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(tokenId: TokenId, type?: T): Promise<R | null>;
3548
+ }
3549
+ interface IChaindataProvider extends IChaindataNetworkProvider, IChaindataTokenProvider {
3550
+ }
3551
+
3552
+ /**
3553
+ * This type will be used for in-memory storage of chaindata.
3554
+ *
3555
+ * Provide a Subject<ChaindataStorage> and subscribe to changes to persist the data to disk.
3556
+ * Instantiate ChaindataProvider with this subject to restore persisted data from disk.
3557
+ */
3558
+ type ChaindataStorage = {
3559
+ networks: Network[];
3560
+ tokens: Token[];
3561
+ miniMetadatas: AnyMiniMetadata[];
3562
+ };
3563
+ type ChaindataProviderOptions = {
3564
+ persistedStorage?: ChaindataStorage | Promise<ChaindataStorage | undefined>;
3565
+ customChaindata$?: Observable<CustomChaindata> | CustomChaindata;
3566
+ dynamicTokens$?: ReplaySubject<Token[]>;
3567
+ };
3568
+ declare class ChaindataProvider implements IChaindataProvider {
3569
+ #private;
3570
+ constructor({ persistedStorage, customChaindata$, dynamicTokens$, }?: ChaindataProviderOptions);
3571
+ /**
3572
+ * Subscribe to this observable and save its contents somewhere persistent.
3573
+ *
3574
+ * Instantiate `new ChaindataProvider({ persistedStorage })` with the saved contents
3575
+ * to prevent the need to wait for them to download on every startup.
3576
+ */
3577
+ get storage$(): Observable<ChaindataStorage>;
3578
+ /**
3579
+ * Mini metadatas
3580
+ */
3581
+ get miniMetadatas$(): Observable<{
3582
+ id: string;
3583
+ source: string;
3584
+ chainId: string;
3585
+ specVersion: number;
3586
+ version: string;
3587
+ data: `0x${string}` | null;
3588
+ extra: any;
3589
+ }[]>;
3590
+ getMiniMetadatas(): Promise<{
3591
+ id: string;
3592
+ source: string;
3593
+ chainId: string;
3594
+ specVersion: number;
3595
+ version: string;
3596
+ data: `0x${string}` | null;
3597
+ extra: any;
3598
+ }[]>;
3599
+ get miniMetadatasMapById$(): Observable<Record<string, {
3600
+ id: string;
3601
+ source: string;
3602
+ chainId: string;
3603
+ specVersion: number;
3604
+ version: string;
3605
+ data: `0x${string}` | null;
3606
+ extra: any;
3607
+ }>>;
3608
+ getMiniMetadatasMapById(): Promise<Record<string, {
3609
+ id: string;
3610
+ source: string;
3611
+ chainId: string;
3612
+ specVersion: number;
3613
+ version: string;
3614
+ data: `0x${string}` | null;
3615
+ extra: any;
3616
+ }>>;
3617
+ getMiniMetadataById$(id: string): Observable<{
3618
+ id: string;
3619
+ source: string;
3620
+ chainId: string;
3621
+ specVersion: number;
3622
+ version: string;
3623
+ data: `0x${string}` | null;
3624
+ extra: any;
3625
+ }>;
3626
+ miniMetadataById(id: string): Promise<{
3627
+ id: string;
3628
+ source: string;
3629
+ chainId: string;
3630
+ specVersion: number;
3631
+ version: string;
3632
+ data: `0x${string}` | null;
3633
+ extra: any;
3634
+ }>;
3635
+ /**
3636
+ * Tokens
3637
+ */
3638
+ get tokens$(): Observable<({
3639
+ id: string;
3640
+ networkId: string;
3641
+ decimals: number;
3642
+ symbol: string;
3643
+ type: "evm-native";
3644
+ platform: "ethereum";
3645
+ isDefault?: boolean | undefined;
3646
+ name?: string | undefined;
3647
+ logo?: string | undefined;
3648
+ coingeckoId?: string | undefined;
3649
+ noDiscovery?: boolean | undefined;
3650
+ mirrorOf?: string | undefined;
3651
+ } | {
3652
+ id: string;
3653
+ networkId: string;
3654
+ decimals: number;
3655
+ symbol: string;
3656
+ type: "evm-erc20";
3657
+ platform: "ethereum";
3658
+ contractAddress: `0x${string}`;
3659
+ isDefault?: boolean | undefined;
3660
+ name?: string | undefined;
3661
+ logo?: string | undefined;
3662
+ coingeckoId?: string | undefined;
3663
+ noDiscovery?: boolean | undefined;
3664
+ mirrorOf?: string | undefined;
3665
+ } | {
3666
+ id: string;
3667
+ networkId: string;
3668
+ decimals: number;
3669
+ symbol: string;
3670
+ type: "evm-uniswapv2";
3671
+ platform: "ethereum";
3672
+ contractAddress: `0x${string}`;
3673
+ symbol0: string;
3674
+ symbol1: string;
3675
+ decimals0: number;
3676
+ decimals1: number;
3677
+ tokenAddress0: `0x${string}`;
3678
+ tokenAddress1: `0x${string}`;
3679
+ isDefault?: boolean | undefined;
3680
+ name?: string | undefined;
3681
+ logo?: string | undefined;
3682
+ coingeckoId?: string | undefined;
3683
+ noDiscovery?: boolean | undefined;
3684
+ mirrorOf?: string | undefined;
3685
+ isCustom?: boolean | undefined;
3686
+ coingeckoId0?: string | undefined;
3687
+ coingeckoId1?: string | undefined;
3688
+ } | {
3689
+ id: string;
3690
+ networkId: string;
3691
+ decimals: number;
3692
+ symbol: string;
3693
+ type: "substrate-assets";
3694
+ platform: "polkadot";
3695
+ assetId: string;
3696
+ isSufficient: boolean;
3697
+ existentialDeposit: string;
3698
+ isDefault?: boolean | undefined;
3699
+ name?: string | undefined;
3700
+ logo?: string | undefined;
3701
+ coingeckoId?: string | undefined;
3702
+ noDiscovery?: boolean | undefined;
3703
+ mirrorOf?: string | undefined;
3704
+ isFrozen?: boolean | undefined;
3705
+ } | {
3706
+ id: string;
3707
+ networkId: string;
3708
+ decimals: number;
3709
+ symbol: string;
3710
+ type: "substrate-dtao";
3711
+ platform: "polkadot";
3712
+ netuid: number;
3713
+ isTransferable: boolean;
3714
+ isDefault?: boolean | undefined;
3715
+ name?: string | undefined;
3716
+ logo?: string | undefined;
3717
+ coingeckoId?: string | undefined;
3718
+ noDiscovery?: boolean | undefined;
3719
+ mirrorOf?: string | undefined;
3720
+ subnetName?: string | undefined;
3721
+ hotkey?: string | undefined;
3722
+ } | {
3723
+ id: string;
3724
+ networkId: string;
3725
+ decimals: number;
3726
+ symbol: string;
3727
+ type: "substrate-foreignassets";
3728
+ platform: "polkadot";
3729
+ onChainId: string;
3730
+ isSufficient: boolean;
3731
+ existentialDeposit: string;
3732
+ isDefault?: boolean | undefined;
3733
+ name?: string | undefined;
3734
+ logo?: string | undefined;
3735
+ coingeckoId?: string | undefined;
3736
+ noDiscovery?: boolean | undefined;
3737
+ mirrorOf?: string | undefined;
3738
+ isFrozen?: boolean | undefined;
3739
+ } | {
3740
+ id: string;
3741
+ networkId: string;
3742
+ decimals: number;
3743
+ symbol: string;
3744
+ type: "substrate-native";
3745
+ platform: "polkadot";
3746
+ existentialDeposit: string;
3747
+ isDefault?: boolean | undefined;
3748
+ name?: string | undefined;
3749
+ logo?: string | undefined;
3750
+ coingeckoId?: string | undefined;
3751
+ noDiscovery?: boolean | undefined;
3752
+ mirrorOf?: string | undefined;
3753
+ } | {
3754
+ id: string;
3755
+ networkId: string;
3756
+ decimals: number;
3757
+ symbol: string;
3758
+ type: "substrate-psp22";
3759
+ platform: "polkadot";
3760
+ contractAddress: string;
3761
+ isDefault?: boolean | undefined;
3762
+ name?: string | undefined;
3763
+ logo?: string | undefined;
3764
+ coingeckoId?: string | undefined;
3765
+ noDiscovery?: boolean | undefined;
3766
+ mirrorOf?: string | undefined;
3767
+ } | {
3768
+ id: string;
3769
+ networkId: string;
3770
+ decimals: number;
3771
+ symbol: string;
3772
+ type: "substrate-tokens";
3773
+ platform: "polkadot";
3774
+ onChainId: string | number;
3775
+ existentialDeposit: string;
3776
+ isDefault?: boolean | undefined;
3777
+ name?: string | undefined;
3778
+ logo?: string | undefined;
3779
+ coingeckoId?: string | undefined;
3780
+ noDiscovery?: boolean | undefined;
3781
+ mirrorOf?: string | undefined;
3782
+ } | {
3783
+ id: string;
3784
+ networkId: string;
3785
+ decimals: number;
3786
+ symbol: string;
3787
+ type: "substrate-hydration";
3788
+ platform: "polkadot";
3789
+ onChainId: number;
3790
+ assetType: "Token" | "Erc20" | "External";
3791
+ isSufficient: boolean;
3792
+ existentialDeposit: string;
3793
+ isDefault?: boolean | undefined;
3794
+ name?: string | undefined;
3795
+ logo?: string | undefined;
3796
+ coingeckoId?: string | undefined;
3797
+ noDiscovery?: boolean | undefined;
3798
+ mirrorOf?: string | undefined;
3799
+ } | {
3800
+ id: string;
3801
+ networkId: string;
3802
+ decimals: number;
3803
+ symbol: string;
3804
+ type: "sol-native";
3805
+ platform: "solana";
3806
+ isDefault?: boolean | undefined;
3807
+ name?: string | undefined;
3808
+ logo?: string | undefined;
3809
+ coingeckoId?: string | undefined;
3810
+ noDiscovery?: boolean | undefined;
3811
+ mirrorOf?: string | undefined;
3812
+ } | {
3813
+ id: string;
3814
+ networkId: string;
3815
+ decimals: number;
3816
+ symbol: string;
3817
+ type: "sol-spl";
3818
+ platform: "solana";
3819
+ mintAddress: string;
3820
+ isDefault?: boolean | undefined;
3821
+ name?: string | undefined;
3822
+ logo?: string | undefined;
3823
+ coingeckoId?: string | undefined;
3824
+ noDiscovery?: boolean | undefined;
3825
+ mirrorOf?: string | undefined;
3826
+ })[]>;
3827
+ getTokens$<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(type?: T): Observable<R[]>;
3828
+ getTokens<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(type?: T): Promise<R[]>;
3829
+ getTokenIds$(type?: TokenType): Observable<string[]>;
3830
+ getTokenIds(type?: TokenType): Promise<string[]>;
3831
+ getTokensMapById$<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(type?: T): Observable<Record<TokenId, R>>;
3832
+ getTokensMapById<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(type?: T): Promise<Record<TokenId, R>>;
3833
+ getTokenById$<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(id: TokenId, type?: T): Observable<R | null>;
3834
+ getTokenById<T extends TokenType | undefined, R extends T extends TokenType ? TokenOfType<T> : Token>(id: TokenId, type?: T): Promise<R | null>;
3835
+ /**
3836
+ * Registers token dynamically a runtime. used for SPL and dTAO tokens.
3837
+ * @param tokens
3838
+ */
3839
+ registerDynamicTokens(tokens: Token[]): Promise<void>;
3840
+ /**
3841
+ * dynamic tokens are created when they are first detected by the balance modules.
3842
+ * this method syncs their metadata (name, symbol, logo) with custom logic specific to each token type
3843
+ */
3844
+ syncDynamicTokens(): Promise<void>;
3845
+ /**
3846
+ * Networks
3847
+ */
3848
+ get networks$(): Observable<({
3849
+ id: string;
3850
+ name: string;
3851
+ nativeTokenId: string;
3852
+ nativeCurrency: {
3853
+ decimals: number;
3854
+ symbol: string;
3855
+ name: string;
3856
+ coingeckoId?: string | undefined;
3857
+ mirrorOf?: string | undefined;
3858
+ logo?: string | undefined;
3859
+ };
3860
+ blockExplorerUrls: string[];
3861
+ genesisHash: `0x${string}`;
3862
+ platform: "polkadot";
3863
+ chainName: string;
3864
+ specName: string;
3865
+ specVersion: number;
3866
+ account: "secp256k1" | "*25519";
3867
+ prefix: number;
3868
+ rpcs: string[];
3869
+ topology: {
3870
+ type: "standalone";
3871
+ } | {
3872
+ type: "relay";
3873
+ } | {
3874
+ type: "parachain";
3875
+ relayId: string;
3876
+ paraId: number;
3877
+ };
3878
+ isTestnet?: boolean | undefined;
3879
+ isDefault?: boolean | undefined;
3880
+ forceScan?: boolean | undefined;
3881
+ logo?: string | undefined;
3882
+ themeColor?: string | undefined;
3883
+ chainspecQrUrl?: string | undefined;
3884
+ latestMetadataQrUrl?: string | undefined;
3885
+ oldPrefix?: number | undefined;
3886
+ registryTypes?: any;
3887
+ signedExtensions?: any;
3888
+ hasCheckMetadataHash?: boolean | undefined;
3889
+ hasExtrinsicSignatureTypePrefix?: boolean | undefined;
3890
+ isUnknownFeeToken?: boolean | undefined;
3891
+ balancesConfig?: {
3892
+ "substrate-native"?: {
3893
+ disable?: boolean | undefined;
3894
+ } | undefined;
3895
+ "substrate-assets"?: Record<string, never> | undefined;
3896
+ "substrate-psp22"?: Record<string, never> | undefined;
3897
+ "substrate-tokens"?: {
3898
+ palletId?: string | undefined;
3899
+ } | undefined;
3900
+ "substrate-foreignassets"?: Record<string, never> | undefined;
3901
+ "substrate-hydration"?: Record<string, never> | undefined;
3902
+ "substrate-dtao"?: Record<string, never> | undefined;
3903
+ } | undefined;
3904
+ } | {
3905
+ id: string;
3906
+ name: string;
3907
+ nativeTokenId: string;
3908
+ nativeCurrency: {
3909
+ decimals: number;
3910
+ symbol: string;
3911
+ name: string;
3912
+ coingeckoId?: string | undefined;
3913
+ mirrorOf?: string | undefined;
3914
+ logo?: string | undefined;
3915
+ };
3916
+ blockExplorerUrls: string[];
3917
+ platform: "ethereum";
3918
+ rpcs: string[];
3919
+ isTestnet?: boolean | undefined;
3920
+ isDefault?: boolean | undefined;
3921
+ forceScan?: boolean | undefined;
3922
+ logo?: string | undefined;
3923
+ themeColor?: string | undefined;
3924
+ substrateChainId?: string | undefined;
3925
+ preserveGasEstimate?: boolean | undefined;
3926
+ feeType?: "legacy" | "eip-1559" | undefined;
3927
+ l2FeeType?: {
3928
+ type: "op-stack";
3929
+ } | {
3930
+ type: "scroll";
3931
+ l1GasPriceOracle: `0x${string}`;
3932
+ } | undefined;
3933
+ contracts?: {
3934
+ Erc20Aggregator?: `0x${string}` | undefined;
3935
+ Multicall3?: `0x${string}` | undefined;
3936
+ } | undefined;
3937
+ balancesConfig?: {
3938
+ "evm-native"?: Record<string, never> | undefined;
3939
+ "evm-erc20"?: Record<string, never> | undefined;
3940
+ "evm-uniswapv2"?: Record<string, never> | undefined;
3941
+ } | undefined;
3942
+ } | {
3943
+ id: string;
3944
+ name: string;
3945
+ nativeTokenId: string;
3946
+ nativeCurrency: {
3947
+ decimals: number;
3948
+ symbol: string;
3949
+ name: string;
3950
+ coingeckoId?: string | undefined;
3951
+ mirrorOf?: string | undefined;
3952
+ logo?: string | undefined;
3953
+ };
3954
+ blockExplorerUrls: string[];
3955
+ platform: "solana";
3956
+ genesisHash: string;
3957
+ rpcs: string[];
3958
+ isTestnet?: boolean | undefined;
3959
+ isDefault?: boolean | undefined;
3960
+ forceScan?: boolean | undefined;
3961
+ logo?: string | undefined;
3962
+ themeColor?: string | undefined;
3963
+ balancesConfig?: {
3964
+ "sol-native"?: Record<string, never> | undefined;
3965
+ "sol-spl"?: Record<string, never> | undefined;
3966
+ } | undefined;
3967
+ })[]>;
3968
+ getNetworks$<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(platform?: P): Observable<R[]>;
3969
+ getNetworks<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(platform?: P): Promise<R[]>;
3970
+ getNetworkIds$(platform?: NetworkPlatform): Observable<string[]>;
3971
+ getNetworkIds(platform?: NetworkPlatform): Promise<string[]>;
3972
+ getNetworksMapById$<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(platform?: P): Observable<Record<NetworkId, R>>;
3973
+ getNetworksMapById<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(platform?: P): Promise<Record<NetworkId, R>>;
3974
+ getNetworksMapByGenesisHash$(): Observable<Record<`0x${string}`, DotNetwork>>;
3975
+ getNetworksMapByGenesisHash(): Promise<Record<`0x${string}`, {
3976
+ id: string;
3977
+ name: string;
3978
+ nativeTokenId: string;
3979
+ nativeCurrency: {
3980
+ decimals: number;
3981
+ symbol: string;
3982
+ name: string;
3983
+ coingeckoId?: string | undefined;
3984
+ mirrorOf?: string | undefined;
3985
+ logo?: string | undefined;
3986
+ };
3987
+ blockExplorerUrls: string[];
3988
+ genesisHash: `0x${string}`;
3989
+ platform: "polkadot";
3990
+ chainName: string;
3991
+ specName: string;
3992
+ specVersion: number;
3993
+ account: "secp256k1" | "*25519";
3994
+ prefix: number;
3995
+ rpcs: string[];
3996
+ topology: {
3997
+ type: "standalone";
3998
+ } | {
3999
+ type: "relay";
4000
+ } | {
4001
+ type: "parachain";
4002
+ relayId: string;
4003
+ paraId: number;
4004
+ };
4005
+ isTestnet?: boolean | undefined;
4006
+ isDefault?: boolean | undefined;
4007
+ forceScan?: boolean | undefined;
4008
+ logo?: string | undefined;
4009
+ themeColor?: string | undefined;
4010
+ chainspecQrUrl?: string | undefined;
4011
+ latestMetadataQrUrl?: string | undefined;
4012
+ oldPrefix?: number | undefined;
4013
+ registryTypes?: any;
4014
+ signedExtensions?: any;
4015
+ hasCheckMetadataHash?: boolean | undefined;
4016
+ hasExtrinsicSignatureTypePrefix?: boolean | undefined;
4017
+ isUnknownFeeToken?: boolean | undefined;
4018
+ balancesConfig?: {
4019
+ "substrate-native"?: {
4020
+ disable?: boolean | undefined;
4021
+ } | undefined;
4022
+ "substrate-assets"?: Record<string, never> | undefined;
4023
+ "substrate-psp22"?: Record<string, never> | undefined;
4024
+ "substrate-tokens"?: {
4025
+ palletId?: string | undefined;
4026
+ } | undefined;
4027
+ "substrate-foreignassets"?: Record<string, never> | undefined;
4028
+ "substrate-hydration"?: Record<string, never> | undefined;
4029
+ "substrate-dtao"?: Record<string, never> | undefined;
4030
+ } | undefined;
4031
+ }>>;
4032
+ getNetworkById$<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(networkId: NetworkId, platform?: P): Observable<R | null>;
4033
+ getNetworkById<P extends NetworkPlatform | undefined, R = P extends NetworkPlatform ? NetworkOfPlatform<P> : Network>(networkId: NetworkId, platform?: P): Promise<R | null>;
4034
+ getNetworkByGenesisHash$(genesisHash: `0x${string}`): Observable<{
4035
+ id: string;
4036
+ name: string;
4037
+ nativeTokenId: string;
4038
+ nativeCurrency: {
4039
+ decimals: number;
4040
+ symbol: string;
4041
+ name: string;
4042
+ coingeckoId?: string | undefined;
4043
+ mirrorOf?: string | undefined;
4044
+ logo?: string | undefined;
4045
+ };
4046
+ blockExplorerUrls: string[];
4047
+ genesisHash: `0x${string}`;
4048
+ platform: "polkadot";
4049
+ chainName: string;
4050
+ specName: string;
4051
+ specVersion: number;
4052
+ account: "secp256k1" | "*25519";
4053
+ prefix: number;
4054
+ rpcs: string[];
4055
+ topology: {
4056
+ type: "standalone";
4057
+ } | {
4058
+ type: "relay";
4059
+ } | {
4060
+ type: "parachain";
4061
+ relayId: string;
4062
+ paraId: number;
4063
+ };
4064
+ isTestnet?: boolean | undefined;
4065
+ isDefault?: boolean | undefined;
4066
+ forceScan?: boolean | undefined;
4067
+ logo?: string | undefined;
4068
+ themeColor?: string | undefined;
4069
+ chainspecQrUrl?: string | undefined;
4070
+ latestMetadataQrUrl?: string | undefined;
4071
+ oldPrefix?: number | undefined;
4072
+ registryTypes?: any;
4073
+ signedExtensions?: any;
4074
+ hasCheckMetadataHash?: boolean | undefined;
4075
+ hasExtrinsicSignatureTypePrefix?: boolean | undefined;
4076
+ isUnknownFeeToken?: boolean | undefined;
4077
+ balancesConfig?: {
4078
+ "substrate-native"?: {
4079
+ disable?: boolean | undefined;
4080
+ } | undefined;
4081
+ "substrate-assets"?: Record<string, never> | undefined;
4082
+ "substrate-psp22"?: Record<string, never> | undefined;
4083
+ "substrate-tokens"?: {
4084
+ palletId?: string | undefined;
4085
+ } | undefined;
4086
+ "substrate-foreignassets"?: Record<string, never> | undefined;
4087
+ "substrate-hydration"?: Record<string, never> | undefined;
4088
+ "substrate-dtao"?: Record<string, never> | undefined;
4089
+ } | undefined;
4090
+ }>;
4091
+ getNetworkByGenesisHash(genesisHash: `0x${string}`): Promise<{
4092
+ id: string;
4093
+ name: string;
4094
+ nativeTokenId: string;
4095
+ nativeCurrency: {
4096
+ decimals: number;
4097
+ symbol: string;
4098
+ name: string;
4099
+ coingeckoId?: string | undefined;
4100
+ mirrorOf?: string | undefined;
4101
+ logo?: string | undefined;
4102
+ };
4103
+ blockExplorerUrls: string[];
4104
+ genesisHash: `0x${string}`;
4105
+ platform: "polkadot";
4106
+ chainName: string;
4107
+ specName: string;
4108
+ specVersion: number;
4109
+ account: "secp256k1" | "*25519";
4110
+ prefix: number;
4111
+ rpcs: string[];
4112
+ topology: {
4113
+ type: "standalone";
4114
+ } | {
4115
+ type: "relay";
4116
+ } | {
4117
+ type: "parachain";
4118
+ relayId: string;
4119
+ paraId: number;
4120
+ };
4121
+ isTestnet?: boolean | undefined;
4122
+ isDefault?: boolean | undefined;
4123
+ forceScan?: boolean | undefined;
4124
+ logo?: string | undefined;
4125
+ themeColor?: string | undefined;
4126
+ chainspecQrUrl?: string | undefined;
4127
+ latestMetadataQrUrl?: string | undefined;
4128
+ oldPrefix?: number | undefined;
4129
+ registryTypes?: any;
4130
+ signedExtensions?: any;
4131
+ hasCheckMetadataHash?: boolean | undefined;
4132
+ hasExtrinsicSignatureTypePrefix?: boolean | undefined;
4133
+ isUnknownFeeToken?: boolean | undefined;
4134
+ balancesConfig?: {
4135
+ "substrate-native"?: {
4136
+ disable?: boolean | undefined;
4137
+ } | undefined;
4138
+ "substrate-assets"?: Record<string, never> | undefined;
4139
+ "substrate-psp22"?: Record<string, never> | undefined;
4140
+ "substrate-tokens"?: {
4141
+ palletId?: string | undefined;
4142
+ } | undefined;
4143
+ "substrate-foreignassets"?: Record<string, never> | undefined;
4144
+ "substrate-hydration"?: Record<string, never> | undefined;
4145
+ "substrate-dtao"?: Record<string, never> | undefined;
4146
+ } | undefined;
4147
+ }>;
4148
+ }
4149
+
4150
+ declare const isNetworkCustom: (network: Network) => boolean;
4151
+ declare const isNetworkKnown: (network: Network) => boolean;
4152
+ declare const isTokenCustom: (token: Token) => boolean;
4153
+ declare const isTokenKnown: (token: Token) => boolean;
4154
+ declare const isTokenTestnet: (token: Token) => boolean;
4155
+ declare const getCleanNetwork: (network: Network) => Network;
4156
+ declare const getCleanToken: (token: Token) => Token;
4157
+
4158
+ type KNOWN_TOKEN_ID = "uniswap";
4159
+ declare const getGithubTokenLogoUrl: (tokenId: KNOWN_TOKEN_ID) => string;
4160
+ /**
4161
+ * Use only if you are sure this token is supported by Talisman or the url might 404
4162
+ * @param coingeckoId
4163
+ * @returns
4164
+ */
4165
+ declare const getGithubTokenLogoUrlByCoingeckoId: (coingeckoId: string) => string;
4166
+
4167
+ export { type AnyMiniMetadata, AnyMiniMetadataSchema, type BlockExplorerQuery, type Chaindata, ChaindataFileSchema, ChaindataProvider, type ChaindataProviderOptions, type ChaindataStorage, type CustomChaindata, CustomChaindataSchema, type DotNetwork, type DotNetworkBalancesConfig, DotNetworkBalancesConfigSchema, type DotNetworkId, type DotNetworkList, DotNetworkSchema, DotNetworkTopologySchema, type DotToken, type EthNetwork, type EthNetworkBalancesConfig, EthNetworkBalancesConfigSchema, type EthNetworkId, type EthNetworkList, EthNetworkSchema, type EthToken, type EthereumAddress, EthereumAddressSchema, type EvmErc20BalancesConfig, EvmErc20BalancesConfigSchema, type EvmErc20Token, type EvmErc20TokenIdSpecs, EvmErc20TokenSchema, type EvmNativeBalancesConfig, EvmNativeBalancesConfigSchema, type EvmNativeToken, type EvmNativeTokenIdSpecs, EvmNativeTokenSchema, type EvmUniswapV2BalancesConfig, EvmUniswapV2BalancesConfigSchema, type EvmUniswapV2Token, type EvmUniswapV2TokenIdSpecs, EvmUniswapV2TokenSchema, type ForeignAssetsTokenIdSpecs, type HexString, HexStringSchema, type IChaindataNetworkProvider, type IChaindataProvider, type IChaindataTokenProvider, type LegacyChain, type LegacyChainId, type LegacyCustomChain, type LegacyCustomEvmNetwork, type LegacyEvmNetwork, type LegacyEvmNetworkId, MINIMETADATA_VERSION, type NativeToken, type NativeTokenType, type Network, type NetworkBase, NetworkBaseSchema, type NetworkId, type NetworkList, type NetworkOfPlatform, type NetworkPlatform, NetworkSchema, type SolNativeBalancesConfig, SolNativeBalancesConfigSchema, type SolNativeToken, type SolNativeTokenIdSpecs, SolNativeTokenSchema, type SolNetwork, type SolNetworkBalancesConfig, SolNetworkBalancesConfigSchema, type SolNetworkId, type SolNetworkList, SolNetworkSchema, type SolSplBalancesConfig, SolSplBalancesConfigSchema, type SolSplToken, type SolSplTokenIdSpecs, SolSplTokenSchema, type SolToken, type SolanaAddress, SolanaAddressSchema, type SubAssetTokenIdSpecs, type SubAssetsBalancesConfig, SubAssetsBalancesConfigSchema, type SubAssetsToken, SubAssetsTokenSchema, type SubDTaoBalancesConfig, SubDTaoBalancesConfigSchema, type SubDTaoToken, type SubDTaoTokenIdSpecs, SubDTaoTokenSchema, type SubForeignAssetsBalancesConfig, SubForeignAssetsBalancesConfigSchema, type SubForeignAssetsToken, SubForeignAssetsTokenSchema, type SubHydrationBalancesConfig, SubHydrationBalancesConfigSchema, type SubHydrationToken, type SubHydrationTokenIdSpecs, SubHydrationTokenSchema, type SubNativeBalancesConfig, SubNativeBalancesConfigSchema, type SubNativeToken, type SubNativeTokenIdSpecs, SubNativeTokenSchema, type SubPsp22BalancesConfig, SubPsp22BalancesConfigSchema, type SubPsp22Token, type SubPsp22TokenIdSpecs, SubPsp22TokenSchema, type SubTokensBalancesConfig, SubTokensBalancesConfigSchema, type SubTokensToken, type SubTokensTokenIdSpecs, SubTokensTokenSchema, TOKEN_TYPE$5 as TOKEN_TYPE, type Token, type TokenBase, TokenBaseSchema, type TokenId, type TokenIdSpecs, type TokenList, type TokenOfPlatform, type TokenOfType, TokenSchema, TokenSchemaBase, type TokenType, TokenTypeSchema, evmErc20TokenId, evmNativeTokenId, evmUniswapV2TokenId, getBlockExplorerLabel, getBlockExplorerUrls, getChaindataDbV3, getCleanNetwork, getCleanToken, getGithubTokenLogoUrl, getGithubTokenLogoUrlByCoingeckoId, getNetworkGenesisHash, isNativeToken, isNativeTokenType, isNetworkCustom, isNetworkDot, isNetworkEth, isNetworkInPlatforms, isNetworkKnown, isNetworkOfPlatform, isNetworkSol, isTokenCustom, isTokenDot, isTokenEth, isTokenEvmErc20, isTokenEvmNative, isTokenEvmUniswapV2, isTokenInTypes, isTokenKnown, isTokenNeedExistentialDeposit, isTokenOfPlatform, isTokenOfType, isTokenSol, isTokenSolSpl, isTokenSubAssets, isTokenSubDTao, isTokenSubForeignAssets, isTokenSubHydration, isTokenSubNative, isTokenSubPsp22, isTokenSubTokens, isTokenTestnet, networkIdFromTokenId, parseEvmErc20TokenId, parseEvmNativeTokenId, parseEvmUniswapV2TokenId, parseSolNativeTokenId, parseSolSplTokenId, parseSubAssetTokenId, parseSubDTaoTokenId, parseSubForeignAssetTokenId, parseSubHydrationTokenId, parseSubNativeTokenId, parseSubPsp22TokenId, parseSubTokensTokenId, parseTokenId, solNativeTokenId, solSplTokenId, subAssetTokenId, subDTaoTokenId, subForeignAssetTokenId, subHydrationTokenId, subNativeTokenId, subPsp22TokenId, subTokensTokenId };