Getting Started

CLI Reference

The Reduck CLI wraps the SDK and lets you run browser automations from the terminal.

Installation

npm install -g @reduck-ai/cli

Authentication

# OAuth login (opens browser)
reduck login

# Or use an API key
export REDUCK_API_KEY=rk_...

Generate an API key from your Reduck dashboard.

Priority order:

  1. --api-key flag
  2. REDUCK_API_KEY environment variable
  3. Stored OAuth token from reduck login

Credentials are stored in ~/.config/reduck/config.json.

Device selection

# List and select a device (saved for future runs)
reduck devices

Priority order:

  1. --device-id flag
  2. REDUCK_DEVICE_ID environment variable
  3. Device saved via reduck devices

Usage

# Run an automation
reduck -q "Go to amazon.fr and find the price of AirPods Pro 2"

# With file uploads
reduck -q "Fill the form with my CV" --mount ./cv.pdf

# Multiple file uploads
reduck -q "Compare these two documents" --mount ./doc1.pdf --mount ./doc2.pdf

# Interrupt a running automation
reduck interrupt <run-id>

# Logout
reduck logout

Press Ctrl+C during a run to cancel it gracefully.

Commands

CommandDescription
reduck loginAuthenticate via OAuth (opens browser)
reduck logoutClear stored credentials
reduck devicesList and select a device
reduck -q "..."Run an automation
reduck interrupt <id>Cancel a running automation

Options

FlagEnv varDescription
-qAutomation prompt (required for runs)
--mountFile path to upload (repeatable)
--api-keyREDUCK_API_KEYAPI key authentication
--device-idREDUCK_DEVICE_IDTarget device ID

Output

The CLI streams formatted output as the automation runs: progress messages, turn dividers, and a final result summary.

[10:42:01] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ run started ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Navigating to amazon.fr...
[10:42:05] ─────────────────────────────────────────── turn ───────────────────────────────────────────
✅ Done

The price of AirPods Pro 2 on amazon.fr is €279.