@polkadot/api-augment 14.2.3 → 15.0.1

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.
@@ -6,7 +6,7 @@ import type { OpaqueKeyOwnershipProof } from '@polkadot/types/interfaces/babe';
6
6
  import type { Extrinsic } from '@polkadot/types/interfaces/extrinsics';
7
7
  import type { OpaqueMetadata } from '@polkadot/types/interfaces/metadata';
8
8
  import type { AccountId32, H256, RuntimeCall, Slot } from '@polkadot/types/interfaces/runtime';
9
- import type { FrameSupportTokensFungibleUnionOfNativeOrWithId, FrameSystemEventRecord, PalletContractsPrimitivesCode, PalletContractsPrimitivesCodeUploadReturnValue, PalletContractsPrimitivesContractAccessError, PalletContractsPrimitivesContractResult, PalletContractsPrimitivesExecReturnValue, PalletContractsPrimitivesStorageDeposit, PalletContractsWasmDeterminism, PalletTransactionPaymentFeeDetails, PalletTransactionPaymentRuntimeDispatchInfo, SpAuthorityDiscoveryAppPublic, SpConsensusBabeAppPublic, SpConsensusBabeBabeConfiguration, SpConsensusBabeEpoch, SpConsensusBeefyDoubleVotingProof, SpConsensusBeefyEcdsaCryptoPublic, SpConsensusBeefyValidatorSet, SpConsensusGrandpaAppPublic, SpConsensusGrandpaEquivocationProof, SpConsensusSlotsEquivocationProof, SpCoreCryptoKeyTypeId, SpInherentsCheckInherentsResult, SpInherentsInherentData, SpMixnetMixnode, SpMixnetMixnodesErr, SpMixnetSessionStatus, SpMmrPrimitivesError, SpMmrPrimitivesLeafProof, SpRuntimeBlock, SpRuntimeDispatchError, SpRuntimeExtrinsicInclusionMode, SpRuntimeHeader, SpRuntimeTransactionValidityTransactionSource, SpRuntimeTransactionValidityTransactionValidityError, SpRuntimeTransactionValidityValidTransaction, SpStatementStoreRuntimeApiInvalidStatement, SpStatementStoreRuntimeApiStatementSource, SpStatementStoreRuntimeApiValidStatement, SpStatementStoreStatement, SpVersionRuntimeVersion, SpWeightsWeightV2Weight } from '@polkadot/types/lookup';
9
+ import type { FrameSupportTokensFungibleUnionOfNativeOrWithId, FrameSystemEventRecord, PalletContractsPrimitivesCode, PalletContractsPrimitivesCodeUploadReturnValue, PalletContractsPrimitivesContractAccessError, PalletContractsPrimitivesContractResult, PalletContractsPrimitivesExecReturnValue, PalletContractsPrimitivesStorageDeposit, PalletContractsWasmDeterminism, PalletRevivePrimitivesCode, PalletRevivePrimitivesCodeUploadReturnValue, PalletRevivePrimitivesContractAccessError, PalletRevivePrimitivesContractResult, PalletRevivePrimitivesExecReturnValue, PalletRevivePrimitivesStorageDeposit, PalletTransactionPaymentFeeDetails, PalletTransactionPaymentRuntimeDispatchInfo, SpAuthorityDiscoveryAppPublic, SpConsensusBabeAppPublic, SpConsensusBabeBabeConfiguration, SpConsensusBabeEpoch, SpConsensusBeefyDoubleVotingProof, SpConsensusBeefyEcdsaCryptoPublic, SpConsensusBeefyForkVotingProofOpaqueValue, SpConsensusBeefyFutureBlockVotingProof, SpConsensusBeefyValidatorSet, SpConsensusGrandpaAppPublic, SpConsensusGrandpaEquivocationProof, SpConsensusSlotsEquivocationProof, SpCoreCryptoKeyTypeId, SpInherentsCheckInherentsResult, SpInherentsInherentData, SpMixnetMixnode, SpMixnetMixnodesErr, SpMixnetSessionStatus, SpMmrPrimitivesError, SpMmrPrimitivesLeafProof, SpRuntimeBlock, SpRuntimeDispatchError, SpRuntimeExtrinsicInclusionMode, SpRuntimeHeader, SpRuntimeTransactionValidityTransactionSource, SpRuntimeTransactionValidityTransactionValidityError, SpRuntimeTransactionValidityValidTransaction, SpStatementStoreRuntimeApiInvalidStatement, SpStatementStoreRuntimeApiStatementSource, SpStatementStoreRuntimeApiValidStatement, SpStatementStoreStatement, SpVersionRuntimeVersion, SpWeightsWeightV2Weight } from '@polkadot/types/lookup';
10
10
  import type { IExtrinsic, Observable } from '@polkadot/types/types';
11
11
  export type __AugmentedCall<ApiType extends ApiTypes> = AugmentedCall<ApiType>;
12
12
  export type __DecoratedCallBase<ApiType extends ApiTypes> = DecoratedCallBase<ApiType>;
@@ -130,6 +130,10 @@ declare module '@polkadot/api-base/types/calls' {
130
130
  * Return the block number where BEEFY consensus is enabled/started
131
131
  **/
132
132
  beefyGenesis: AugmentedCall<ApiType, () => Observable<Option<u32>>>;
133
+ /**
134
+ * Generates a proof that the `prev_block_number` is part of the canonical chain at, `best_known_block_number`.
135
+ **/
136
+ generateAncestryProof: AugmentedCall<ApiType, (prev_block_number: u32 | AnyNumber | Uint8Array, best_known_block_number: Option<u32> | null | Uint8Array | u32 | AnyNumber) => Observable<Option<Bytes>>>;
133
137
  /**
134
138
  * Generates a proof of key ownership for the given authority in the, given set. An example usage of this module is coupled with the, session historical module to prove that a given authority key is, tied to a given staking identity during a specific session. Proofs, of key ownership are necessary for submitting equivocation reports., NOTE: even though the API takes a `set_id` as parameter the current, implementations ignores this parameter and instead relies on this, method being called at the correct block height, i.e. any point at, which the given set id is live on-chain. Future implementations will, instead use indexed data through an offchain worker, not requiring, older states to be available.
135
139
  **/
@@ -141,6 +145,20 @@ declare module '@polkadot/api-base/types/calls' {
141
145
  first?: any;
142
146
  second?: any;
143
147
  } | string | Uint8Array, key_owner_proof: Bytes | string | Uint8Array) => Observable<Option<Null>>>;
148
+ /**
149
+ * Submits an unsigned extrinsic to report a fork voting equivocation. The caller, must provide the fork voting proof (the ancestry proof should be obtained using, `generate_ancestry_proof`) and a key ownership proof (should be obtained using, `generate_key_ownership_proof`). The extrinsic will be unsigned and should only, be accepted for local authorship (not to be broadcast to the network). This method, returns `None` when creation of the extrinsic fails, e.g. if equivocation, reporting is disabled for the given runtime (i.e. this method is, hardcoded to return `None`). Only useful in an offchain context.
150
+ **/
151
+ submitReportForkVotingUnsignedExtrinsic: AugmentedCall<ApiType, (equivocation_proof: SpConsensusBeefyForkVotingProofOpaqueValue | {
152
+ vote?: any;
153
+ ancestryProof?: any;
154
+ header?: any;
155
+ } | string | Uint8Array, key_owner_proof: Bytes | string | Uint8Array) => Observable<Option<Null>>>;
156
+ /**
157
+ * Submits an unsigned extrinsic to report a future block voting equivocation. The caller, must provide the future block voting proof and a key ownership proof, (should be obtained using `generate_key_ownership_proof`)., The extrinsic will be unsigned and should only be accepted for local, authorship (not to be broadcast to the network). This method returns, `None` when creation of the extrinsic fails, e.g. if equivocation, reporting is disabled for the given runtime (i.e. this method is, hardcoded to return `None`). Only useful in an offchain context.
158
+ **/
159
+ submitReportFutureBlockVotingUnsignedExtrinsic: AugmentedCall<ApiType, (equivocation_proof: SpConsensusBeefyFutureBlockVotingProof | {
160
+ vote?: any;
161
+ } | string | Uint8Array, key_owner_proof: Bytes | string | Uint8Array) => Observable<Option<Null>>>;
144
162
  /**
145
163
  * Return the current active BEEFY validator set
146
164
  **/
@@ -255,7 +273,7 @@ declare module '@polkadot/api-base/types/calls' {
255
273
  **/
256
274
  buildState: AugmentedCall<ApiType, (json: Bytes | string | Uint8Array) => Observable<Result<Null, Text>>>;
257
275
  /**
258
- * Returns a JSON blob representation of the built-in `RuntimeGenesisConfig` identified by, `id`.,, If `id` is `None` the function returns JSON blob representation of the default, `RuntimeGenesisConfig` struct of the runtime. Implementation must provide default, `RuntimeGenesisConfig`.,, Otherwise function returns a JSON representation of the built-in, named, `RuntimeGenesisConfig` preset identified by `id`, or `None` if such preset does not, exists. Returned `Vec<u8>` contains bytes of JSON blob (patch) which comprises a list of, (potentially nested) key-value pairs that are intended for customizing the default, runtime genesis config. The patch shall be merged (rfc7386) with the JSON representation, of the default `RuntimeGenesisConfig` to create a comprehensive genesis config that can, be used in `build_state` method.
276
+ * Returns a JSON blob representation of the built-in `RuntimeGenesisConfig` identified by, `id`.,, If `id` is `None` the function returns JSON blob representation of the default, `RuntimeGenesisConfig` struct of the runtime. Implementation must provide default, `RuntimeGenesisConfig`.,, Otherwise function returns a JSON representation of the built-in, named, `RuntimeGenesisConfig` preset identified by `id`, or `None` if such preset does not, exist. Returned `Vec<u8>` contains bytes of JSON blob (patch) which comprises a list of, (potentially nested) key-value pairs that are intended for customizing the default, runtime genesis config. The patch shall be merged (rfc7386) with the JSON representation, of the default `RuntimeGenesisConfig` to create a comprehensive genesis config that can, be used in `build_state` method.
259
277
  **/
260
278
  getPreset: AugmentedCall<ApiType, (id: Option<Text> | null | Uint8Array | Text | string) => Observable<Option<Bytes>>>;
261
279
  /**
@@ -419,6 +437,10 @@ declare module '@polkadot/api-base/types/calls' {
419
437
  * Returns the pending slash for a given pool member.
420
438
  **/
421
439
  memberPendingSlash: AugmentedCall<ApiType, (member: AccountId32 | string | Uint8Array) => Observable<u128>>;
440
+ /**
441
+ * Returns the total contribution of a pool member including any balance that is unbonding.
442
+ **/
443
+ memberTotalBalance: AugmentedCall<ApiType, (who: AccountId32 | string | Uint8Array) => Observable<u128>>;
422
444
  /**
423
445
  * Returns the pending rewards for the member that the AccountId was given for.
424
446
  **/
@@ -427,6 +449,10 @@ declare module '@polkadot/api-base/types/calls' {
427
449
  * Returns the equivalent balance of `points` for a given pool.
428
450
  **/
429
451
  pointsToBalance: AugmentedCall<ApiType, (pool_id: u32 | AnyNumber | Uint8Array, points: u128 | AnyNumber | Uint8Array) => Observable<u128>>;
452
+ /**
453
+ * Total balance contributed to the pool.
454
+ **/
455
+ poolBalance: AugmentedCall<ApiType, (pool_id: u32 | AnyNumber | Uint8Array) => Observable<u128>>;
430
456
  /**
431
457
  * Returns true if the pool with `pool_id` needs migration.,, This can happen when the `pallet-nomination-pools` has switched to using strategy, [`DelegateStake`](pallet_nomination_pools::adapter::DelegateStake) but the pool, still has funds that were staked using the older strategy, [TransferStake](pallet_nomination_pools::adapter::TransferStake). Use, [`migrate_pool_to_delegate_stake`](pallet_nomination_pools::Call::migrate_pool_to_delegate_stake), to migrate the pool.
432
458
  **/
@@ -457,6 +483,46 @@ declare module '@polkadot/api-base/types/calls' {
457
483
  **/
458
484
  [key: string]: DecoratedCallBase<ApiType>;
459
485
  };
486
+ /** 0x8c403e5c4a9fd442/ */
487
+ reviveApi: {
488
+ /**
489
+ * Perform a call from a specified account to a given contract.,, See [`crate::Pallet::bare_call`].
490
+ **/
491
+ call: AugmentedCall<ApiType, (origin: AccountId32 | string | Uint8Array, dest: AccountId32 | string | Uint8Array, value: u128 | AnyNumber | Uint8Array, gas_limit: Option<SpWeightsWeightV2Weight> | null | Uint8Array | SpWeightsWeightV2Weight | {
492
+ refTime?: any;
493
+ proofSize?: any;
494
+ } | string, storage_deposit_limit: Option<u128> | null | Uint8Array | u128 | AnyNumber, input_data: Bytes | string | Uint8Array) => Observable<{
495
+ readonly gasConsumed: SpWeightsWeightV2Weight;
496
+ readonly gasRequired: SpWeightsWeightV2Weight;
497
+ readonly storageDeposit: PalletRevivePrimitivesStorageDeposit;
498
+ readonly debugMessage: Bytes;
499
+ readonly result: Result<PalletRevivePrimitivesExecReturnValue, SpRuntimeDispatchError>;
500
+ readonly events: Option<Vec<FrameSystemEventRecord>>;
501
+ } & Struct>>;
502
+ /**
503
+ * Query a given storage key in a given contract.,, Returns `Ok(Some(Vec<u8>))` if the storage value exists under the given key in the, specified account and `Ok(None)` if it doesn't. If the account specified by the address, doesn't exist, or doesn't have a contract then `Err` is returned.
504
+ **/
505
+ getStorage: AugmentedCall<ApiType, (address: AccountId32 | string | Uint8Array, key: Bytes | string | Uint8Array) => Observable<Result<Option<Bytes>, PalletRevivePrimitivesContractAccessError>>>;
506
+ /**
507
+ * Instantiate a new contract.,, See `[crate::Pallet::bare_instantiate]`.
508
+ **/
509
+ instantiate: AugmentedCall<ApiType, (origin: AccountId32 | string | Uint8Array, value: u128 | AnyNumber | Uint8Array, gas_limit: Option<SpWeightsWeightV2Weight> | null | Uint8Array | SpWeightsWeightV2Weight | {
510
+ refTime?: any;
511
+ proofSize?: any;
512
+ } | string, storage_deposit_limit: Option<u128> | null | Uint8Array | u128 | AnyNumber, code: PalletRevivePrimitivesCode | {
513
+ Upload: any;
514
+ } | {
515
+ Existing: any;
516
+ } | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => Observable<PalletRevivePrimitivesContractResult>>;
517
+ /**
518
+ * Upload new code without instantiating a contract from it.,, See [`crate::Pallet::bare_upload_code`].
519
+ **/
520
+ uploadCode: AugmentedCall<ApiType, (origin: AccountId32 | string | Uint8Array, code: Bytes | string | Uint8Array, storage_deposit_limit: Option<u128> | null | Uint8Array | u128 | AnyNumber) => Observable<Result<PalletRevivePrimitivesCodeUploadReturnValue, SpRuntimeDispatchError>>>;
521
+ /**
522
+ * Generic call
523
+ **/
524
+ [key: string]: DecoratedCallBase<ApiType>;
525
+ };
460
526
  /** 0xab3c0572291feb8b/ */
461
527
  sessionKeys: {
462
528
  /**
@@ -4,7 +4,7 @@ import type { Data } from '@polkadot/types';
4
4
  import type { Bytes, Compact, Option, U8aFixed, Vec, bool, u128, u16, u32, u64, u8 } from '@polkadot/types-codec';
5
5
  import type { AnyNumber, IMethod, ITuple } from '@polkadot/types-codec/types';
6
6
  import type { AccountId32, Call, H256, MultiAddress, Perbill, Percent, Perquintill } from '@polkadot/types/interfaces/runtime';
7
- import type { FrameSupportPreimagesBounded, FrameSupportScheduleDispatchTime, FrameSupportTokensFungibleUnionOfNativeOrWithId, KitchensinkRuntimeOriginCaller, KitchensinkRuntimeProxyType, KitchensinkRuntimeRuntimeParameters, KitchensinkRuntimeSessionKeys, PalletAllianceCid, PalletAllianceDisbandWitness, PalletAllianceUnscrupulousItem, PalletBalancesAdjustmentDirection, PalletBrokerConfigRecord, PalletBrokerCoreMask, PalletBrokerFinality, PalletBrokerOnDemandRevenueRecord, PalletBrokerRegionId, PalletBrokerScheduleItem, PalletContractsWasmDeterminism, PalletConvictionVotingConviction, PalletConvictionVotingVoteAccountVote, PalletCoreFellowshipParamsTypeOption, PalletCoreFellowshipParamsTypeU128, PalletCoreFellowshipWish, PalletDemocracyConviction, PalletDemocracyMetadataOwner, PalletDemocracyVoteAccountVote, PalletElectionProviderMultiPhaseRawSolution, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenRenouncing, PalletIdentityJudgement, PalletIdentityLegacyIdentityInfo, PalletImOnlineHeartbeat, PalletImOnlineSr25519AppSr25519Signature, PalletMigrationsHistoricCleanupSelector, PalletMigrationsMigrationCursor, PalletMixnetRegistration, PalletMultisigTimepoint, PalletNftsAttributeNamespace, PalletNftsCancelAttributesApprovalWitness, PalletNftsCollectionConfig, PalletNftsDestroyWitness, PalletNftsItemConfig, PalletNftsItemTip, PalletNftsMintSettings, PalletNftsMintWitness, PalletNftsPreSignedAttributes, PalletNftsPreSignedMint, PalletNftsPriceWithDirection, PalletNominationPoolsBondExtra, PalletNominationPoolsClaimPermission, PalletNominationPoolsCommissionChangeRate, PalletNominationPoolsCommissionClaimPermission, PalletNominationPoolsConfigOpAccountId32, PalletNominationPoolsConfigOpPerbill, PalletNominationPoolsConfigOpU128, PalletNominationPoolsConfigOpU32, PalletNominationPoolsPoolState, PalletStakingPalletConfigOpPerbill, PalletStakingPalletConfigOpPercent, PalletStakingPalletConfigOpU128, PalletStakingPalletConfigOpU32, PalletStakingRewardDestination, PalletStakingUnlockChunk, PalletStakingValidatorPrefs, PalletStateTrieMigrationMigrationLimits, PalletStateTrieMigrationMigrationTask, PalletStateTrieMigrationProgress, PalletUniquesDestroyWitness, PalletVestingVestingInfo, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusBeefyDoubleVotingProof, SpConsensusBeefyForkVotingProof, SpConsensusBeefyFutureBlockVotingProof, SpConsensusGrandpaEquivocationProof, SpConsensusSlotsEquivocationProof, SpMixnetAppSignature, SpNposElectionsElectionScore, SpNposElectionsSupport, SpRuntimeMultiSignature, SpSessionMembershipProof, SpTransactionStorageProofTransactionStorageProof, SpWeightsWeightV2Weight } from '@polkadot/types/lookup';
7
+ import type { FrameSupportPreimagesBounded, FrameSupportScheduleDispatchTime, FrameSupportTokensFungibleUnionOfNativeOrWithId, KitchensinkRuntimeOriginCaller, KitchensinkRuntimeProxyType, KitchensinkRuntimeRuntimeParameters, KitchensinkRuntimeSessionKeys, PalletAllianceCid, PalletAllianceDisbandWitness, PalletAllianceUnscrupulousItem, PalletBalancesAdjustmentDirection, PalletBrokerConfigRecord, PalletBrokerCoreMask, PalletBrokerFinality, PalletBrokerOnDemandRevenueRecord, PalletBrokerRegionId, PalletBrokerScheduleItem, PalletContractsWasmDeterminism, PalletConvictionVotingConviction, PalletConvictionVotingVoteAccountVote, PalletCoreFellowshipParamsTypeOption, PalletCoreFellowshipParamsTypeU128, PalletCoreFellowshipWish, PalletDemocracyConviction, PalletDemocracyMetadataOwner, PalletDemocracyVoteAccountVote, PalletElectionProviderMultiPhaseRawSolution, PalletElectionProviderMultiPhaseSolutionOrSnapshotSize, PalletElectionsPhragmenRenouncing, PalletIdentityJudgement, PalletIdentityLegacyIdentityInfo, PalletImOnlineHeartbeat, PalletImOnlineSr25519AppSr25519Signature, PalletMigrationsHistoricCleanupSelector, PalletMigrationsMigrationCursor, PalletMixnetRegistration, PalletMultisigTimepoint, PalletNftsAttributeNamespace, PalletNftsCancelAttributesApprovalWitness, PalletNftsCollectionConfig, PalletNftsDestroyWitness, PalletNftsItemConfig, PalletNftsItemTip, PalletNftsMintSettings, PalletNftsMintWitness, PalletNftsPreSignedAttributes, PalletNftsPreSignedMint, PalletNftsPriceWithDirection, PalletNominationPoolsBondExtra, PalletNominationPoolsClaimPermission, PalletNominationPoolsCommissionChangeRate, PalletNominationPoolsCommissionClaimPermission, PalletNominationPoolsConfigOpAccountId32, PalletNominationPoolsConfigOpPerbill, PalletNominationPoolsConfigOpU128, PalletNominationPoolsConfigOpU32, PalletNominationPoolsPoolState, PalletStakingPalletConfigOpPerbill, PalletStakingPalletConfigOpPercent, PalletStakingPalletConfigOpU128, PalletStakingPalletConfigOpU32, PalletStakingRewardDestination, PalletStakingUnlockChunk, PalletStakingValidatorPrefs, PalletStateTrieMigrationMigrationLimits, PalletStateTrieMigrationMigrationTask, PalletStateTrieMigrationProgress, PalletUniquesDestroyWitness, PalletVestingVestingInfo, SpConsensusBabeDigestsNextConfigDescriptor, SpConsensusBeefyDoubleVotingProof, SpConsensusBeefyForkVotingProofAncestryProof, SpConsensusBeefyFutureBlockVotingProof, SpConsensusGrandpaEquivocationProof, SpConsensusSlotsEquivocationProof, SpMixnetAppSignature, SpNposElectionsElectionScore, SpNposElectionsSupport, SpRuntimeMultiSignature, SpSessionMembershipProof, SpTransactionStorageProofTransactionStorageProof, SpWeightsWeightV2Weight } from '@polkadot/types/lookup';
8
8
  export type __AugmentedSubmittable = AugmentedSubmittable<() => unknown>;
9
9
  export type __SubmittableExtrinsic<ApiType extends ApiTypes> = SubmittableExtrinsic<ApiType>;
10
10
  export type __SubmittableExtrinsicFunction<ApiType extends ApiTypes> = SubmittableExtrinsicFunction<ApiType>;
@@ -291,7 +291,7 @@ declare module '@polkadot/api-base/types/submittable' {
291
291
  * calls to render the liquidity withdrawable and rectify the exchange rate.
292
292
  *
293
293
  * Once liquidity is added, someone may successfully call
294
- * [`Pallet::swap_exact_tokens_for_tokens`] successfully.
294
+ * [`Pallet::swap_exact_tokens_for_tokens`].
295
295
  **/
296
296
  addLiquidity: AugmentedSubmittable<(asset1: FrameSupportTokensFungibleUnionOfNativeOrWithId | {
297
297
  Native: any;
@@ -1025,8 +1025,6 @@ declare module '@polkadot/api-base/types/submittable' {
1025
1025
  *
1026
1026
  * - `id`: The identifier of the asset to be destroyed. This must identify an existing
1027
1027
  * asset.
1028
- *
1029
- * The asset class must be frozen before calling `start_destroy`.
1030
1028
  **/
1031
1029
  startDestroy: AugmentedSubmittable<(id: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>]>;
1032
1030
  /**
@@ -1130,6 +1128,35 @@ declare module '@polkadot/api-base/types/submittable' {
1130
1128
  } | {
1131
1129
  Address20: any;
1132
1130
  } | string | Uint8Array, amount: Compact<u128> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, MultiAddress, Compact<u128>]>;
1131
+ /**
1132
+ * Transfer the entire transferable balance from the caller asset account.
1133
+ *
1134
+ * NOTE: This function only attempts to transfer _transferable_ balances. This means that
1135
+ * any held, frozen, or minimum balance (when `keep_alive` is `true`), will not be
1136
+ * transferred by this function. To ensure that this function results in a killed account,
1137
+ * you might need to prepare the account by removing any reference counters, storage
1138
+ * deposits, etc...
1139
+ *
1140
+ * The dispatch origin of this call must be Signed.
1141
+ *
1142
+ * - `id`: The identifier of the asset for the account holding a deposit.
1143
+ * - `dest`: The recipient of the transfer.
1144
+ * - `keep_alive`: A boolean to determine if the `transfer_all` operation should send all
1145
+ * of the funds the asset account has, causing the sender asset account to be killed
1146
+ * (false), or transfer everything except at least the minimum balance, which will
1147
+ * guarantee to keep the sender asset account alive (true).
1148
+ **/
1149
+ transferAll: AugmentedSubmittable<(id: Compact<u32> | AnyNumber | Uint8Array, dest: MultiAddress | {
1150
+ Id: any;
1151
+ } | {
1152
+ Index: any;
1153
+ } | {
1154
+ Raw: any;
1155
+ } | {
1156
+ Address32: any;
1157
+ } | {
1158
+ Address20: any;
1159
+ } | string | Uint8Array, keepAlive: bool | boolean | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, MultiAddress, bool]>;
1133
1160
  /**
1134
1161
  * Transfer some asset balance from a previously delegated account to some third-party
1135
1162
  * account.
@@ -1479,7 +1506,7 @@ declare module '@polkadot/api-base/types/submittable' {
1479
1506
  * and validate the given key ownership proof against the extracted offender.
1480
1507
  * If both are valid, the offence will be reported.
1481
1508
  **/
1482
- reportForkVoting: AugmentedSubmittable<(equivocationProof: SpConsensusBeefyForkVotingProof | {
1509
+ reportForkVoting: AugmentedSubmittable<(equivocationProof: SpConsensusBeefyForkVotingProofAncestryProof | {
1483
1510
  vote?: any;
1484
1511
  ancestryProof?: any;
1485
1512
  header?: any;
@@ -1487,7 +1514,7 @@ declare module '@polkadot/api-base/types/submittable' {
1487
1514
  session?: any;
1488
1515
  trieNodes?: any;
1489
1516
  validatorCount?: any;
1490
- } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [SpConsensusBeefyForkVotingProof, SpSessionMembershipProof]>;
1517
+ } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [SpConsensusBeefyForkVotingProofAncestryProof, SpSessionMembershipProof]>;
1491
1518
  /**
1492
1519
  * Report fork voting equivocation. This method will verify the equivocation proof
1493
1520
  * and validate the given key ownership proof against the extracted offender.
@@ -1498,7 +1525,7 @@ declare module '@polkadot/api-base/types/submittable' {
1498
1525
  * if the block author is defined it will be defined as the equivocation
1499
1526
  * reporter.
1500
1527
  **/
1501
- reportForkVotingUnsigned: AugmentedSubmittable<(equivocationProof: SpConsensusBeefyForkVotingProof | {
1528
+ reportForkVotingUnsigned: AugmentedSubmittable<(equivocationProof: SpConsensusBeefyForkVotingProofAncestryProof | {
1502
1529
  vote?: any;
1503
1530
  ancestryProof?: any;
1504
1531
  header?: any;
@@ -1506,7 +1533,7 @@ declare module '@polkadot/api-base/types/submittable' {
1506
1533
  session?: any;
1507
1534
  trieNodes?: any;
1508
1535
  validatorCount?: any;
1509
- } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [SpConsensusBeefyForkVotingProof, SpSessionMembershipProof]>;
1536
+ } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [SpConsensusBeefyForkVotingProofAncestryProof, SpSessionMembershipProof]>;
1510
1537
  /**
1511
1538
  * Report future block voting equivocation. This method will verify the equivocation proof
1512
1539
  * and validate the given key ownership proof against the extracted offender.
@@ -1733,6 +1760,16 @@ declare module '@polkadot/api-base/types/submittable' {
1733
1760
  renewalBump?: any;
1734
1761
  contributionTimeout?: any;
1735
1762
  } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [PalletBrokerConfigRecord]>;
1763
+ /**
1764
+ * Extrinsic for disabling auto renewal.
1765
+ *
1766
+ * Callable by the sovereign account of the task on the specified core.
1767
+ *
1768
+ * - `origin`: Must be the sovereign account of the task.
1769
+ * - `core`: The core for which we want to disable auto renewal.
1770
+ * - `task`: The task for which we want to disable auto renewal.
1771
+ **/
1772
+ disableAutoRenew: AugmentedSubmittable<(core: u16 | AnyNumber | Uint8Array, task: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, u32]>;
1736
1773
  /**
1737
1774
  * Drop an expired Instantaneous Pool Contribution record from the chain.
1738
1775
  *
@@ -1770,6 +1807,20 @@ declare module '@polkadot/api-base/types/submittable' {
1770
1807
  * - `when`: The timeslice to which the expired renewal refers. This must have passed.
1771
1808
  **/
1772
1809
  dropRenewal: AugmentedSubmittable<(core: u16 | AnyNumber | Uint8Array, when: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, u32]>;
1810
+ /**
1811
+ * Extrinsic for enabling auto renewal.
1812
+ *
1813
+ * Callable by the sovereign account of the task on the specified core. This account
1814
+ * will be charged at the start of every bulk period for renewing core time.
1815
+ *
1816
+ * - `origin`: Must be the sovereign account of the task
1817
+ * - `core`: The core to which the task to be renewed is currently assigned.
1818
+ * - `task`: The task for which we want to enable auto renewal.
1819
+ * - `workload_end_hint`: should be used when enabling auto-renewal for a core that is not
1820
+ * expiring in the upcoming bulk period (e.g., due to holding a lease) since it would be
1821
+ * inefficient to look up when the core expires to schedule the next renewal.
1822
+ **/
1823
+ enableAutoRenew: AugmentedSubmittable<(core: u16 | AnyNumber | Uint8Array, task: u32 | AnyNumber | Uint8Array, workloadEndHint: Option<u32> | null | Uint8Array | u32 | AnyNumber) => SubmittableExtrinsic<ApiType>, [u16, u32, Option<u32>]>;
1773
1824
  /**
1774
1825
  * Split a Bulk Coretime Region into two wholly-overlapping Regions with complementary
1775
1826
  * interlace masks which together make up the original Region's interlace mask.
@@ -3643,7 +3694,7 @@ declare module '@polkadot/api-base/types/submittable' {
3643
3694
  * - `max_fee`: The maximum fee that may be paid. This should just be auto-populated as:
3644
3695
  *
3645
3696
  * ```nocompile
3646
- * Self::registrars().get(reg_index).unwrap().fee
3697
+ * Registrars::<T>::get().get(reg_index).unwrap().fee
3647
3698
  * ```
3648
3699
  *
3649
3700
  * Emits `JudgementRequested` if successful.
@@ -5366,8 +5417,13 @@ declare module '@polkadot/api-base/types/submittable' {
5366
5417
  Address20: any;
5367
5418
  } | string | Uint8Array, poolId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, MultiAddress, MultiAddress, MultiAddress, u32]>;
5368
5419
  /**
5369
- * Stake funds with a pool. The amount to bond is transferred from the member to the
5370
- * pools account and immediately increases the pools bond.
5420
+ * Stake funds with a pool. The amount to bond is transferred from the member to the pool
5421
+ * account and immediately increases the pools bond.
5422
+ *
5423
+ * The method of transferring the amount to the pool account is determined by
5424
+ * [`adapter::StakeStrategyType`]. If the pool is configured to use
5425
+ * [`adapter::StakeStrategyType::Delegate`], the funds remain in the account of
5426
+ * the `origin`, while the pool gains the right to use these funds for staking.
5371
5427
  *
5372
5428
  * # Note
5373
5429
  *
@@ -6273,8 +6329,6 @@ declare module '@polkadot/api-base/types/submittable' {
6273
6329
  *
6274
6330
  * - `id`: The identifier of the asset to be destroyed. This must identify an existing
6275
6331
  * asset.
6276
- *
6277
- * The asset class must be frozen before calling `start_destroy`.
6278
6332
  **/
6279
6333
  startDestroy: AugmentedSubmittable<(id: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>]>;
6280
6334
  /**
@@ -6378,6 +6432,35 @@ declare module '@polkadot/api-base/types/submittable' {
6378
6432
  } | {
6379
6433
  Address20: any;
6380
6434
  } | string | Uint8Array, amount: Compact<u128> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, MultiAddress, Compact<u128>]>;
6435
+ /**
6436
+ * Transfer the entire transferable balance from the caller asset account.
6437
+ *
6438
+ * NOTE: This function only attempts to transfer _transferable_ balances. This means that
6439
+ * any held, frozen, or minimum balance (when `keep_alive` is `true`), will not be
6440
+ * transferred by this function. To ensure that this function results in a killed account,
6441
+ * you might need to prepare the account by removing any reference counters, storage
6442
+ * deposits, etc...
6443
+ *
6444
+ * The dispatch origin of this call must be Signed.
6445
+ *
6446
+ * - `id`: The identifier of the asset for the account holding a deposit.
6447
+ * - `dest`: The recipient of the transfer.
6448
+ * - `keep_alive`: A boolean to determine if the `transfer_all` operation should send all
6449
+ * of the funds the asset account has, causing the sender asset account to be killed
6450
+ * (false), or transfer everything except at least the minimum balance, which will
6451
+ * guarantee to keep the sender asset account alive (true).
6452
+ **/
6453
+ transferAll: AugmentedSubmittable<(id: Compact<u32> | AnyNumber | Uint8Array, dest: MultiAddress | {
6454
+ Id: any;
6455
+ } | {
6456
+ Index: any;
6457
+ } | {
6458
+ Raw: any;
6459
+ } | {
6460
+ Address32: any;
6461
+ } | {
6462
+ Address20: any;
6463
+ } | string | Uint8Array, keepAlive: bool | boolean | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u32>, MultiAddress, bool]>;
6381
6464
  /**
6382
6465
  * Transfer some asset balance from a previously delegated account to some third-party
6383
6466
  * account.
@@ -7361,6 +7444,141 @@ declare module '@polkadot/api-base/types/submittable' {
7361
7444
  **/
7362
7445
  [key: string]: SubmittableExtrinsicFunction<ApiType>;
7363
7446
  };
7447
+ revive: {
7448
+ /**
7449
+ * Makes a call to an account, optionally transferring some balance.
7450
+ *
7451
+ * # Parameters
7452
+ *
7453
+ * * `dest`: Address of the contract to call.
7454
+ * * `value`: The balance to transfer from the `origin` to `dest`.
7455
+ * * `gas_limit`: The gas limit enforced when executing the constructor.
7456
+ * * `storage_deposit_limit`: The maximum amount of balance that can be charged from the
7457
+ * caller to pay for the storage consumed.
7458
+ * * `data`: The input data to pass to the contract.
7459
+ *
7460
+ * * If the account is a smart-contract account, the associated code will be
7461
+ * executed and any value will be transferred.
7462
+ * * If the account is a regular account, any value will be transferred.
7463
+ * * If no account exists and the call value is not less than `existential_deposit`,
7464
+ * a regular account will be created and any value will be transferred.
7465
+ **/
7466
+ call: AugmentedSubmittable<(dest: MultiAddress | {
7467
+ Id: any;
7468
+ } | {
7469
+ Index: any;
7470
+ } | {
7471
+ Raw: any;
7472
+ } | {
7473
+ Address32: any;
7474
+ } | {
7475
+ Address20: any;
7476
+ } | string | Uint8Array, value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: SpWeightsWeightV2Weight | {
7477
+ refTime?: any;
7478
+ proofSize?: any;
7479
+ } | string | Uint8Array, storageDepositLimit: Compact<u128> | AnyNumber | Uint8Array, data: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, Compact<u128>, SpWeightsWeightV2Weight, Compact<u128>, Bytes]>;
7480
+ /**
7481
+ * Instantiates a contract from a previously deployed wasm binary.
7482
+ *
7483
+ * This function is identical to [`Self::instantiate_with_code`] but without the
7484
+ * code deployment step. Instead, the `code_hash` of an on-chain deployed wasm binary
7485
+ * must be supplied.
7486
+ **/
7487
+ instantiate: AugmentedSubmittable<(value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: SpWeightsWeightV2Weight | {
7488
+ refTime?: any;
7489
+ proofSize?: any;
7490
+ } | string | Uint8Array, storageDepositLimit: Compact<u128> | AnyNumber | Uint8Array, codeHash: H256 | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, SpWeightsWeightV2Weight, Compact<u128>, H256, Bytes, Bytes]>;
7491
+ /**
7492
+ * Instantiates a new contract from the supplied `code` optionally transferring
7493
+ * some balance.
7494
+ *
7495
+ * This dispatchable has the same effect as calling [`Self::upload_code`] +
7496
+ * [`Self::instantiate`]. Bundling them together provides efficiency gains. Please
7497
+ * also check the documentation of [`Self::upload_code`].
7498
+ *
7499
+ * # Parameters
7500
+ *
7501
+ * * `value`: The balance to transfer from the `origin` to the newly created contract.
7502
+ * * `gas_limit`: The gas limit enforced when executing the constructor.
7503
+ * * `storage_deposit_limit`: The maximum amount of balance that can be charged/reserved
7504
+ * from the caller to pay for the storage consumed.
7505
+ * * `code`: The contract code to deploy in raw bytes.
7506
+ * * `data`: The input data to pass to the contract constructor.
7507
+ * * `salt`: Used for the address derivation. See [`Pallet::contract_address`].
7508
+ *
7509
+ * Instantiation is executed as follows:
7510
+ *
7511
+ * - The supplied `code` is deployed, and a `code_hash` is created for that code.
7512
+ * - If the `code_hash` already exists on the chain the underlying `code` will be shared.
7513
+ * - The destination address is computed based on the sender, code_hash and the salt.
7514
+ * - The smart-contract account is created at the computed address.
7515
+ * - The `value` is transferred to the new account.
7516
+ * - The `deploy` function is executed in the context of the newly-created account.
7517
+ **/
7518
+ instantiateWithCode: AugmentedSubmittable<(value: Compact<u128> | AnyNumber | Uint8Array, gasLimit: SpWeightsWeightV2Weight | {
7519
+ refTime?: any;
7520
+ proofSize?: any;
7521
+ } | string | Uint8Array, storageDepositLimit: Compact<u128> | AnyNumber | Uint8Array, code: Bytes | string | Uint8Array, data: Bytes | string | Uint8Array, salt: Bytes | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, SpWeightsWeightV2Weight, Compact<u128>, Bytes, Bytes, Bytes]>;
7522
+ /**
7523
+ * When a migration is in progress, this dispatchable can be used to run migration steps.
7524
+ * Calls that contribute to advancing the migration have their fees waived, as it's helpful
7525
+ * for the chain. Note that while the migration is in progress, the pallet will also
7526
+ * leverage the `on_idle` hooks to run migration steps.
7527
+ **/
7528
+ migrate: AugmentedSubmittable<(weightLimit: SpWeightsWeightV2Weight | {
7529
+ refTime?: any;
7530
+ proofSize?: any;
7531
+ } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [SpWeightsWeightV2Weight]>;
7532
+ /**
7533
+ * Remove the code stored under `code_hash` and refund the deposit to its owner.
7534
+ *
7535
+ * A code can only be removed by its original uploader (its owner) and only if it is
7536
+ * not used by any contract.
7537
+ **/
7538
+ removeCode: AugmentedSubmittable<(codeHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [H256]>;
7539
+ /**
7540
+ * Privileged function that changes the code of an existing contract.
7541
+ *
7542
+ * This takes care of updating refcounts and all other necessary operations. Returns
7543
+ * an error if either the `code_hash` or `dest` do not exist.
7544
+ *
7545
+ * # Note
7546
+ *
7547
+ * This does **not** change the address of the contract in question. This means
7548
+ * that the contract address is no longer derived from its code hash after calling
7549
+ * this dispatchable.
7550
+ **/
7551
+ setCode: AugmentedSubmittable<(dest: MultiAddress | {
7552
+ Id: any;
7553
+ } | {
7554
+ Index: any;
7555
+ } | {
7556
+ Raw: any;
7557
+ } | {
7558
+ Address32: any;
7559
+ } | {
7560
+ Address20: any;
7561
+ } | string | Uint8Array, codeHash: H256 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, H256]>;
7562
+ /**
7563
+ * Upload new `code` without instantiating a contract from it.
7564
+ *
7565
+ * If the code does not already exist a deposit is reserved from the caller
7566
+ * and unreserved only when [`Self::remove_code`] is called. The size of the reserve
7567
+ * depends on the size of the supplied `code`.
7568
+ *
7569
+ * # Note
7570
+ *
7571
+ * Anyone can instantiate a contract from any uploaded code and thus prevent its removal.
7572
+ * To avoid this situation a constructor could employ access control so that it can
7573
+ * only be instantiated by permissioned entities. The same is true when uploading
7574
+ * through [`Self::instantiate_with_code`].
7575
+ **/
7576
+ uploadCode: AugmentedSubmittable<(code: Bytes | string | Uint8Array, storageDepositLimit: Compact<u128> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Bytes, Compact<u128>]>;
7577
+ /**
7578
+ * Generic tx
7579
+ **/
7580
+ [key: string]: SubmittableExtrinsicFunction<ApiType>;
7581
+ };
7364
7582
  rootTesting: {
7365
7583
  /**
7366
7584
  * A dispatch that will fill the block weight up to the given ratio.
package/package.json CHANGED
@@ -18,7 +18,7 @@
18
18
  "./cjs/packageDetect.js"
19
19
  ],
20
20
  "type": "module",
21
- "version": "14.2.3",
21
+ "version": "15.0.1",
22
22
  "main": "./cjs/index.js",
23
23
  "module": "./index.js",
24
24
  "types": "./index.d.ts",
@@ -451,12 +451,12 @@
451
451
  }
452
452
  },
453
453
  "dependencies": {
454
- "@polkadot/api-base": "14.2.3",
455
- "@polkadot/rpc-augment": "14.2.3",
456
- "@polkadot/types": "14.2.3",
457
- "@polkadot/types-augment": "14.2.3",
458
- "@polkadot/types-codec": "14.2.3",
459
- "@polkadot/util": "^13.2.2",
454
+ "@polkadot/api-base": "15.0.1",
455
+ "@polkadot/rpc-augment": "15.0.1",
456
+ "@polkadot/types": "15.0.1",
457
+ "@polkadot/types-augment": "15.0.1",
458
+ "@polkadot/types-codec": "15.0.1",
459
+ "@polkadot/util": "^13.2.3",
460
460
  "tslib": "^2.8.0"
461
461
  }
462
462
  }
package/packageInfo.js CHANGED
@@ -1 +1 @@
1
- export const packageInfo = { name: '@polkadot/api-augment', path: (import.meta && import.meta.url) ? new URL(import.meta.url).pathname.substring(0, new URL(import.meta.url).pathname.lastIndexOf('/') + 1) : 'auto', type: 'esm', version: '14.2.3' };
1
+ export const packageInfo = { name: '@polkadot/api-augment', path: (import.meta && import.meta.url) ? new URL(import.meta.url).pathname.substring(0, new URL(import.meta.url).pathname.lastIndexOf('/') + 1) : 'auto', type: 'esm', version: '15.0.1' };
@@ -248,6 +248,7 @@ declare module '@polkadot/api-base/types/consts' {
248
248
  [key: string]: Codec;
249
249
  };
250
250
  broker: {
251
+ maxAutoRenewals: u32 & AugmentedConst<ApiType>;
251
252
  /**
252
253
  * Maximum number of legacy leases.
253
254
  **/
@@ -1227,6 +1228,56 @@ declare module '@polkadot/api-base/types/consts' {
1227
1228
  **/
1228
1229
  [key: string]: Codec;
1229
1230
  };
1231
+ revive: {
1232
+ apiVersion: u16 & AugmentedConst<ApiType>;
1233
+ /**
1234
+ * The percentage of the storage deposit that should be held for using a code hash.
1235
+ * Instantiating a contract, or calling [`chain_extension::Ext::lock_delegate_dependency`]
1236
+ * protects the code from being removed. In order to prevent abuse these actions are
1237
+ * protected with a percentage of the code deposit.
1238
+ **/
1239
+ codeHashLockupDepositPercent: Perbill & AugmentedConst<ApiType>;
1240
+ /**
1241
+ * The amount of balance a caller has to pay for each byte of storage.
1242
+ *
1243
+ * # Note
1244
+ *
1245
+ * It is safe to chage this value on a live chain as all refunds are pro rata.
1246
+ **/
1247
+ depositPerByte: u128 & AugmentedConst<ApiType>;
1248
+ /**
1249
+ * The amount of balance a caller has to pay for each storage item.
1250
+ *
1251
+ * # Note
1252
+ *
1253
+ * It is safe to chage this value on a live chain as all refunds are pro rata.
1254
+ **/
1255
+ depositPerItem: u128 & AugmentedConst<ApiType>;
1256
+ /**
1257
+ * The maximum length of a contract code in bytes.
1258
+ *
1259
+ * This value hugely affects the memory requirements of this pallet since all the code of
1260
+ * all contracts on the call stack will need to be held in memory. Setting of a correct
1261
+ * value will be enforced in [`Pallet::integrity_test`].
1262
+ **/
1263
+ maxCodeLen: u32 & AugmentedConst<ApiType>;
1264
+ /**
1265
+ * Make contract callable functions marked as `#[unstable]` available.
1266
+ *
1267
+ * Contracts that use `#[unstable]` functions won't be able to be uploaded unless
1268
+ * this is set to `true`. This is only meant for testnets and dev nodes in order to
1269
+ * experiment with new features.
1270
+ *
1271
+ * # Warning
1272
+ *
1273
+ * Do **not** set to `true` on productions chains.
1274
+ **/
1275
+ unsafeUnstableInterface: bool & AugmentedConst<ApiType>;
1276
+ /**
1277
+ * Generic const
1278
+ **/
1279
+ [key: string]: Codec;
1280
+ };
1230
1281
  safeMode: {
1231
1282
  /**
1232
1283
  * The amount that will be reserved upon calling [`Pallet::enter`].