ReserveRepatriated
Event v101 → v424, v432 → current #6Emitted when reserved balance is moved from one account to another.
View events on chainThe Big Picture
Reserve repatriation moves reserved funds from one account to another without going through the free balance. This is used in scenarios like slashing (moving reserved collateral to a beneficiary) or deposit transfers. The destination_status determines whether the funds become free or reserved in the receiving account.
Use Cases
- Track reserve transfers between accounts
- Monitor slashing or deposit reallocation
- Build reserve balance tracking tools
From Chain Metadata
Some balance was moved from the reserve of the first account to the second account. Final argument indicates the destination balance type.
Migration Notes
amount changed from u64 to TaoBalance
Update decoders: SCALE encoding is positional, so any signature change (added, removed, or type-changed fields, or storage shape changes) shifts byte offsets and existing decoders will misparse this item. Re-derive types from the new metadata.
Triggers
Preconditions
- Source account has sufficient reserved balance
- Repatriation operation authorized
Effects
Postconditions
- Source reserved balance decreased
- Destination balance increased (reserved or free based on status)
Side Effects
- May affect existential deposit calculations for both accounts
Event Data
| # | Name | Type | Description |
|---|---|---|---|
| 0 | from | AccountId | from: Account address (32 bytes, SS58-encoded) (hex -> SS58) |
| 1 | to | AccountId | to: Account address (32 bytes, SS58-encoded) (hex -> SS58) |
| 2 | amount | TaoBalance T::Balance | amount: Balance in chain native currency (RAO for TAO; ÷10⁹) |
| 3 | destination_status | BalanceStatus Status | destination_status (BalanceStatus) |
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 ReserveRepatriated events
client.finalizedBlock$.subscribe(async (block) => {
const events = await api.event.Balances.ReserveRepatriated.get(block.hash);
for (const evt of events) {
console.log("ReserveRepatriated:", evt.payload);
}
});Version History
Runtime Info
- Pallet Index
- 5
- Event Index
- 6
- First Version
- v101
- Current Version
- v472