Shell
π Reddit Research Agent
Extract market research gold from Reddit using the hidden JSON API.
An autonomous agent that discovers pain points, product opportunities, competitor mentions, and buying signals from Reddit discussions.
The Hidden Trick
Add /.json to any Reddit URL:
https://www.reddit.com/r/SaaS/comments/xyz/title/
β
https://www.reddit.com/r/SaaS/comments/xyz/title/.json
You get the entire thread including all nested comments as structured JSON. No API key required.
Quick Start
# Install dependencies
npm install
# Set Claude API key (for analysis)
export ANTHROPIC_API_KEY=sk-ant-...
# Run a scan
npx tsx src/agent/index.ts run
What You Get
Pain Points
- Problems people are experiencing
- Frustrations with current solutions
- What's missing from the market
Product Opportunities
- Features people wish existed
- Gaps competitors aren't filling
- Ideas with validation built-in
Competitor Intelligence
- Products mentioned (positive/negative)
- Why people switch
- Pricing sensitivity
Buying Signals
- "Looking for recommendations..."
- "Just switched from X to Y..."
- "Would pay for something that..."
Usage
Python Scripts (Quick Research)
# Find goldmine threads in a subreddit
python3 find_goldmine_threads.py SaaS
python3 find_goldmine_threads.py entrepreneur --query "frustrating"
# Extract a specific thread
python3 reddit_extractor.py "https://reddit.com/r/SaaS/comments/xyz/"
TypeScript Agent (Automated Research)
# Single scan cycle
npx tsx src/agent/index.ts run
# Scheduled agent (daily at 9 AM)
npx tsx src/agent/index.ts schedule
# Add subreddits to track
npx tsx src/agent/index.ts add SaaS "wish existed"
npx tsx src/agent/index.ts add smallbusiness
# View statistics
npx tsx src/agent/index.ts stats
# Web dashboard to explore insights
npx tsx src/agent/index.ts dashboard 3456
# Parallel scan multiple subreddits
npx tsx src/agent/index.ts parallel "SaaS,entrepreneur,smallbusiness"
Example Output
π TOP GOLDMINE THREADS
======================================================================
1. [Score: 39.7] I Took Over a Commercial Gym and it's Been a Nightmare
π 1336 pts | π¬ 292 comments | π 97%
π https://reddit.com/r/smallbusiness/comments/...
2. [Score: 36.76] We're getting crushed by the big bakery chains
π 358 pts | π¬ 254 comments | π 96%
π https://reddit.com/r/smallbusiness/comments/...
Analyzed Insights
## Pain Points
- Manual order processing eating admin time (frequency: 5)
- Can't afford custom software development
- Competing on price is a losing battle
## Opportunities
- [high] Shopify-style ordering for wholesale bakeries
- [medium] Baker-specific software suite
- [high] Community engagement tools for local businesses
## Key Quote
> "If not, I will 100% create a plug-n-play baker software suite
> for free and sell it to other bakers for profit."
High-Value Subreddits
| Category | Subreddits |
|---|---|
| B2B/SaaS | r/SaaS, r/startups, r/entrepreneur |
| Small Business | r/smallbusiness, r/Entrepreneur |
| Dev Tools | r/webdev, r/programming, r/devops |
| Consumer | r/productivity, r/ADHD, r/homelab |
| Niche Hobbies | Any passionate community |
Goldmine Queries
The agent automatically searches for high-value phrases:
"wish existed"- Product ideas with built-in demand"hate about"- Pain points and frustrations"frustrating"- Problems to solve"looking for"- Active buying intent"alternative to"- Competitor weakness"switched from"- Migration patterns"paying for"- Willingness to spend
Architecture
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Reddit Research Agent β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β Scanner βββΆ Analyzer (Claude) βββΆ Storage (SQLite) β
β β β β β
β βΌ βΌ βΌ β
β Reddit JSON Insights Reports & Alerts β
β β β
β βββββββ΄ββββββ β
β β β β
β Dashboard Integrations β
β (Web UI) (Slack/Email/ β
β Notion) β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Project Structure
reddit-research/
βββ src/
β βββ reddit/ # Reddit API fetching
β βββ agent/ # Analysis, runner, multi-agent
β βββ db/ # SQLite storage
β βββ alerts/ # Slack & Email notifications
β βββ sync/ # Notion integration
β βββ dashboard/ # Web UI server
β βββ utils/ # Rate limiting, helpers
βββ docs/ # Documentation
β βββ ARCHITECTURE.md
β βββ QUICKSTART.md
β βββ API.md
βββ *.py # Python quick scripts
βββ package.json
Documentation
Production Features
Web Dashboard
Browse insights visually at http://localhost:3456:
- Pain points, opportunities, competitors, buying signals
- Top subreddits and recent scan stats
- JSON API at
/apifor custom integrations
Alerts (Slack & Email)
Get notified on high-value thread discoveries:
export SLACK_WEBHOOK_URL=https://hooks.slack.com/services/...
export EMAIL_API_KEY=re_xxx # Resend or SendGrid
export EMAIL_PROVIDER=resend
export [email protected]
export [email protected]
Notion Sync
Auto-push insights to your Notion workspace:
export NOTION_API_KEY=secret_xxx
export NOTION_PARENT_PAGE_ID=xxx-xxx-xxx # or NOTION_DATABASE_ID
Rate Limiting
Built-in token bucket rate limiter with exponential backoff prevents Reddit blocking (60 req/min limit handled automatically).
Multi-Agent Parallel Scanning
Scan multiple subreddits concurrently:
npx tsx src/agent/index.ts parallel "SaaS,entrepreneur,webdev" --queries "wish existed,frustrated"
Cost
| Operation | Cost |
|---|---|
| Reddit fetching | Free |
| Quick analysis | Free |
| Claude analysis | ~$0.01/thread |
| 100 threads/day | ~$1/day |
License
MIT
π° "There is a lot of MONEY in niche subreddits"