Skip to content

Navigation Menu

Sign in
Sign up

Repository files navigation

πŸš€ Reddit Growth Agent

AI-powered Reddit marketing strategist & post generator for startups

Node.js SQLite OpenRouter License: ISC


Analyze your startup β†’ Research subreddits β†’ Understand the vibe β†’ Generate authentic posts


✨ What Is It?

Reddit Growth Agent (v2) is an interactive CLI tool that helps startups gain their first users from Reddit β€” powered by AI. It walks you through a complete Reddit marketing workflow:

  1. 🧠 Startup Analysis β€” Breaks down your value prop, identifies your ICP (Ideal Customer Profile), and finds the best subreddits to target.
  2. πŸ“‘ Subreddit Research β€” Fetches real top posts from each subreddit so the AI understands what actually performs well.
  3. 🎭 Vibe Reports β€” Generates a "vibe check" for each subreddit: tone, slang, unwritten rules, what gets upvoted vs. downvoted.
  4. ✍️ Post Generation β€” Creates multiple ready-to-post Reddit entries tailored to each subreddit's culture and your startup's story.
  5. πŸ”„ Interactive Refinement β€” Chat with the AI to tweak and polish your posts until they're perfect.
  6. πŸ’Ύ Export β€” Save everything to Markdown files for easy use.

All research and generated content is cached in a local SQLite database, so you never lose progress and can pick up where you left off.


πŸ“ Project Structure

File Description
index.js 🏠 Entry point β€” Runs the interactive CLI menu and orchestrates the full workflow
api.js πŸ€– AI & I/O β€” Handles OpenRouter API calls and readline-based user input
db.js πŸ—„οΈ Database β€” SQLite operations for startups, subreddits, vibe reports, and posts
prompts.js πŸ“ Prompt templates β€” All AI system prompts for analysis, vibes, and post generation
reddit.js πŸ“‘ Reddit fetcher β€” Pulls top posts from subreddits via Reddit's .json endpoints
scraper.js 🌐 Website scraper β€” Extracts context from your startup's website automatically
workflows.js βš™οΈ Workflow engine β€” Core logic for each step: analysis, research, vibes, generation, refinement, export
.env.example πŸ”‘ Config template β€” Template for required environment variables
package.json πŸ“¦ Dependencies β€” Project metadata and npm scripts

πŸ› οΈ Getting Started

1. Install dependencies

npm install

2. Set up environment variables

cp .env.example .env

Open .env and add your OpenRouter API key (get one at openrouter.ai/keys):

OPENROUTER_API_KEY=sk-or-v1-your-key-here
OPENROUTER_MODEL=google/gemini-2.5-flash

3. Set up the Reddit Cookie

Important

This step is required. Reddit blocks unauthenticated requests to its .json endpoints with a 403 Forbidden. The agent bypasses this by using your browser's session cookie β€” no official API keys or OAuth needed.

πŸͺ How to get your Reddit cookie (click to expand)
  1. Open reddit.com in your browser while logged in
  2. Open Developer Tools (F12 or Cmd+Opt+I)
  3. Go to the Network tab
  4. Refresh the page
  5. Click on any request made to www.reddit.com
  6. In the Headers section, find Cookie: under Request Headers
  7. Copy the entire value (it's one long string)
  8. Paste it into your .env file:
REDDIT_COOKIE=reddit_session=abc123; edgebucket=xyz; ...

[!NOTE] The cookie is a long string β€” paste it all on one line, no quotes needed. It may expire after a while; just repeat these steps to get a fresh one.

4. Run the agent

npm start

You'll be greeted with an interactive menu:

╔══════════════════════════════════════════════════════════════╗
β•‘ πŸš€ Reddit Growth Agent v2 πŸš€ β•‘
β•‘ AI post generator with SQLite caching β•‘
β•šβ•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•β•
πŸ“‹ MAIN MENU
 0. πŸš€ Run Full Flow (Analysis β†’ Research β†’ Vibes β†’ Posts)
 1. ▢️ Run Startup Analysis & ICP
 2. ▢️ Fetch Subreddit Research
 3. ▢️ Generate Vibe Reports
 4. ✍️ Generate Reddit Posts
 5. πŸ“„ View Saved Posts
 6. πŸ”„ Refine Posts (interactive)
 7. πŸ’Ύ Export All Posts to Markdown
 8. πŸ”™ Switch Startup
 9. ❌ Exit

🀝 Contributing

Contributors are welcome! Whether it's improving the AI prompts, adding new features, squashing bugs, or enhancing docs β€” all contributions are appreciated.

  1. Fork the repo
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request


Built with ❀️ for indie hackers and startup founders

Go get those users. 🎯

About

AI-powered Reddit marketing strategist & post generator agent for startups organic customer acquisition

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

AltStyle γ«γ‚ˆγ£γ¦ε€‰ζ›γ•γ‚ŒγŸγƒšγƒΌγ‚Έ (->γ‚ͺγƒͺγ‚ΈγƒŠγƒ«) /