Skip to main content

A professional CLI for managing Bittensor subnet pool operations

Project description

🌊 poolcli

A command-line interface for managing Bittensor subnet pool operations. poolcli simplifies wallet authentication, developer key management, and pool administration through an intuitive CLI.

Features

  • Wallet Authentication: Seamless Bittensor wallet integration with secure token management
  • Developer Key Management: Create, list, and manage developer keys with invoice tracking
  • Pool Management: Create, list, and inspect subnet pools
  • Session Management: Automatic token caching and re-authentication support

Installation

pip install poolcli
or
uv add poolcli

Or install from source:

git clone <repository-url>
cd poolcli
pip install -e .

Requirements

  • Python 3.10+

Quick Start

1. Authenticate

poolcli auth login --wallet-name my_wallet

You'll be prompted for your hotkey (defaults to "default" if not specified).

2. View Your Wallets

poolcli wallet list

This displays all available coldkeys and their associated hotkeys with addresses.

3. Create a Developer Key

poolcli key create --wallet-name my_wallet

This command will:

  • Authenticate with your wallet
  • Create an invoice for a developer key
  • Prompt for payment in TAO
  • Optionally create a pool after successful payment

4. Create a Pool

poolcli pool create --wallet-name my_wallet

5. View Your Pools

poolcli pool list --wallet-name my_wallet

Command Reference

Authentication (auth)

Manage authentication and sessions.

poolcli auth login

Authenticate with your Bittensor wallet.

poolcli auth login \
  --wallet-name my_wallet \
  --hotkey default \
  --force  # Force re-authentication

Options:

  • --wallet-name (required): Your Bittensor wallet name
  • --hotkey: Hotkey name (defaults to "default")
  • --backend-url: Backend API URL
  • --force: Force re-authentication even if a valid session exists

poolcli auth status

Check your current authentication status.

poolcli auth status --wallet-name my_wallet

poolcli auth logout

Clear all stored authentication tokens.

poolcli auth logout

Key Management (key)

Manage developer keys and invoices.

poolcli key create

Create a new developer key invoice and optionally proceed with payment.

poolcli key create \
  --wallet-name my_wallet \
  --hotkey default \

Options:

  • --wallet-name (required): Your Bittensor wallet name
  • --hotkey: Hotkey to use for the key (defaults to "default")
  • --backend-url: Backend API URL
  • --force: Force re-authentication

poolcli key list

List all developer keys for your wallet.

poolcli key list \
  --wallet-name my_wallet \
  --page 1 \
  --limit 15 \
  --status active

Options:

  • --wallet-name (required): Your Bittensor wallet name
  • --page: Page number for pagination (default: 1)
  • --limit: Number of keys per page (default: 15)
  • --status: Filter by status: active, expired, or unused
  • --backend-url: Backend API URL

poolcli key invoice get

Check the status of a specific invoice.

poolcli key invoice get <invoice-id> --wallet-name my_wallet

Arguments:

  • invoice-id: The invoice ID to check

Options:

  • --wallet-name (required): Your Bittensor wallet name
  • --backend-url: Backend API URL

Pool Management (pool)

Manage your Bittensor subnet pools.

poolcli pool create

Create a new pool for your wallet.

poolcli pool create \
  --wallet-name my_wallet \
  --hotkey default \

Options:

  • --wallet-name (required): Your Bittensor wallet name
  • --hotkey: Hotkey to use for the pool (defaults to "default")
  • --backend-url: Backend API URL
  • --force: Force re-authentication

poolcli pool list

List all pools for your wallet.

poolcli pool list \
  --wallet-name my_wallet \
  --page 1 \
  --limit 15

Options:

  • --wallet-name (required): Your Bittensor wallet name
  • --page: Page number for pagination (default: 1)
  • --limit: Number of pools per page (default: 15)
  • --backend-url: Backend API URL
  • --force: Force re-authentication

poolcli pool show

View detailed information about a specific pool.

poolcli pool show <pool-id> --wallet-name my_wallet

Arguments:

  • pool-id: The pool ID to inspect

Options:

  • --wallet-name (required): Your Bittensor wallet name
  • --backend-url: Backend API URL

Wallet Management (wallet)

Inspect your Bittensor wallets.

poolcli wallet list

Display all available coldkeys and their associated hotkeys with addresses.

poolcli wallet list

This command scans your wallet directory and displays public key information (no password required).

Global Options

poolcli --version      # Show version and exit
poolcli --commands     # Show all available commands and exit
poolcli --help         # Show help message and exit

Wallet Storage

Bittensor wallets are typically stored in ~/.bittensor/wallets/. The wallet list command reads from this directory.

Common Workflows

Complete Setup Workflow

# 1. View available wallets
poolcli wallet list

# 2. Authenticate
poolcli auth login --wallet-name my_wallet

# 3. Create a developer key
poolcli key create --wallet-name my_wallet

# 4. Check key status
poolcli key list --wallet-name my_wallet --status active

# 5. Create a pool
poolcli pool create --wallet-name my_wallet

# 6. View your pools
poolcli pool list --wallet-name my_wallet

Check Invoice Status

# Create invoice
poolcli key create --wallet-name my_wallet

# Check status later
poolcli key invoice get <invoice-id> --wallet-name my_wallet

Development

Installation for Development

git clone <repository-url>
cd poolcli
pip install -e ".[dev]"

License

GNU GENERAL PUBLIC LICENSE Version 2

Support

For issues, questions, or contributions, please create issue in github.

See Also

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

poolcli-1.0.2.tar.gz (24.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

poolcli-1.0.2-py3-none-any.whl (33.7 kB view details)

Uploaded Python 3

File details

Details for the file poolcli-1.0.2.tar.gz.

File metadata

  • Download URL: poolcli-1.0.2.tar.gz
  • Upload date:
  • Size: 24.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.4

File hashes

Hashes for poolcli-1.0.2.tar.gz
Algorithm Hash digest
SHA256 f9455e578eee1eee487008ee618f2b87990bd79d84a2ca2aaa3e58ed470790fd
MD5 6e493a2d53632c3c388a2712f1fd952b
BLAKE2b-256 44c067565aeb1dad1e1549cfc987cdfb2d8909304846fd9d9a0fd5db12ebae73

See more details on using hashes here.

File details

Details for the file poolcli-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: poolcli-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 33.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.4

File hashes

Hashes for poolcli-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 2efbd6ee04a9440cb1329b7a0f7689f16a49502a05af87929666c667b10bf0bf
MD5 8b8ca318bfbb23f7ef06f5283917c896
BLAKE2b-256 291d3f449c899a96a735cc068567d4517fba43b76c5b37ba1ba05ce9f253ee91

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page