Proxy::Call

Variant 169 v393

pallet_subtensor_proxy::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 (12)

IndexNameFieldsDocs
0proxy
force_proxy_type: Option
Dispatch the given `call` from an account that the sender is authorised for through `add_proxy`. The dispatch origin for this call must be _Signed_. Parameters: - `real`: The account that the proxy will make a call on behalf of. - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call. - `call`: The call to be made by the `real` account.
1add_proxy
delegate: MultiAddress
proxy_type: ProxyType
delay: u32
Register a proxy account for the sender that is able to make calls on its behalf. The dispatch origin for this call must be _Signed_. Parameters: - `proxy`: The account that the `caller` would like to make a proxy. - `proxy_type`: The permissions allowed for this proxy account. - `delay`: The announcement period required of the initial proxy. Will generally be zero.
2remove_proxy
delegate: MultiAddress
proxy_type: ProxyType
delay: u32
Unregister a proxy account for the sender. The dispatch origin for this call must be _Signed_. Parameters: - `proxy`: The account that the `caller` would like to remove as a proxy. - `proxy_type`: The permissions currently enabled for the removed proxy account.
3remove_proxiesnoneUnregister all proxy accounts for the sender. The dispatch origin for this call must be _Signed_. WARNING: This may be called on accounts created by `create_pure`, however if done, then the unreserved fees will be inaccessible. **All access to this account will be lost.**
4create_pure
proxy_type: ProxyType
delay: u32
index: u16
Spawn a fresh new account that is guaranteed to be otherwise inaccessible, and initialize it with a proxy of `proxy_type` for `origin` sender. Requires a `Signed` origin. - `proxy_type`: The type of the proxy that the sender will be registered as over the new account. This will almost always be the most permissive `ProxyType` possible to allow for maximum flexibility. - `index`: A disambiguation index, in case this is called multiple times in the same transaction (e.g. with `utility::batch`). Unless you're using `batch` you probably just want to use `0`. - `delay`: The announcement period required of the initial proxy. Will generally be zero. Fails with `Duplicate` if this has already been called in this transaction, from the same sender, with the same parameters. Fails if there are insufficient funds to pay for deposit.
5kill_pure
spawner: MultiAddress
proxy_type: ProxyType
index: u16
height: Compact<u32>
ext_index: Compact<u32>
Removes a previously spawned pure proxy. WARNING: **All access to this account will be lost.** Any funds held in it will be inaccessible. Requires a `Signed` origin, and the sender account must have been created by a call to `create_pure` with corresponding parameters. - `spawner`: The account that originally called `create_pure` to create this account. - `index`: The disambiguation index originally passed to `create_pure`. Probably `0`. - `proxy_type`: The proxy type originally passed to `create_pure`. - `height`: The height of the chain when the call to `create_pure` was processed. - `ext_index`: The extrinsic index in which the call to `create_pure` was processed. Fails with `NoPermission` in case the caller is not a previously created pure account whose `create_pure` call has corresponding parameters.
6announce
call_hash: H256
Publish the hash of a proxy-call that will be made in the future. This must be called some number of blocks before the corresponding `proxy` is attempted if the delay associated with the proxy relationship is greater than zero. No more than `MaxPending` announcements may be made at any one time. This will take a deposit of `AnnouncementDepositFactor` as well as `AnnouncementDepositBase` if there are no other pending announcements. The dispatch origin for this call must be _Signed_ and a proxy of `real`. Parameters: - `real`: The account that the proxy will make a call on behalf of. - `call_hash`: The hash of the call to be made by the `real` account.
7remove_announcement
call_hash: H256
Remove a given announcement. May be called by a proxy account to remove a call they previously announced and return the deposit. The dispatch origin for this call must be _Signed_. Parameters: - `real`: The account that the proxy will make a call on behalf of. - `call_hash`: The hash of the call to be made by the `real` account.
8reject_announcement
delegate: MultiAddress
call_hash: H256
Remove the given announcement of a delegate. May be called by a target (proxied) account to remove a call that one of their delegates (`delegate`) has announced they want to execute. The deposit is returned. The dispatch origin for this call must be _Signed_. Parameters: - `delegate`: The account that previously announced the call. - `call_hash`: The hash of the call to be made.
9proxy_announced
delegate: MultiAddress
force_proxy_type: Option
Dispatch the given `call` from an account that the sender is authorized for through `add_proxy`. Removes any corresponding announcement(s). The dispatch origin for this call must be _Signed_. Parameters: - `real`: The account that the proxy will make a call on behalf of. - `force_proxy_type`: Specify the exact proxy type to be used and checked for this call. - `call`: The call to be made by the `real` account.
10poke_depositnonePoke / Adjust deposits made for proxies and announcements based on current values. This can be used by accounts to possibly lower their locked amount. The dispatch origin for this call must be _Signed_. The transaction fee is waived if the deposit amount has changed. Emits `DepositPoked` if successful.
11set_real_pays_fee
delegate: MultiAddress
pays_fee: bool
Set whether the real account pays transaction fees for proxy calls made by a specific delegate. The dispatch origin for this call must be _Signed_ and must be the real (delegator) account that has an existing proxy relationship with the delegate. Parameters: - `delegate`: The proxy account for which to set the fee payment preference. - `pays_fee`: If `true`, the real account will pay fees for proxy calls made by this delegate. If `false`, the delegate pays (default behavior).

SCALE Encoding

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

Examples

proxy = proxy(real, force_proxy_type, call)
0x00<field0><field1><field2>
00 Variant index 0 = proxy
field 0 real: MultiAddress
field 1 force_proxy_type: Option
field 2 call: RuntimeCall
add_proxy = add_proxy(delegate, proxy_type, delay)
0x01<field0><field1><field2>
01 Variant index 1 = add_proxy
field 0 delegate: MultiAddress
field 1 proxy_type: ProxyType
field 2 delay: u32
remove_proxy = remove_proxy(delegate, proxy_type, delay)
0x02<field0><field1><field2>
02 Variant index 2 = remove_proxy
field 0 delegate: MultiAddress
field 1 proxy_type: ProxyType
field 2 delay: u32

Code Examples

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

const registry = new TypeRegistry();

// Encode Proxy::Call — variant "proxy"
const value = registry.createType("Proxy::Call", { proxy: { real: 0, force_proxy_type: 0, call: 0 } });
console.log("Hex:", value.toHex());

Type Parameters

T

Referenced By (23)

and 3 more...

Also See

Type Information

Type ID
169
Kind
Variant
Path
pallet_subtensor_proxy::pallet::Call
Runtime
v393