@dedot/chaintypes 0.0.1-alpha.22
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/LICENSE +201 -0
- package/README.md +3 -0
- package/aleph/consts.d.ts +533 -0
- package/aleph/consts.js +2 -0
- package/aleph/errors.d.ts +822 -0
- package/aleph/errors.js +2 -0
- package/aleph/events.d.ts +997 -0
- package/aleph/events.js +2 -0
- package/aleph/index.d.ts +19 -0
- package/aleph/index.js +3 -0
- package/aleph/query.d.ts +1271 -0
- package/aleph/query.js +2 -0
- package/aleph/rpc.d.ts +575 -0
- package/aleph/rpc.js +2 -0
- package/aleph/runtime.d.ts +410 -0
- package/aleph/runtime.js +2 -0
- package/aleph/tx.d.ts +2206 -0
- package/aleph/tx.js +2 -0
- package/aleph/types.d.ts +5560 -0
- package/aleph/types.js +2 -0
- package/astar/consts.d.ts +679 -0
- package/astar/consts.js +2 -0
- package/astar/errors.d.ts +1317 -0
- package/astar/errors.js +2 -0
- package/astar/events.d.ts +1707 -0
- package/astar/events.js +2 -0
- package/astar/index.d.ts +19 -0
- package/astar/index.js +3 -0
- package/astar/query.d.ts +1474 -0
- package/astar/query.js +2 -0
- package/astar/rpc.d.ts +775 -0
- package/astar/rpc.js +2 -0
- package/astar/runtime.d.ts +262 -0
- package/astar/runtime.js +2 -0
- package/astar/tx.d.ts +4810 -0
- package/astar/tx.js +2 -0
- package/astar/types.d.ts +12338 -0
- package/astar/types.js +2 -0
- package/cjs/aleph/consts.js +3 -0
- package/cjs/aleph/errors.js +3 -0
- package/cjs/aleph/events.js +3 -0
- package/cjs/aleph/index.js +19 -0
- package/cjs/aleph/query.js +3 -0
- package/cjs/aleph/rpc.js +3 -0
- package/cjs/aleph/runtime.js +3 -0
- package/cjs/aleph/tx.js +3 -0
- package/cjs/aleph/types.js +3 -0
- package/cjs/astar/consts.js +3 -0
- package/cjs/astar/errors.js +3 -0
- package/cjs/astar/events.js +3 -0
- package/cjs/astar/index.js +19 -0
- package/cjs/astar/query.js +3 -0
- package/cjs/astar/rpc.js +3 -0
- package/cjs/astar/runtime.js +3 -0
- package/cjs/astar/tx.js +3 -0
- package/cjs/astar/types.js +3 -0
- package/cjs/index.js +2 -0
- package/cjs/kusama/consts.js +3 -0
- package/cjs/kusama/errors.js +3 -0
- package/cjs/kusama/events.js +3 -0
- package/cjs/kusama/index.js +19 -0
- package/cjs/kusama/query.js +3 -0
- package/cjs/kusama/rpc.js +3 -0
- package/cjs/kusama/runtime.js +3 -0
- package/cjs/kusama/tx.js +3 -0
- package/cjs/kusama/types.js +3 -0
- package/cjs/kusamaAssetHub/consts.js +3 -0
- package/cjs/kusamaAssetHub/errors.js +3 -0
- package/cjs/kusamaAssetHub/events.js +3 -0
- package/cjs/kusamaAssetHub/index.js +19 -0
- package/cjs/kusamaAssetHub/query.js +3 -0
- package/cjs/kusamaAssetHub/rpc.js +3 -0
- package/cjs/kusamaAssetHub/runtime.js +3 -0
- package/cjs/kusamaAssetHub/tx.js +3 -0
- package/cjs/kusamaAssetHub/types.js +3 -0
- package/cjs/moonbeam/consts.js +3 -0
- package/cjs/moonbeam/errors.js +3 -0
- package/cjs/moonbeam/events.js +3 -0
- package/cjs/moonbeam/index.js +19 -0
- package/cjs/moonbeam/query.js +3 -0
- package/cjs/moonbeam/rpc.js +3 -0
- package/cjs/moonbeam/runtime.js +3 -0
- package/cjs/moonbeam/tx.js +3 -0
- package/cjs/moonbeam/types.js +3 -0
- package/cjs/package.json +1 -0
- package/cjs/packageInfo.js +5 -0
- package/cjs/polkadot/consts.js +3 -0
- package/cjs/polkadot/errors.js +3 -0
- package/cjs/polkadot/events.js +3 -0
- package/cjs/polkadot/index.js +19 -0
- package/cjs/polkadot/query.js +3 -0
- package/cjs/polkadot/rpc.js +3 -0
- package/cjs/polkadot/runtime.js +3 -0
- package/cjs/polkadot/tx.js +3 -0
- package/cjs/polkadot/types.js +3 -0
- package/cjs/polkadotAssetHub/consts.js +3 -0
- package/cjs/polkadotAssetHub/errors.js +3 -0
- package/cjs/polkadotAssetHub/events.js +3 -0
- package/cjs/polkadotAssetHub/index.js +19 -0
- package/cjs/polkadotAssetHub/query.js +3 -0
- package/cjs/polkadotAssetHub/rpc.js +3 -0
- package/cjs/polkadotAssetHub/runtime.js +3 -0
- package/cjs/polkadotAssetHub/tx.js +3 -0
- package/cjs/polkadotAssetHub/types.js +3 -0
- package/cjs/rococoAssetHub/consts.js +3 -0
- package/cjs/rococoAssetHub/errors.js +3 -0
- package/cjs/rococoAssetHub/events.js +3 -0
- package/cjs/rococoAssetHub/index.js +19 -0
- package/cjs/rococoAssetHub/query.js +3 -0
- package/cjs/rococoAssetHub/rpc.js +3 -0
- package/cjs/rococoAssetHub/runtime.js +3 -0
- package/cjs/rococoAssetHub/tx.js +3 -0
- package/cjs/rococoAssetHub/types.js +3 -0
- package/cjs/substrate/consts.js +3 -0
- package/cjs/substrate/errors.js +3 -0
- package/cjs/substrate/events.js +3 -0
- package/cjs/substrate/index.js +19 -0
- package/cjs/substrate/query.js +3 -0
- package/cjs/substrate/rpc.js +3 -0
- package/cjs/substrate/runtime.js +3 -0
- package/cjs/substrate/tx.js +3 -0
- package/cjs/substrate/types.js +3 -0
- package/cjs/westendAssetHub/consts.js +3 -0
- package/cjs/westendAssetHub/errors.js +3 -0
- package/cjs/westendAssetHub/events.js +3 -0
- package/cjs/westendAssetHub/index.js +19 -0
- package/cjs/westendAssetHub/query.js +3 -0
- package/cjs/westendAssetHub/rpc.js +3 -0
- package/cjs/westendAssetHub/runtime.js +3 -0
- package/cjs/westendAssetHub/tx.js +3 -0
- package/cjs/westendAssetHub/types.js +3 -0
- package/index.d.ts +5 -0
- package/index.js +1 -0
- package/kusama/consts.d.ts +1427 -0
- package/kusama/consts.js +2 -0
- package/kusama/errors.d.ts +2494 -0
- package/kusama/errors.js +2 -0
- package/kusama/events.d.ts +2960 -0
- package/kusama/events.js +2 -0
- package/kusama/index.d.ts +19 -0
- package/kusama/index.js +3 -0
- package/kusama/query.d.ts +3251 -0
- package/kusama/query.js +2 -0
- package/kusama/rpc.d.ts +726 -0
- package/kusama/rpc.js +2 -0
- package/kusama/runtime.d.ts +844 -0
- package/kusama/runtime.js +2 -0
- package/kusama/tx.d.ts +6014 -0
- package/kusama/tx.js +2 -0
- package/kusama/types.d.ts +15903 -0
- package/kusama/types.js +2 -0
- package/kusamaAssetHub/consts.d.ts +632 -0
- package/kusamaAssetHub/consts.js +2 -0
- package/kusamaAssetHub/errors.d.ts +1164 -0
- package/kusamaAssetHub/errors.js +2 -0
- package/kusamaAssetHub/events.d.ts +2162 -0
- package/kusamaAssetHub/events.js +2 -0
- package/kusamaAssetHub/index.d.ts +19 -0
- package/kusamaAssetHub/index.js +3 -0
- package/kusamaAssetHub/query.d.ts +1301 -0
- package/kusamaAssetHub/query.js +2 -0
- package/kusamaAssetHub/rpc.d.ts +590 -0
- package/kusamaAssetHub/rpc.js +2 -0
- package/kusamaAssetHub/runtime.d.ts +402 -0
- package/kusamaAssetHub/runtime.js +2 -0
- package/kusamaAssetHub/tx.d.ts +4217 -0
- package/kusamaAssetHub/tx.js +2 -0
- package/kusamaAssetHub/types.d.ts +10418 -0
- package/kusamaAssetHub/types.js +2 -0
- package/moonbeam/consts.d.ts +961 -0
- package/moonbeam/consts.js +2 -0
- package/moonbeam/errors.d.ts +1797 -0
- package/moonbeam/errors.js +2 -0
- package/moonbeam/events.d.ts +2840 -0
- package/moonbeam/events.js +2 -0
- package/moonbeam/index.d.ts +19 -0
- package/moonbeam/index.js +3 -0
- package/moonbeam/query.d.ts +2027 -0
- package/moonbeam/query.js +2 -0
- package/moonbeam/rpc.d.ts +809 -0
- package/moonbeam/rpc.js +2 -0
- package/moonbeam/runtime.d.ts +506 -0
- package/moonbeam/runtime.js +2 -0
- package/moonbeam/tx.d.ts +5205 -0
- package/moonbeam/tx.js +2 -0
- package/moonbeam/types.d.ts +12349 -0
- package/moonbeam/types.js +2 -0
- package/package.json +33 -0
- package/packageInfo.d.ts +4 -0
- package/packageInfo.js +3 -0
- package/polkadot/consts.d.ts +1160 -0
- package/polkadot/consts.js +2 -0
- package/polkadot/errors.d.ts +2020 -0
- package/polkadot/errors.js +2 -0
- package/polkadot/events.d.ts +2235 -0
- package/polkadot/events.js +2 -0
- package/polkadot/index.d.ts +19 -0
- package/polkadot/index.js +3 -0
- package/polkadot/query.d.ts +2811 -0
- package/polkadot/query.js +2 -0
- package/polkadot/rpc.d.ts +726 -0
- package/polkadot/rpc.js +2 -0
- package/polkadot/runtime.d.ts +844 -0
- package/polkadot/runtime.js +2 -0
- package/polkadot/tx.d.ts +5009 -0
- package/polkadot/tx.js +2 -0
- package/polkadot/types.d.ts +13729 -0
- package/polkadot/types.js +2 -0
- package/polkadotAssetHub/consts.d.ts +524 -0
- package/polkadotAssetHub/consts.js +2 -0
- package/polkadotAssetHub/errors.d.ts +925 -0
- package/polkadotAssetHub/errors.js +2 -0
- package/polkadotAssetHub/events.d.ts +1787 -0
- package/polkadotAssetHub/events.js +2 -0
- package/polkadotAssetHub/index.d.ts +19 -0
- package/polkadotAssetHub/index.js +3 -0
- package/polkadotAssetHub/query.d.ts +1222 -0
- package/polkadotAssetHub/query.js +2 -0
- package/polkadotAssetHub/rpc.d.ts +590 -0
- package/polkadotAssetHub/rpc.js +2 -0
- package/polkadotAssetHub/runtime.d.ts +359 -0
- package/polkadotAssetHub/runtime.js +2 -0
- package/polkadotAssetHub/tx.d.ts +3492 -0
- package/polkadotAssetHub/tx.js +2 -0
- package/polkadotAssetHub/types.d.ts +9164 -0
- package/polkadotAssetHub/types.js +2 -0
- package/rococoAssetHub/consts.d.ts +658 -0
- package/rococoAssetHub/consts.js +2 -0
- package/rococoAssetHub/errors.d.ts +1231 -0
- package/rococoAssetHub/errors.js +2 -0
- package/rococoAssetHub/events.d.ts +2172 -0
- package/rococoAssetHub/events.js +2 -0
- package/rococoAssetHub/index.d.ts +19 -0
- package/rococoAssetHub/index.js +3 -0
- package/rococoAssetHub/query.d.ts +1269 -0
- package/rococoAssetHub/query.js +2 -0
- package/rococoAssetHub/rpc.d.ts +590 -0
- package/rococoAssetHub/rpc.js +2 -0
- package/rococoAssetHub/runtime.d.ts +428 -0
- package/rococoAssetHub/runtime.js +2 -0
- package/rococoAssetHub/tx.d.ts +4307 -0
- package/rococoAssetHub/tx.js +2 -0
- package/rococoAssetHub/types.d.ts +11066 -0
- package/rococoAssetHub/types.js +2 -0
- package/substrate/consts.d.ts +1971 -0
- package/substrate/consts.js +2 -0
- package/substrate/errors.d.ts +3337 -0
- package/substrate/errors.js +2 -0
- package/substrate/events.d.ts +4777 -0
- package/substrate/events.js +2 -0
- package/substrate/index.d.ts +19 -0
- package/substrate/index.js +3 -0
- package/substrate/query.d.ts +3350 -0
- package/substrate/query.js +2 -0
- package/substrate/rpc.d.ts +718 -0
- package/substrate/rpc.js +2 -0
- package/substrate/runtime.d.ts +708 -0
- package/substrate/runtime.js +2 -0
- package/substrate/tx.d.ts +8800 -0
- package/substrate/tx.js +2 -0
- package/substrate/types.d.ts +20332 -0
- package/substrate/types.js +2 -0
- package/westendAssetHub/consts.d.ts +658 -0
- package/westendAssetHub/consts.js +2 -0
- package/westendAssetHub/errors.d.ts +1231 -0
- package/westendAssetHub/errors.js +2 -0
- package/westendAssetHub/events.d.ts +2172 -0
- package/westendAssetHub/events.js +2 -0
- package/westendAssetHub/index.d.ts +19 -0
- package/westendAssetHub/index.js +3 -0
- package/westendAssetHub/query.d.ts +1269 -0
- package/westendAssetHub/query.js +2 -0
- package/westendAssetHub/rpc.d.ts +590 -0
- package/westendAssetHub/rpc.js +2 -0
- package/westendAssetHub/runtime.d.ts +456 -0
- package/westendAssetHub/runtime.js +2 -0
- package/westendAssetHub/tx.d.ts +4307 -0
- package/westendAssetHub/tx.js +2 -0
- package/westendAssetHub/types.d.ts +11062 -0
- package/westendAssetHub/types.js +2 -0
|
@@ -0,0 +1,410 @@
|
|
|
1
|
+
import type { GenericRuntimeApis, GenericRuntimeApiMethod } from '@dedot/types';
|
|
2
|
+
import type { RuntimeVersion, Header, DispatchError, Result, UncheckedExtrinsicLike, UncheckedExtrinsic, H256, Bytes, BytesLike, AccountId32Like } from '@dedot/codecs';
|
|
3
|
+
import type { SpRuntimeBlock, SpCoreOpaqueMetadata, SpRuntimeTransactionValidityTransactionValidityError, SpInherentsInherentData, SpInherentsCheckInherentsResult, SpRuntimeTransactionValidityValidTransaction, SpRuntimeTransactionValidityTransactionSource, SpConsensusSlotsSlotDuration, SpConsensusAuraSr25519AppSr25519Public, SpCoreCryptoKeyTypeId, PalletTransactionPaymentRuntimeDispatchInfo, PalletTransactionPaymentFeeDetails, SpWeightsWeightV2Weight, PrimitivesAppPublic, PrimitivesApiError, PrimitivesSessionAuthorityData, PrimitivesSessionCommittee, PrimitivesSessionValidatorError, PalletContractsPrimitivesContractResult, PalletContractsPrimitivesContractResultResult, PalletContractsPrimitivesCode, PalletContractsPrimitivesCodeUploadReturnValue, PalletContractsWasmDeterminism, PalletContractsPrimitivesContractAccessError } from './types';
|
|
4
|
+
export interface RuntimeApis extends GenericRuntimeApis {
|
|
5
|
+
/**
|
|
6
|
+
* @runtimeapi: Core - 0xdf6acb689907609b
|
|
7
|
+
**/
|
|
8
|
+
core: {
|
|
9
|
+
/**
|
|
10
|
+
* Returns the version of the runtime.
|
|
11
|
+
*
|
|
12
|
+
* @callname: Core_version
|
|
13
|
+
**/
|
|
14
|
+
version: GenericRuntimeApiMethod<() => Promise<RuntimeVersion>>;
|
|
15
|
+
/**
|
|
16
|
+
* Execute the given block.
|
|
17
|
+
*
|
|
18
|
+
* @callname: Core_execute_block
|
|
19
|
+
* @param {SpRuntimeBlock} block
|
|
20
|
+
**/
|
|
21
|
+
executeBlock: GenericRuntimeApiMethod<(block: SpRuntimeBlock) => Promise<[]>>;
|
|
22
|
+
/**
|
|
23
|
+
* Initialize a block with the given header.
|
|
24
|
+
*
|
|
25
|
+
* @callname: Core_initialize_block
|
|
26
|
+
* @param {Header} header
|
|
27
|
+
**/
|
|
28
|
+
initializeBlock: GenericRuntimeApiMethod<(header: Header) => Promise<[]>>;
|
|
29
|
+
/**
|
|
30
|
+
* Generic runtime api call
|
|
31
|
+
**/
|
|
32
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* @runtimeapi: Metadata - 0x37e397fc7c91f5e4
|
|
36
|
+
**/
|
|
37
|
+
metadata: {
|
|
38
|
+
/**
|
|
39
|
+
* Returns the metadata of a runtime.
|
|
40
|
+
*
|
|
41
|
+
* @callname: Metadata_metadata
|
|
42
|
+
**/
|
|
43
|
+
metadata: GenericRuntimeApiMethod<() => Promise<SpCoreOpaqueMetadata>>;
|
|
44
|
+
/**
|
|
45
|
+
* Returns the metadata at a given version.
|
|
46
|
+
*
|
|
47
|
+
* If the given `version` isn't supported, this will return `None`.
|
|
48
|
+
* Use [`Self::metadata_versions`] to find out about supported metadata version of the runtime.
|
|
49
|
+
*
|
|
50
|
+
* @callname: Metadata_metadata_at_version
|
|
51
|
+
* @param {number} version
|
|
52
|
+
**/
|
|
53
|
+
metadataAtVersion: GenericRuntimeApiMethod<(version: number) => Promise<SpCoreOpaqueMetadata | undefined>>;
|
|
54
|
+
/**
|
|
55
|
+
* Returns the supported metadata versions.
|
|
56
|
+
*
|
|
57
|
+
* This can be used to call `metadata_at_version`.
|
|
58
|
+
*
|
|
59
|
+
* @callname: Metadata_metadata_versions
|
|
60
|
+
**/
|
|
61
|
+
metadataVersions: GenericRuntimeApiMethod<() => Promise<Array<number>>>;
|
|
62
|
+
/**
|
|
63
|
+
* Generic runtime api call
|
|
64
|
+
**/
|
|
65
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
66
|
+
};
|
|
67
|
+
/**
|
|
68
|
+
* @runtimeapi: BlockBuilder - 0x40fe3ad401f8959a
|
|
69
|
+
**/
|
|
70
|
+
blockBuilder: {
|
|
71
|
+
/**
|
|
72
|
+
* Apply the given extrinsic.
|
|
73
|
+
*
|
|
74
|
+
* Returns an inclusion outcome which specifies if this extrinsic is included in
|
|
75
|
+
* this block or not.
|
|
76
|
+
*
|
|
77
|
+
* @callname: BlockBuilder_apply_extrinsic
|
|
78
|
+
* @param {UncheckedExtrinsicLike} extrinsic
|
|
79
|
+
**/
|
|
80
|
+
applyExtrinsic: GenericRuntimeApiMethod<(extrinsic: UncheckedExtrinsicLike) => Promise<Result<Result<[], DispatchError>, SpRuntimeTransactionValidityTransactionValidityError>>>;
|
|
81
|
+
/**
|
|
82
|
+
* Finish the current block.
|
|
83
|
+
*
|
|
84
|
+
* @callname: BlockBuilder_finalize_block
|
|
85
|
+
**/
|
|
86
|
+
finalizeBlock: GenericRuntimeApiMethod<() => Promise<Header>>;
|
|
87
|
+
/**
|
|
88
|
+
* Generate inherent extrinsics. The inherent data will vary from chain to chain.
|
|
89
|
+
*
|
|
90
|
+
* @callname: BlockBuilder_inherent_extrinsics
|
|
91
|
+
* @param {SpInherentsInherentData} inherent
|
|
92
|
+
**/
|
|
93
|
+
inherentExtrinsics: GenericRuntimeApiMethod<(inherent: SpInherentsInherentData) => Promise<Array<UncheckedExtrinsic>>>;
|
|
94
|
+
/**
|
|
95
|
+
* Check that the inherents are valid. The inherent data will vary from chain to chain.
|
|
96
|
+
*
|
|
97
|
+
* @callname: BlockBuilder_check_inherents
|
|
98
|
+
* @param {SpRuntimeBlock} block
|
|
99
|
+
* @param {SpInherentsInherentData} data
|
|
100
|
+
**/
|
|
101
|
+
checkInherents: GenericRuntimeApiMethod<(block: SpRuntimeBlock, data: SpInherentsInherentData) => Promise<SpInherentsCheckInherentsResult>>;
|
|
102
|
+
/**
|
|
103
|
+
* Generic runtime api call
|
|
104
|
+
**/
|
|
105
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
106
|
+
};
|
|
107
|
+
/**
|
|
108
|
+
* @runtimeapi: TaggedTransactionQueue - 0xd2bc9897eed08f15
|
|
109
|
+
**/
|
|
110
|
+
taggedTransactionQueue: {
|
|
111
|
+
/**
|
|
112
|
+
* Validate the transaction.
|
|
113
|
+
*
|
|
114
|
+
* This method is invoked by the transaction pool to learn details about given transaction.
|
|
115
|
+
* The implementation should make sure to verify the correctness of the transaction
|
|
116
|
+
* against current state. The given `block_hash` corresponds to the hash of the block
|
|
117
|
+
* that is used as current state.
|
|
118
|
+
*
|
|
119
|
+
* Note that this call may be performed by the pool multiple times and transactions
|
|
120
|
+
* might be verified in any possible order.
|
|
121
|
+
*
|
|
122
|
+
* @callname: TaggedTransactionQueue_validate_transaction
|
|
123
|
+
* @param {SpRuntimeTransactionValidityTransactionSource} source
|
|
124
|
+
* @param {UncheckedExtrinsicLike} tx
|
|
125
|
+
* @param {H256} block_hash
|
|
126
|
+
**/
|
|
127
|
+
validateTransaction: GenericRuntimeApiMethod<(source: SpRuntimeTransactionValidityTransactionSource, tx: UncheckedExtrinsicLike, blockHash: H256) => Promise<Result<SpRuntimeTransactionValidityValidTransaction, SpRuntimeTransactionValidityTransactionValidityError>>>;
|
|
128
|
+
/**
|
|
129
|
+
* Generic runtime api call
|
|
130
|
+
**/
|
|
131
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
132
|
+
};
|
|
133
|
+
/**
|
|
134
|
+
* @runtimeapi: AuraApi - 0xdd718d5cc53262d4
|
|
135
|
+
**/
|
|
136
|
+
auraApi: {
|
|
137
|
+
/**
|
|
138
|
+
* Returns the slot duration for Aura.
|
|
139
|
+
*
|
|
140
|
+
* Currently, only the value provided by this type at genesis will be used.
|
|
141
|
+
*
|
|
142
|
+
* @callname: AuraApi_slot_duration
|
|
143
|
+
**/
|
|
144
|
+
slotDuration: GenericRuntimeApiMethod<() => Promise<SpConsensusSlotsSlotDuration>>;
|
|
145
|
+
/**
|
|
146
|
+
* Return the current set of authorities.
|
|
147
|
+
*
|
|
148
|
+
* @callname: AuraApi_authorities
|
|
149
|
+
**/
|
|
150
|
+
authorities: GenericRuntimeApiMethod<() => Promise<Array<SpConsensusAuraSr25519AppSr25519Public>>>;
|
|
151
|
+
/**
|
|
152
|
+
* Generic runtime api call
|
|
153
|
+
**/
|
|
154
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
155
|
+
};
|
|
156
|
+
/**
|
|
157
|
+
* @runtimeapi: OffchainWorkerApi - 0xf78b278be53f454c
|
|
158
|
+
**/
|
|
159
|
+
offchainWorkerApi: {
|
|
160
|
+
/**
|
|
161
|
+
* Starts the off-chain task for given block header.
|
|
162
|
+
*
|
|
163
|
+
* @callname: OffchainWorkerApi_offchain_worker
|
|
164
|
+
* @param {Header} header
|
|
165
|
+
**/
|
|
166
|
+
offchainWorker: GenericRuntimeApiMethod<(header: Header) => Promise<[]>>;
|
|
167
|
+
/**
|
|
168
|
+
* Generic runtime api call
|
|
169
|
+
**/
|
|
170
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
171
|
+
};
|
|
172
|
+
/**
|
|
173
|
+
* @runtimeapi: SessionKeys - 0xab3c0572291feb8b
|
|
174
|
+
**/
|
|
175
|
+
sessionKeys: {
|
|
176
|
+
/**
|
|
177
|
+
* Generate a set of session keys with optionally using the given seed.
|
|
178
|
+
* The keys should be stored within the keystore exposed via runtime
|
|
179
|
+
* externalities.
|
|
180
|
+
*
|
|
181
|
+
* The seed needs to be a valid `utf8` string.
|
|
182
|
+
*
|
|
183
|
+
* Returns the concatenated SCALE encoded public keys.
|
|
184
|
+
*
|
|
185
|
+
* @callname: SessionKeys_generate_session_keys
|
|
186
|
+
* @param {BytesLike | undefined} seed
|
|
187
|
+
**/
|
|
188
|
+
generateSessionKeys: GenericRuntimeApiMethod<(seed?: BytesLike | undefined) => Promise<Bytes>>;
|
|
189
|
+
/**
|
|
190
|
+
* Decode the given public session keys.
|
|
191
|
+
*
|
|
192
|
+
* Returns the list of public raw public keys + key type.
|
|
193
|
+
*
|
|
194
|
+
* @callname: SessionKeys_decode_session_keys
|
|
195
|
+
* @param {BytesLike} encoded
|
|
196
|
+
**/
|
|
197
|
+
decodeSessionKeys: GenericRuntimeApiMethod<(encoded: BytesLike) => Promise<Array<[Bytes, SpCoreCryptoKeyTypeId]> | undefined>>;
|
|
198
|
+
/**
|
|
199
|
+
* Generic runtime api call
|
|
200
|
+
**/
|
|
201
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
202
|
+
};
|
|
203
|
+
/**
|
|
204
|
+
* @runtimeapi: AccountNonceApi - 0xbc9d89904f5b923f
|
|
205
|
+
**/
|
|
206
|
+
accountNonceApi: {
|
|
207
|
+
/**
|
|
208
|
+
* Get current account nonce of given `AccountId`.
|
|
209
|
+
*
|
|
210
|
+
* @callname: AccountNonceApi_account_nonce
|
|
211
|
+
* @param {AccountId32Like} account
|
|
212
|
+
**/
|
|
213
|
+
accountNonce: GenericRuntimeApiMethod<(account: AccountId32Like) => Promise<number>>;
|
|
214
|
+
/**
|
|
215
|
+
* Generic runtime api call
|
|
216
|
+
**/
|
|
217
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
218
|
+
};
|
|
219
|
+
/**
|
|
220
|
+
* @runtimeapi: TransactionPaymentApi - 0x37c8bb1350a9a2a8
|
|
221
|
+
**/
|
|
222
|
+
transactionPaymentApi: {
|
|
223
|
+
/**
|
|
224
|
+
*
|
|
225
|
+
* @callname: TransactionPaymentApi_query_info
|
|
226
|
+
* @param {UncheckedExtrinsicLike} uxt
|
|
227
|
+
* @param {number} len
|
|
228
|
+
**/
|
|
229
|
+
queryInfo: GenericRuntimeApiMethod<(uxt: UncheckedExtrinsicLike, len: number) => Promise<PalletTransactionPaymentRuntimeDispatchInfo>>;
|
|
230
|
+
/**
|
|
231
|
+
*
|
|
232
|
+
* @callname: TransactionPaymentApi_query_fee_details
|
|
233
|
+
* @param {UncheckedExtrinsicLike} uxt
|
|
234
|
+
* @param {number} len
|
|
235
|
+
**/
|
|
236
|
+
queryFeeDetails: GenericRuntimeApiMethod<(uxt: UncheckedExtrinsicLike, len: number) => Promise<PalletTransactionPaymentFeeDetails>>;
|
|
237
|
+
/**
|
|
238
|
+
*
|
|
239
|
+
* @callname: TransactionPaymentApi_query_weight_to_fee
|
|
240
|
+
* @param {SpWeightsWeightV2Weight} weight
|
|
241
|
+
**/
|
|
242
|
+
queryWeightToFee: GenericRuntimeApiMethod<(weight: SpWeightsWeightV2Weight) => Promise<bigint>>;
|
|
243
|
+
/**
|
|
244
|
+
*
|
|
245
|
+
* @callname: TransactionPaymentApi_query_length_to_fee
|
|
246
|
+
* @param {number} length
|
|
247
|
+
**/
|
|
248
|
+
queryLengthToFee: GenericRuntimeApiMethod<(length: number) => Promise<bigint>>;
|
|
249
|
+
/**
|
|
250
|
+
* Generic runtime api call
|
|
251
|
+
**/
|
|
252
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
253
|
+
};
|
|
254
|
+
/**
|
|
255
|
+
* @runtimeapi: AlephSessionApi - 0x2be3f75b696ad1f6
|
|
256
|
+
**/
|
|
257
|
+
alephSessionApi: {
|
|
258
|
+
/**
|
|
259
|
+
*
|
|
260
|
+
* @callname: AlephSessionApi_next_session_authorities
|
|
261
|
+
**/
|
|
262
|
+
nextSessionAuthorities: GenericRuntimeApiMethod<() => Promise<Result<Array<PrimitivesAppPublic>, PrimitivesApiError>>>;
|
|
263
|
+
/**
|
|
264
|
+
*
|
|
265
|
+
* @callname: AlephSessionApi_authorities
|
|
266
|
+
**/
|
|
267
|
+
authorities: GenericRuntimeApiMethod<() => Promise<Array<PrimitivesAppPublic>>>;
|
|
268
|
+
/**
|
|
269
|
+
*
|
|
270
|
+
* @callname: AlephSessionApi_next_session_authority_data
|
|
271
|
+
**/
|
|
272
|
+
nextSessionAuthorityData: GenericRuntimeApiMethod<() => Promise<Result<PrimitivesSessionAuthorityData, PrimitivesApiError>>>;
|
|
273
|
+
/**
|
|
274
|
+
*
|
|
275
|
+
* @callname: AlephSessionApi_authority_data
|
|
276
|
+
**/
|
|
277
|
+
authorityData: GenericRuntimeApiMethod<() => Promise<PrimitivesSessionAuthorityData>>;
|
|
278
|
+
/**
|
|
279
|
+
*
|
|
280
|
+
* @callname: AlephSessionApi_session_period
|
|
281
|
+
**/
|
|
282
|
+
sessionPeriod: GenericRuntimeApiMethod<() => Promise<number>>;
|
|
283
|
+
/**
|
|
284
|
+
*
|
|
285
|
+
* @callname: AlephSessionApi_millisecs_per_block
|
|
286
|
+
**/
|
|
287
|
+
millisecsPerBlock: GenericRuntimeApiMethod<() => Promise<bigint>>;
|
|
288
|
+
/**
|
|
289
|
+
*
|
|
290
|
+
* @callname: AlephSessionApi_finality_version
|
|
291
|
+
**/
|
|
292
|
+
finalityVersion: GenericRuntimeApiMethod<() => Promise<number>>;
|
|
293
|
+
/**
|
|
294
|
+
*
|
|
295
|
+
* @callname: AlephSessionApi_next_session_finality_version
|
|
296
|
+
**/
|
|
297
|
+
nextSessionFinalityVersion: GenericRuntimeApiMethod<() => Promise<number>>;
|
|
298
|
+
/**
|
|
299
|
+
* Predict finality committee and block producers for the given session. `session` must be
|
|
300
|
+
* within the current era (current, in the staking context).
|
|
301
|
+
*
|
|
302
|
+
* If the active era `E` starts in the session `a`, and ends in session `b` then from
|
|
303
|
+
* session `a` to session `b-1` this function can answer question who will be in the
|
|
304
|
+
* committee in the era `E`. In the last session of the era `E` (`b`) this can be used to
|
|
305
|
+
* determine all of the sessions in the era `E+1`.
|
|
306
|
+
*
|
|
307
|
+
* @callname: AlephSessionApi_predict_session_committee
|
|
308
|
+
* @param {number} session
|
|
309
|
+
**/
|
|
310
|
+
predictSessionCommittee: GenericRuntimeApiMethod<(session: number) => Promise<Result<PrimitivesSessionCommittee, PrimitivesSessionValidatorError>>>;
|
|
311
|
+
/**
|
|
312
|
+
* Generic runtime api call
|
|
313
|
+
**/
|
|
314
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
315
|
+
};
|
|
316
|
+
/**
|
|
317
|
+
* @runtimeapi: NominationPoolsApi - 0x17a6bc0d0062aeb3
|
|
318
|
+
**/
|
|
319
|
+
nominationPoolsApi: {
|
|
320
|
+
/**
|
|
321
|
+
* Returns the pending rewards for the member that the AccountId was given for.
|
|
322
|
+
*
|
|
323
|
+
* @callname: NominationPoolsApi_pending_rewards
|
|
324
|
+
* @param {AccountId32Like} who
|
|
325
|
+
**/
|
|
326
|
+
pendingRewards: GenericRuntimeApiMethod<(who: AccountId32Like) => Promise<bigint>>;
|
|
327
|
+
/**
|
|
328
|
+
* Returns the equivalent balance of `points` for a given pool.
|
|
329
|
+
*
|
|
330
|
+
* @callname: NominationPoolsApi_points_to_balance
|
|
331
|
+
* @param {number} pool_id
|
|
332
|
+
* @param {bigint} points
|
|
333
|
+
**/
|
|
334
|
+
pointsToBalance: GenericRuntimeApiMethod<(poolId: number, points: bigint) => Promise<bigint>>;
|
|
335
|
+
/**
|
|
336
|
+
* Returns the equivalent points of `new_funds` for a given pool.
|
|
337
|
+
*
|
|
338
|
+
* @callname: NominationPoolsApi_balance_to_points
|
|
339
|
+
* @param {number} pool_id
|
|
340
|
+
* @param {bigint} new_funds
|
|
341
|
+
**/
|
|
342
|
+
balanceToPoints: GenericRuntimeApiMethod<(poolId: number, newFunds: bigint) => Promise<bigint>>;
|
|
343
|
+
/**
|
|
344
|
+
* Generic runtime api call
|
|
345
|
+
**/
|
|
346
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
347
|
+
};
|
|
348
|
+
/**
|
|
349
|
+
* @runtimeapi: ContractsApi - 0x68b66ba122c93fa7
|
|
350
|
+
**/
|
|
351
|
+
contractsApi: {
|
|
352
|
+
/**
|
|
353
|
+
* Perform a call from a specified account to a given contract.
|
|
354
|
+
*
|
|
355
|
+
* See [`crate::Pallet::bare_call`].
|
|
356
|
+
*
|
|
357
|
+
* @callname: ContractsApi_call
|
|
358
|
+
* @param {AccountId32Like} origin
|
|
359
|
+
* @param {AccountId32Like} dest
|
|
360
|
+
* @param {bigint} value
|
|
361
|
+
* @param {SpWeightsWeightV2Weight | undefined} gas_limit
|
|
362
|
+
* @param {bigint | undefined} storage_deposit_limit
|
|
363
|
+
* @param {BytesLike} input_data
|
|
364
|
+
**/
|
|
365
|
+
call: GenericRuntimeApiMethod<(origin: AccountId32Like, dest: AccountId32Like, value: bigint, gasLimit: SpWeightsWeightV2Weight | undefined, storageDepositLimit: bigint | undefined, inputData: BytesLike) => Promise<PalletContractsPrimitivesContractResult>>;
|
|
366
|
+
/**
|
|
367
|
+
* Instantiate a new contract.
|
|
368
|
+
*
|
|
369
|
+
* See `[crate::Pallet::bare_instantiate]`.
|
|
370
|
+
*
|
|
371
|
+
* @callname: ContractsApi_instantiate
|
|
372
|
+
* @param {AccountId32Like} origin
|
|
373
|
+
* @param {bigint} value
|
|
374
|
+
* @param {SpWeightsWeightV2Weight | undefined} gas_limit
|
|
375
|
+
* @param {bigint | undefined} storage_deposit_limit
|
|
376
|
+
* @param {PalletContractsPrimitivesCode} code
|
|
377
|
+
* @param {BytesLike} data
|
|
378
|
+
* @param {BytesLike} salt
|
|
379
|
+
**/
|
|
380
|
+
instantiate: GenericRuntimeApiMethod<(origin: AccountId32Like, value: bigint, gasLimit: SpWeightsWeightV2Weight | undefined, storageDepositLimit: bigint | undefined, code: PalletContractsPrimitivesCode, data: BytesLike, salt: BytesLike) => Promise<PalletContractsPrimitivesContractResultResult>>;
|
|
381
|
+
/**
|
|
382
|
+
* Upload new code without instantiating a contract from it.
|
|
383
|
+
*
|
|
384
|
+
* See [`crate::Pallet::bare_upload_code`].
|
|
385
|
+
*
|
|
386
|
+
* @callname: ContractsApi_upload_code
|
|
387
|
+
* @param {AccountId32Like} origin
|
|
388
|
+
* @param {BytesLike} code
|
|
389
|
+
* @param {bigint | undefined} storage_deposit_limit
|
|
390
|
+
* @param {PalletContractsWasmDeterminism} determinism
|
|
391
|
+
**/
|
|
392
|
+
uploadCode: GenericRuntimeApiMethod<(origin: AccountId32Like, code: BytesLike, storageDepositLimit: bigint | undefined, determinism: PalletContractsWasmDeterminism) => Promise<Result<PalletContractsPrimitivesCodeUploadReturnValue, DispatchError>>>;
|
|
393
|
+
/**
|
|
394
|
+
* Query a given storage key in a given contract.
|
|
395
|
+
*
|
|
396
|
+
* Returns `Ok(Some(Vec<u8>))` if the storage value exists under the given key in the
|
|
397
|
+
* specified account and `Ok(None)` if it doesn't. If the account specified by the address
|
|
398
|
+
* doesn't exist, or doesn't have a contract then `Err` is returned.
|
|
399
|
+
*
|
|
400
|
+
* @callname: ContractsApi_get_storage
|
|
401
|
+
* @param {AccountId32Like} address
|
|
402
|
+
* @param {BytesLike} key
|
|
403
|
+
**/
|
|
404
|
+
getStorage: GenericRuntimeApiMethod<(address: AccountId32Like, key: BytesLike) => Promise<Result<Bytes | undefined, PalletContractsPrimitivesContractAccessError>>>;
|
|
405
|
+
/**
|
|
406
|
+
* Generic runtime api call
|
|
407
|
+
**/
|
|
408
|
+
[method: string]: GenericRuntimeApiMethod;
|
|
409
|
+
};
|
|
410
|
+
}
|
package/aleph/runtime.js
ADDED