Unreserved

Event v101 → current #5

Emitted when balance is moved from reserved to free.

View events on chain

From Chain Metadata

Some balance was unreserved (moved from reserved to free).

Triggers

Emitted by

Preconditions

  • Account has sufficient reserved balance
  • Unreserve operation requested

Effects

Storage Modified

Postconditions

  • Reserved balance decreased
  • Free balance increased

Side Effects

  • Balance now available for transfers

Event Data

#NameTypeDescription
0
who
AccountId who: Account address (32 bytes, SS58-encoded) (hex -> SS58)
1
amount
u64 T::Balanceamount: Balance in chain native currency (RAO for TAO; ÷10⁹) (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 Unreserved events
client.finalizedBlock$.subscribe(async (block) => {
  const events = await api.event.Balances.Unreserved.get(block.hash);
  for (const evt of events) {
    console.log("Unreserved:", evt.payload);
  }
});

Runtime Info

Pallet Index
5
Event Index
5
First Version
v101
Current Version
v411