Read the web from your terminal. Built for AI coding agents.
The Reader CLI scrapes, crawls, and screenshots web pages via the Reader API. It outputs clean markdown to stdout, ready to pipe into any AI workflow.
npm install -g @vakra-dev/reader-cliOr run directly:
npx @vakra-dev/reader-cli scrape https://example.comFor humans - save your API key once:
reader config set api-key rdr_your_key_hereFor AI agents / CI - set the environment variable:
export READER_API_KEY=rdr_your_key_hereGet your API key at console.reader.dev.
reader scrape https://example.comOutput is clean markdown, printed to stdout:
reader scrape https://docs.stripe.com/payments > stripe-payments.mdreader scrape https://example.com # markdown (default)
reader scrape https://example.com -f html # cleaned HTML
reader scrape https://example.com -f screenshot -o page.png # full-page screenshotGet the full API response with metadata:
reader scrape https://example.com --jsonDiscover and scrape all pages:
reader crawl https://docs.example.com --max-pages 20Save pages to individual files:
reader crawl https://docs.example.com -o ./docs/List URLs only:
reader crawl https://example.com --urls-onlyreader statusReader CLI v0.1.0
API: https://api.reader.dev (connected)
Key: rdr_...c3bb
Credits: 874 / 1000 (free tier)
Resets: 2026-07-01
reader credits
reader credits --jsonreader config set api-key <key> # save API key
reader config set api-url <url> # custom API URL
reader config show # show current configConfig is stored at ~/.reader/config.json. Environment variables take precedence:
| Setting | Env var | Default |
|---|---|---|
| API key | READER_API_KEY |
- |
| API URL | READER_API_URL |
https://api.reader.dev |
| Flag | Description | Default |
|---|---|---|
-f, --format |
Output format: markdown, html, screenshot |
markdown |
--json |
Full JSON response | - |
-o, --output |
Write to file | stdout |
--no-main-content |
Include nav, header, footer | - |
--include-tags |
CSS selectors to keep | - |
--exclude-tags |
CSS selectors to remove | - |
--wait-for |
Wait for CSS selector | - |
--timeout |
Timeout in ms | 30000 |
--proxy-mode |
standard, stealth, auto |
auto |
| Flag | Description | Default |
|---|---|---|
--max-depth |
Crawl depth | 2 |
--max-pages |
Max pages to crawl | 20 |
--urls-only |
Only list URLs | - |
--json |
Full JSON response | - |
-o, --output-dir |
Write pages to directory | stdout |
Shows CLI version, API connectivity, credit balance, and tier.
| Flag | Description |
|---|---|
--json |
Full JSON response |
| Subcommand | Description |
|---|---|
set api-key <key> |
Save API key |
set api-url <url> |
Set custom API URL |
show |
Display current config |
The CLI is designed for seamless use with AI coding agents like Claude Code, Cursor, and Codex:
- Markdown to stdout - agents read content directly
- Errors to stderr - never pollutes piped output
- Exit codes - 0 on success, 1 on error
- No interactive prompts - everything via flags and env vars
--jsonflag - structured output for programmatic use
MIT - see LICENSE.