Skip to main content
The official Octav CLI lets you interact with the Octav API directly from your terminal. Built in Rust for speed, it outputs structured JSON — making it ideal for shell scripts, CI pipelines, and AI agent tool-use.
Quick Install — One command to get started:

Why Use the CLI?

AI Agent Tool-Use

Structured JSON output that AI agents can parse and act on — no SDK or HTTP client needed

Terminal Workflows

Pipe portfolio data into jq, scripts, cron jobs, or monitoring systems

Fast & Lightweight

Written in Rust — single binary, no runtime dependencies, instant startup

x402 Agent Payments

Built-in support for the x402 payment protocol — AI agents can pay per request without API keys

Installation


Authentication

Store your API key once and it’s used automatically for all commands.
The API key is resolved in priority order:
  1. --api-key flag (highest precedence)
  2. OCTAV_API_KEY environment variable
  3. ~/.octav/config.json config file
For AI agent workflows, set the OCTAV_API_KEY environment variable so the agent doesn’t need to manage config files.

Commands

Portfolio

Full portfolio including DeFi positions across all chains.
Cost: 1 credit per address
Wallet token balances only (excludes DeFi protocol positions).
Cost: 1 credit per address
Net asset value in a specified currency.
Supported fiat currencies: USD (default), EUR, CAD, AED, CHF, SGD. Crypto: ETH, SOL, cbBTC, EURC, BNB.Cost: 1 credit per address
Aggregated token distribution across all chains for a specific date.
Cost: 1 credit per address

Transactions

Query transaction history with filtering and pagination.
Cost: 1 credit per address
Trigger manual transaction synchronization.
Cost: 1 credit per address

Historical

Portfolio snapshot for a specific date.
Cost: 1 credit per address
Subscribe to automatic daily portfolio snapshots.
Cost: 1 credit per address

Metadata & Specialized

Check sync status for addresses.
Cost: Free
Check API credit balance.
Cost: Free
Check Solana airdrop eligibility.
Cost: 1 credit
Get Polymarket prediction market positions.
Cost: 1 credit

Agent Commands (x402)

For AI agents that pay per request using the x402 payment protocol — no API key required.
Use these only when the user explicitly asks for x402, or when the agent has a funded wallet and no API key — otherwise use the API-key commands above. Only wallet, portfolio, nav, status, and chains are available over x402; everything else, including transaction history, needs an API key. See Agent Endpoints (x402).
Wallet holdings via x402 payment.
Full portfolio via x402 payment.

Using with AI Agents

The CLI outputs structured JSON, making it a natural fit for AI agent tool-use. Agents can invoke octav commands via shell execution and parse the JSON response directly.

Example: Claude Code / Cursor Agent

The agent runs:
And receives structured JSON it can reason over.

Example: Autonomous Monitoring Script

Output Format

All commands return JSON. Pretty-printed by default, compact with --raw:
The --raw flag also disables field stripping, returning the full API response.

Multiple Addresses

Most commands accept multiple addresses as a comma-separated list:
Maximum 10 addresses per request.

Error Handling

Errors are returned as JSON on stdout with a non-zero exit code:

Resources

GitHub

Source code and issues

API Docs

Full REST API reference

Pricing

Credit packages and costs