@polkadot/api-augment 8.10.1 → 8.11.3

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.
@@ -0,0 +1,309 @@
1
+ import type { ApiTypes, AugmentedCall, DecoratedCallBase } from '@polkadot/api-base/types';
2
+ import type { Bytes, Null, Option, Result, Vec, u32, u64 } from '@polkadot/types-codec';
3
+ import type { AnyNumber, ITuple } from '@polkadot/types-codec/types';
4
+ import type { BabeEquivocationProof, BabeGenesisConfiguration, Epoch, OpaqueKeyOwnershipProof } from '@polkadot/types/interfaces/babe';
5
+ import type { CheckInherentsResult, InherentData } from '@polkadot/types/interfaces/blockbuilder';
6
+ import type { BlockHash } from '@polkadot/types/interfaces/chain';
7
+ import type { AuthorityId } from '@polkadot/types/interfaces/consensus';
8
+ import type { CodeUploadResult, ContractExecResult, ContractInstantiateResult } from '@polkadot/types/interfaces/contracts';
9
+ import type { Extrinsic } from '@polkadot/types/interfaces/extrinsics';
10
+ import type { AuthorityList, GrandpaEquivocationProof, SetId } from '@polkadot/types/interfaces/grandpa';
11
+ import type { OpaqueMetadata } from '@polkadot/types/interfaces/metadata';
12
+ import type { MmrBatchProof, MmrEncodableOpaqueLeaf, MmrError, MmrLeafIndex, MmrProof } from '@polkadot/types/interfaces/mmr';
13
+ import type { FeeDetails, RuntimeDispatchInfo } from '@polkadot/types/interfaces/payment';
14
+ import type { AccountId, Balance, Block, Hash, Header, Index, KeyTypeId, Slot } from '@polkadot/types/interfaces/runtime';
15
+ import type { RuntimeVersion } from '@polkadot/types/interfaces/state';
16
+ import type { ApplyExtrinsicResult } from '@polkadot/types/interfaces/system';
17
+ import type { TransactionSource, TransactionValidity } from '@polkadot/types/interfaces/txqueue';
18
+ import type { IExtrinsic, Observable } from '@polkadot/types/types';
19
+ export declare type __AugmentedCall<ApiType extends ApiTypes> = AugmentedCall<ApiType>;
20
+ export declare type __DecoratedCallBase<ApiType extends ApiTypes> = DecoratedCallBase<ApiType>;
21
+ declare module '@polkadot/api-base/types/calls' {
22
+ interface AugmentedCalls<ApiType extends ApiTypes> {
23
+ /** 0xbc9d89904f5b923f/1 */
24
+ accountNonceApi: {
25
+ /**
26
+ * The API to query account nonce (aka transaction index)
27
+ **/
28
+ accountNonce: AugmentedCall<ApiType, (accountId: AccountId | string | Uint8Array) => Observable<Index>>;
29
+ /**
30
+ * Generic call
31
+ **/
32
+ [key: string]: DecoratedCallBase<ApiType>;
33
+ };
34
+ /** 0x687ad44ad37f03c2/1 */
35
+ authorityDiscoveryApi: {
36
+ /**
37
+ * Retrieve authority identifiers of the current and next authority set.
38
+ **/
39
+ authorities: AugmentedCall<ApiType, () => Observable<Vec<AuthorityId>>>;
40
+ /**
41
+ * Generic call
42
+ **/
43
+ [key: string]: DecoratedCallBase<ApiType>;
44
+ };
45
+ /** 0xcbca25e39f142387/2 */
46
+ babeApi: {
47
+ /**
48
+ * Return the genesis configuration for BABE. The configuration is only read on genesis.
49
+ **/
50
+ configuration: AugmentedCall<ApiType, () => Observable<BabeGenesisConfiguration>>;
51
+ /**
52
+ * Returns information regarding the current epoch.
53
+ **/
54
+ currentEpoch: AugmentedCall<ApiType, () => Observable<Epoch>>;
55
+ /**
56
+ * Returns the slot that started the current epoch.
57
+ **/
58
+ currentEpochStart: AugmentedCall<ApiType, () => Observable<Slot>>;
59
+ /**
60
+ * Generates a proof of key ownership for the given authority in the current epoch.
61
+ **/
62
+ generateKeyOwnershipProof: AugmentedCall<ApiType, (slot: Slot | AnyNumber | Uint8Array, authorityId: AuthorityId | string | Uint8Array) => Observable<Option<OpaqueKeyOwnershipProof>>>;
63
+ /**
64
+ * Returns information regarding the next epoch (which was already previously announced).
65
+ **/
66
+ nextEpoch: AugmentedCall<ApiType, () => Observable<Epoch>>;
67
+ /**
68
+ * Submits an unsigned extrinsic to report an equivocation.
69
+ **/
70
+ submitReportEquivocationUnsignedExtrinsic: AugmentedCall<ApiType, (equivocationProof: BabeEquivocationProof | {
71
+ offender?: any;
72
+ slotNumber?: any;
73
+ firstHeader?: any;
74
+ secondHeader?: any;
75
+ } | string | Uint8Array, keyOwnerProof: OpaqueKeyOwnershipProof | string | Uint8Array) => Observable<Option<Null>>>;
76
+ /**
77
+ * Generic call
78
+ **/
79
+ [key: string]: DecoratedCallBase<ApiType>;
80
+ };
81
+ /** 0x40fe3ad401f8959a/6 */
82
+ blockBuilder: {
83
+ /**
84
+ * Apply the given extrinsic.
85
+ **/
86
+ applyExtrinsic: AugmentedCall<ApiType, (extrinsic: Extrinsic | IExtrinsic | string | Uint8Array) => Observable<ApplyExtrinsicResult>>;
87
+ /**
88
+ * Check that the inherents are valid.
89
+ **/
90
+ checkInherents: AugmentedCall<ApiType, (block: Block | {
91
+ header?: any;
92
+ extrinsics?: any;
93
+ } | string | Uint8Array, data: InherentData | {
94
+ data?: any;
95
+ } | string | Uint8Array) => Observable<CheckInherentsResult>>;
96
+ /**
97
+ * Finish the current block.
98
+ **/
99
+ finalizeBlock: AugmentedCall<ApiType, () => Observable<Header>>;
100
+ /**
101
+ * Generate inherent extrinsics.
102
+ **/
103
+ inherentExtrinsics: AugmentedCall<ApiType, (inherent: InherentData | {
104
+ data?: any;
105
+ } | string | Uint8Array) => Observable<Vec<Extrinsic>>>;
106
+ /**
107
+ * Generic call
108
+ **/
109
+ [key: string]: DecoratedCallBase<ApiType>;
110
+ };
111
+ /** 0x68b66ba122c93fa7/1 */
112
+ contractsApi: {
113
+ /**
114
+ * Perform a call from a specified account to a given contract.
115
+ **/
116
+ call: AugmentedCall<ApiType, (origin: AccountId | string | Uint8Array, dest: AccountId | string | Uint8Array, value: Balance | AnyNumber | Uint8Array, gasLimit: u64 | AnyNumber | Uint8Array, storageDepositLimit: Option<Balance> | null | object | string | Uint8Array, inputData: Bytes | string | Uint8Array) => Observable<ContractExecResult>>;
117
+ /**
118
+ * Query a given storage key in a given contract.
119
+ **/
120
+ getStorage: AugmentedCall<ApiType, (address: AccountId | string | Uint8Array, key: Bytes | string | Uint8Array) => Observable<Option<Bytes>>>;
121
+ /**
122
+ * Instantiate a new contract.
123
+ **/
124
+ instantiate: AugmentedCall<ApiType, (origin: AccountId | string | Uint8Array, value: Balance | AnyNumber | Uint8Array, gasLimit: u64 | AnyNumber | Uint8Array, storageDepositLimit: Option<Balance> | null | object | string | Uint8Array, code: Bytes | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => Observable<ContractInstantiateResult>>;
125
+ /**
126
+ * Upload new code without instantiating a contract from it.
127
+ **/
128
+ uploadCode: AugmentedCall<ApiType, (origin: AccountId | string | Uint8Array, code: Bytes | string | Uint8Array, storageDepositLimit: Option<Balance> | null | object | string | Uint8Array) => Observable<CodeUploadResult>>;
129
+ /**
130
+ * Generic call
131
+ **/
132
+ [key: string]: DecoratedCallBase<ApiType>;
133
+ };
134
+ /** 0xdf6acb689907609b/4 */
135
+ core: {
136
+ /**
137
+ * Execute the given block.
138
+ **/
139
+ executeBlock: AugmentedCall<ApiType, (block: Block | {
140
+ header?: any;
141
+ extrinsics?: any;
142
+ } | string | Uint8Array) => Observable<Null>>;
143
+ /**
144
+ * Initialize a block with the given header.
145
+ **/
146
+ initializeBlock: AugmentedCall<ApiType, (header: Header | {
147
+ parentHash?: any;
148
+ number?: any;
149
+ stateRoot?: any;
150
+ extrinsicsRoot?: any;
151
+ digest?: any;
152
+ } | string | Uint8Array) => Observable<Null>>;
153
+ /**
154
+ * Returns the version of the runtime.
155
+ **/
156
+ version: AugmentedCall<ApiType, () => Observable<RuntimeVersion>>;
157
+ /**
158
+ * Generic call
159
+ **/
160
+ [key: string]: DecoratedCallBase<ApiType>;
161
+ };
162
+ /** 0xed99c5acb25eedf5/3 */
163
+ grandpaApi: {
164
+ /**
165
+ * Get current GRANDPA authority set id.
166
+ **/
167
+ currentSetId: AugmentedCall<ApiType, () => Observable<SetId>>;
168
+ /**
169
+ * Generates a proof of key ownership for the given authority in the given set.
170
+ **/
171
+ generateKeyOwnershipProof: AugmentedCall<ApiType, (setId: SetId | AnyNumber | Uint8Array, authorityId: AuthorityId | string | Uint8Array) => Observable<Option<OpaqueKeyOwnershipProof>>>;
172
+ /**
173
+ * Get the current GRANDPA authorities and weights. This should not change except for when changes are scheduled and the corresponding delay has passed.
174
+ **/
175
+ grandpaAuthorities: AugmentedCall<ApiType, () => Observable<AuthorityList>>;
176
+ /**
177
+ * Submits an unsigned extrinsic to report an equivocation.
178
+ **/
179
+ submitReportEquivocationUnsignedExtrinsic: AugmentedCall<ApiType, (equivocationProof: GrandpaEquivocationProof | {
180
+ setId?: any;
181
+ equivocation?: any;
182
+ } | string | Uint8Array, keyOwnerProof: OpaqueKeyOwnershipProof | string | Uint8Array) => Observable<Option<Null>>>;
183
+ /**
184
+ * Generic call
185
+ **/
186
+ [key: string]: DecoratedCallBase<ApiType>;
187
+ };
188
+ /** 0x37e397fc7c91f5e4/1 */
189
+ metadata: {
190
+ /**
191
+ * Returns the metadata of a runtime
192
+ **/
193
+ metadata: AugmentedCall<ApiType, () => Observable<OpaqueMetadata>>;
194
+ /**
195
+ * Generic call
196
+ **/
197
+ [key: string]: DecoratedCallBase<ApiType>;
198
+ };
199
+ /** 0x91d5df18b0d2cf58/1 */
200
+ mmrApi: {
201
+ /**
202
+ * Generate MMR proof for a series of leaves under given indices.
203
+ **/
204
+ generateBatchProof: AugmentedCall<ApiType, (leafIndices: Vec<MmrLeafIndex> | (MmrLeafIndex | AnyNumber | Uint8Array)[]) => Observable<Result<ITuple<[Vec<MmrEncodableOpaqueLeaf>, MmrBatchProof]>, MmrError>>>;
205
+ /**
206
+ * Generate MMR proof for a leaf under given index.
207
+ **/
208
+ generateProof: AugmentedCall<ApiType, (leafIndex: MmrLeafIndex | AnyNumber | Uint8Array) => Observable<Result<ITuple<[MmrEncodableOpaqueLeaf, MmrProof]>, MmrError>>>;
209
+ /**
210
+ * Return the on-chain MMR root hash.
211
+ **/
212
+ mmrRoot: AugmentedCall<ApiType, () => Observable<Result<Hash, MmrError>>>;
213
+ /**
214
+ * Verify MMR proof against on-chain MMR for a batch of leaves.
215
+ **/
216
+ verifyBatchProof: AugmentedCall<ApiType, (leaves: Vec<MmrEncodableOpaqueLeaf> | (MmrEncodableOpaqueLeaf | string | Uint8Array)[], proof: MmrBatchProof | {
217
+ leafIndices?: any;
218
+ leafCount?: any;
219
+ items?: any;
220
+ } | string | Uint8Array) => Observable<Result<ITuple<[]>, MmrError>>>;
221
+ /**
222
+ * Verify MMR proof against given root hash or a batch of leaves.
223
+ **/
224
+ verifyBatchProofStateless: AugmentedCall<ApiType, (root: Hash | string | Uint8Array, leaves: Vec<MmrEncodableOpaqueLeaf> | (MmrEncodableOpaqueLeaf | string | Uint8Array)[], proof: MmrBatchProof | {
225
+ leafIndices?: any;
226
+ leafCount?: any;
227
+ items?: any;
228
+ } | string | Uint8Array) => Observable<Result<ITuple<[]>, MmrError>>>;
229
+ /**
230
+ * Verify MMR proof against on-chain MMR.
231
+ **/
232
+ verifyProof: AugmentedCall<ApiType, (leaf: MmrEncodableOpaqueLeaf | string | Uint8Array, proof: MmrProof | {
233
+ leafIndex?: any;
234
+ leafCount?: any;
235
+ items?: any;
236
+ } | string | Uint8Array) => Observable<Result<ITuple<[]>, MmrError>>>;
237
+ /**
238
+ * Verify MMR proof against given root hash.
239
+ **/
240
+ verifyProofStateless: AugmentedCall<ApiType, (root: Hash | string | Uint8Array, leaf: MmrEncodableOpaqueLeaf | string | Uint8Array, proof: MmrProof | {
241
+ leafIndex?: any;
242
+ leafCount?: any;
243
+ items?: any;
244
+ } | string | Uint8Array) => Observable<Result<ITuple<[]>, MmrError>>>;
245
+ /**
246
+ * Generic call
247
+ **/
248
+ [key: string]: DecoratedCallBase<ApiType>;
249
+ };
250
+ /** 0xf78b278be53f454c/2 */
251
+ offchainWorkerApi: {
252
+ /**
253
+ * Starts the off-chain task for given block header.
254
+ **/
255
+ offchainWorker: AugmentedCall<ApiType, (header: Header | {
256
+ parentHash?: any;
257
+ number?: any;
258
+ stateRoot?: any;
259
+ extrinsicsRoot?: any;
260
+ digest?: any;
261
+ } | string | Uint8Array) => Observable<Null>>;
262
+ /**
263
+ * Generic call
264
+ **/
265
+ [key: string]: DecoratedCallBase<ApiType>;
266
+ };
267
+ /** 0xab3c0572291feb8b/1 */
268
+ sessionKeys: {
269
+ /**
270
+ * Decode the given public session keys.
271
+ **/
272
+ decodeSessionKeys: AugmentedCall<ApiType, (encoded: Bytes | string | Uint8Array) => Observable<Option<Vec<ITuple<[Bytes, KeyTypeId]>>>>>;
273
+ /**
274
+ * Generate a set of session keys with optionally using the given seed.
275
+ **/
276
+ generateSessionKeys: AugmentedCall<ApiType, (seed: Option<Bytes> | null | object | string | Uint8Array) => Observable<Bytes>>;
277
+ /**
278
+ * Generic call
279
+ **/
280
+ [key: string]: DecoratedCallBase<ApiType>;
281
+ };
282
+ /** 0xd2bc9897eed08f15/3 */
283
+ taggedTransactionQueue: {
284
+ /**
285
+ * Validate the transaction.
286
+ **/
287
+ validateTransaction: AugmentedCall<ApiType, (source: TransactionSource | 'InBlock' | 'Local' | 'External' | number | Uint8Array, tx: Extrinsic | IExtrinsic | string | Uint8Array, blockHash: BlockHash | string | Uint8Array) => Observable<TransactionValidity>>;
288
+ /**
289
+ * Generic call
290
+ **/
291
+ [key: string]: DecoratedCallBase<ApiType>;
292
+ };
293
+ /** 0x37c8bb1350a9a2a8/1 */
294
+ transactionPaymentApi: {
295
+ /**
296
+ * The transaction fee details
297
+ **/
298
+ queryFeeDetails: AugmentedCall<ApiType, (uxt: Extrinsic | IExtrinsic | string | Uint8Array, len: u32 | AnyNumber | Uint8Array) => Observable<FeeDetails>>;
299
+ /**
300
+ * The transaction info
301
+ **/
302
+ queryInfo: AugmentedCall<ApiType, (uxt: Extrinsic | IExtrinsic | string | Uint8Array, len: u32 | AnyNumber | Uint8Array) => Observable<RuntimeDispatchInfo>>;
303
+ /**
304
+ * Generic call
305
+ **/
306
+ [key: string]: DecoratedCallBase<ApiType>;
307
+ };
308
+ }
309
+ }
@@ -0,0 +1 @@
1
+ export {};
package/substrate/tx.d.ts CHANGED
@@ -1,9 +1,12 @@
1
- import type { ApiTypes } from '@polkadot/api-base/types';
1
+ import type { ApiTypes, AugmentedSubmittable, SubmittableExtrinsic, SubmittableExtrinsicFunction } from '@polkadot/api-base/types';
2
2
  import type { Data } from '@polkadot/types';
3
3
  import type { Bytes, Compact, Option, U8aFixed, Vec, WrapperKeepOpaque, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
4
4
  import type { AnyNumber, IMethod, ITuple } from '@polkadot/types-codec/types';
5
5
  import type { AccountId32, Call, H256, MultiAddress, Perbill, Percent, Perquintill } from '@polkadot/types/interfaces/runtime';
6
6
  import type { FrameSupportScheduleDispatchTime, FrameSupportScheduleMaybeHashed, NodeRuntimeOriginCaller, NodeRuntimeProxyType, NodeRuntimeSessionKeys, PalletAllianceCid, PalletAllianceUnscrupulousItem, PalletAssetsDestroyWitness, PalletConvictionVotingConviction, PalletConvictionVotingVoteAccountVote, PalletDemocracyConviction, PalletDemocracyVoteAccountVote, PalletElectionProviderMultiPhaseRawSolution, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenRenouncing, PalletIdentityBitFlags, PalletIdentityIdentityInfo, PalletIdentityJudgement, PalletImOnlineHeartbeat, PalletImOnlineSr25519AppSr25519Signature, PalletMultisigTimepoint, PalletNominationPoolsBondExtra, PalletNominationPoolsConfigOpAccountId32, PalletNominationPoolsConfigOpU128, PalletNominationPoolsConfigOpU32, PalletNominationPoolsPoolState, PalletSocietyJudgement, PalletStakingPalletConfigOpPerbill, PalletStakingPalletConfigOpPercent, PalletStakingPalletConfigOpU128, PalletStakingPalletConfigOpU32, PalletStakingRewardDestination, PalletStakingValidatorPrefs, PalletStateTrieMigrationMigrationLimits, PalletStateTrieMigrationMigrationTask, PalletStateTrieMigrationProgress, PalletUniquesDestroyWitness, PalletVestingVestingInfo, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusSlotsEquivocationProof, SpFinalityGrandpaEquivocationProof, SpNposElectionsElectionScore, SpNposElectionsSupport, SpRuntimeHeader, SpSessionMembershipProof, SpTransactionStorageProofTransactionStorageProof } from '@polkadot/types/lookup';
7
+ export declare type __AugmentedSubmittable = AugmentedSubmittable<() => unknown>;
8
+ export declare type __SubmittableExtrinsic<ApiType extends ApiTypes> = SubmittableExtrinsic<ApiType>;
9
+ export declare type __SubmittableExtrinsicFunction<ApiType extends ApiTypes> = SubmittableExtrinsicFunction<ApiType>;
7
10
  declare module '@polkadot/api-base/types/submittable' {
8
11
  interface AugmentedSubmittables<ApiType extends ApiTypes> {
9
12
  alliance: {
@@ -2105,8 +2108,9 @@ declare module '@polkadot/api-base/types/submittable' {
2105
2108
  * The dispatch of this call must be `FastTrackOrigin`.
2106
2109
  *
2107
2110
  * - `proposal_hash`: The hash of the current external proposal.
2108
- * - `voting_period`: The period that is allowed for voting on this proposal. Increased to
2109
- * `FastTrackVotingPeriod` if too low.
2111
+ * - `voting_period`: The period that is allowed for voting on this proposal.
2112
+ * Must be always greater than zero.
2113
+ * For `FastTrackOrigin` must be equal or greater than `FastTrackVotingPeriod`.
2110
2114
  * - `delay`: The number of block after voting has ended in approval and this should be
2111
2115
  * enacted. This doesn't have a minimum amount.
2112
2116
  *
package/mod.d.ts DELETED
@@ -1 +0,0 @@
1
- export * from './index';
package/mod.ts DELETED
@@ -1,4 +0,0 @@
1
- // Copyright 2017-2022 @polkadot/api-augment authors & contributors
2
- // SPDX-License-Identifier: Apache-2.0
3
-
4
- export * from './index';