Multisig::Call
Variant 164 v393pallet_multisig::pallet::Call
Contains a variant per dispatchable extrinsic that this pallet has.
About This Type
Call enum for the Call pallet.
Contains all dispatchable functions (extrinsics) for the Call pallet. Each variant represents a different callable function with its parameters.
Variants (5)
| Index | Name | Fields | Docs |
|---|---|---|---|
| 0 | as_multi_threshold_1 | other_signatories: Vec<AccountId> call: RuntimeCall | Immediately dispatch a multi-signature call using a single approval from the caller. The dispatch origin for this call must be _Signed_. - `other_signatories`: The accounts (other than the sender) who are part of the multi-signature, but do not participate in the approval process. - `call`: The call to be executed. Result is equivalent to the dispatched result. ## Complexity O(Z + C) where Z is the length of the call and C its execution weight. |
| 1 | as_multi | threshold: u16 other_signatories: Vec<AccountId> maybe_timepoint: Option call: RuntimeCall max_weight: Weight | Register approval for a dispatch to be made from a deterministic composite account if approved by a total of `threshold - 1` of `other_signatories`. If there are enough, then dispatch the call. Payment: `DepositBase` will be reserved if this is the first approval, plus `threshold` times `DepositFactor`. It is returned once this dispatch happens or is cancelled. The dispatch origin for this call must be _Signed_. - `threshold`: The total number of approvals for this dispatch before it is executed. - `other_signatories`: The accounts (other than the sender) who can approve this dispatch. May not be empty. - `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is not the first approval, then it must be `Some`, with the timepoint (block number and transaction index) of the first approval transaction. - `call`: The call to be executed. NOTE: Unless this is the final approval, you will generally want to use `approve_as_multi` instead, since it only requires a hash of the call. Result is equivalent to the dispatched result if `threshold` is exactly `1`. Otherwise on success, result is `Ok` and the result from the interior call, if it was executed, may be found in the deposited `MultisigExecuted` event. ## Complexity - `O(S + Z + Call)`. - Up to one balance-reserve or unreserve operation. - One passthrough operation, one insert, both `O(S)` where `S` is the number of signatories. `S` is capped by `MaxSignatories`, with weight being proportional. - One call encode & hash, both of complexity `O(Z)` where `Z` is tx-len. - One encode & hash, both of complexity `O(S)`. - Up to one binary search and insert (`O(logS + S)`). - I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove. - One event. - The weight of the `call`. - Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit taken for its lifetime of `DepositBase + threshold * DepositFactor`. |
| 2 | approve_as_multi | threshold: u16 other_signatories: Vec<AccountId> maybe_timepoint: Option call_hash: [u8; 32] max_weight: Weight | Register approval for a dispatch to be made from a deterministic composite account if approved by a total of `threshold - 1` of `other_signatories`. Payment: `DepositBase` will be reserved if this is the first approval, plus `threshold` times `DepositFactor`. It is returned once this dispatch happens or is cancelled. The dispatch origin for this call must be _Signed_. - `threshold`: The total number of approvals for this dispatch before it is executed. - `other_signatories`: The accounts (other than the sender) who can approve this dispatch. May not be empty. - `maybe_timepoint`: If this is the first approval, then this must be `None`. If it is not the first approval, then it must be `Some`, with the timepoint (block number and transaction index) of the first approval transaction. - `call_hash`: The hash of the call to be executed. NOTE: If this is the final approval, you will want to use `as_multi` instead. ## Complexity - `O(S)`. - Up to one balance-reserve or unreserve operation. - One passthrough operation, one insert, both `O(S)` where `S` is the number of signatories. `S` is capped by `MaxSignatories`, with weight being proportional. - One encode & hash, both of complexity `O(S)`. - Up to one binary search and insert (`O(logS + S)`). - I/O: 1 read `O(S)`, up to 1 mutate `O(S)`. Up to one remove. - One event. - Storage: inserts one item, value size bounded by `MaxSignatories`, with a deposit taken for its lifetime of `DepositBase + threshold * DepositFactor`. |
| 3 | cancel_as_multi | Cancel a pre-existing, on-going multisig transaction. Any deposit reserved previously for this operation will be unreserved on success. The dispatch origin for this call must be _Signed_. - `threshold`: The total number of approvals for this dispatch before it is executed. - `other_signatories`: The accounts (other than the sender) who can approve this dispatch. May not be empty. - `timepoint`: The timepoint (block number and transaction index) of the first approval transaction for this dispatch. - `call_hash`: The hash of the call to be executed. ## Complexity - `O(S)`. - Up to one balance-reserve or unreserve operation. - One passthrough operation, one insert, both `O(S)` where `S` is the number of signatories. `S` is capped by `MaxSignatories`, with weight being proportional. - One encode & hash, both of complexity `O(S)`. - One event. - I/O: 1 read `O(S)`, one remove. - Storage: removes one item. | |
| 4 | poke_deposit | Poke the deposit reserved for an existing multisig operation. The dispatch origin for this call must be _Signed_ and must be the original depositor of the multisig operation. The transaction fee is waived if the deposit amount has changed. - `threshold`: The total number of approvals needed for this multisig. - `other_signatories`: The accounts (other than the sender) who are part of the multisig. - `call_hash`: The hash of the call this deposit is reserved for. Emits `DepositPoked` if successful. |
SCALE Encoding
- Rule
- 1-byte variant index followed by variant-specific field data. 5 possible variants.
- Size
- variable (1+ bytes)
Examples
as_multi_threshold_1 = as_multi_threshold_1(other_signatories, call)
0x00<field0><field1>00 Variant index 0 = as_multi_threshold_1field 0 other_signatories: Vec<AccountId>field 1 call: RuntimeCallas_multi = as_multi(threshold, other_signatories, maybe_timepoint, call, max_weight)
0x01<field0><field1><field2><field3><field4>01 Variant index 1 = as_multifield 0 threshold: u16field 1 other_signatories: Vec<AccountId>field 2 maybe_timepoint: Optionfield 3 call: RuntimeCallfield 4 max_weight: Weightapprove_as_multi = approve_as_multi(threshold, other_signatories, maybe_timepoint, call_hash, max_weight)
0x02<field0><field1><field2><field3><field4>02 Variant index 2 = approve_as_multifield 0 threshold: u16field 1 other_signatories: Vec<AccountId>field 2 maybe_timepoint: Optionfield 3 call_hash: [u8; 32]field 4 max_weight: WeightCode Examples
import { TypeRegistry } from "@polkadot/types";
const registry = new TypeRegistry();
// Encode Multisig::Call — variant "as_multi_threshold_1"
const value = registry.createType("Multisig::Call", { as_multi_threshold_1: { other_signatories: "5GrwvaEF5zXb26Fz9rcQpDWS57CtERHpNehXCPcNoHGKutQY", call: 0 } });
console.log("Hex:", value.toHex());Type Parameters
T
Referenced By (23)
#123 RuntimeCall via System#123 RuntimeCall via Timestamp#123 RuntimeCall via Grandpa#123 RuntimeCall via Balances#123 RuntimeCall via SubtensorModule#123 RuntimeCall via Utility#123 RuntimeCall via Sudo#123 RuntimeCall via Multisig#123 RuntimeCall via Preimage#123 RuntimeCall via Scheduler#123 RuntimeCall via Proxy#123 RuntimeCall via Registry#123 RuntimeCall via Commitments#123 RuntimeCall via AdminUtils#123 RuntimeCall via SafeMode#123 RuntimeCall via Ethereum#123 RuntimeCall via EVM#123 RuntimeCall via BaseFee#123 RuntimeCall via Drand#123 RuntimeCall via Crowdloan
and 3 more...
Also See
Type Information
- Type ID
- 164
- Kind
- Variant
- Path
- pallet_multisig::pallet::Call
- Runtime
- v393