DepositSlashed

Event v154 → current #5

Emitted when a deposit is slashed (not returned) due to abuse.

View events on chain
Useful for: validatorsdevelopersanalytics

The Big Picture

Someone's deposit was confiscated because governance determined their safe-mode activation was frivolous or malicious. This is the enforcement mechanism that gives deposits teeth - without slashing risk, deposits would just be temporary locks.

Use Cases

  • Track governance enforcement actions
  • Build reputation systems based on safe-mode behavior
  • Monitor for abuse patterns

From Chain Metadata

An account had reserve slashed that was reserved.

Triggers

Preconditions

  • Account has a deposit at the specified block
  • ForceDepositOrigin authorized slash

Effects

Storage Modified

Postconditions

  • Deposit is forfeited (not returned to account)
  • Deposit entry removed from storage

Side Effects

  • Slashed funds typically go to treasury

Event Data

#NameTypeDescription
0
account
AccountId Account whose deposit was slashed (hex -> SS58)
1
amount
u64 BalanceOf<T>Slashed deposit amount (RAO) (RAO -> TAO (/ 10^9))

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 DepositSlashed events
client.finalizedBlock$.subscribe(async (block) => {
  const events = await api.event.SafeMode.DepositSlashed.get(block.hash);
  for (const evt of events) {
    console.log("DepositSlashed:", evt.payload);
  }
});

Runtime Info

Pallet Index
20
Event Index
5
First Version
v154
Current Version
v411