Transactions
set-subnet-identity
Publish identity metadata for a subnet (signer must be the subnet owner).
Stores the subnet's public profile — name, links, contact, logo — so
explorers and participants can identify it. Owner-only: the signing
coldkey must own the subnet. Everything submitted is public and permanent
history on chain. Calling again overwrites the whole record (empty fields
clear their previous values); the chain enforces length limits on each
field. Purely cosmetic — for the token ticker use update_symbol, and
for economics use set_hyperparameter.
| Signer | Origin | Pallet | Wraps |
|---|---|---|---|
coldkey | subnet owner | SubtensorModule | SubtensorModule.set_subnet_identity |
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
netuid | integer | yes | Subnet the identity is for; the signer must be its owner. |
subnet_name | string | yes | Display name shown for the subnet. |
github_repo | string | no | GitHub repository URL for the subnet's code. |
subnet_contact | string | no | Contact address for the subnet operators. |
subnet_url | string | no | Website for the subnet. |
discord | string | no | Discord handle or server invite. |
description | string | no | Short free-text description of what the subnet does. |
logo_url | string | no | Logo image URL for the subnet. |
additional | string | no | Any extra free-text information to publish. |
Address parameters (--hotkey, --coldkey, --dest, ...) accept a raw ss58
address, an address-book or proxy-book name, or a local wallet/hotkey name.
CLI
Preview with --dry-run (shows fee, effects, and policy result without
submitting), then submit:
btcli tx set-subnet-identity \
--netuid <int> \
--subnet-name <value> --dry-run
btcli tx set-subnet-identity \
--netuid <int> \
--subnet-name <value> -w my_coldkeyPython
import bittensor as bt
from bittensor.wallet import Wallet
wallet = Wallet(name="my_coldkey", hotkey="my_hotkey")
intent = bt.SetSubnetIdentity(netuid=1, subnet_name="...")
sub = bt.Subtensor()
plan = sub.plan(intent, wallet) # fee, effects, policy — no submission
result = sub.execute(intent, wallet)
if not result.success:
print(result.error.code, result.error.remediation)(bt.Subtensor is also the async client — async with bt.Subtensor() as client:
— see The client.) Or build the intent by op name, as
an agent would:
result = sub.execute_tool("set_subnet_identity", {...}, wallet)On-chain implementation
SubtensorModule.set_subnet_identity — pallets/subtensor/src/macros/dispatches.rs#L1155:
#[pallet::call_index(78)]
#[pallet::weight(<T as crate::pallet::Config>::WeightInfo::set_subnet_identity())]
pub fn set_subnet_identity(
origin: OriginFor<T>,
netuid: NetUid,
subnet_name: Vec<u8>,
github_repo: Vec<u8>,
subnet_contact: Vec<u8>,
subnet_url: Vec<u8>,
discord: Vec<u8>,
description: Vec<u8>,
logo_url: Vec<u8>,
additional: Vec<u8>,
) -> DispatchResult {
Self::do_set_subnet_identity(
origin,
netuid,
subnet_name,
github_repo,
subnet_contact,
subnet_url,
discord,
description,
logo_url,
additional,
)
}Delegates to do_set_subnet_identity.
Every file is browsable under /code exactly as built into the runtime, or as plain text under /code/raw/<path> (index: /code/index.json).