All Projects → turnage → Graw

turnage / Graw

Licence: mit
Golang Reddit API Wrapper

Programming Languages

go
31211 projects - #10 most used programming language

Labels

Projects that are alternatives of or similar to Graw

Imguralbumbot
A reddit bot for linking direct images of single-picture albums
Stars: ✭ 107 (-57.37%)
Mutual labels:  bot, reddit
Reddit Video Download Bot
A reddit bot that provides downloadable video links
Stars: ✭ 301 (+19.92%)
Mutual labels:  bot, reddit
Reddit Anti Gif Bot
A Reddit bot providing an mp4 link/mirror for gif submissions
Stars: ✭ 138 (-45.02%)
Mutual labels:  bot, reddit
Spam Bot 3000
Social media research and promotion, semi-autonomous CLI bot
Stars: ✭ 79 (-68.53%)
Mutual labels:  bot, reddit
Redd
Redd is a batteries-included API wrapper for reddit.
Stars: ✭ 180 (-28.29%)
Mutual labels:  bot, reddit
Get Me A Date
😍 Help me get a 💘 date tonight 🌛
Stars: ✭ 228 (-9.16%)
Mutual labels:  bot
Profiles
👍 Make JavaScript Great Again
Stars: ✭ 238 (-5.18%)
Mutual labels:  bot
Gpt2bot
Your new Telegram buddy powered by transformers
Stars: ✭ 228 (-9.16%)
Mutual labels:  bot
Laravel Crawler Detect
A Laravel wrapper for CrawlerDetect - the web crawler detection library
Stars: ✭ 227 (-9.56%)
Mutual labels:  bot
Sapconversationalai
✨ 🤖 🤖 Build your own conversational bot on our Collaborative Bot Platform! 🤖🤖 ✨
Stars: ✭ 247 (-1.59%)
Mutual labels:  bot
Telegram channel downloader
一个电报群组、频道下载脚本,支持上传到GD、OD等rclone可以挂载的网盘。
Stars: ✭ 216 (-13.94%)
Mutual labels:  bot
Reeddit
Minimal, elastic Reddit reader web-app client
Stars: ✭ 235 (-6.37%)
Mutual labels:  reddit
Micromsg Bot
微信表情机器人
Stars: ✭ 230 (-8.37%)
Mutual labels:  bot
First Timers Bot
A friendly bot that helps onboarding new Open Source Contributors
Stars: ✭ 239 (-4.78%)
Mutual labels:  bot
Twitch Js
A community-centric, community-supported version of tmi.js
Stars: ✭ 225 (-10.36%)
Mutual labels:  bot
Prettier Github
Format code in GitHub comments with Prettier
Stars: ✭ 244 (-2.79%)
Mutual labels:  bot
Python Telegram Bot
We have made you a wrapper you can't refuse
Stars: ✭ 17,209 (+6756.18%)
Mutual labels:  bot
Bastion
🚀 Get an enhanced Discord experience!
Stars: ✭ 234 (-6.77%)
Mutual labels:  bot
Publicleech
can be found on Telegram as https://telegram.dog/PublicLeechGroup
Stars: ✭ 236 (-5.98%)
Mutual labels:  bot
Facebooktoolkit
a tool to get Facebook data, and some Facebook bots, and extra tools found on Facebook Toolkit ++.
Stars: ✭ 227 (-9.56%)
Mutual labels:  bot

graw

Build Status Version: 1.2.0 GoDoc

go get github.com/turnage/graw

graw is a library for building Reddit bots that takes care of everything you don't want to. Read the tutorial book!

As of major version 1, the API promise is: no breaking changes, ever. Details below. This applies to all (library) subpackages of graw.

Usage

The design of graw is that your bot is a handler for events, Reddit is a source of events, and graw connects the two. If you want to announce all the new posts in a given subreddit, this is your bot:

type announcer struct {}

func (a *announcer) Post(post *reddit.Post) error {
        fmt.Printf("%s posted \"%s\"\n", post.Author, post.Title)
        return nil
}

Give this to graw with an api handle from the reddit package and a tell it what events you want to subscribe to; graw will take care of the rest. See the godoc and tutorial book for more information.

Features

The primary feature of graw is robust event streams. graw supports many exciting event streams:

  • New posts in subreddits.
  • New comments in subreddits.
  • New posts or comments by users.
  • Private messages sent to the bot.
  • Replies to the bot's posts.
  • Replies to the bot's comments.
  • Mentions of the bot's username.

Processing all of these events is as as simple as implementing a method to receive them!

graw also provides two lower level packages for developers to tackle other interactions with Reddit like one-shot scripts and bot actions. See subdirectories in the godoc.

API Promise

As of version 1.0.0, the graw API is stable. I will not make any backwards incompatible changes, ever. The only exceptions are:

  • I may add methods to an interface. This will only break you if you embed it and implement a method with the same name as the one I add.
  • I may add fields to the Config struct. This will only break you if you embed it and add a field with the same name as the one I add, or initialize it positionally.

I don't foresee anyone having a reason to do either of these things.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].