remove_proxy

Call v149 → current #2

Remove a previously registered proxy .

View calls on chain

Click items to navigate. Pan and zoom to explore.

Used by: stakersvalidatorsdeveloperswallets

The Big Picture

Removing proxies revokes their permissions and recovers deposits.

Use Cases

  • Revoke compromised proxy
  • Clean up unused proxies
  • Rotate proxy keys

From Chain Metadata

See [`Pallet::remove_proxy`].

Input Parameters

#NameTypeDescription
0
delegate
MultiAddress AccountIdLookupOf<T>Proxy account to remove authorization from
1
proxy_type
ProxyType Type of proxy permission to remove
2
delay
u32 BlockNumberFor<T>Delay that was configured for this proxy

Permissions

Origin
Unknown
Required Role

Permission data inferred from metadata. May be incomplete.

Requirements

  • Proxy exists
  • Caller is the account that added the proxy

Effects

Events Emitted

Storage Modified

Postconditions

  • Proxy removed
  • Deposit returned
  • ProxyRemoved event emitted

Side Effects

  • Proxy can no longer act on behalf of the account

Code Examples

// ----------------------------------------------------------------------
// HEADS UP: 2 args below have a complex type with no usable default.
// Look for `undefined as any` and replace them with real values
// before running — the snippet compiles, but will fail at runtime as-is.
// ----------------------------------------------------------------------
import { createClient, Binary } from "polkadot-api";
import { getWsProvider } from "polkadot-api/ws";
import { sub } from "@polkadot-api/descriptors"; // generated by: npx papi add sub -w wss://entrypoint-finney.opentensor.ai:443

const client = createClient(getWsProvider("wss://entrypoint-finney.opentensor.ai:443"));
const api = client.getTypedApi(sub);

// Build remove_proxy call (typed, named args)
const delegate = undefined as any /* MultiAddress — replace with real value */;
const proxy_type = undefined as any /* ProxyType — replace with real value */;
const delay = 0;

const tx = api.tx.Proxy.remove_proxy({
  delegate,
  proxy_type,
  delay,
});

Runtime Info

Pallet Index
16
Call Index
2
First Version
v149
Current Version
v411