System::Call

Variant 106 v393

frame_system::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 (11)

IndexNameFieldsDocs
0remark
remark: Vec<u8>
Make some on-chain remark. Can be executed by every `origin`.
1set_heap_pages
pages: u64
Set the number of pages in the WebAssembly environment's heap.
2set_code
code: Vec<u8>
Set the new runtime code.
3set_code_without_checks
code: Vec<u8>
Set the new runtime code without doing any checks of the given `code`. Note that runtime upgrades will not run if this is called with a not-increasing spec version!
4set_storageSet some items of storage.
5kill_storageKill some items from storage.
6kill_prefix
prefix: Vec<u8>
subkeys: u32
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.
7remark_with_event
remark: Vec<u8>
Make some on-chain remark and emit event.
9authorize_upgrade
code_hash: H256
Authorize an upgrade to a given `code_hash` for the runtime. The runtime can be supplied later. This call requires Root origin.
10authorize_upgrade_without_checks
code_hash: H256
Authorize an upgrade to a given `code_hash` for the runtime. The runtime can be supplied later. WARNING: This authorizes an upgrade that will take place without any safety checks, for example that the spec name remains the same and that the version number increases. Not recommended for normal use. Use `authorize_upgrade` instead. This call requires Root origin.
11apply_authorized_upgrade
code: Vec<u8>
Provide the preimage (runtime binary) `code` for an upgrade that has been authorized. If the authorization required a version check, this call will ensure the spec name remains unchanged and that the spec version has increased. Depending on the runtime's `OnSetCode` configuration, this function may directly apply the new `code` in the same block or attempt to schedule the upgrade. All origins are allowed.

SCALE Encoding

Rule
1-byte variant index followed by variant-specific field data. 11 possible variants.
Size
variable (1+ bytes)

Examples

remark = remark(remark)
0x00<field0>
00 Variant index 0 = remark
field 0 remark: Vec<u8>
set_heap_pages = set_heap_pages(pages)
0x01<field0>
01 Variant index 1 = set_heap_pages
field 0 pages: u64
set_code = set_code(code)
0x02<field0>
02 Variant index 2 = set_code
field 0 code: Vec<u8>

Code Examples

import { TypeRegistry } from "@polkadot/types";

const registry = new TypeRegistry();

// Encode System::Call — variant "remark"
const value = registry.createType("System::Call", { remark: { remark: 0 } });
console.log("Hex:", value.toHex());

Type Parameters

T

Referenced By (23)

and 3 more...

Also See

Type Information

Type ID
106
Kind
Variant
Path
frame_system::pallet::Call
Runtime
v393