ProxyRemoved

Event v149 → v323, v326 → current #5

Emitted when a proxy is unregistered from an account.

View events on chain
Useful for: stakersvalidatorsdeveloperswalletsanalytics

The Big Picture

Proxy removal revokes all permissions for that proxy.

Use Cases

  • Track when proxy permissions are revoked

From Chain Metadata

A proxy was removed.

Triggers

Preconditions

  • Proxy exists
  • Called by delegator

Effects

Storage Modified

Postconditions

  • Proxy removed
  • Deposit returned

Event Data

#NameTypeDescription
0
delegator
AccountId Account that revoked proxy permission (hex -> SS58)
1
delegatee
AccountId Account whose proxy permission was revoked (hex -> SS58)
2
proxy_type
ProxyType Type of proxy permission removed
3
delay
u32 BlockNumberFor<T>Delay that was configured for this proxy

Code Examples

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);

// Subscribe to ProxyRemoved events
client.finalizedBlock$.subscribe(async (block) => {
  const events = await api.event.Proxy.ProxyRemoved.get(block.hash);
  for (const evt of events) {
    console.log("ProxyRemoved:", evt.payload);
  }
});

Version History

v149 block 3,014,339 4 args
v326 block 6,608,228 4 args Current

Runtime Info

Pallet Index
16
Event Index
5
First Version
v149
Current Version
v411