@reddgrow/cli
v0.1.6
Published
AI Agent Reddit Toolkit — safe Reddit intelligence via ReddGrow API
Maintainers
Readme
What is ReddGrow?
68% of AI-generated answers cite Reddit. ReddGrow is a Reddit intelligence platform that finds the conversations that matter — and the CLI gives AI agents direct access to that data.
Search subreddits, read posts and comments, analyze user profiles, track domain mentions, and check posting rules — all through a clean JSON API designed for agent workflows.
Get Your API Key
- Sign up at reddgrow.ai
- Go to Settings → API Keys
- Create a new key — it starts with
rg_ - Use it with the CLI or set the environment variable:
reddgrow auth login rg_your_api_key_here
# or
export REDDGROW_API_KEY=rg_your_api_key_hereInstall
npm install -g @reddgrow/cliyarn global add @reddgrow/clipnpm add -g @reddgrow/clibun add -g @reddgrow/cliQuick Start
# 1. Install globally
npm install -g @reddgrow/cli# 2. Authenticate
reddgrow auth login rg_your_api_key_here# 3. Fetch trending posts from any subreddit
reddgrow subreddits posts typescript --sort top --time weekCommands
Auth
| Command | Description |
|---------|-------------|
| reddgrow auth login <key> | Save your API key |
| reddgrow auth whoami | Show identity and credit balance |
| reddgrow auth status | Show connection status |
| reddgrow auth logout | Remove saved API key |
Subreddits (r)
| Command | Description |
|---------|-------------|
| reddgrow subreddits search <query> | Find relevant communities |
| reddgrow subreddits about <name> | Get community info and stats |
| reddgrow subreddits rules <name> | Get posting rules |
| reddgrow subreddits posts <name> | Fetch the post feed |
| reddgrow subreddits comments <name> | Get recent comment stream |
| reddgrow subreddits wiki <name> | List wiki pages |
| reddgrow subreddits wiki-page <name> <page> | Read a wiki page |
| reddgrow subreddits widgets <name> | Get sidebar widgets |
| reddgrow subreddits traffic <name> | Get traffic statistics |
| reddgrow subreddits check-url <name> <url> | Check if URL was already posted |
Options for subreddits posts: --sort hot\|new\|top\|rising\|controversial · --time hour\|day\|week\|month\|year\|all · --limit <n>
Posts
| Command | Description |
|---------|-------------|
| reddgrow posts search <query> | Search posts across all of Reddit |
| reddgrow posts comments <subreddit> <id> | Get comments for a post |
| reddgrow posts duplicates <subreddit> <id> | Find duplicate submissions |
| reddgrow posts batch <id> [id...] | Fetch multiple posts at once |
Users (u)
| Command | Description |
|---------|-------------|
| reddgrow users profile <username> | Get user profile and karma |
| reddgrow users posts <username> | Get post history |
| reddgrow users comments <username> | Get comment history |
Domains (d)
| Command | Description |
|---------|-------------|
| reddgrow domains mentions <domain> | Find Reddit posts linking to a domain |
Output Modes
ReddGrow auto-detects whether it's running interactively or piped, and adjusts output accordingly.
Human mode (interactive terminal) — rich, colored output:
┌─────────────────────────────────────────┐
│ ✓ Connected to ReddGrow API │
│ │
│ API Key rg_abc6...ef12 │
│ API URL https://api.reddgrow.ai │
└─────────────────────────────────────────┘Agent mode (piped / non-TTY) — raw JSON to stdout, errors to stderr:
{
"id": "typescript",
"subscribers": 312000,
"title": "TypeScript",
"description": "TypeScript is a language for application-scale JavaScript."
}[!TIP] Mode is auto-detected when piping output. Force it explicitly with
--mode agentorexport REDDGROW_MODE=agent.
AI Agent Integration
ReddGrow ships a SKILL.md that Claude and other AI agents can consume via OpenClaw.
Claude / OpenClaw: The SKILL.md bundled in this package teaches your agent all commands, workflows, and credit costs automatically.
Pipe to jq:
# Get the top 5 post titles from r/typescript this week
reddgrow subreddits posts typescript --sort top --time week | jq '.[0:5] | .[].title'
# Save subreddit info to a file
reddgrow subreddits about typescript > typescript-info.json
# Check if a URL has been shared before posting
reddgrow subreddits check-url typescript "https://mysite.com/article" | jq '.alreadyPosted'Recommended workflow for agents:
# 1. Research the community
reddgrow subreddits about <name>
reddgrow subreddits rules <name>
reddgrow subreddits wiki <name>
# 2. Check for duplicates before posting
reddgrow subreddits check-url <name> "<url>"
# 3. Monitor your account
reddgrow auth whoamiConfiguration
| Variable | Description | Default |
|----------|-------------|---------|
| REDDGROW_API_KEY | Your API key (overrides saved key) | — |
| REDDGROW_API_URL | API base URL | https://api.reddgrow.ai |
| REDDGROW_MODE | Output mode: human or agent | auto-detected |
Config is stored at ~/.reddgrow/config.json. The --mode flag and environment variables always take precedence over the saved config.
Links
- Website: reddgrow.ai
- npm: @reddgrow/cli
License
MIT © ReddGrow
