@paraspell/sdk 12.4.0 → 12.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.mjs +4 -3
  2. package/package.json +10 -10
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { getEvmPrivateKeyHex, NumberFormatError, createClientCache, createClientPoolHelpers, isConfig, getChainProviders, InvalidAddressError, BatchMode, findNativeAssetInfoOrThrow, MissingChainApiError, isExternalChain, Parents, Version, findAssetInfoOrThrow, computeFeeFromDryRun, hasXcmPaymentApiSupport, replaceBigInt, getAssetsObject, RuntimeApiUnavailableError, wrapTxBypass, assertHasLocation, localizeLocation, isAssetXcEqual, addXcmVersionHeader, RELAY_LOCATION, getRelayChainOf, padValueBy, isRelayChain, isAssetEqual, createChainClient as createChainClient$1, getBalance as getBalance$1, claimAssets as claimAssets$1, Foreign, ForeignAbstract, Native, Override, findAssetInfo, getAllAssetsSymbols, getAssetDecimals, getAssetId, getAssets, getExistentialDeposit, getNativeAssetSymbol, getNativeAssets, getOtherAssets, getRelayChainSymbol, getSupportedAssets, getTChain, hasSupportForAsset, isChainEvm, convertSs58 as convertSs58$1, transferMoonbeamEvm, validateAddress, transferMoonbeamToEth, Builder as Builder$1, handleSwapExecuteTransfer as handleSwapExecuteTransfer$1, getParaEthTransferFees as getParaEthTransferFees$1, getBridgeStatus as getBridgeStatus$1, getXcmFee as getXcmFee$1, send as send$1, dryRun as dryRun$1, dryRunOrigin as dryRunOrigin$1, getOriginXcmFee as getOriginXcmFee$1 } from '@paraspell/sdk-core';
1
+ import { getEvmPrivateKeyHex, NumberFormatError, createClientCache, createClientPoolHelpers, isConfig, getChainProviders, InvalidAddressError, BatchMode, findNativeAssetInfoOrThrow, MissingChainApiError, isExternalChain, Parents, Version, findAssetInfoOrThrow, computeFeeFromDryRun, hasXcmPaymentApiSupport, replaceBigInt, getAssetsObject, RuntimeApiUnavailableError, wrapTxBypass, assertHasLocation, localizeLocation, isAssetXcEqual, addXcmVersionHeader, RELAY_LOCATION, getRelayChainOf, isRelayChain, padValueBy, isAssetEqual, createChainClient as createChainClient$1, getBalance as getBalance$1, claimAssets as claimAssets$1, Foreign, ForeignAbstract, Native, Override, findAssetInfo, getAllAssetsSymbols, getAssetDecimals, getAssetId, getAssets, getExistentialDeposit, getNativeAssetSymbol, getNativeAssets, getOtherAssets, getRelayChainSymbol, getSupportedAssets, getTChain, hasSupportForAsset, isChainEvm, convertSs58 as convertSs58$1, transferMoonbeamEvm, validateAddress, transferMoonbeamToEth, Builder as Builder$1, handleSwapExecuteTransfer as handleSwapExecuteTransfer$1, getBridgeStatus as getBridgeStatus$1, getParaEthTransferFees as getParaEthTransferFees$1, getXcmFee as getXcmFee$1, send as send$1, dryRun as dryRun$1, dryRunOrigin as dryRunOrigin$1, getOriginXcmFee as getOriginXcmFee$1 } from '@paraspell/sdk-core';
2
2
  export * from '@paraspell/sdk-core';
3
3
  import { secp256k1 } from '@noble/curves/secp256k1.js';
4
4
  import { keccak_256 } from '@noble/hashes/sha3.js';
@@ -1019,7 +1019,7 @@ var PapiApi = /*#__PURE__*/function () {
1019
1019
  value: function () {
1020
1020
  var _getDryRunCall = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee10(options) {
1021
1021
  var _this = this;
1022
- var tx, chain, destination, address, feeAsset, bypassOptions, _options$useRootOrigi, useRootOrigin, supportsDryRunApi, DEFAULT_XCM_VERSION, basePayload, resolvedTx, performDryRunCall, getExecutionSuccessFromResult, findFailureObjectFromResult, extractFailureReasonFromResult, result, isSuccess, failureOutputReason, initialFailureReason, resolvedFeeAsset, actualWeight, weight, forwardedXcms, destParaId, hasLocation, getPaymentInfoWeight, overriddenWeight, xcmFee, executionFee, fee, _t2, _t3;
1022
+ var tx, chain, destination, address, feeAsset, bypassOptions, _options$useRootOrigi, useRootOrigin, supportsDryRunApi, DEFAULT_XCM_VERSION, basePayload, resolvedTx, performDryRunCall, getExecutionSuccessFromResult, findFailureObjectFromResult, extractFailureReasonFromResult, result, isSuccess, failureOutputReason, initialFailureReason, resolvedFeeAsset, actualWeight, weight, forwardedXcms, destParaId, hasLocation, USE_XCM_PAYMENT_API_CHAINS, getPaymentInfoWeight, overriddenWeight, xcmFee, executionFee, fee, _t2, _t3;
1023
1023
  return _regenerator().w(function (_context10) {
1024
1024
  while (1) switch (_context10.n) {
1025
1025
  case 0:
@@ -1177,7 +1177,8 @@ var PapiApi = /*#__PURE__*/function () {
1177
1177
  forwardedXcms = result.value.forwarded_xcms.length > 0 ? result.value.forwarded_xcms[0] : [];
1178
1178
  destParaId = forwardedXcms.length === 0 ? undefined : forwardedXcms[0].value.interior.type === 'Here' ? 0 : forwardedXcms[0].value.interior.value.value;
1179
1179
  hasLocation = resolvedFeeAsset.asset.location;
1180
- if (!(hasXcmPaymentApiSupport(chain) && result.value.local_xcm && hasLocation && (feeAsset || chain.startsWith('AssetHub') && destination === 'Ethereum') || resolvedFeeAsset.isCustomAsset)) {
1180
+ USE_XCM_PAYMENT_API_CHAINS = ['Astar'];
1181
+ if (!(hasXcmPaymentApiSupport(chain) && result.value.local_xcm && hasLocation && (feeAsset || USE_XCM_PAYMENT_API_CHAINS.includes(chain) || chain.startsWith('AssetHub') && destination === 'Ethereum') || resolvedFeeAsset.isCustomAsset)) {
1181
1182
  _context10.n = 15;
1182
1183
  break;
1183
1184
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@paraspell/sdk",
3
- "version": "12.4.0",
3
+ "version": "12.5.1",
4
4
  "description": "SDK for ParaSpell XCM/XCMP tool for developers",
5
5
  "repository": {
6
6
  "type": "git",
@@ -24,19 +24,19 @@
24
24
  ],
25
25
  "dependencies": {
26
26
  "@noble/hashes": "^2.0.1",
27
- "@polkadot-api/legacy-provider": "^0.3.6",
27
+ "@polkadot-api/legacy-provider": "^0.3.8",
28
28
  "@polkadot-labs/hdkd": "^0.0.26",
29
29
  "@polkadot-labs/hdkd-helpers": "^0.0.27",
30
- "viem": "2.40.3",
31
- "@paraspell/sdk-core": "12.4.0"
30
+ "viem": "2.45.0",
31
+ "@paraspell/sdk-core": "12.5.1"
32
32
  },
33
33
  "peerDependencies": {
34
- "polkadot-api": ">= 1.23.1 < 2"
34
+ "polkadot-api": ">= 1.23.3 < 2"
35
35
  },
36
36
  "devDependencies": {
37
37
  "@acala-network/chopsticks": "^1.2.5",
38
- "@babel/plugin-syntax-import-attributes": "^7.27.1",
39
- "@babel/preset-env": "^7.28.5",
38
+ "@babel/plugin-syntax-import-attributes": "^7.28.6",
39
+ "@babel/preset-env": "^7.28.6",
40
40
  "@codecov/rollup-plugin": "^1.9.1",
41
41
  "@noble/curves": "^2.0.1",
42
42
  "@rollup/plugin-babel": "^6.1.0",
@@ -44,10 +44,10 @@
44
44
  "@rollup/plugin-typescript": "^12.3.0",
45
45
  "@scure/bip32": "^2.0.1",
46
46
  "@scure/bip39": "^2.0.1",
47
- "@vitest/coverage-v8": "^4.0.16",
48
- "axios": "^1.13.2",
47
+ "@vitest/coverage-v8": "^4.0.18",
48
+ "axios": "^1.13.4",
49
49
  "dotenv": "^17.2.3",
50
- "rollup": "^4.54.0",
50
+ "rollup": "^4.57.0",
51
51
  "rollup-plugin-dts": "^6.3.0",
52
52
  "tslib": "^2.8.1"
53
53
  },