docbot

command module
v0.0.0-...-3bbc5df Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 19, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

README

docbot

FOSSBilling Discord GitHub go.mod Go version GitHub

Screenshot

A simple Discord bot that replies with the related documentation page when you call it. It will likely mainly be used in the FOSSBilling Discord server, but I'm planning to make it more extensible and customizable in the future.

Heavily inspired by the bot in Laravel's Discord server with the same name.

How it works

  • The bot is invited with minimal permissions, the permissions to read and send messages should be fine.
  • The bot will then listen for messages in the channels it has access to. If a message starts with docs, it will reply with the full documentation URL.

How to use

You can invite the bot using this invite link (the link only has "Send messages" permissions) or build and deploy it yourself.

How to deploy

The bot is written in Go and uses DiscordGo to interact with the Discord API. You can build it using go build and run it with ./docbot.

The bot uses the following environment variables:

  • DISCORD_TOKEN - The bot token. You can get one from the Discord Developer Portal. Make sure to enable the "Message Content Intent" under the "Privileged Gateway Intents" section. You can also use the -t flag to pass the token instead.

Licensing

Copyright (c) 2022, evrifaessa.

This project is licensed under Apache License 2.0. See the LICENSE file for more information.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL