Skip to content

The full metagraph of one subnet

GET
/metagraph/{netuid}/

Every neuron of one subnet and mechanism (mechid), by uid: its keys and role, stake, consensus scores, emission and daily rewards in alpha, TAO and USD, axon address and registration, with a summary of the subnet. Unpaginated.

Rate limit: 600 requests per minute per IP (scope anon).

Stable: the operation and its fields leave only after 180 days of notice.

  • None
netuid
required
integer

Subnet netuid. 0 is root.

mechid
integer

Mechanism to read. Default 0; an unparseable value silently reads as 0.

Every neuron of the mechanism by uid, with a summary of the subnet.

Media typeapplication/json
object
subnet
required

The subnet the neurons belong to, as of its latest read.

object
id
required

Netuid.

integer
name
required

The name the owner’s on-chain identity gives the subnet, else the chain’s default name for the netuid.

string
symbol
required

The subnet token’s symbol.

string
price
required

In TAO per alpha. The spot price of the subnet token; 1 on root.

number format: double
emission_value
required

In TAO per block. What the subnet receives each block: the pool injection plus the chain’s alpha buys.

number format: double
registration_cost
required

In TAO. The current burn to register a neuron on this subnet.

number format: double
blocks_since_epoch
required

In blocks. Blocks since the subnet’s last epoch.

integer
tempo
required

In blocks. Blocks between two epochs.

integer
modality
required

Legacy field, always 0.

integer
mechanism_count
required

Incentive mechanisms on this subnet.

integer
mechanism_emission_split
required

Whole percent of emission per mechanism; [] when unset, which splits emission evenly.

identity
required

Null when the subnet has no on-chain identity.

object
ss58_address
required

The owner coldkey; null when the subnet has no owner.

string
nullable
name
required

The name the identity gives the subnet, else the chain’s default name for the netuid. Null after the owner removed the identity.

string
nullable
image
required

The logo URL as published on chain.

string
nullable
count
required

Neurons in neurons.

integer
neurons
required

The neurons of the requested mechanism, by uid.

Array<object>
object
uid
required
integer
mechid
required

The mechanism of this row, the one mechid selects.

integer
hotkey
required
string
coldkey
required
string
identity
required

The on-chain identity of the hotkey, else of the coldkey; null when neither has one.

object
name
required

The display name published on chain, or a label Taoswap curates for accounts such as exchange wallets.

string
nullable
url
required

Website.

string
nullable
github
required

Code repository URL.

string
nullable
image
required

Absolute URL of the logo Taoswap hosts when it has one, else the logo URL published on chain.

string
nullable
image_thumb
required

Absolute URL of image fit within 64 px, as WebP, for small renderings; null when image is not a raster logo Taoswap hosts (an SVG, an on-chain URL, empty) or its thumbnail is not written yet.

string
nullable
discord
required

Discord contact, as the account wrote it.

string
nullable
description
required

Free text describing the account, as published on chain.

string
nullable
additional
required

Free text the account added to its identity.

string
nullable
x_id
required

The X (Twitter) handle, without @. Curated by Taoswap, not on chain.

string
nullable
type
required

owner, validator or miner.

string
status
required

IMMUNE while the neuron is inside its subnet’s immunity period from registration, ACTIVE after.

string
is_validator
required

True for a staked hotkey setting weights, or a permit holder earning no miner incentive.

boolean
is_owner
required

True when the subnet owner’s coldkey or owner hotkey controls this uid.

boolean
stake
required

In alpha. Its stake weight, not a balance: alpha stake plus the TAO weight times root stake, childkeys included.

number format: double
vtrust
required

A fraction from 0 to 1: how closely this validator’s weights agree with consensus.

number format: double
consensus
required

A fraction from 0 to 1: this uid’s share of consensus weight at the last epoch.

number format: double
dividends
required

A fraction from 0 to 1: this uid’s share of the subnet’s dividends at the last epoch.

number format: double
incentive
required

A fraction from 0 to 1: this uid’s share of miner incentive in this mechanism at the last epoch.

number format: double
emission
required

In alpha per epoch. The emission paid to this uid at the last epoch, withheld owner incentive excluded.

number format: double
emission_withheld
required

In alpha per epoch. What the chain withholds from this uid, an owner hotkey’s incentive, recycled or burned. emission and the daily rewards exclude it.

number format: double
emission_tao
required

In TAO per epoch. emission at token.price.

number format: double
emission_usd
required

In USD per epoch. emission_tao at the latest daily TAO price.

number format: double
daily_rewards
required

In TAO per day. daily_rewards_alpha at token.price.

number format: double
daily_rewards_alpha
required

In alpha per day. emission times the subnet’s epochs per day.

number format: double
daily_rewards_usd
required

In USD per day. daily_rewards at the latest daily TAO price.

number format: double
token
required

The subnet’s token, whose current price converts emission_tao and daily_rewards.

object
symbol
required

The subnet token’s symbol, often a single non-Latin character.

string
price
required

In TAO per alpha. The subnet’s current spot price; 1 on root.

number format: double
ip
required

Axon IP address; null when the neuron serves no axon.

string
nullable
port
required

Axon port; null when the neuron serves no axon.

integer
nullable
block_at_registration
required

The block at which this uid registered; 0 when unknown.

integer
registration_cost
required

In TAO. The subnet’s current registration burn, the same on every row, not what this neuron paid.

number format: double
updated_at_block
required

The block of the last chain read of this neuron’s mechanism.

integer
last_update
required

In blocks. Blocks since the neuron last set weights, not a block number.

integer
nullable
last_update_block
required

The block at which the neuron last set weights; its registration block when it never did.

integer
delegate_take
required

Percent: the share of stakers’ dividends this hotkey keeps; 0 on rows that are not validators.

number format: double
childkey_take
required

Percent: the take kept on parent stake, at least the subnet’s floor; 0 on rows that are not validators.

number format: double

Examples

ExampleMetagraph

Subnet 64, one validator and one miner

{
"subnet": {
"id": 64,
"name": "Chutes",
"symbol": "ش",
"price": 0.068190336,
"emission_value": 0.044017191,
"registration_cost": 0.0005,
"blocks_since_epoch": 333,
"tempo": 360,
"modality": 0,
"mechanism_count": 1,
"mechanism_emission_split": [],
"identity": {
"ss58_address": "5FRYKhbmfXPDoHdUUDMx27E3HuMvAzwjzFMMq3rNurUhAyS9",
"name": "Chutes",
"image": "https://storage.googleapis.com/chutes-random/logo-chutes.png"
}
},
"count": 2,
"neurons": [
{
"uid": 46,
"mechid": 0,
"stake": 333625.607993428,
"vtrust": 0.9975432974746319,
"consensus": 0,
"dividends": 0.08833447775997559,
"incentive": 0,
"emission": 13.039988594,
"emission_withheld": 0,
"emission_tao": 0.8860031334183606,
"emission_usd": 230.14817393675332,
"daily_rewards": 17.72006266836721,
"daily_rewards_alpha": 260.79977188,
"daily_rewards_usd": 4602.963478735066,
"token": {
"symbol": "ش",
"price": 0.067945085
},
"coldkey": "5E9fVY1jexCNVMjd2rdBsAxeamFGEMfzHcyTn2fHgdHeYc5p",
"hotkey": "5CAAxTpdKUAkQ28aYAPABGXxSGpAkQ6u8jQPwmg5mMaKpQ1C",
"identity": {
"name": "Yuma, a DCG Company",
"url": "https://yumaai.com/",
"github": "",
"image": "https://api.taoswap.org/static/identities/curated/accounts/5E9fVY1jexCNVMjd2rdBsAxeamFGEMfzHcyTn2fHgdHeYc5p.png",
"image_thumb": "https://api.taoswap.org/static/identities/thumbs/curated/accounts/5E9fVY1jexCNVMjd2rdBsAxeamFGEMfzHcyTn2fHgdHeYc5p.png.webp",
"discord": "",
"description": "Yuma powers transformative projects on Bittensor.",
"additional": "",
"x_id": "YumaGroup"
},
"ip": null,
"port": null,
"block_at_registration": 5158401,
"registration_cost": 0.0005,
"type": "validator",
"status": "ACTIVE",
"is_validator": true,
"is_owner": false,
"updated_at_block": 9345556,
"last_update": 2181,
"last_update_block": 9345529,
"delegate_take": 17.9995422293431,
"childkey_take": 17.9995422293431
},
{
"uid": 207,
"mechid": 0,
"stake": 480.774706749,
"vtrust": 0,
"consensus": 0.20018310826276037,
"dividends": 0,
"incentive": 0.20036621652552072,
"emission": 29.575319904,
"emission_withheld": 0,
"emission_tao": 2.009497624779472,
"emission_usd": 521.9871030127156,
"daily_rewards": 40.189952495589445,
"daily_rewards_alpha": 591.50639808,
"daily_rewards_usd": 10439.742060254313,
"token": {
"symbol": "ش",
"price": 0.067945085
},
"coldkey": "5FyBy1yBnm1ZLoLGEskzXWLbsCuC9961fkLG1ZTs9DbcnpMB",
"hotkey": "5CSa1rZAzh8Nf9nT9wMBghE6DPzTFoEdWZaRXD6mdVBkVJhw",
"identity": null,
"ip": null,
"port": null,
"block_at_registration": 6613911,
"registration_cost": 0.0005,
"type": "miner",
"status": "ACTIVE",
"is_validator": false,
"is_owner": false,
"updated_at_block": 9345556,
"last_update": 4453165,
"last_update_block": 4894545,
"delegate_take": 0,
"childkey_take": 0
}
]
}

A parameter failed its check, which message names. code is usually VALIDATION_ERROR.

Media typeapplication/json

The error envelope every 4xx and 5xx response carries. The introduction lists the code values.

object
error
required

Always true. Lets a client branch without reading the status code.

boolean
code
required

Machine-readable error code, such as VALIDATION_ERROR or RESOURCE_NOT_FOUND. Branch on it, not on message.

string
message
required

One human-readable sentence.

string
detail
required

Extra context for some codes, such as the invalid fields of a VALIDATION_ERROR or retry_after on RATE_LIMITED; else null.

nullable

Examples

ExampleVALIDATIONERROR

VALIDATION_ERROR

{
"error": true,
"code": "VALIDATION_ERROR",
"message": "Invalid subnet id",
"detail": null
}

RESOURCE_NOT_FOUND. Carries Cache-Control: public, max-age=15, short because a new block or extrinsic is indexed up to a minute late.

Media typeapplication/json

The error envelope every 4xx and 5xx response carries. The introduction lists the code values.

object
error
required

Always true. Lets a client branch without reading the status code.

boolean
code
required

Machine-readable error code, such as VALIDATION_ERROR or RESOURCE_NOT_FOUND. Branch on it, not on message.

string
message
required

One human-readable sentence.

string
detail
required

Extra context for some codes, such as the invalid fields of a VALIDATION_ERROR or retry_after on RATE_LIMITED; else null.

nullable

Examples

ExampleRESOURCENOTFOUND

RESOURCE_NOT_FOUND

{
"error": true,
"code": "RESOURCE_NOT_FOUND",
"message": "Not found",
"detail": null
}

Rate limit exceeded (600/minute, per IP). Retry-After carries the seconds to wait.

Media typeapplication/json

The error envelope every 4xx and 5xx response carries. The introduction lists the code values.

object
error
required

Always true. Lets a client branch without reading the status code.

boolean
code
required

Machine-readable error code, such as VALIDATION_ERROR or RESOURCE_NOT_FOUND. Branch on it, not on message.

string
message
required

One human-readable sentence.

string
detail
required

Extra context for some codes, such as the invalid fields of a VALIDATION_ERROR or retry_after on RATE_LIMITED; else null.

nullable

Examples

ExampleRATELIMITED

RATE_LIMITED

{
"error": true,
"code": "RATE_LIMITED",
"message": "Request was throttled",
"detail": {
"retry_after": 12
}
}
Retry-After
integer

Seconds before the next request is accepted.