Reddit

Plugin name: reddit

Plugin name: reddit

The Reddit plugin provides a few various Reddit feeds including new posts on specified subreddits and different types of private moderation feeds.

Configuration Options

OptionDescriptionTypeDefault
subsA mapping of subreddit names to subreddit configurations. You may only subscribe to a maximum of 3 distinct subreddits.dictempty
mod_feedsA mapping of usernames to mod feed configs.dictempty
multiA single multireddit config.dictempty

Subreddit Configuration

OptionDescriptionTypeDefault
channelChannel to send feed messages.snowflakeempty
modeType of feed message. Options: PLAIN, PRETTY. Pretty mode uses embedded messages.strPRETTY
nsfwWhether to include NSFW posts.boolfalse
include_statsWhether to include upvote/downvote data and comment stats on each post.boolfalse
notify_roleRole to notify on each new post.snowflakeempty
delay_secSeconds to delay the post feed.int0

Mod Feed Configuration

OptionDescriptionTypeDefault
mod_hashThe username's private feed hash key. See instructions below.strempty
channelsA mapping of channels to mod feed channel configs.dictempty
channels → enable_mod_listingsA list of private moderation feeds to enable. Options: SPAM, REPORTS, NEW_MODMAIL, MODLOGlist(str)empty
channels → notify_roleA role ID to notify when new mod feed posts are posted in the channel.snowflakeempty
enable_cleanEnables option to delete or archive reports.boolfalse
archive_channelArchive channel for reports.snowflakeempty

enable_clean description

If enable_clean is true, a clipboard reaction is added to every report. Reacting to the clipboard will add a checkmark and an x reaction. The timeout to react to the additional reactions is 30sec.

If the checkmark reaction is selected, the report will be deleted if archive_channel is false and archived into the archive_channel if true.

If the x reaction is selected, the checkmark and x will be removed and only the clipboard will remain.

mod_hash Setup

If you are a moderator in any subreddit:

  1. Visit https://old.reddit.com/prefs/ and make sure that enable private RSS feeds (available from the 'RSS feed' tab in prefs) is checked.
  2. Visit https://old.reddit.com/prefs/feeds/.
  3. Open any of the RSS or JSON feeds and look at the URL which should look similar to https://old.reddit.com/user/redditor/downvoted.rss?feed=12327266948a123979d1114afd8b123d542be9cd&user=redditor.
  4. The mod_hash to copy is after the feed parameter. In the above example, you would want to copy 12327266948a123979d1114afd8b123d542be9cd to your config.

Multireddit Configuration

A multireddit is a user-created Reddit custom feed that can contain a multitude of subreddits. This allows users to overcome the limitation of the maximum of three single subreddit feed configurations. However the multireddit feed may only be posted in one channel.

OptionDescriptionTypeDefault
usernameUsername that created the multifeed.strempty
feed_nameThe custom feed name.strempty
channelChannel to send feed messages.snowflakeempty
modeType of feed message. Options: PLAIN, PRETTY. Pretty mode uses embedded messages.strPRETTY
nsfwWhether to include NSFW posts.boolfalse
include_statsWhether to include upvote/downvote data and comment stats on each post.boolfalse
notify_roleRole to notify on each new post.snowflakeempty
delay_secSeconds to delay the post feed.int0

For an example multireddit feed with the URL https://www.reddit.com/user/redditor/m/rabbits/, the username would be redditor and the feed_name would be rabbits.

Configuration Example

plugins:
  reddit:
    subs:
      aww: # Subreddit name
        channel: 579533838892400659
        mode: pretty
        delay_sec: 10
    mod_feeds:
      alchameth: # Reddit Username
        mod_hash: 75efda66948a68c979d11254afd1b621c542be9cf
        channels:
          583887495733968909:
            enable_mod_listings:
              - REPORTS
              - SPAM
              - NEW_MODMAIL
              - MODLOG
        enable_clean: true
        archive_channel: 583887225733968463
    multi:
      username: alchameth
      feed_name: rabbits
      channel: 433763867808122625
      delay_sec: 300