import type { Bytes, Compact, Option, Vec, bool, u32, u64 } from '@polkadot/types'; import type { AnyNumber, ITuple } from '@polkadot/types/types'; import type { Currency } from '@equilab/api/interfaces/latest'; import type { EthereumAddress } from '@polkadot/types/interfaces/claims'; import type { EcdsaSignature, Extrinsic } from '@polkadot/types/interfaces/extrinsics'; import type { GrandpaEquivocationProof, KeyOwnerProof } from '@polkadot/types/interfaces/grandpa'; import type { AccountId, Balance, BalanceOf, BlockNumber, Call, ChangesTrieConfiguration, Header, KeyValue, LookupSource, Moment, Perbill, ValidatorId, Weight } from '@polkadot/types/interfaces/runtime'; import type { Keys } from '@polkadot/types/interfaces/session'; import type { Key } from '@polkadot/types/interfaces/system'; import type { VestingInfo } from '@polkadot/types/interfaces/vesting'; import type { ApiTypes, SubmittableExtrinsic } from '@polkadot/api/types'; declare module '@polkadot/api/types/submittable' { interface AugmentedSubmittables { authorship: { /** * Provide a set of uncles. **/ setUncles: AugmentedSubmittable<(newUncles: Vec
| (Header | { parentHash?: any; number?: any; stateRoot?: any; extrinsicsRoot?: any; digest?: any; } | string | Uint8Array)[]) => SubmittableExtrinsic, [Vec
]>; }; balances: { /** * Burns currency (sudo only). Used to withdraw currency from the system **/ burn: AugmentedSubmittable<(currency: Currency | 'Unknown' | 'Usd' | 'Eq' | 'Eth' | 'Btc' | 'Eos' | 'Dot' | 'Crv' | number | Uint8Array, from: AccountId | string | Uint8Array, value: Balance | AnyNumber | Uint8Array) => SubmittableExtrinsic, [Currency, AccountId, Balance]>; /** * Adds currency to account balance (sudo only). Used to deposit currency * into system **/ deposit: AugmentedSubmittable<(currency: Currency | 'Unknown' | 'Usd' | 'Eq' | 'Eth' | 'Btc' | 'Eos' | 'Dot' | 'Crv' | number | Uint8Array, to: AccountId | string | Uint8Array, value: Balance | AnyNumber | Uint8Array) => SubmittableExtrinsic, [Currency, AccountId, Balance]>; /** * Disable transfers between accounts **/ disableTransfers: AugmentedSubmittable<() => SubmittableExtrinsic, []>; /** * Enable transfers between accounts **/ enableTransfers: AugmentedSubmittable<() => SubmittableExtrinsic, []>; /** * Transfers `value` amount of `currency` from trx sender to account id `to` **/ transfer: AugmentedSubmittable<(currency: Currency | 'Unknown' | 'Usd' | 'Eq' | 'Eth' | 'Btc' | 'Eos' | 'Dot' | 'Crv' | number | Uint8Array, to: AccountId | string | Uint8Array, value: Balance | AnyNumber | Uint8Array) => SubmittableExtrinsic, [Currency, AccountId, Balance]>; }; claim: { /** * Attest to a statement, needed to finalize the claims process. * * Unsigned Validation: * A call to attest is deemed valid if the sender has a `Preclaim` registered * and provides a `statement` which is expected for the account. * * Parameters: * - `statement`: The identity of the statement which is being attested to in the signature. **/ attest: AugmentedSubmittable<(statement: Bytes | string | Uint8Array) => SubmittableExtrinsic, [Bytes]>; /** * Make a claim to collect your currency. * * The dispatch origin for this call must be _None_. * * Unsigned Validation: * A call to claim is deemed valid if the signature provided matches * the expected signed message of: * * > Ethereum Signed Message: * > (configured prefix string)(address) * * and `address` matches the `dest` account. * * Parameters: * - `dest`: The destination account to payout the claim. * - `ethereum_signature`: The signature of an ethereum signed message * matching the format described above. **/ claim: AugmentedSubmittable<(dest: AccountId | string | Uint8Array, ethereumSignature: EcdsaSignature | string | Uint8Array) => SubmittableExtrinsic, [AccountId, EcdsaSignature]>; /** * Make a claim to collect your currency by signing a statement. * * The dispatch origin for this call must be _None_. * * Unsigned Validation: * A call to `claim_attest` is deemed valid if the signature provided matches * the expected signed message of: * * > Ethereum Signed Message: * > (configured prefix string)(address)(statement) * * and `address` matches the `dest` account; the `statement` must match that which is * expected according to your purchase arrangement. * * Parameters: * - `dest`: The destination account to payout the claim. * - `ethereum_signature`: The signature of an ethereum signed message * matching the format described above. * - `statement`: The identity of the statement which is being attested to in the signature. **/ claimAttest: AugmentedSubmittable<(dest: AccountId | string | Uint8Array, ethereumSignature: EcdsaSignature | string | Uint8Array, statement: Bytes | string | Uint8Array) => SubmittableExtrinsic, [AccountId, EcdsaSignature, Bytes]>; /** * Mint a new claim to collect currency * * The dispatch origin for this call must be _Root_. * * Parameters: * - `who`: The Ethereum address allowed to collect this claim. * - `value`: The balance that will be claimed. * - `vesting_schedule`: An optional vesting schedule for the claim **/ mintClaim: AugmentedSubmittable<(who: EthereumAddress | string | Uint8Array, value: BalanceOf | AnyNumber | Uint8Array, vestingSchedule: Option> | null | object | string | Uint8Array, statement: bool | boolean | Uint8Array) => SubmittableExtrinsic, [EthereumAddress, BalanceOf, Option>, bool]>; /** * Gives claims ownership from `old` to `new` **/ moveClaim: AugmentedSubmittable<(old: EthereumAddress | string | Uint8Array, updated: EthereumAddress | string | Uint8Array, maybePreclaim: Option | null | object | string | Uint8Array) => SubmittableExtrinsic, [EthereumAddress, EthereumAddress, Option]>; }; eqSessionManager: { /** * Adds validator. Root authorization required to add validator. **/ addValidator: AugmentedSubmittable<(validatorId: ValidatorId | string | Uint8Array) => SubmittableExtrinsic, [ValidatorId]>; /** * Removes validator. Root authorization required to remove validator. **/ removeValidator: AugmentedSubmittable<(validatorId: ValidatorId | string | Uint8Array) => SubmittableExtrinsic, [ValidatorId]>; }; eqVesting: { /** * Force a vested transfer. * * The dispatch origin for this call must be _Root_. * * - `source`: The account whose funds should be transferred. * - `target`: The account that should be transferred the vested funds. * - `amount`: The amount of funds to transfer and will be vested. * - `schedule`: The vesting schedule attached to the transfer. * * Emits `VestingCreated`. **/ forceVestedTransfer: AugmentedSubmittable<(source: LookupSource | string | Uint8Array, target: LookupSource | string | Uint8Array, schedule: VestingInfo | { locked?: any; perBlock?: any; startingBlock?: any; } | string | Uint8Array) => SubmittableExtrinsic, [LookupSource, LookupSource, VestingInfo]>; /** * Unlock any vested funds of the sender account. * * The dispatch origin for this call must be _Signed_ and the sender must have funds still * locked under this module. * * Emits either `VestingCompleted` or `VestingUpdated`. **/ vest: AugmentedSubmittable<() => SubmittableExtrinsic, []>; /** * Unlock any vested funds of a `target` account. * * The dispatch origin for this call must be _Signed_. * * - `target`: The account whose vested funds should be unlocked. Must have funds still * locked under this module. * * Emits either `VestingCompleted` or `VestingUpdated`. **/ vestOther: AugmentedSubmittable<(target: LookupSource | string | Uint8Array) => SubmittableExtrinsic, [LookupSource]>; /** * Create a vested transfer. * * The dispatch origin for this call must be _Signed_. * * - `target`: The account that should be transferred the vested funds. * - `schedule`: The vesting schedule attached to the transfer. * * Emits `VestingCreated`. **/ vestedTransfer: AugmentedSubmittable<(target: LookupSource | string | Uint8Array, schedule: VestingInfo | { locked?: any; perBlock?: any; startingBlock?: any; } | string | Uint8Array) => SubmittableExtrinsic, [LookupSource, VestingInfo]>; }; grandpa: { /** * Note that the current authority set of the GRANDPA finality gadget has * stalled. This will trigger a forced authority set change at the beginning * of the next session, to be enacted `delay` blocks after that. The delay * should be high enough to safely assume that the block signalling the * forced change will not be re-orged (e.g. 1000 blocks). The GRANDPA voters * will start the new authority set using the given finalized block as base. * Only callable by root. **/ noteStalled: AugmentedSubmittable<(delay: BlockNumber | AnyNumber | Uint8Array, bestFinalizedBlockNumber: BlockNumber | AnyNumber | Uint8Array) => SubmittableExtrinsic, [BlockNumber, BlockNumber]>; /** * Report voter equivocation/misbehavior. This method will verify the * equivocation proof and validate the given key ownership proof * against the extracted offender. If both are valid, the offence * will be reported. **/ reportEquivocation: AugmentedSubmittable<(equivocationProof: GrandpaEquivocationProof | { setId?: any; equivocation?: any; } | string | Uint8Array, keyOwnerProof: KeyOwnerProof | { session?: any; trieNodes?: any; validatorCount?: any; } | string | Uint8Array) => SubmittableExtrinsic, [GrandpaEquivocationProof, KeyOwnerProof]>; /** * Report voter equivocation/misbehavior. This method will verify the * equivocation proof and validate the given key ownership proof * against the extracted offender. If both are valid, the offence * will be reported. * * This extrinsic must be called unsigned and it is expected that only * block authors will call it (validated in `ValidateUnsigned`), as such * if the block author is defined it will be defined as the equivocation * reporter. **/ reportEquivocationUnsigned: AugmentedSubmittable<(equivocationProof: GrandpaEquivocationProof | { setId?: any; equivocation?: any; } | string | Uint8Array, keyOwnerProof: KeyOwnerProof | { session?: any; trieNodes?: any; validatorCount?: any; } | string | Uint8Array) => SubmittableExtrinsic, [GrandpaEquivocationProof, KeyOwnerProof]>; }; session: { /** * Removes any session key(s) of the function caller. * This doesn't take effect until the next session. * * The dispatch origin of this function must be signed. * * # * - Complexity: `O(1)` in number of key types. * Actual cost depends on the number of length of `T::Keys::key_ids()` which is fixed. * - DbReads: `T::ValidatorIdOf`, `NextKeys`, `origin account` * - DbWrites: `NextKeys`, `origin account` * - DbWrites per key id: `KeyOwnder` * # **/ purgeKeys: AugmentedSubmittable<() => SubmittableExtrinsic, []>; /** * Sets the session key(s) of the function caller to `keys`. * Allows an account to set its session key prior to becoming a validator. * This doesn't take effect until the next session. * * The dispatch origin of this function must be signed. * * # * - Complexity: `O(1)` * Actual cost depends on the number of length of `T::Keys::key_ids()` which is fixed. * - DbReads: `origin account`, `T::ValidatorIdOf`, `NextKeys` * - DbWrites: `origin account`, `NextKeys` * - DbReads per key id: `KeyOwner` * - DbWrites per key id: `KeyOwner` * # **/ setKeys: AugmentedSubmittable<(keys: Keys, proof: Bytes | string | Uint8Array) => SubmittableExtrinsic, [Keys, Bytes]>; }; sudo: { /** * Authenticates the current sudo key and sets the given AccountId (`new`) as the new sudo key. * * The dispatch origin for this call must be _Signed_. * * # * - O(1). * - Limited storage reads. * - One DB change. * # **/ setKey: AugmentedSubmittable<(updated: LookupSource | string | Uint8Array) => SubmittableExtrinsic, [LookupSource]>; /** * Authenticates the sudo key and dispatches a function call with `Root` origin. * * The dispatch origin for this call must be _Signed_. * * # * - O(1). * - Limited storage reads. * - One DB write (event). * - Weight of derivative `call` execution + 10,000. * # **/ sudo: AugmentedSubmittable<(call: Call | { callIndex?: any; args?: any; } | string | Uint8Array) => SubmittableExtrinsic, [Call]>; /** * Authenticates the sudo key and dispatches a function call with `Signed` origin from * a given account. * * The dispatch origin for this call must be _Signed_. * * # * - O(1). * - Limited storage reads. * - One DB write (event). * - Weight of derivative `call` execution + 10,000. * # **/ sudoAs: AugmentedSubmittable<(who: LookupSource | string | Uint8Array, call: Call | { callIndex?: any; args?: any; } | string | Uint8Array) => SubmittableExtrinsic, [LookupSource, Call]>; /** * Authenticates the sudo key and dispatches a function call with `Root` origin. * This function does not check the weight of the call, and instead allows the * Sudo user to specify the weight of the call. * * The dispatch origin for this call must be _Signed_. * * # * - O(1). * - The weight of this call is defined by the caller. * # **/ sudoUncheckedWeight: AugmentedSubmittable<(call: Call | { callIndex?: any; args?: any; } | string | Uint8Array, weight: Weight | AnyNumber | Uint8Array) => SubmittableExtrinsic, [Call, Weight]>; }; system: { /** * A dispatch that will fill the block weight up to the given ratio. **/ fillBlock: AugmentedSubmittable<(ratio: Perbill | AnyNumber | Uint8Array) => SubmittableExtrinsic, [Perbill]>; /** * Kill all storage items with a key that starts with the given prefix. * * **NOTE:** We rely on the Root origin to provide us the number of subkeys under * the prefix we are removing to accurately calculate the weight of this function. * * # * - `O(P)` where `P` amount of keys with prefix `prefix` * - `P` storage deletions. * - Base Weight: 0.834 * P µs * - Writes: Number of subkeys + 1 * # **/ killPrefix: AugmentedSubmittable<(prefix: Key | string | Uint8Array, subkeys: u32 | AnyNumber | Uint8Array) => SubmittableExtrinsic, [Key, u32]>; /** * Kill some items from storage. * * # * - `O(IK)` where `I` length of `keys` and `K` length of one key * - `I` storage deletions. * - Base Weight: .378 * i µs * - Writes: Number of items * # **/ killStorage: AugmentedSubmittable<(keys: Vec | (Key | string | Uint8Array)[]) => SubmittableExtrinsic, [Vec]>; /** * Make some on-chain remark. * * # * - `O(1)` * - Base Weight: 0.665 µs, independent of remark length. * - No DB operations. * # **/ remark: AugmentedSubmittable<(remark: Bytes | string | Uint8Array) => SubmittableExtrinsic, [Bytes]>; /** * Set the new changes trie configuration. * * # * - `O(1)` * - 1 storage write or delete (codec `O(1)`). * - 1 call to `deposit_log`: Uses `append` API, so O(1) * - Base Weight: 7.218 µs * - DB Weight: * - Writes: Changes Trie, System Digest * # **/ setChangesTrieConfig: AugmentedSubmittable<(changesTrieConfig: Option | null | object | string | Uint8Array) => SubmittableExtrinsic, [Option]>; /** * Set the new runtime code. * * # * - `O(C + S)` where `C` length of `code` and `S` complexity of `can_set_code` * - 1 storage write (codec `O(C)`). * - 1 call to `can_set_code`: `O(S)` (calls `sp_io::misc::runtime_version` which is expensive). * - 1 event. * The weight of this function is dependent on the runtime, but generally this is very expensive. * We will treat this as a full block. * # **/ setCode: AugmentedSubmittable<(code: Bytes | string | Uint8Array) => SubmittableExtrinsic, [Bytes]>; /** * Set the new runtime code without doing any checks of the given `code`. * * # * - `O(C)` where `C` length of `code` * - 1 storage write (codec `O(C)`). * - 1 event. * The weight of this function is dependent on the runtime. We will treat this as a full block. * # **/ setCodeWithoutChecks: AugmentedSubmittable<(code: Bytes | string | Uint8Array) => SubmittableExtrinsic, [Bytes]>; /** * Set the number of pages in the WebAssembly environment's heap. * * # * - `O(1)` * - 1 storage write. * - Base Weight: 1.405 µs * - 1 write to HEAP_PAGES * # **/ setHeapPages: AugmentedSubmittable<(pages: u64 | AnyNumber | Uint8Array) => SubmittableExtrinsic, [u64]>; /** * Set some items of storage. * * # * - `O(I)` where `I` length of `items` * - `I` storage writes (`O(1)`). * - Base Weight: 0.568 * i µs * - Writes: Number of items * # **/ setStorage: AugmentedSubmittable<(items: Vec | (KeyValue)[]) => SubmittableExtrinsic, [Vec]>; /** * Kill the sending account, assuming there are no references outstanding and the composite * data is equal to its default value. * * # * - `O(1)` * - 1 storage read and deletion. * -------------------- * Base Weight: 8.626 µs * No DB Read or Write operations because caller is already in overlay * # **/ suicide: AugmentedSubmittable<() => SubmittableExtrinsic, []>; }; timestamp: { /** * Set the current time. * * This call should be invoked exactly once per block. It will panic at the finalization * phase, if this call hasn't been invoked by that time. * * The timestamp should be greater than the previous one by the amount specified by * `MinimumPeriod`. * * The dispatch origin for this call must be `Inherent`. * * # * - `O(T)` where `T` complexity of `on_timestamp_set` * - 1 storage read and 1 storage mutation (codec `O(1)`). (because of `DidUpdate::take` in `on_finalize`) * - 1 event handler `on_timestamp_set` `O(T)`. * # **/ set: AugmentedSubmittable<(now: Compact | AnyNumber | Uint8Array) => SubmittableExtrinsic, [Compact]>; }; } interface SubmittableExtrinsics extends AugmentedSubmittables { (extrinsic: Call | Extrinsic | Uint8Array | string): SubmittableExtrinsic; } }