@paraspell/assets 12.9.4 → 12.9.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/dist/index.mjs +92 -115
- package/package.json +10 -10
package/README.md
CHANGED
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
|
|
25
25
|
## Information
|
|
26
26
|
|
|
27
|
-
This package serves as a `core` component for both `@paraspell/sdk` and `@paraspell/sdk-pjs` and is `automatically` installed as a `dependency`. The package on its own offers functionality that can be imported separately and be used in front-end applications. It allows
|
|
27
|
+
This package serves as a `core` component for both `@paraspell/sdk` and `@paraspell/sdk-pjs` and is `automatically` installed as a `dependency`. The package on its own offers functionality that can be imported separately and be used in front-end applications. It allows retrieving asset data from compatible Parachains. Users can retrieve details like `asset decimals`, `registered assets on particular Parachain`, `check if the asset is registered on Parachain`, and more.
|
|
28
28
|
|
|
29
29
|
## Implementation
|
|
30
30
|
|
|
@@ -36,7 +36,7 @@ npm install | pnpm add | yarn add @paraspell/assets
|
|
|
36
36
|
|
|
37
37
|
### Import functionality
|
|
38
38
|
|
|
39
|
-
To use this functionality you first have to import it in the following way.
|
|
39
|
+
To use this functionality, you first have to import it in the following way.
|
|
40
40
|
|
|
41
41
|
```ts
|
|
42
42
|
import { getSupportedDestinations, getSupportedAssets, getFeeAssets, getAssetsObject, getAssetId, getRelayChainSymbol, getNativeAssets, getNativeAssets, getOtherAssets, getAllAssetsSymbols, hasSupportForAsset, getAssetDecimals, getParaId, getTChain, getAssetLocation, TParachain, TRelaychain, TSubstrateChain, TExternalChain, TChain, findAssetInfo, findAssetInfoOrThrow } from '@paraspell/assets'
|
|
@@ -44,7 +44,7 @@ import { getSupportedDestinations, getSupportedAssets, getFeeAssets, getAssetsOb
|
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
### Query assets object
|
|
47
|
-
This function returns `assets object` from `assets.json` for `particular Parachain
|
|
47
|
+
This function returns `assets object` from `assets.json` for `particular Parachain`, including information about `native` and `foreign` assets. Function uses [TChain](https://paraspell.github.io/docs/sdk/AssetPallet.html#import-chains-as-types) types.
|
|
48
48
|
|
|
49
49
|
```ts
|
|
50
50
|
getAssetsObject(TChain)
|
|
@@ -213,4 +213,4 @@ Published under [MIT License](https://github.com/paraspell/xcm-tools/blob/main/p
|
|
|
213
213
|
<source media="(prefers-color-scheme: light)" srcset="https://github.com/paraspell/presskit/blob/main/logos_supporters/polkadot_kusama_w3f_standard.png">
|
|
214
214
|
<img width="750" alt="Shows a black logo in light color mode and a white one in dark color mode." src="https://github.com/paraspell/presskit/blob/main/logos_supporters/polkadot_kusama_w3f_standard.png">
|
|
215
215
|
</picture>
|
|
216
|
-
</p>
|
|
216
|
+
</p>
|
package/dist/index.mjs
CHANGED
|
@@ -7077,6 +7077,29 @@ var AssetHubPolkadot = {
|
|
|
7077
7077
|
existentialDeposit: "1",
|
|
7078
7078
|
alias: "PEPE2"
|
|
7079
7079
|
},
|
|
7080
|
+
{
|
|
7081
|
+
assetId: "50000470",
|
|
7082
|
+
symbol: "USDt",
|
|
7083
|
+
decimals: 6,
|
|
7084
|
+
location: {
|
|
7085
|
+
parents: 1,
|
|
7086
|
+
interior: {
|
|
7087
|
+
X3: [
|
|
7088
|
+
{
|
|
7089
|
+
Parachain: 1000
|
|
7090
|
+
},
|
|
7091
|
+
{
|
|
7092
|
+
PalletInstance: 50
|
|
7093
|
+
},
|
|
7094
|
+
{
|
|
7095
|
+
GeneralIndex: 50000470
|
|
7096
|
+
}
|
|
7097
|
+
]
|
|
7098
|
+
}
|
|
7099
|
+
},
|
|
7100
|
+
existentialDeposit: "10000",
|
|
7101
|
+
alias: "USDt2"
|
|
7102
|
+
},
|
|
7080
7103
|
{
|
|
7081
7104
|
assetId: "201",
|
|
7082
7105
|
symbol: "WUD",
|
|
@@ -7121,7 +7144,8 @@ var AssetHubPolkadot = {
|
|
|
7121
7144
|
}
|
|
7122
7145
|
},
|
|
7123
7146
|
existentialDeposit: "10000",
|
|
7124
|
-
isFeeAsset: true
|
|
7147
|
+
isFeeAsset: true,
|
|
7148
|
+
alias: "USDt1"
|
|
7125
7149
|
},
|
|
7126
7150
|
{
|
|
7127
7151
|
assetId: "50000028",
|
|
@@ -7996,7 +8020,8 @@ var AssetHubPolkadot = {
|
|
|
7996
8020
|
]
|
|
7997
8021
|
}
|
|
7998
8022
|
},
|
|
7999
|
-
existentialDeposit: "1"
|
|
8023
|
+
existentialDeposit: "1",
|
|
8024
|
+
alias: "XRT2"
|
|
8000
8025
|
},
|
|
8001
8026
|
{
|
|
8002
8027
|
symbol: "WBTC",
|
|
@@ -8219,6 +8244,22 @@ var AssetHubPolkadot = {
|
|
|
8219
8244
|
isFeeAsset: true,
|
|
8220
8245
|
alias: "NEURO2"
|
|
8221
8246
|
},
|
|
8247
|
+
{
|
|
8248
|
+
symbol: "XRT",
|
|
8249
|
+
decimals: 9,
|
|
8250
|
+
location: {
|
|
8251
|
+
parents: 1,
|
|
8252
|
+
interior: {
|
|
8253
|
+
X1: [
|
|
8254
|
+
{
|
|
8255
|
+
Parachain: 3388
|
|
8256
|
+
}
|
|
8257
|
+
]
|
|
8258
|
+
}
|
|
8259
|
+
},
|
|
8260
|
+
existentialDeposit: "1000",
|
|
8261
|
+
alias: "XRT1"
|
|
8262
|
+
},
|
|
8222
8263
|
{
|
|
8223
8264
|
symbol: "LINK",
|
|
8224
8265
|
decimals: 18,
|
|
@@ -8304,88 +8345,6 @@ var AssetHubPolkadot = {
|
|
|
8304
8345
|
}
|
|
8305
8346
|
]
|
|
8306
8347
|
};
|
|
8307
|
-
var Altair = {
|
|
8308
|
-
relaychainSymbol: "KSM",
|
|
8309
|
-
nativeAssetSymbol: "AIR",
|
|
8310
|
-
isEVM: false,
|
|
8311
|
-
ss58Prefix: 136,
|
|
8312
|
-
supportsDryRunApi: false,
|
|
8313
|
-
supportsXcmPaymentApi: false,
|
|
8314
|
-
assets: [
|
|
8315
|
-
{
|
|
8316
|
-
symbol: "AIR",
|
|
8317
|
-
isNative: true,
|
|
8318
|
-
decimals: 18,
|
|
8319
|
-
existentialDeposit: "1000000000000",
|
|
8320
|
-
location: {
|
|
8321
|
-
parents: 1,
|
|
8322
|
-
interior: {
|
|
8323
|
-
X1: [
|
|
8324
|
-
{
|
|
8325
|
-
Parachain: 2088
|
|
8326
|
-
}
|
|
8327
|
-
]
|
|
8328
|
-
}
|
|
8329
|
-
}
|
|
8330
|
-
},
|
|
8331
|
-
{
|
|
8332
|
-
assetId: "3",
|
|
8333
|
-
symbol: "KSM",
|
|
8334
|
-
decimals: 12,
|
|
8335
|
-
location: {
|
|
8336
|
-
parents: 1,
|
|
8337
|
-
interior: {
|
|
8338
|
-
Here: null
|
|
8339
|
-
}
|
|
8340
|
-
},
|
|
8341
|
-
existentialDeposit: "10000000000"
|
|
8342
|
-
},
|
|
8343
|
-
{
|
|
8344
|
-
assetId: "1",
|
|
8345
|
-
symbol: "USDT",
|
|
8346
|
-
decimals: 6,
|
|
8347
|
-
location: {
|
|
8348
|
-
parents: 1,
|
|
8349
|
-
interior: {
|
|
8350
|
-
X3: [
|
|
8351
|
-
{
|
|
8352
|
-
Parachain: 1000
|
|
8353
|
-
},
|
|
8354
|
-
{
|
|
8355
|
-
PalletInstance: 50
|
|
8356
|
-
},
|
|
8357
|
-
{
|
|
8358
|
-
GeneralIndex: 1984
|
|
8359
|
-
}
|
|
8360
|
-
]
|
|
8361
|
-
}
|
|
8362
|
-
},
|
|
8363
|
-
existentialDeposit: "10000"
|
|
8364
|
-
},
|
|
8365
|
-
{
|
|
8366
|
-
assetId: "2",
|
|
8367
|
-
symbol: "aUSD",
|
|
8368
|
-
decimals: 12,
|
|
8369
|
-
location: {
|
|
8370
|
-
parents: 1,
|
|
8371
|
-
interior: {
|
|
8372
|
-
X2: [
|
|
8373
|
-
{
|
|
8374
|
-
Parachain: 2000
|
|
8375
|
-
},
|
|
8376
|
-
{
|
|
8377
|
-
GeneralKey: {
|
|
8378
|
-
length: 2,
|
|
8379
|
-
data: "0x0081000000000000000000000000000000000000000000000000000000000000"
|
|
8380
|
-
}
|
|
8381
|
-
}
|
|
8382
|
-
]
|
|
8383
|
-
}
|
|
8384
|
-
},
|
|
8385
|
-
existentialDeposit: "10000000000"
|
|
8386
|
-
}
|
|
8387
|
-
]
|
|
8388
|
-
};
|
|
8389
8348
|
var Basilisk = {
|
|
8390
8349
|
relaychainSymbol: "KSM",
|
|
8391
8350
|
nativeAssetSymbol: "BSX",
|
|
@@ -10892,6 +10851,32 @@ var Jamton = {
|
|
|
10892
10851
|
}
|
|
10893
10852
|
]
|
|
10894
10853
|
};
|
|
10854
|
+
var RobonomicsPolkadot = {
|
|
10855
|
+
relaychainSymbol: "DOT",
|
|
10856
|
+
nativeAssetSymbol: "XRT",
|
|
10857
|
+
isEVM: false,
|
|
10858
|
+
ss58Prefix: 32,
|
|
10859
|
+
supportsDryRunApi: true,
|
|
10860
|
+
supportsXcmPaymentApi: true,
|
|
10861
|
+
assets: [
|
|
10862
|
+
{
|
|
10863
|
+
symbol: "XRT",
|
|
10864
|
+
isNative: true,
|
|
10865
|
+
decimals: 9,
|
|
10866
|
+
existentialDeposit: "1000",
|
|
10867
|
+
location: {
|
|
10868
|
+
parents: 1,
|
|
10869
|
+
interior: {
|
|
10870
|
+
X1: [
|
|
10871
|
+
{
|
|
10872
|
+
Parachain: 3388
|
|
10873
|
+
}
|
|
10874
|
+
]
|
|
10875
|
+
}
|
|
10876
|
+
}
|
|
10877
|
+
}
|
|
10878
|
+
]
|
|
10879
|
+
};
|
|
10895
10880
|
var PeopleKusama = {
|
|
10896
10881
|
relaychainSymbol: "KSM",
|
|
10897
10882
|
nativeAssetSymbol: "KSM",
|
|
@@ -13384,35 +13369,6 @@ var Manta = {
|
|
|
13384
13369
|
}
|
|
13385
13370
|
]
|
|
13386
13371
|
};
|
|
13387
|
-
var Nodle = {
|
|
13388
|
-
relaychainSymbol: "DOT",
|
|
13389
|
-
nativeAssetSymbol: "NODL",
|
|
13390
|
-
isEVM: false,
|
|
13391
|
-
ss58Prefix: 37,
|
|
13392
|
-
supportsDryRunApi: false,
|
|
13393
|
-
supportsXcmPaymentApi: false,
|
|
13394
|
-
assets: [
|
|
13395
|
-
{
|
|
13396
|
-
symbol: "NODL",
|
|
13397
|
-
isNative: true,
|
|
13398
|
-
decimals: 11,
|
|
13399
|
-
existentialDeposit: "10000",
|
|
13400
|
-
location: {
|
|
13401
|
-
parents: 1,
|
|
13402
|
-
interior: {
|
|
13403
|
-
X2: [
|
|
13404
|
-
{
|
|
13405
|
-
Parachain: 2026
|
|
13406
|
-
},
|
|
13407
|
-
{
|
|
13408
|
-
PalletInstance: 2
|
|
13409
|
-
}
|
|
13410
|
-
]
|
|
13411
|
-
}
|
|
13412
|
-
}
|
|
13413
|
-
}
|
|
13414
|
-
]
|
|
13415
|
-
};
|
|
13416
13372
|
var NeuroWeb = {
|
|
13417
13373
|
relaychainSymbol: "DOT",
|
|
13418
13374
|
nativeAssetSymbol: "NEURO",
|
|
@@ -16475,6 +16431,28 @@ var AssetHubPaseo = {
|
|
|
16475
16431
|
},
|
|
16476
16432
|
existentialDeposit: "100"
|
|
16477
16433
|
},
|
|
16434
|
+
{
|
|
16435
|
+
assetId: "50000688",
|
|
16436
|
+
symbol: "WUD",
|
|
16437
|
+
decimals: 18,
|
|
16438
|
+
location: {
|
|
16439
|
+
parents: 1,
|
|
16440
|
+
interior: {
|
|
16441
|
+
X3: [
|
|
16442
|
+
{
|
|
16443
|
+
Parachain: 1000
|
|
16444
|
+
},
|
|
16445
|
+
{
|
|
16446
|
+
PalletInstance: 50
|
|
16447
|
+
},
|
|
16448
|
+
{
|
|
16449
|
+
GeneralIndex: 50000688
|
|
16450
|
+
}
|
|
16451
|
+
]
|
|
16452
|
+
}
|
|
16453
|
+
},
|
|
16454
|
+
existentialDeposit: "1000000000000"
|
|
16455
|
+
},
|
|
16478
16456
|
{
|
|
16479
16457
|
assetId: "27",
|
|
16480
16458
|
symbol: "USDC",
|
|
@@ -19170,7 +19148,6 @@ var assetsMapJson = {
|
|
|
19170
19148
|
Heima: Heima,
|
|
19171
19149
|
Moonbeam: Moonbeam,
|
|
19172
19150
|
AssetHubPolkadot: AssetHubPolkadot,
|
|
19173
|
-
Altair: Altair,
|
|
19174
19151
|
Basilisk: Basilisk,
|
|
19175
19152
|
BifrostKusama: BifrostKusama,
|
|
19176
19153
|
Crab: Crab,
|
|
@@ -19182,6 +19159,7 @@ var assetsMapJson = {
|
|
|
19182
19159
|
Moonriver: Moonriver,
|
|
19183
19160
|
Quartz: Quartz,
|
|
19184
19161
|
Jamton: Jamton,
|
|
19162
|
+
RobonomicsPolkadot: RobonomicsPolkadot,
|
|
19185
19163
|
PeopleKusama: PeopleKusama,
|
|
19186
19164
|
PeoplePolkadot: PeoplePolkadot,
|
|
19187
19165
|
Shiden: Shiden,
|
|
@@ -19191,7 +19169,6 @@ var assetsMapJson = {
|
|
|
19191
19169
|
Unique: Unique,
|
|
19192
19170
|
Crust: Crust,
|
|
19193
19171
|
Manta: Manta,
|
|
19194
|
-
Nodle: Nodle,
|
|
19195
19172
|
NeuroWeb: NeuroWeb,
|
|
19196
19173
|
Pendulum: Pendulum,
|
|
19197
19174
|
Zeitgeist: Zeitgeist,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@paraspell/assets",
|
|
3
|
-
"version": "12.9.
|
|
3
|
+
"version": "12.9.6",
|
|
4
4
|
"description": "Assets for ParaSpell XCM/XCMP tool for developers",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -23,24 +23,24 @@
|
|
|
23
23
|
"dist"
|
|
24
24
|
],
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@paraspell/sdk-common": "12.9.
|
|
26
|
+
"@paraspell/sdk-common": "12.9.6"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"@babel/plugin-syntax-import-attributes": "^7.28.6",
|
|
30
|
-
"@babel/preset-env": "^7.29.
|
|
30
|
+
"@babel/preset-env": "^7.29.2",
|
|
31
31
|
"@codecov/rollup-plugin": "^1.9.1",
|
|
32
|
-
"@polkadot/api": "^16.5.
|
|
33
|
-
"@polkadot/types": "^16.5.
|
|
34
|
-
"@rollup/plugin-babel": "^
|
|
32
|
+
"@polkadot/api": "^16.5.6",
|
|
33
|
+
"@polkadot/types": "^16.5.6",
|
|
34
|
+
"@rollup/plugin-babel": "^7.0.0",
|
|
35
35
|
"@rollup/plugin-json": "^6.1.0",
|
|
36
36
|
"@rollup/plugin-typescript": "^12.3.0",
|
|
37
37
|
"@snowbridge/registry": "^0.4.4",
|
|
38
|
-
"@vitest/coverage-v8": "^4.
|
|
38
|
+
"@vitest/coverage-v8": "^4.1.2",
|
|
39
39
|
"dotenv": "^17.3.1",
|
|
40
|
-
"rollup": "^4.
|
|
41
|
-
"rollup-plugin-dts": "^6.
|
|
40
|
+
"rollup": "^4.60.1",
|
|
41
|
+
"rollup-plugin-dts": "^6.4.1",
|
|
42
42
|
"ts-node": "^10.9.2",
|
|
43
|
-
"viem": "
|
|
43
|
+
"viem": "2.47.1"
|
|
44
44
|
},
|
|
45
45
|
"scripts": {
|
|
46
46
|
"compile": "tsc --noEmit",
|