@paraspell/sdk 10.10.11 → 10.11.0

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 CHANGED
@@ -71,15 +71,16 @@ import { Native, Foreign, ForeignAbstract } from '@paraspell/sdk'; //Only needed
71
71
  ```
72
72
  NOTES:
73
73
  - Local transfers are now available for every currency and every chain. To try them, simply use the same origin and destination parameters.
74
+ - Transfer info queries are now all in the Builder pattern and don't require any imports other than the builder.
75
+ - You can now query Ethereum asset balances on Ethereum via balance query
74
76
  ```
75
77
 
76
78
  ```
77
79
  Latest news:
78
- - Transfer info queries are now all in the Builder pattern and don't require any imports other than the builder.
79
- - You can now query Ethereum asset balances on Ethereum via balance query
80
+ - The Builder() now accepts an optional configuration object (To enhance localhost experience and testing). This object can contain apiOverrides and a development flag. More information in the "Localhost test setup" section.
80
81
  ```
81
82
 
82
- ### Sending XCM:
83
+ ### Sending XCM
83
84
 
84
85
  For full documentation with examples on this feature head over to [official documentation](https://paraspell.github.io/docs/sdk/xcmPallet.html).
85
86
 
@@ -271,6 +272,30 @@ import { hasDryRunSupport } from "@paraspell/sdk-pjs";
271
272
  const result = hasDryRunSupport(node)
272
273
  ```
273
274
 
275
+ ### Localhost test setup
276
+
277
+ SDK offers enhanced localhost support. You can pass an object containing overrides for all WS endpoints (Including hops) used in the test transfer. This allows for advanced localhost testing such as localhost dry-run or xcm-fee queries. More information about available options can be found in the [official documentation](https://paraspell.github.io/docs/sdk/xcmPallet.html#localhost-testing-setup).
278
+
279
+ ```ts
280
+ const builder = await Builder({
281
+ development: true, // Optional: Enforces overrides for all chains used
282
+ apiOverrides: {
283
+ Hydration: // "wsEndpointString" | papiClient
284
+ BridgeHubPolkadot: // "wsEndpointString" | papiClient
285
+ //ChainName: ...
286
+ }
287
+ })
288
+ .from(CHAIN)
289
+ .to(CHAIN)
290
+ .currency({id: currencyID, amount: amount} | {symbol: currencySymbol, amount: amount} | {symbol: Native('currencySymbol'), amount: amount} | {symbol: Foreign('currencySymbol'), amount: amount} | {symbol: ForeignAbstract('currencySymbol'), amount: amount} | {multilocation: AssetMultilocationString, amount: amount | AssetMultilocationJson, amount: amount} | {multilocation: Override('Custom Multilocation'), amount: amount} | {multiasset: {currencySelection /* for example symbol: symbol or id: id, or multilocation: multilocation*/, amount: amount}})
291
+ .address(address)
292
+
293
+ const tx = await builder.build()
294
+
295
+ //Disconnect API after TX
296
+ await builder.disconnect()
297
+ ```
298
+
274
299
  ### XCM Fee queries
275
300
 
276
301
  For full documentation with examples on this feature, head to [official documentation](https://paraspell.github.io/docs/sdk/xcmUtils.html).
@@ -392,7 +417,7 @@ import { convertSs58 } from "@paraspell/sdk";
392
417
  let result = convertSs58(address, node) // returns converted address in string
393
418
  ```
394
419
 
395
- ### Asset queries:
420
+ ### Asset queries
396
421
 
397
422
  For full documentation with examples on this feature, head over to [official documentation](https://paraspell.github.io/docs/sdk/AssetPallet.html).
398
423
 
@@ -475,6 +500,10 @@ console.log(SUPPORTED_PALLETS)
475
500
 
476
501
  XCM SDK can be tested in [Playground](https://playground.paraspell.xyz/xcm-sdk/xcm-transfer).
477
502
 
503
+ ## Contribute to XCM Tools and earn rewards 💰
504
+
505
+ We run an open Bug Bounty Program that rewards contributors for reporting and fixing bugs in the project. More information on bug bounty can be found in the [official documentation](https://paraspell.github.io/docs/contribution.html).
506
+
478
507
  ## Get Support 🚑
479
508
 
480
509
  - Contact form on our [landing page](https://paraspell.xyz/#contact-us).