Larke f4eab956d8 | 1 year ago | |
---|---|---|
.fleet | 1 year ago | |
examples | 1 year ago | |
.gitignore | 1 year ago | |
LICENSE | 2 years ago | |
README.md | 1 year ago | |
bot.go | 2 years ago | |
builder.go | 2 years ago | |
client.go | 2 years ago | |
go.mod | 1 year ago | |
parser.go | 2 years ago |
Go Twitch Bot Api wrapper, with an easy to use interface.
package main
import (
"github.com/witer33/twitchbot"
)
func main() {
bot := twitchbot.NewBot("oauth:abcdef", "mybot", []string{"channel"})
bot.OnMessage(func(bot *twitchbot.Bot, message *twitchbot.Message) {
if message.Message == "!ping" {
message.Reply("pong")
message.Delete()
}
})
bot.Run()
}