SubtokenEnabled
Storage Map v273 → v411Whether subtoken trading is enabled per subnet .
Explore chainQueried by: stakerssubnet ownersdevelopers
The Big Picture
Each subnet has alpha tokens. This toggle controls whether trading of these tokens is enabled. When disabled, alpha cannot be traded directly.
Use Cases
- Check if trading is enabled
- Plan trading strategies
- Build trading interfaces
From Chain Metadata
MAP ( netuid ) --> If subtoken trading enabled
Purpose & Usage
Purpose
Toggle subnet token (alpha) trading.
Common Query Patterns
- Query by netuid
Query Keys
| # | Name | Type | Description |
|---|---|---|---|
| 1 | netuid | u16 | netuid (u16, hashed key component) |
Stored Value
If (bool)
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);
// Query SubtokenEnabled storage
const netuid = 1;
const result = await api.query.SubtensorModule.SubtokenEnabled.getValue(netuid);
console.log("SubtokenEnabled:", result);Version History
v273 block 5,659,032 Added
v278–v289 · runtime versions skipped on chain (never deployed)
v290 block 5,947,548 Internal re-bind Current
Runtime Info
View Source- Pallet
- SubtensorModule
- Storage Kind
- Map
- First Version
- v273
- Current Version
- v411