/reddit-comment-bot

Reddit bot that auto replies to comments on set subreddits

Primary LanguagePython

Reddit Comment Bot

This Reddit Comment Bot is a python-based auto-responder.

  • Pick a subreddit to scan
  • Designate a specific comment to search for
  • Set your bot's reply

Requirements

Setup

Reddit App:
  1. Navigate to the Apps page
  2. Click create an app
  3. name: Set a name for your app
  4. type: Script
  5. description: Optional
  6. about url: Optional
  7. redirect uri: http://localhost:8080
  8. Note the outputted client id and secret
config.py:
  1. username: your Reddit username
  2. password: your Reddit password
  3. client_id: the outputted client id
  4. client_secret: the outputted secret
reddit_bot.py:

Set the subreddit to search (default = "r/test"):

r.subreddit('test')

Comment search criteria (default = "sample user comment"):

if "sample user comment"

Bot's comment reply (default = "Hey, I like your comment!"):

comment.reply("Hey, I like your comment!")

Usage

Navigate into the bot directory. Run your bot:

$ python reddit_bot.py