Spectrum CLI is now LIVE!

Spectrum CLI is a command line tool that gives developers and AI agents blockchain data across 24 chains from a single install.
It provides 96 commands spanning EVM chains, Solana, Bitcoin, Cosmos, and Starknet, returns raw JSON by default, and ships a machine readable catalog of every command so an agent can learn the entire tool in one call. It runs on Node.js 20 or later, is MIT licensed, and installs with one npm command.
npm install -g @spectrumnodes/cli
Spectrum CLI at a Glance
- What It Is: Command line interface for the Spectrum API
- Built For: Developers, analysts, and AI agents
- Commands: 96, across 14 namespaces
- Chains: 24 (16 EVM, plus Solana, Bitcoin, Starknet, and 5 Cosmos chains)
- Agent Interface:
spectrum commandsemits a full JSON Schema catalog - Default Output: Raw JSON, with
--humanfor aligned tables - Install:
npm install -g @spectrumnodes/cli - Requires: Node.js 20 or later, plus a Spectrum API endpoint
- License: MIT
The Problem With Giving Agents Onchain Data
An AI agent that needs blockchain data today inherits the same bad options a developer does. You can hand it an SDK it has to write and compile code against. You can hand it a pile of JSON RPC method names to memorize and payloads to format by hand. Or you can point it at a block explorer it cannot use at all, because a web page is not a tool an agent can call.
Every one of those means bespoke integration work, and every one of them breaks the moment the agent reaches for a chain or protocol it was not wired for. What an agent actually needs is a single tool it can read, understand, and call across every chain, with output that flows straight back into its loop. That is what Spectrum CLI is built to be.
A Catalog Your Agent Reads Once
Most command line tools expect a human to read a --help tree. That works poorly when the thing calling your tool is a language model. So Spectrum ships its command surface as data.
spectrum commands
That single call returns all 96 commands, each with its arguments and a full JSON Schema, including which chains and protocols are valid for that command. An agent reads the catalog once and can then construct any query across all 24 chains. Drop it into the agent's context or a tool definition, and there is no wrapper to maintain and no handwritten description that drifts out of date the next time the CLI ships.
JSON for Machines, Tables for People
Spectrum CLI returns raw JSON by default, which is exactly what an agent, a script, or a CI job wants to consume.
spectrum prices price ETH | jq .priceUsd
Output pipes cleanly into jq and composes with standard shell tooling. Errors are written to stderr rather than stdout, so pipes stay clean, and exit codes are consistent enough for an agent or a script to branch on. When a person is the one reading, the --human flag renders aligned tables instead. Same command, two audiences.
Fewer Failed Calls by Design
For an agent, a call that cannot succeed is a wasted turn and wasted tokens. Spectrum reduces those by refusing to offer the impossible.
Each command derives its valid chains from a central registry and offers only the chains where that protocol is actually deployed. Requesting a Uniswap v3 quote on a chain where the quoter contract was never deployed is a common source of failed calls, so defi uniswap-v3-quote lists the exact chains where the quoter exists rather than every chain the protocol is nominally associated with. Arguments and chains are validated before any network request. Fewer dead ends for a person, fewer wasted steps for an agent.

What You Can Query
Spectrum CLI covers token balances and portfolios, DeFi positions, NFT ownership, ENS resolution, yields, prices, gas comparisons, smart contract reads, and raw JSON RPC.
DeFi coverage includes Uniswap v2, v3, and v4 quotes, Curve and LlamaLend, Pendle, Aave, Jupiter swaps on Solana, and perps funding rates from Hyperliquid and dYdX.
Read Only by Design
Spectrum CLI reads data and builds unsigned transactions, such as an approval revoke. It does not sign transactions and it does not broadcast them.
In an agent workflow, that boundary is a feature. The agent can prepare a transaction, but the decision to sign and send stays with a human or a wallet you control. Credentials help too: your API endpoint lives in a config file with owner only permissions and is masked wherever it prints.
What Do You Want To Do?
- Fetch a wallet balance on any chain:
spectrum tokens balance <address> --human - Get a live swap quote:
spectrum defi uniswap-v3-quote <in> <out> <amount> --chain base - Compare gas across every chain at once:
spectrum core gas-comparison --human - Pipe a value into a script:
spectrum prices price ETH | jq .priceUsd - Give an agent the whole tool surface:
spectrum commands
How Do You Install Spectrum CLI?
Spectrum CLI requires Node.js 20 or later. Installation and first query take three lines:
npm install -g @spectrumnodes/cli spectrum config set api <your-endpoint> spectrum tokens balance 0xd8dA...96045 --human
The first command installs the CLI globally and puts spectrum on your PATH. The second points it at your Spectrum API endpoint. The third returns a balance.
Frequently Asked Questions
Can an AI Agent Use Spectrum CLI Without a Custom Integration?
Yes. Running spectrum commands returns a machine readable catalog of all 96 commands with a full JSON Schema for each, including valid chains and protocols. An agent reads it once and can construct any query across 24 chains.
Is Spectrum CLI 96 Commands per Chain?
No. There are 96 commands in total, spanning 24 chains. Individual commands support the subset of chains where the relevant protocol is deployed.
Can Spectrum CLI Execute Trades?
No. Spectrum CLI reads data and constructs unsigned transactions such as approval revokes. Signing and broadcasting stay with the user.
Which Chains Does Spectrum CLI Support?
Ethereum, Polygon, BSC, Optimism, Base, Avalanche, Arbitrum, Gnosis, Berachain, Moonbeam, Monad, Linea, Hyperliquid, Scroll, Plasma, X Layer, Solana, Bitcoin, Starknet, Cosmos Hub, Osmosis, Axelar, Noble, and Agoric.
Full command reference and quickstart: spectrum.com/cli
