Metadata-Version: 2.4
Name: dolomite-cli
Version: 1.0.0
Summary: CLI tool for querying Dolomite protocol data across all chains
Project-URL: Homepage, https://github.com/openclaw/dolomite-cli
License-Expression: MIT
License-File: LICENSE
Keywords: blockchain,cli,defi,dolomite,interest-rates
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Office/Business :: Financial
Requires-Python: >=3.10
Description-Content-Type: text/markdown

# dolomite CLI

Query Dolomite protocol data across all chains. Returns structured JSON. No API keys required.

## Install

```bash
pipx install dolomite-cli
```

Or with pip:

```bash
pip install dolomite-cli
```

Requires Python 3.10+. Zero dependencies (stdlib only).

### From source

```bash
git clone https://github.com/openclaw/dolomite-cli
cd dolomite-cli
pip install -e .
```

## Commands

| Command | Description |
|---------|-------------|
| `dolomite rates` | All markets with supply/borrow rates |
| `dolomite positions` | Top borrowing positions by size |
| `dolomite flows` | Recent large deposits/withdrawals |
| `dolomite liquidations` | Recent liquidation events |
| `dolomite tvl` | Protocol TVL summary per chain |
| `dolomite markets --token USDC` | Detailed info for a specific token |
| `dolomite account <address>` | Full position detail for an address |
| `dolomite risks` | High-risk positions and utilization alerts |
| `dolomite schema` | Show all commands, chains, entities, examples |

## Examples

```bash
# Stablecoin rates across all chains
dolomite rates --stables-only

# Top 20 positions on Ethereum
dolomite positions --chain ethereum --top 20

# Whale flows in the last 48 hours
dolomite flows --hours 48 --min-usd 100000

# Deposits only
dolomite flows --type deposit --hours 72

# Look up a specific whale
dolomite account 0x8be46b25d59616e594f0a9e20147fb14c1b989d9

# High-risk positions (>80% LTV, >$100K)
dolomite risks --min-ltv 80 --min-usd 100000

# Berachain rates only
dolomite rates --chain berachain

# USDC across all chains
dolomite markets --token USDC
```

## Output

All commands output JSON to stdout. Errors go to stderr. Pipe to `jq` for filtering:

```bash
# Top 5 stablecoin rates
dolomite rates --stables-only | jq '.markets[:5][] | {chain, symbol, supply_rate_pct}'

# Total protocol TVL
dolomite tvl | jq '.total_supply_usd'

# Addresses with >85% LTV
dolomite risks --min-ltv 85 | jq '.high_ltv_positions[] | {address, ltv_pct, supply_usd}'
```

## Chains

| Chain | Chain ID | Status |
|-------|----------|--------|
| Ethereum | 1 | Active (~$370M TVL) |
| Arbitrum | 42161 | Active (~$52M TVL) |
| Berachain | 80094 | Active (~$50M TVL) |
| Mantle | 5000 | Minimal |
| Base | 8453 | Minimal |
| X Layer | 196 | Minimal |

Default: queries Ethereum, Arbitrum, Berachain. Use `--chain all` for everything.

## Data Sources

- **Subgraph API**: `subgraph.api.dolomite.io` — on-chain positions, flows, liquidations
- **REST API**: `api.dolomite.io` — token prices, interest rates, market data

No authentication required. All data is public.

## For AI Agents

Run `dolomite schema` to get a complete description of all commands, available entities, and example queries. The output is JSON — parseable by any model.
