@dedot/chaintypes 0.12.0 → 0.14.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/astar/consts.d.ts +25 -12
- package/astar/errors.d.ts +1 -6
- package/astar/events.d.ts +0 -68
- package/astar/index.d.ts +1 -1
- package/astar/query.d.ts +18 -31
- package/astar/runtime.d.ts +151 -14
- package/astar/tx.d.ts +114 -13
- package/astar/types.d.ts +185 -121
- package/moonbeam/consts.d.ts +29 -4
- package/moonbeam/errors.d.ts +16 -11
- package/moonbeam/events.d.ts +47 -2
- package/moonbeam/index.d.ts +1 -1
- package/moonbeam/query.d.ts +38 -14
- package/moonbeam/runtime.d.ts +125 -15
- package/moonbeam/tx.d.ts +2233 -253
- package/moonbeam/types.d.ts +4110 -583
- package/package.json +2 -2
package/astar/tx.d.ts
CHANGED
|
@@ -45,6 +45,8 @@ import type {
|
|
|
45
45
|
XcmVersionedAssets,
|
|
46
46
|
StagingXcmV4Location,
|
|
47
47
|
XcmV3WeightLimit,
|
|
48
|
+
StagingXcmExecutorAssetTransferTransferType,
|
|
49
|
+
XcmVersionedAssetId,
|
|
48
50
|
XcmVersionedAsset,
|
|
49
51
|
CumulusPrimitivesCoreAggregateMessageOrigin,
|
|
50
52
|
EthereumTransactionTransactionV2,
|
|
@@ -2033,7 +2035,7 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
|
|
|
2033
2035
|
*
|
|
2034
2036
|
* This will waive the transaction fee if at least all but 10% of the accounts needed to
|
|
2035
2037
|
* be upgraded. (We let some not have to be upgraded just in order to allow for the
|
|
2036
|
-
*
|
|
2038
|
+
* possibility of churn).
|
|
2037
2039
|
*
|
|
2038
2040
|
* @param {Array<AccountId32Like>} who
|
|
2039
2041
|
**/
|
|
@@ -4392,6 +4394,26 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
|
|
|
4392
4394
|
>
|
|
4393
4395
|
>;
|
|
4394
4396
|
|
|
4397
|
+
/**
|
|
4398
|
+
* Set slash destination.
|
|
4399
|
+
* Use `Some` to deposit slashed balance into destination or `None` to burn it.
|
|
4400
|
+
*
|
|
4401
|
+
* @param {AccountId32Like | undefined} destination
|
|
4402
|
+
**/
|
|
4403
|
+
setSlashDestination: GenericTxCall<
|
|
4404
|
+
Rv,
|
|
4405
|
+
(destination: AccountId32Like | undefined) => ChainSubmittableExtrinsic<
|
|
4406
|
+
Rv,
|
|
4407
|
+
{
|
|
4408
|
+
pallet: 'CollatorSelection';
|
|
4409
|
+
palletCall: {
|
|
4410
|
+
name: 'SetSlashDestination';
|
|
4411
|
+
params: { destination: AccountId32Like | undefined };
|
|
4412
|
+
};
|
|
4413
|
+
}
|
|
4414
|
+
>
|
|
4415
|
+
>;
|
|
4416
|
+
|
|
4395
4417
|
/**
|
|
4396
4418
|
* Generic pallet tx call
|
|
4397
4419
|
**/
|
|
@@ -4863,7 +4885,7 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
|
|
|
4863
4885
|
*
|
|
4864
4886
|
* Fee payment on the destination side is made from the asset in the `assets` vector of
|
|
4865
4887
|
* index `fee_asset_item`, up to enough to pay for `weight_limit` of weight. If more weight
|
|
4866
|
-
* is needed than `weight_limit`, then the operation will fail and the assets
|
|
4888
|
+
* is needed than `weight_limit`, then the operation will fail and the sent assets may be
|
|
4867
4889
|
* at risk.
|
|
4868
4890
|
*
|
|
4869
4891
|
* - `origin`: Must be capable of withdrawing the `assets` and executing XCM.
|
|
@@ -4915,7 +4937,7 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
|
|
|
4915
4937
|
*
|
|
4916
4938
|
* Fee payment on the destination side is made from the asset in the `assets` vector of
|
|
4917
4939
|
* index `fee_asset_item`, up to enough to pay for `weight_limit` of weight. If more weight
|
|
4918
|
-
* is needed than `weight_limit`, then the operation will fail and the assets
|
|
4940
|
+
* is needed than `weight_limit`, then the operation will fail and the sent assets may be
|
|
4919
4941
|
* at risk.
|
|
4920
4942
|
*
|
|
4921
4943
|
* - `origin`: Must be capable of withdrawing the `assets` and executing XCM.
|
|
@@ -4991,7 +5013,7 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
|
|
|
4991
5013
|
* Fee payment on the destination side is made from the asset in the `assets` vector of
|
|
4992
5014
|
* index `fee_asset_item` (hence referred to as `fees`), up to enough to pay for
|
|
4993
5015
|
* `weight_limit` of weight. If more weight is needed than `weight_limit`, then the
|
|
4994
|
-
* operation will fail and the assets
|
|
5016
|
+
* operation will fail and the sent assets may be at risk.
|
|
4995
5017
|
*
|
|
4996
5018
|
* `assets` (excluding `fees`) must have same reserve location or otherwise be teleportable
|
|
4997
5019
|
* to `dest`, no limitations imposed on `fees`.
|
|
@@ -5080,23 +5102,102 @@ export interface ChainTx<Rv extends RpcVersion> extends GenericChainTx<Rv, TxCal
|
|
|
5080
5102
|
>;
|
|
5081
5103
|
|
|
5082
5104
|
/**
|
|
5083
|
-
*
|
|
5105
|
+
* Transfer assets from the local chain to the destination chain using explicit transfer
|
|
5106
|
+
* types for assets and fees.
|
|
5107
|
+
*
|
|
5108
|
+
* `assets` must have same reserve location or may be teleportable to `dest`. Caller must
|
|
5109
|
+
* provide the `assets_transfer_type` to be used for `assets`:
|
|
5110
|
+
* - `TransferType::LocalReserve`: transfer assets to sovereign account of destination
|
|
5111
|
+
* chain and forward a notification XCM to `dest` to mint and deposit reserve-based
|
|
5112
|
+
* assets to `beneficiary`.
|
|
5113
|
+
* - `TransferType::DestinationReserve`: burn local assets and forward a notification to
|
|
5114
|
+
* `dest` chain to withdraw the reserve assets from this chain's sovereign account and
|
|
5115
|
+
* deposit them to `beneficiary`.
|
|
5116
|
+
* - `TransferType::RemoteReserve(reserve)`: burn local assets, forward XCM to `reserve`
|
|
5117
|
+
* chain to move reserves from this chain's SA to `dest` chain's SA, and forward another
|
|
5118
|
+
* XCM to `dest` to mint and deposit reserve-based assets to `beneficiary`. Typically
|
|
5119
|
+
* the remote `reserve` is Asset Hub.
|
|
5120
|
+
* - `TransferType::Teleport`: burn local assets and forward XCM to `dest` chain to
|
|
5121
|
+
* mint/teleport assets and deposit them to `beneficiary`.
|
|
5122
|
+
*
|
|
5123
|
+
* On the destination chain, as well as any intermediary hops, `BuyExecution` is used to
|
|
5124
|
+
* buy execution using transferred `assets` identified by `remote_fees_id`.
|
|
5125
|
+
* Make sure enough of the specified `remote_fees_id` asset is included in the given list
|
|
5126
|
+
* of `assets`. `remote_fees_id` should be enough to pay for `weight_limit`. If more weight
|
|
5127
|
+
* is needed than `weight_limit`, then the operation will fail and the sent assets may be
|
|
5128
|
+
* at risk.
|
|
5129
|
+
*
|
|
5130
|
+
* `remote_fees_id` may use different transfer type than rest of `assets` and can be
|
|
5131
|
+
* specified through `fees_transfer_type`.
|
|
5132
|
+
*
|
|
5133
|
+
* The caller needs to specify what should happen to the transferred assets once they reach
|
|
5134
|
+
* the `dest` chain. This is done through the `custom_xcm_on_dest` parameter, which
|
|
5135
|
+
* contains the instructions to execute on `dest` as a final step.
|
|
5136
|
+
* This is usually as simple as:
|
|
5137
|
+
* `Xcm(vec![DepositAsset { assets: Wild(AllCounted(assets.len())), beneficiary }])`,
|
|
5138
|
+
* but could be something more exotic like sending the `assets` even further.
|
|
5139
|
+
*
|
|
5140
|
+
* - `origin`: Must be capable of withdrawing the `assets` and executing XCM.
|
|
5141
|
+
* - `dest`: Destination context for the assets. Will typically be `[Parent,
|
|
5142
|
+
* Parachain(..)]` to send from parachain to parachain, or `[Parachain(..)]` to send from
|
|
5143
|
+
* relay to parachain, or `(parents: 2, (GlobalConsensus(..), ..))` to send from
|
|
5144
|
+
* parachain across a bridge to another ecosystem destination.
|
|
5145
|
+
* - `assets`: The assets to be withdrawn. This should include the assets used to pay the
|
|
5146
|
+
* fee on the `dest` (and possibly reserve) chains.
|
|
5147
|
+
* - `assets_transfer_type`: The XCM `TransferType` used to transfer the `assets`.
|
|
5148
|
+
* - `remote_fees_id`: One of the included `assets` to be be used to pay fees.
|
|
5149
|
+
* - `fees_transfer_type`: The XCM `TransferType` used to transfer the `fees` assets.
|
|
5150
|
+
* - `custom_xcm_on_dest`: The XCM to be executed on `dest` chain as the last step of the
|
|
5151
|
+
* transfer, which also determines what happens to the assets on the destination chain.
|
|
5152
|
+
* - `weight_limit`: The remote-side weight limit, if any, for the XCM fee purchase.
|
|
5153
|
+
*
|
|
5154
|
+
* @param {XcmVersionedLocation} dest
|
|
5155
|
+
* @param {XcmVersionedAssets} assets
|
|
5156
|
+
* @param {StagingXcmExecutorAssetTransferTransferType} assetsTransferType
|
|
5157
|
+
* @param {XcmVersionedAssetId} remoteFeesId
|
|
5158
|
+
* @param {StagingXcmExecutorAssetTransferTransferType} feesTransferType
|
|
5159
|
+
* @param {XcmVersionedXcm} customXcmOnDest
|
|
5160
|
+
* @param {XcmV3WeightLimit} weightLimit
|
|
5084
5161
|
**/
|
|
5085
|
-
|
|
5086
|
-
|
|
5087
|
-
|
|
5088
|
-
|
|
5089
|
-
|
|
5090
|
-
|
|
5162
|
+
transferAssetsUsingTypeAndThen: GenericTxCall<
|
|
5163
|
+
Rv,
|
|
5164
|
+
(
|
|
5165
|
+
dest: XcmVersionedLocation,
|
|
5166
|
+
assets: XcmVersionedAssets,
|
|
5167
|
+
assetsTransferType: StagingXcmExecutorAssetTransferTransferType,
|
|
5168
|
+
remoteFeesId: XcmVersionedAssetId,
|
|
5169
|
+
feesTransferType: StagingXcmExecutorAssetTransferTransferType,
|
|
5170
|
+
customXcmOnDest: XcmVersionedXcm,
|
|
5171
|
+
weightLimit: XcmV3WeightLimit,
|
|
5172
|
+
) => ChainSubmittableExtrinsic<
|
|
5173
|
+
Rv,
|
|
5174
|
+
{
|
|
5175
|
+
pallet: 'PolkadotXcm';
|
|
5176
|
+
palletCall: {
|
|
5177
|
+
name: 'TransferAssetsUsingTypeAndThen';
|
|
5178
|
+
params: {
|
|
5179
|
+
dest: XcmVersionedLocation;
|
|
5180
|
+
assets: XcmVersionedAssets;
|
|
5181
|
+
assetsTransferType: StagingXcmExecutorAssetTransferTransferType;
|
|
5182
|
+
remoteFeesId: XcmVersionedAssetId;
|
|
5183
|
+
feesTransferType: StagingXcmExecutorAssetTransferTransferType;
|
|
5184
|
+
customXcmOnDest: XcmVersionedXcm;
|
|
5185
|
+
weightLimit: XcmV3WeightLimit;
|
|
5186
|
+
};
|
|
5187
|
+
};
|
|
5188
|
+
}
|
|
5189
|
+
>
|
|
5190
|
+
>;
|
|
5191
|
+
|
|
5091
5192
|
/**
|
|
5092
5193
|
* Generic pallet tx call
|
|
5093
5194
|
**/
|
|
5094
5195
|
[callName: string]: GenericTxCall<Rv, TxCall<Rv>>;
|
|
5095
5196
|
};
|
|
5096
5197
|
/**
|
|
5097
|
-
* Pallet `
|
|
5198
|
+
* Pallet `CumulusXcm`'s transaction calls
|
|
5098
5199
|
**/
|
|
5099
|
-
|
|
5200
|
+
cumulusXcm: {
|
|
5100
5201
|
/**
|
|
5101
5202
|
* Generic pallet tx call
|
|
5102
5203
|
**/
|