@polkadot/api-augment 16.3.1 → 16.4.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.
package/kusama/tx.d.ts CHANGED
@@ -1263,6 +1263,7 @@ declare module '@polkadot/api-base/types/submittable' {
1263
1263
  } | {
1264
1264
  Task: any;
1265
1265
  } | string | Uint8Array, u16 | AnyNumber | Uint8Array])[], endHint: Option<u32> | null | Uint8Array | u32 | AnyNumber) => SubmittableExtrinsic<ApiType>, [u16, u32, Vec<ITuple<[PalletBrokerCoretimeInterfaceCoreAssignment, u16]>>, Option<u32>]>;
1266
+ creditAccount: AugmentedSubmittable<(who: AccountId32 | string | Uint8Array, amount: u128 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [AccountId32, u128]>;
1266
1267
  /**
1267
1268
  * Request the configuration to be updated with the specified number of cores. Warning:
1268
1269
  * Since this only schedules a configuration update, it takes two sessions to come into
@@ -2042,6 +2043,19 @@ declare module '@polkadot/api-base/types/submittable' {
2042
2043
  * - `O(1)`.
2043
2044
  **/
2044
2045
  freeze: AugmentedSubmittable<(index: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
2046
+ /**
2047
+ * Poke the deposit reserved for an index.
2048
+ *
2049
+ * The dispatch origin for this call must be _Signed_ and the signing account must have a
2050
+ * non-frozen account `index`.
2051
+ *
2052
+ * The transaction fees is waived if the deposit is changed after poking/reconsideration.
2053
+ *
2054
+ * - `index`: the index whose deposit is to be poked/reconsidered.
2055
+ *
2056
+ * Emits `DepositPoked` if successful.
2057
+ **/
2058
+ pokeDeposit: AugmentedSubmittable<(index: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
2045
2059
  /**
2046
2060
  * Assign an index already owned by the sender to another account. The balance reservation
2047
2061
  * is effectively transferred to the new account.
@@ -2247,6 +2261,22 @@ declare module '@polkadot/api-base/types/submittable' {
2247
2261
  height?: any;
2248
2262
  index?: any;
2249
2263
  } | string | Uint8Array, callHash: U8aFixed | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, Vec<AccountId32>, PalletMultisigTimepoint, U8aFixed]>;
2264
+ /**
2265
+ * Poke the deposit reserved for an existing multisig operation.
2266
+ *
2267
+ * The dispatch origin for this call must be _Signed_ and must be the original depositor of
2268
+ * the multisig operation.
2269
+ *
2270
+ * The transaction fee is waived if the deposit amount has changed.
2271
+ *
2272
+ * - `threshold`: The total number of approvals needed for this multisig.
2273
+ * - `other_signatories`: The accounts (other than the sender) who are part of the
2274
+ * multisig.
2275
+ * - `call_hash`: The hash of the call this deposit is reserved for.
2276
+ *
2277
+ * Emits `DepositPoked` if successful.
2278
+ **/
2279
+ pokeDeposit: AugmentedSubmittable<(threshold: u16 | AnyNumber | Uint8Array, otherSignatories: Vec<AccountId32> | (AccountId32 | string | Uint8Array)[], callHash: U8aFixed | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [u16, Vec<AccountId32>, U8aFixed]>;
2250
2280
  /**
2251
2281
  * Generic tx
2252
2282
  **/
@@ -2492,8 +2522,10 @@ declare module '@polkadot/api-base/types/submittable' {
2492
2522
  * Fails unless [`crate::pallet::Config::StakeAdapter`] is of strategy type:
2493
2523
  * [`adapter::StakeStrategyType::Delegate`].
2494
2524
  *
2495
- * This call can be dispatched permissionlessly (i.e. by any account). If the member has
2496
- * slash to be applied, caller may be rewarded with the part of the slash.
2525
+ * The pending slash amount of the member must be equal or more than `ExistentialDeposit`.
2526
+ * This call can be dispatched permissionlessly (i.e. by any account). If the execution
2527
+ * is successful, fee is refunded and caller may be rewarded with a part of the slash
2528
+ * based on the [`crate::pallet::Config::StakeAdapter`] configuration.
2497
2529
  **/
2498
2530
  applySlash: AugmentedSubmittable<(memberAccount: MultiAddress | {
2499
2531
  Id: any;
@@ -2552,25 +2584,37 @@ declare module '@polkadot/api-base/types/submittable' {
2552
2584
  * The dispatch origin of this call can be signed by the pool nominator or the pool
2553
2585
  * root role, same as [`Pallet::nominate`].
2554
2586
  *
2587
+ * This directly forwards the call to an implementation of `StakingInterface` (e.g.,
2588
+ * `pallet-staking`) through [`Config::StakeAdapter`], on behalf of the bonded pool.
2589
+ *
2555
2590
  * Under certain conditions, this call can be dispatched permissionlessly (i.e. by any
2556
2591
  * account).
2557
2592
  *
2558
2593
  * # Conditions for a permissionless dispatch:
2559
- * * When pool depositor has less than `MinNominatorBond` staked, otherwise pool members
2594
+ * * When pool depositor has less than `MinNominatorBond` staked, otherwise pool members
2560
2595
  * are unable to unbond.
2561
2596
  *
2562
2597
  * # Conditions for permissioned dispatch:
2563
- * * The caller has a nominator or root role of the pool.
2564
- * This directly forward the call to the staking pallet, on behalf of the pool bonded
2565
- * account.
2598
+ * * The caller is the pool's nominator or root.
2566
2599
  **/
2567
2600
  chill: AugmentedSubmittable<(poolId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
2568
2601
  /**
2569
2602
  * Claim pending commission.
2570
2603
  *
2571
- * The dispatch origin of this call must be signed by the `root` role of the pool. Pending
2572
- * commission is paid out and added to total claimed commission`. Total pending commission
2573
- * is reset to zero. the current.
2604
+ * The `root` role of the pool is _always_ allowed to claim the pool's commission.
2605
+ *
2606
+ * If the pool has set `CommissionClaimPermission::Permissionless`, then any account can
2607
+ * trigger the process of claiming the pool's commission.
2608
+ *
2609
+ * If the pool has set its `CommissionClaimPermission` to `Account(acc)`, then only
2610
+ * accounts
2611
+ * * `acc`, and
2612
+ * * the pool's root account
2613
+ *
2614
+ * may call this extrinsic on behalf of the pool.
2615
+ *
2616
+ * Pending commissions are paid out and added to the total claimed commission.
2617
+ * The total pending commission is reset to zero.
2574
2618
  **/
2575
2619
  claimCommission: AugmentedSubmittable<(poolId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u32]>;
2576
2620
  /**
@@ -2681,8 +2725,9 @@ declare module '@polkadot/api-base/types/submittable' {
2681
2725
  Address20: any;
2682
2726
  } | string | Uint8Array, poolId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [Compact<u128>, MultiAddress, MultiAddress, MultiAddress, u32]>;
2683
2727
  /**
2684
- * Stake funds with a pool. The amount to bond is transferred from the member to the pool
2685
- * account and immediately increases the pools bond.
2728
+ * Stake funds with a pool. The amount to bond is delegated (or transferred based on
2729
+ * [`adapter::StakeStrategyType`]) from the member to the pool account and immediately
2730
+ * increases the pool's bond.
2686
2731
  *
2687
2732
  * The method of transferring the amount to the pool account is determined by
2688
2733
  * [`adapter::StakeStrategyType`]. If the pool is configured to use
@@ -2738,13 +2783,13 @@ declare module '@polkadot/api-base/types/submittable' {
2738
2783
  * The dispatch origin of this call must be signed by the pool nominator or the pool
2739
2784
  * root role.
2740
2785
  *
2741
- * This directly forward the call to the staking pallet, on behalf of the pool bonded
2742
- * account.
2786
+ * This directly forwards the call to an implementation of `StakingInterface` (e.g.,
2787
+ * `pallet-staking`) through [`Config::StakeAdapter`], on behalf of the bonded pool.
2743
2788
  *
2744
2789
  * # Note
2745
2790
  *
2746
- * In addition to a `root` or `nominator` role of `origin`, pool's depositor needs to have
2747
- * at least `depositor_min_bond` in the pool to start nominating.
2791
+ * In addition to a `root` or `nominator` role of `origin`, the pool's depositor needs to
2792
+ * have at least `depositor_min_bond` in the pool to start nominating.
2748
2793
  **/
2749
2794
  nominate: AugmentedSubmittable<(poolId: u32 | AnyNumber | Uint8Array, validators: Vec<AccountId32> | (AccountId32 | string | Uint8Array)[]) => SubmittableExtrinsic<ApiType>, [u32, Vec<AccountId32>]>;
2750
2795
  /**
@@ -3022,6 +3067,26 @@ declare module '@polkadot/api-base/types/submittable' {
3022
3067
  * - `OnDemandOrderPlaced`
3023
3068
  **/
3024
3069
  placeOrderKeepAlive: AugmentedSubmittable<(maxAmount: u128 | AnyNumber | Uint8Array, paraId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u128, u32]>;
3070
+ /**
3071
+ * Create a single on demand core order with credits.
3072
+ * Will charge the owner's on-demand credit account the spot price for the current block.
3073
+ *
3074
+ * Parameters:
3075
+ * - `origin`: The sender of the call, on-demand credits will be withdrawn from this
3076
+ * account.
3077
+ * - `max_amount`: The maximum number of credits to spend from the origin to place an
3078
+ * order.
3079
+ * - `para_id`: A `ParaId` the origin wants to provide blockspace for.
3080
+ *
3081
+ * Errors:
3082
+ * - `InsufficientCredits`
3083
+ * - `QueueFull`
3084
+ * - `SpotPriceHigherThanMaxAmount`
3085
+ *
3086
+ * Events:
3087
+ * - `OnDemandOrderPlaced`
3088
+ **/
3089
+ placeOrderWithCredits: AugmentedSubmittable<(maxAmount: u128 | AnyNumber | Uint8Array, paraId: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [u128, u32]>;
3025
3090
  /**
3026
3091
  * Generic tx
3027
3092
  **/
@@ -3163,7 +3228,7 @@ declare module '@polkadot/api-base/types/submittable' {
3163
3228
  };
3164
3229
  preimage: {
3165
3230
  /**
3166
- * Ensure that the a bulk of pre-images is upgraded.
3231
+ * Ensure that the bulk of pre-images is upgraded.
3167
3232
  *
3168
3233
  * The caller pays no fee if at least 90% of pre-images were successfully updated.
3169
3234
  **/
@@ -3303,6 +3368,17 @@ declare module '@polkadot/api-base/types/submittable' {
3303
3368
  } | {
3304
3369
  Address20: any;
3305
3370
  } | string | Uint8Array, proxyType: KusamaRuntimeConstantsProxyProxyType | 'Any' | 'NonTransfer' | 'Governance' | 'Staking' | 'CancelProxy' | 'Auction' | 'Society' | 'NominationPools' | 'Spokesperson' | 'ParaRegistration' | number | Uint8Array, index: u16 | AnyNumber | Uint8Array, height: Compact<u32> | AnyNumber | Uint8Array, extIndex: Compact<u32> | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [MultiAddress, KusamaRuntimeConstantsProxyProxyType, u16, Compact<u32>, Compact<u32>]>;
3371
+ /**
3372
+ * Poke / Adjust deposits made for proxies and announcements based on current values.
3373
+ * This can be used by accounts to possibly lower their locked amount.
3374
+ *
3375
+ * The dispatch origin for this call must be _Signed_.
3376
+ *
3377
+ * The transaction fee is waived if the deposit amount has changed.
3378
+ *
3379
+ * Emits `DepositPoked` if successful.
3380
+ **/
3381
+ pokeDeposit: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
3306
3382
  /**
3307
3383
  * Dispatch the given `call` from an account that the sender is authorised for through
3308
3384
  * `add_proxy`.
@@ -3585,7 +3661,7 @@ declare module '@polkadot/api-base/types/submittable' {
3585
3661
  **/
3586
3662
  removeRecovery: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
3587
3663
  /**
3588
- * Allow ROOT to bypass the recovery process and set an a rescuer account
3664
+ * Allow ROOT to bypass the recovery process and set a rescuer account
3589
3665
  * for a lost account directly.
3590
3666
  *
3591
3667
  * The dispatch origin for this call must be _ROOT_.
@@ -4472,6 +4548,40 @@ declare module '@polkadot/api-base/types/submittable' {
4472
4548
  } | {
4473
4549
  Address20: any;
4474
4550
  } | string | Uint8Array)[]) => SubmittableExtrinsic<ApiType>, [Vec<MultiAddress>]>;
4551
+ /**
4552
+ * This function allows governance to manually slash a validator and is a
4553
+ * **fallback mechanism**.
4554
+ *
4555
+ * The dispatch origin must be `T::AdminOrigin`.
4556
+ *
4557
+ * ## Parameters
4558
+ * - `validator_stash` - The stash account of the validator to slash.
4559
+ * - `era` - The era in which the validator was in the active set.
4560
+ * - `slash_fraction` - The percentage of the stake to slash, expressed as a Perbill.
4561
+ *
4562
+ * ## Behavior
4563
+ *
4564
+ * The slash will be applied using the standard slashing mechanics, respecting the
4565
+ * configured `SlashDeferDuration`.
4566
+ *
4567
+ * This means:
4568
+ * - If the validator was already slashed by a higher percentage for the same era, this
4569
+ * slash will have no additional effect.
4570
+ * - If the validator was previously slashed by a lower percentage, only the difference
4571
+ * will be applied.
4572
+ * - The slash will be deferred by `SlashDeferDuration` eras before being enacted.
4573
+ **/
4574
+ manualSlash: AugmentedSubmittable<(validatorStash: AccountId32 | string | Uint8Array, era: u32 | AnyNumber | Uint8Array, slashFraction: Perbill | AnyNumber | Uint8Array) => SubmittableExtrinsic<ApiType>, [AccountId32, u32, Perbill]>;
4575
+ /**
4576
+ * Removes the legacy Staking locks if they exist.
4577
+ *
4578
+ * This removes the legacy lock on the stake with [`Config::OldCurrency`] and creates a
4579
+ * hold on it if needed. If all stake cannot be held, the best effort is made to hold as
4580
+ * much as possible. The remaining stake is forced withdrawn from the ledger.
4581
+ *
4582
+ * The fee is waived if the migration is successful.
4583
+ **/
4584
+ migrateCurrency: AugmentedSubmittable<(stash: AccountId32 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [AccountId32]>;
4475
4585
  /**
4476
4586
  * Declare the desire to nominate `targets` for the origin controller.
4477
4587
  *
@@ -4757,15 +4867,6 @@ declare module '@polkadot/api-base/types/submittable' {
4757
4867
  commission?: any;
4758
4868
  blocked?: any;
4759
4869
  } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [PalletStakingValidatorPrefs]>;
4760
- /**
4761
- * Adjusts the staking ledger by withdrawing any excess staked amount.
4762
- *
4763
- * This function corrects cases where a user's recorded stake in the ledger
4764
- * exceeds their actual staked funds. This situation can arise due to cases such as
4765
- * external slashing by another pallet, leading to an inconsistency between the ledger
4766
- * and the actual stake.
4767
- **/
4768
- withdrawOverstake: AugmentedSubmittable<(stash: AccountId32 | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [AccountId32]>;
4769
4870
  /**
4770
4871
  * Remove any unlocked chunks from the `unlocking` queue from our management.
4771
4872
  *
@@ -5136,6 +5237,22 @@ declare module '@polkadot/api-base/types/submittable' {
5136
5237
  } | {
5137
5238
  XcmPallet: any;
5138
5239
  } | string | Uint8Array, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [StagingKusamaRuntimeOriginCaller, Call]>;
5240
+ /**
5241
+ * Dispatches a function call with a provided origin.
5242
+ *
5243
+ * Almost the same as [`Pallet::dispatch_as`] but forwards any error of the inner call.
5244
+ *
5245
+ * The dispatch origin for this call must be _Root_.
5246
+ **/
5247
+ dispatchAsFallible: AugmentedSubmittable<(asOrigin: StagingKusamaRuntimeOriginCaller | {
5248
+ system: any;
5249
+ } | {
5250
+ Origins: any;
5251
+ } | {
5252
+ ParachainsOrigin: any;
5253
+ } | {
5254
+ XcmPallet: any;
5255
+ } | string | Uint8Array, call: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [StagingKusamaRuntimeOriginCaller, Call]>;
5139
5256
  /**
5140
5257
  * Send a batch of dispatch calls.
5141
5258
  * Unlike `batch`, it allows errors and won't interrupt.
@@ -5152,6 +5269,32 @@ declare module '@polkadot/api-base/types/submittable' {
5152
5269
  * - O(C) where C is the number of calls to be batched.
5153
5270
  **/
5154
5271
  forceBatch: AugmentedSubmittable<(calls: Vec<Call> | (Call | IMethod | string | Uint8Array)[]) => SubmittableExtrinsic<ApiType>, [Vec<Call>]>;
5272
+ /**
5273
+ * Dispatch a fallback call in the event the main call fails to execute.
5274
+ * May be called from any origin except `None`.
5275
+ *
5276
+ * This function first attempts to dispatch the `main` call.
5277
+ * If the `main` call fails, the `fallback` is attemted.
5278
+ * if the fallback is successfully dispatched, the weights of both calls
5279
+ * are accumulated and an event containing the main call error is deposited.
5280
+ *
5281
+ * In the event of a fallback failure the whole call fails
5282
+ * with the weights returned.
5283
+ *
5284
+ * - `main`: The main call to be dispatched. This is the primary action to execute.
5285
+ * - `fallback`: The fallback call to be dispatched in case the `main` call fails.
5286
+ *
5287
+ * ## Dispatch Logic
5288
+ * - If the origin is `root`, both the main and fallback calls are executed without
5289
+ * applying any origin filters.
5290
+ * - If the origin is not `root`, the origin filter is applied to both the `main` and
5291
+ * `fallback` calls.
5292
+ *
5293
+ * ## Use Case
5294
+ * - Some use cases might involve submitting a `batch` type call in either main, fallback
5295
+ * or both.
5296
+ **/
5297
+ ifElse: AugmentedSubmittable<(main: Call | IMethod | string | Uint8Array, fallback: Call | IMethod | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [Call, Call]>;
5155
5298
  /**
5156
5299
  * Dispatch a function call with a specified weight.
5157
5300
  *
@@ -5417,6 +5560,26 @@ declare module '@polkadot/api-base/types/submittable' {
5417
5560
  [key: string]: SubmittableExtrinsicFunction<ApiType>;
5418
5561
  };
5419
5562
  xcmPallet: {
5563
+ /**
5564
+ * Authorize another `aliaser` location to alias into the local `origin` making this call.
5565
+ * The `aliaser` is only authorized until the provided `expiry` block number.
5566
+ * The call can also be used for a previously authorized alias in order to update its
5567
+ * `expiry` block number.
5568
+ *
5569
+ * Usually useful to allow your local account to be aliased into from a remote location
5570
+ * also under your control (like your account on another chain).
5571
+ *
5572
+ * WARNING: make sure the caller `origin` (you) trusts the `aliaser` location to act in
5573
+ * their/your name. Once authorized using this call, the `aliaser` can freely impersonate
5574
+ * `origin` in XCM programs executed on the local chain.
5575
+ **/
5576
+ addAuthorizedAlias: AugmentedSubmittable<(aliaser: XcmVersionedLocation | {
5577
+ V3: any;
5578
+ } | {
5579
+ V4: any;
5580
+ } | {
5581
+ V5: any;
5582
+ } | string | Uint8Array, expires: Option<u64> | null | Uint8Array | u64 | AnyNumber) => SubmittableExtrinsic<ApiType>, [XcmVersionedLocation, Option<u64>]>;
5420
5583
  /**
5421
5584
  * Claims assets trapped on this pallet because of leftover assets during XCM execution.
5422
5585
  *
@@ -5611,6 +5774,22 @@ declare module '@polkadot/api-base/types/submittable' {
5611
5774
  } | {
5612
5775
  Limited: any;
5613
5776
  } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [XcmVersionedLocation, XcmVersionedLocation, XcmVersionedAssets, u32, XcmV3WeightLimit]>;
5777
+ /**
5778
+ * Remove all previously authorized `aliaser`s that can alias into the local `origin`
5779
+ * making this call.
5780
+ **/
5781
+ removeAllAuthorizedAliases: AugmentedSubmittable<() => SubmittableExtrinsic<ApiType>, []>;
5782
+ /**
5783
+ * Remove a previously authorized `aliaser` from the list of locations that can alias into
5784
+ * the local `origin` making this call.
5785
+ **/
5786
+ removeAuthorizedAlias: AugmentedSubmittable<(aliaser: XcmVersionedLocation | {
5787
+ V3: any;
5788
+ } | {
5789
+ V4: any;
5790
+ } | {
5791
+ V5: any;
5792
+ } | string | Uint8Array) => SubmittableExtrinsic<ApiType>, [XcmVersionedLocation]>;
5614
5793
  /**
5615
5794
  * Transfer some assets from the local chain to the destination chain through their local,
5616
5795
  * destination or remote reserve.
package/package.json CHANGED
@@ -18,7 +18,7 @@
18
18
  "./cjs/packageDetect.js"
19
19
  ],
20
20
  "type": "module",
21
- "version": "16.3.1",
21
+ "version": "16.4.2",
22
22
  "main": "./cjs/index.js",
23
23
  "module": "./index.js",
24
24
  "types": "./index.d.ts",
@@ -603,11 +603,11 @@
603
603
  }
604
604
  },
605
605
  "dependencies": {
606
- "@polkadot/api-base": "16.3.1",
607
- "@polkadot/rpc-augment": "16.3.1",
608
- "@polkadot/types": "16.3.1",
609
- "@polkadot/types-augment": "16.3.1",
610
- "@polkadot/types-codec": "16.3.1",
606
+ "@polkadot/api-base": "16.4.2",
607
+ "@polkadot/rpc-augment": "16.4.2",
608
+ "@polkadot/types": "16.4.2",
609
+ "@polkadot/types-augment": "16.4.2",
610
+ "@polkadot/types-codec": "16.4.2",
611
611
  "@polkadot/util": "^13.5.3",
612
612
  "tslib": "^2.8.1"
613
613
  }
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: '16.3.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: '16.4.2' };