A simple "greeter bot" for Reddit
Python
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib
.gitignore
LICENSE
README.md
main.py
requirements.txt
settings.json
tests.py

README.md

Reddit Greeter Bot

This is a simple example on how a "greeter bot" for Reddit could be coded. It was an assignment for my programming class. Its task is to greet all of the post authors in a specified subreddit with a set greeting (by posting it as a comment on their latest post).

Core features:

  • Only greets every author once
  • Obeys the official Reddit API rules
  • Stores the settings in a separate file

Usage

  1. Customize the settings in settings.json
  2. Run main.py
  3. The bot will now greet existing posts, as well as watch for new ones

Greeting Formatting

The greeting is formatted in the same way as an ordinary Reddit comment, which means it is formatted using markdown. Something worth noting is that Reddit requires double newlines (\n\n) instead of just one. To include the author's name in the greeting, use this: {name}