@polkadot/api-augment 10.1.4 → 10.2.2

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.
@@ -10,9 +10,9 @@ import type { AuthorityId } from '@polkadot/types/interfaces/consensus';
10
10
  import type { Extrinsic } from '@polkadot/types/interfaces/extrinsics';
11
11
  import type { AuthorityList, GrandpaEquivocationProof, SetId } from '@polkadot/types/interfaces/grandpa';
12
12
  import type { OpaqueMetadata } from '@polkadot/types/interfaces/metadata';
13
- import type { MmrBatchProof, MmrEncodableOpaqueLeaf, MmrError, MmrLeafIndex, MmrProof } from '@polkadot/types/interfaces/mmr';
13
+ import type { MmrBatchProof, MmrEncodableOpaqueLeaf, MmrError } from '@polkadot/types/interfaces/mmr';
14
14
  import type { NpPoolId } from '@polkadot/types/interfaces/nompools';
15
- import type { CandidateCommitments, CandidateEvent, CommittedCandidateReceipt, CoreState, GroupRotationInfo, InboundDownwardMessage, InboundHrmpMessage, OccupiedCoreAssumption, ParaId, ParaValidatorIndex, PersistedValidationData, PvfCheckStatement, ScrapedOnChainVotes, SessionInfo, ValidationCode, ValidationCodeHash, ValidatorSignature } from '@polkadot/types/interfaces/parachains';
15
+ import type { CandidateCommitments, CandidateEvent, CandidateHash, CommittedCandidateReceipt, CoreState, DisputeState, ExecutorParams, GroupRotationInfo, InboundDownwardMessage, InboundHrmpMessage, OccupiedCoreAssumption, ParaId, ParaValidatorIndex, PersistedValidationData, PvfCheckStatement, ScrapedOnChainVotes, SessionInfo, ValidationCode, ValidationCodeHash, ValidatorSignature } from '@polkadot/types/interfaces/parachains';
16
16
  import type { FeeDetails, RuntimeDispatchInfo } from '@polkadot/types/interfaces/payment';
17
17
  import type { AccountId, Balance, Block, BlockNumber, Call, Hash, Header, Index, KeyTypeId, Slot, ValidatorId, Weight } from '@polkadot/types/interfaces/runtime';
18
18
  import type { SessionIndex } from '@polkadot/types/interfaces/session';
@@ -192,12 +192,20 @@ declare module '@polkadot/api-base/types/calls' {
192
192
  **/
193
193
  [key: string]: DecoratedCallBase<ApiType>;
194
194
  };
195
- /** 0x37e397fc7c91f5e4/1 */
195
+ /** 0x37e397fc7c91f5e4/2 */
196
196
  metadata: {
197
197
  /**
198
198
  * Returns the metadata of a runtime
199
199
  **/
200
200
  metadata: AugmentedCall<ApiType, () => Observable<OpaqueMetadata>>;
201
+ /**
202
+ * Returns the metadata at a given version.
203
+ **/
204
+ metadataAtVersion: AugmentedCall<ApiType, (version: u32 | AnyNumber | Uint8Array) => Observable<Option<OpaqueMetadata>>>;
205
+ /**
206
+ * Returns the supported metadata versions.
207
+ **/
208
+ metadataVersions: AugmentedCall<ApiType, () => Observable<Vec<u32>>>;
201
209
  /**
202
210
  * Generic call
203
211
  **/
@@ -206,46 +214,26 @@ declare module '@polkadot/api-base/types/calls' {
206
214
  /** 0x91d5df18b0d2cf58/2 */
207
215
  mmrApi: {
208
216
  /**
209
- * Generate MMR proof for a series of leaves under given indices.
210
- **/
211
- generateBatchProof: AugmentedCall<ApiType, (leafIndices: Vec<MmrLeafIndex> | (MmrLeafIndex | AnyNumber | Uint8Array)[]) => Observable<Result<ITuple<[Vec<MmrEncodableOpaqueLeaf>, MmrBatchProof]>, MmrError>>>;
212
- /**
213
- * Generate MMR proof for a leaf under given index.
217
+ * Generate MMR proof for the given block numbers.
214
218
  **/
215
- generateProof: AugmentedCall<ApiType, (leafIndex: MmrLeafIndex | AnyNumber | Uint8Array) => Observable<Result<ITuple<[MmrEncodableOpaqueLeaf, MmrProof]>, MmrError>>>;
219
+ generateProof: AugmentedCall<ApiType, (blockNumbers: Vec<BlockNumber> | (BlockNumber | AnyNumber | Uint8Array)[], bestKnownBlockNumber: Option<BlockNumber> | null | Uint8Array | BlockNumber | AnyNumber) => Observable<Result<ITuple<[Vec<MmrEncodableOpaqueLeaf>, MmrBatchProof]>, MmrError>>>;
216
220
  /**
217
221
  * Return the on-chain MMR root hash.
218
222
  **/
219
- mmrRoot: AugmentedCall<ApiType, () => Observable<Result<Hash, MmrError>>>;
220
- /**
221
- * Verify MMR proof against on-chain MMR for a batch of leaves.
222
- **/
223
- verifyBatchProof: AugmentedCall<ApiType, (leaves: Vec<MmrEncodableOpaqueLeaf> | (MmrEncodableOpaqueLeaf | string | Uint8Array)[], proof: MmrBatchProof | {
224
- leafIndices?: any;
225
- leafCount?: any;
226
- items?: any;
227
- } | string | Uint8Array) => Observable<Result<ITuple<[]>, MmrError>>>;
228
- /**
229
- * Verify MMR proof against given root hash or a batch of leaves.
230
- **/
231
- verifyBatchProofStateless: AugmentedCall<ApiType, (root: Hash | string | Uint8Array, leaves: Vec<MmrEncodableOpaqueLeaf> | (MmrEncodableOpaqueLeaf | string | Uint8Array)[], proof: MmrBatchProof | {
232
- leafIndices?: any;
233
- leafCount?: any;
234
- items?: any;
235
- } | string | Uint8Array) => Observable<Result<ITuple<[]>, MmrError>>>;
223
+ root: AugmentedCall<ApiType, () => Observable<Result<Hash, MmrError>>>;
236
224
  /**
237
225
  * Verify MMR proof against on-chain MMR.
238
226
  **/
239
- verifyProof: AugmentedCall<ApiType, (leaf: MmrEncodableOpaqueLeaf | string | Uint8Array, proof: MmrProof | {
240
- leafIndex?: any;
227
+ verifyProof: AugmentedCall<ApiType, (leaves: Vec<MmrEncodableOpaqueLeaf> | (MmrEncodableOpaqueLeaf | string | Uint8Array)[], proof: MmrBatchProof | {
228
+ leafIndices?: any;
241
229
  leafCount?: any;
242
230
  items?: any;
243
231
  } | string | Uint8Array) => Observable<Result<ITuple<[]>, MmrError>>>;
244
232
  /**
245
233
  * Verify MMR proof against given root hash.
246
234
  **/
247
- verifyProofStateless: AugmentedCall<ApiType, (root: Hash | string | Uint8Array, leaf: MmrEncodableOpaqueLeaf | string | Uint8Array, proof: MmrProof | {
248
- leafIndex?: any;
235
+ verifyProofStateless: AugmentedCall<ApiType, (root: Hash | string | Uint8Array, leaves: Vec<MmrEncodableOpaqueLeaf> | (MmrEncodableOpaqueLeaf | string | Uint8Array)[], proof: MmrBatchProof | {
236
+ leafIndices?: any;
249
237
  leafCount?: any;
250
238
  items?: any;
251
239
  } | string | Uint8Array) => Observable<Result<ITuple<[]>, MmrError>>>;
@@ -290,7 +278,7 @@ declare module '@polkadot/api-base/types/calls' {
290
278
  **/
291
279
  [key: string]: DecoratedCallBase<ApiType>;
292
280
  };
293
- /** 0xaf2c0297a23e6d3d/2 */
281
+ /** 0xaf2c0297a23e6d3d/4 */
294
282
  parachainHost: {
295
283
  /**
296
284
  * Returns the persisted validation data for the given `ParaId` along with the corresponding validation code hash.
@@ -319,6 +307,10 @@ declare module '@polkadot/api-base/types/calls' {
319
307
  processedDownwardMessages?: any;
320
308
  hrmpWatermark?: any;
321
309
  } | string | Uint8Array) => Observable<bool>>;
310
+ /**
311
+ * Returns all onchain disputes.
312
+ **/
313
+ disputes: AugmentedCall<ApiType, () => Observable<Vec<ITuple<[SessionIndex, CandidateHash, DisputeState]>>>>;
322
314
  /**
323
315
  * Get all the pending inbound messages in the downward message queue for a para.
324
316
  **/
@@ -339,6 +331,10 @@ declare module '@polkadot/api-base/types/calls' {
339
331
  * Returns code hashes of PVFs that require pre-checking by validators in the active set.
340
332
  **/
341
333
  pvfsRequirePrecheck: AugmentedCall<ApiType, () => Observable<Vec<ValidationCodeHash>>>;
334
+ /**
335
+ * Returns execution parameters for the session.
336
+ **/
337
+ sessionExecutorParams: AugmentedCall<ApiType, (sessionIndex: SessionIndex | AnyNumber | Uint8Array) => Observable<Option<ExecutorParams>>>;
342
338
  /**
343
339
  * Returns the session index expected at a child of the block.
344
340
  **/