@dedot/chaintypes 0.137.0 → 0.138.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dedot/chaintypes",
3
- "version": "0.137.0",
3
+ "version": "0.138.0",
4
4
  "description": "Types for substrate-based chains",
5
5
  "author": "Thang X. Vu <thang@dedot.dev>",
6
6
  "homepage": "https://dedot.dev",
@@ -25,7 +25,7 @@
25
25
  "directory": "dist"
26
26
  },
27
27
  "license": "Apache-2.0",
28
- "gitHead": "9a6abae5da2547728ae4ff05c047f89da82e3797",
28
+ "gitHead": "ef00a96204f31490b1d0ae84ea65e142c00e98ee",
29
29
  "module": "./index.js",
30
30
  "types": "./index.d.ts",
31
31
  "exports": {
@@ -1115,6 +1115,26 @@ export interface ChainErrors<Rv extends RpcVersion> extends GenericChainErrors<R
1115
1115
  **/
1116
1116
  [error: string]: GenericPalletError<Rv>;
1117
1117
  };
1118
+ /**
1119
+ * Pallet `Dispatcher`'s errors
1120
+ **/
1121
+ dispatcher: {
1122
+ /**
1123
+ * The EVM call execution failed. This happens when the EVM returns an exit reason
1124
+ * other than `ExitSucceed(Returned)` or `ExitSucceed(Stopped)`.
1125
+ **/
1126
+ EvmCallFailed: GenericPalletError<Rv>;
1127
+
1128
+ /**
1129
+ * The provided call is not an EVM call. This extrinsic only accepts `pallet_evm::Call::call`.
1130
+ **/
1131
+ NotEvmCall: GenericPalletError<Rv>;
1132
+
1133
+ /**
1134
+ * Generic pallet error
1135
+ **/
1136
+ [error: string]: GenericPalletError<Rv>;
1137
+ };
1118
1138
  /**
1119
1139
  * Pallet `AssetRegistry`'s errors
1120
1140
  **/
@@ -25,7 +25,7 @@ export interface VersionedPaseoHydrationApi<Rv extends RpcVersion> extends Gener
25
25
 
26
26
  /**
27
27
  * @name: PaseoHydrationApi
28
- * @specVersion: 337
28
+ * @specVersion: 338
29
29
  **/
30
30
  export interface PaseoHydrationApi {
31
31
  legacy: VersionedPaseoHydrationApi<RpcLegacy>;
@@ -52,6 +52,7 @@ import type {
52
52
  PalletStateTrieMigrationMigrationLimits,
53
53
  PalletConvictionVotingVoteVoting,
54
54
  PalletReferendaReferendumInfo,
55
+ EvmCoreErrorExitReason,
55
56
  PalletAssetRegistryAssetDetails,
56
57
  HydradxRuntimeXcmAssetLocation,
57
58
  PalletClaimsEthereumAddress,
@@ -1141,6 +1142,12 @@ export interface ChainStorage<Rv extends RpcVersion> extends GenericChainStorage
1141
1142
  **/
1142
1143
  extraGas: GenericStorageQuery<Rv, () => bigint>;
1143
1144
 
1145
+ /**
1146
+ *
1147
+ * @param {Callback<EvmCoreErrorExitReason | undefined> =} callback
1148
+ **/
1149
+ lastEvmCallExitReason: GenericStorageQuery<Rv, () => EvmCoreErrorExitReason | undefined>;
1150
+
1144
1151
  /**
1145
1152
  * Generic pallet storage query
1146
1153
  **/
@@ -5320,6 +5320,33 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
5320
5320
  >
5321
5321
  >;
5322
5322
 
5323
+ /**
5324
+ * Execute a single EVM call.
5325
+ * This extrinsic will fail if the EVM call returns any other ExitReason than `ExitSucceed(Returned)` or `ExitSucceed(Stopped)`.
5326
+ * Look the [hydradx_runtime::evm::runner::WrapRunner] implementation for details.
5327
+ *
5328
+ * Parameters:
5329
+ * - `origin`: Signed origin.
5330
+ * - `call`: presumably `pallet_evm::Call::call` as boxed `RuntimeCall`.
5331
+ *
5332
+ * Emits `EvmCallFailed` event when failed.
5333
+ *
5334
+ * @param {HydradxRuntimeRuntimeCallLike} call
5335
+ **/
5336
+ dispatchEvmCall: GenericTxCall<
5337
+ Rv,
5338
+ (call: HydradxRuntimeRuntimeCallLike) => ChainSubmittableExtrinsic<
5339
+ Rv,
5340
+ {
5341
+ pallet: 'Dispatcher';
5342
+ palletCall: {
5343
+ name: 'DispatchEvmCall';
5344
+ params: { call: HydradxRuntimeRuntimeCallLike };
5345
+ };
5346
+ }
5347
+ >
5348
+ >;
5349
+
5323
5350
  /**
5324
5351
  * Generic pallet tx call
5325
5352
  **/
@@ -7437,7 +7464,7 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
7437
7464
  * This function allows setting either fixed or dynamic fee configuration for a specific asset.
7438
7465
  *
7439
7466
  * # Arguments
7440
- * * `origin` - Root origin required
7467
+ * * `origin` - Authority origin required
7441
7468
  * * `asset_id` - The asset ID to configure
7442
7469
  * * `config` - Fee configuration (Fixed or Dynamic)
7443
7470
  *
@@ -7468,7 +7495,7 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
7468
7495
  * After removal, the asset will use the default dynamic fee parameters configured in the runtime.
7469
7496
  *
7470
7497
  * # Arguments
7471
- * * `origin` - Root origin required
7498
+ * * `origin` - Authority origin required
7472
7499
  * * `asset_id` - The asset ID to remove configuration for
7473
7500
  *
7474
7501
  * @param {number} assetId
@@ -6092,7 +6092,19 @@ export type PalletDispatcherCall =
6092
6092
  * This allows executing calls with additional weight (gas) limit.
6093
6093
  * The extra gas is not refunded, even if not used.
6094
6094
  **/
6095
- | { name: 'DispatchWithExtraGas'; params: { call: HydradxRuntimeRuntimeCall; extraGas: bigint } };
6095
+ | { name: 'DispatchWithExtraGas'; params: { call: HydradxRuntimeRuntimeCall; extraGas: bigint } }
6096
+ /**
6097
+ * Execute a single EVM call.
6098
+ * This extrinsic will fail if the EVM call returns any other ExitReason than `ExitSucceed(Returned)` or `ExitSucceed(Stopped)`.
6099
+ * Look the [hydradx_runtime::evm::runner::WrapRunner] implementation for details.
6100
+ *
6101
+ * Parameters:
6102
+ * - `origin`: Signed origin.
6103
+ * - `call`: presumably `pallet_evm::Call::call` as boxed `RuntimeCall`.
6104
+ *
6105
+ * Emits `EvmCallFailed` event when failed.
6106
+ **/
6107
+ | { name: 'DispatchEvmCall'; params: { call: HydradxRuntimeRuntimeCall } };
6096
6108
 
6097
6109
  export type PalletDispatcherCallLike =
6098
6110
  | { name: 'DispatchAsTreasury'; params: { call: HydradxRuntimeRuntimeCallLike } }
@@ -6112,7 +6124,19 @@ export type PalletDispatcherCallLike =
6112
6124
  * This allows executing calls with additional weight (gas) limit.
6113
6125
  * The extra gas is not refunded, even if not used.
6114
6126
  **/
6115
- | { name: 'DispatchWithExtraGas'; params: { call: HydradxRuntimeRuntimeCallLike; extraGas: bigint } };
6127
+ | { name: 'DispatchWithExtraGas'; params: { call: HydradxRuntimeRuntimeCallLike; extraGas: bigint } }
6128
+ /**
6129
+ * Execute a single EVM call.
6130
+ * This extrinsic will fail if the EVM call returns any other ExitReason than `ExitSucceed(Returned)` or `ExitSucceed(Stopped)`.
6131
+ * Look the [hydradx_runtime::evm::runner::WrapRunner] implementation for details.
6132
+ *
6133
+ * Parameters:
6134
+ * - `origin`: Signed origin.
6135
+ * - `call`: presumably `pallet_evm::Call::call` as boxed `RuntimeCall`.
6136
+ *
6137
+ * Emits `EvmCallFailed` event when failed.
6138
+ **/
6139
+ | { name: 'DispatchEvmCall'; params: { call: HydradxRuntimeRuntimeCallLike } };
6116
6140
 
6117
6141
  /**
6118
6142
  * Contains a variant per dispatchable extrinsic that this pallet has.
@@ -8110,7 +8134,7 @@ export type PalletDynamicFeesCall =
8110
8134
  * This function allows setting either fixed or dynamic fee configuration for a specific asset.
8111
8135
  *
8112
8136
  * # Arguments
8113
- * * `origin` - Root origin required
8137
+ * * `origin` - Authority origin required
8114
8138
  * * `asset_id` - The asset ID to configure
8115
8139
  * * `config` - Fee configuration (Fixed or Dynamic)
8116
8140
  **/
@@ -8122,7 +8146,7 @@ export type PalletDynamicFeesCall =
8122
8146
  * After removal, the asset will use the default dynamic fee parameters configured in the runtime.
8123
8147
  *
8124
8148
  * # Arguments
8125
- * * `origin` - Root origin required
8149
+ * * `origin` - Authority origin required
8126
8150
  * * `asset_id` - The asset ID to remove configuration for
8127
8151
  **/
8128
8152
  | { name: 'RemoveAssetFee'; params: { assetId: number } };
@@ -8134,7 +8158,7 @@ export type PalletDynamicFeesCallLike =
8134
8158
  * This function allows setting either fixed or dynamic fee configuration for a specific asset.
8135
8159
  *
8136
8160
  * # Arguments
8137
- * * `origin` - Root origin required
8161
+ * * `origin` - Authority origin required
8138
8162
  * * `asset_id` - The asset ID to configure
8139
8163
  * * `config` - Fee configuration (Fixed or Dynamic)
8140
8164
  **/
@@ -8146,7 +8170,7 @@ export type PalletDynamicFeesCallLike =
8146
8170
  * After removal, the asset will use the default dynamic fee parameters configured in the runtime.
8147
8171
  *
8148
8172
  * # Arguments
8149
- * * `origin` - Root origin required
8173
+ * * `origin` - Authority origin required
8150
8174
  * * `asset_id` - The asset ID to remove configuration for
8151
8175
  **/
8152
8176
  | { name: 'RemoveAssetFee'; params: { assetId: number } };
@@ -17290,6 +17314,20 @@ export type PalletWhitelistError =
17290
17314
  **/
17291
17315
  | 'CallAlreadyWhitelisted';
17292
17316
 
17317
+ /**
17318
+ * The `Error` enum of this pallet.
17319
+ **/
17320
+ export type PalletDispatcherError =
17321
+ /**
17322
+ * The EVM call execution failed. This happens when the EVM returns an exit reason
17323
+ * other than `ExitSucceed(Returned)` or `ExitSucceed(Stopped)`.
17324
+ **/
17325
+ | 'EvmCallFailed'
17326
+ /**
17327
+ * The provided call is not an EVM call. This extrinsic only accepts `pallet_evm::Call::call`.
17328
+ **/
17329
+ | 'NotEvmCall';
17330
+
17293
17331
  export type PalletAssetRegistryAssetDetails = {
17294
17332
  name?: Bytes | undefined;
17295
17333
  assetType: PalletAssetRegistryAssetType;
@@ -20011,6 +20049,7 @@ export type HydradxRuntimeRuntimeError =
20011
20049
  | { pallet: 'ConvictionVoting'; palletError: PalletConvictionVotingError }
20012
20050
  | { pallet: 'Referenda'; palletError: PalletReferendaError }
20013
20051
  | { pallet: 'Whitelist'; palletError: PalletWhitelistError }
20052
+ | { pallet: 'Dispatcher'; palletError: PalletDispatcherError }
20014
20053
  | { pallet: 'AssetRegistry'; palletError: PalletAssetRegistryError }
20015
20054
  | { pallet: 'Claims'; palletError: PalletClaimsError }
20016
20055
  | { pallet: 'CollatorRewards'; palletError: PalletCollatorRewardsError }