Yet another general purpose discord bot https://yagpdb.xyz
Find a file
2025-11-06 22:05:44 +05:30
.circleci fix broken dca test because of ffmpeg deprecating vol arg (#1924) 2025-08-19 22:55:11 +05:30
.github github: remove workflow, add PR template (#1903) 2025-06-27 12:49:49 +05:30
.vscode added debug config for docker and local, to make it easier to debug yagpdb (#1630) 2024-04-10 00:37:34 +05:30
admin Update package imports to V2 (#1195) 2022-05-05 14:49:47 +05:30
analytics Update package imports to V2 (#1195) 2022-05-05 14:49:47 +05:30
antiphishing Fix automod not working on content that is query escaped (#1858) 2025-03-18 23:20:01 +05:30
automod automod: clarify Delete Multiple Messages effect tooltip (#1900) 2025-06-24 00:55:15 +05:30
automod_legacy Fix automod not working on content that is query escaped (#1858) 2025-03-18 23:20:01 +05:30
autorole Added support for bulk role (#1933) 2025-08-30 19:39:40 +05:30
bot added more stubs for spammy events (#1976) 2025-11-06 21:40:36 +05:30
bulkrole fixed filter not showing streaming, muted, and autorole in filter roles, fixed incorrect date filter read, added date in the notification for filter (#1969) 2025-10-11 19:11:09 +05:30
cah Handled error for failure to start trivia, fixed never ending interaction response for cah create 2024-01-09 20:53:21 +05:30
cmd Added support for changing bot avatar and banner per server (#1944) 2025-09-11 23:52:59 +05:30
commands added global overrides to the widget (#1948) 2025-09-16 18:25:44 +05:30
common fix broken in, virtual smack for poor testing on the maintainer 2025-11-06 22:05:44 +05:30
customcommands added cc id to header on edit cc page (#1966) 2025-10-11 17:14:58 +05:30
discordlogger Update package imports to V2 (#1195) 2022-05-05 14:49:47 +05:30
feeds Update package imports to V2 (#1195) 2022-05-05 14:49:47 +05:30
frontend Fixed response deletion prompt for custom commands and general notifications (#1954) 2025-09-27 10:39:40 +05:30
lib added more stubs for spammy events (#1976) 2025-11-06 21:40:36 +05:30
logs logs: allow selection of channel allow/denylist mode (#1899) 2025-07-10 20:29:32 +05:30
moderation Undo making sendPunishDM execute as a go routine when kicking or banning (#1926) 2025-08-24 13:21:23 +05:30
notifications Fixed response deletion prompt for custom commands and general notifications (#1954) 2025-09-27 10:39:40 +05:30
personalizer added a reset button to personalizer ui (#1953) 2025-09-27 10:39:23 +05:30
premium move log in sync premium to be less spammy 2025-10-06 23:18:55 +05:30
reddit Reddit: add up/down vote counts to non-embed slow feed (#1866) 2025-04-09 12:53:22 +05:30
reminders reminders: fix target channel flag (#1831) 2025-01-23 11:47:10 +05:30
reputation change thanks rep to give rep to all mentioned users in the message (#1939) 2025-09-04 12:18:57 +05:30
rolecommands Added support for bulk role (#1933) 2025-08-30 19:39:40 +05:30
rss added delayed retry logic to rss feeds (#1968) 2025-10-11 19:10:55 +05:30
rsvp Added server info button to all plausible DMs + minor refactors (#1905) 2025-07-10 20:32:10 +05:30
safebrowsing Fix automod not working on content that is query escaped (#1858) 2025-03-18 23:20:01 +05:30
serverstats made the sqlboiler.toml files consistent between all plugins (#1794) 2024-12-13 11:08:50 +05:30
soundboard made the sqlboiler.toml files consistent between all plugins (#1794) 2024-12-13 11:08:50 +05:30
stdcommands added slash for viewperms (#1963) 2025-10-03 14:02:31 +05:30
streaming Replaced the terms blacklist/whitelist with more appropriate terms (#1748) 2024-11-07 19:12:42 +05:30
tickets Fix UTF-8 encoding detection in ticket transcripts by adding BOM (#1955) 2025-09-27 10:39:52 +05:30
timezonecompanion tzc: just use the system tzdb (#1950) 2025-09-27 10:38:33 +05:30
trivia general: add v2 components (#1884) 2025-05-07 21:39:03 +05:30
twitter all: prefer print over joinStr "" (#1833) 2025-02-11 20:08:14 +05:30
verification made the sqlboiler.toml files consistent between all plugins (#1794) 2024-12-13 11:08:50 +05:30
web Fixed a panic I noticed in logs for improper parsing of origin host (#1961) 2025-10-01 12:17:51 +05:30
yagpdb_docker reverted changes in debug docker compose 2025-10-07 13:15:17 +05:30
youtube Fixed incorrect type in pubsub handler for custom notifications 2025-10-13 16:26:39 +05:30
.gitattributes fixes 2021-10-07 10:53:20 +05:30
.gitignore fixed unsaved alert on youtube add form 2025-01-10 15:23:47 +05:30
breaking_changes.md Update redis requirements in readme, update autorole full scan text description, update breaking_changes (#1181) 2022-04-19 16:05:07 +05:30
CONTRIBUTING.md meta/contrib: improve contributing guidelines (#1538) 2023-07-17 16:10:51 +05:30
go.mod added stubs for events that spam the logs (#1974) 2025-11-04 22:27:26 +05:30
go.sum added stubs for events that spam the logs (#1974) 2025-11-04 22:27:26 +05:30
info.html update some info (#526) 2019-10-06 16:50:55 +02:00
LICENSE Update license (#444) 2019-05-06 14:04:58 +02:00
README.md README: clarify and simplify HTTPS setup instructions in README (#1920) 2025-07-31 12:17:00 +05:30
SUGGESTION_TEMPLATE.md Update SUGGESTION_TEMPLATE.md (#453) 2019-05-26 22:04:31 +02:00

YAGPDB - Yet Another General Purpose Discord Bot

YAGPDB is a multifunctional, modular Discord bot. It is modular in the sense that for most things plugins exist -- However, some plugins may depend on other plugins.

Plugins

  • YouTube Feed
  • Stream Announcements
  • Server Stats
  • Soundboard
  • Reputation
  • Reminders
  • Reddit Feed
  • Notifications
  • Moderation
  • Logs
  • Custom Commands
  • And More!

Selfhosting

There are two ways of selfhosting this bot: standalone, or dockerized.

General Bot Setup

Directions on creating an app and getting credentials may be found here.

YAGPDB does not require you to authorize the bot: all of that will be handled via the Control Panel.

In addition, you will need to add the following urls to the bot's "REDIRECT URI(S)" configuration:

HTTPS Options

YAGPDB supports two main HTTPS setups:

1. YAGPDB Handles HTTPS (Built-in)

Let YAGPDB serve HTTPS directly (no reverse proxy):

  • Just run with https (Default is true; you may specify this flag explicitly if desired):
    ./yagpdb --https=true
    
  • All HTTPS traffic is handled by YAGPDB.

Put YAGPDB behind a reverse proxy (like Nginx, Caddy, etc.):

  • Disable YAGPDB's built-in HTTPS server:
    • --https=false: YAGPDB uses plain HTTP internally.
    • --extHttps=true: Tell YAGPDB that HTTPS is handled externally.
    ./yagpdb --https=false --extHttps=true
    
  • Your proxy handles HTTPS, YAGPDB talks HTTP.

Hosting Dockerized

If you have docker-compose installed, that might be the fastest route of getting the bot up and running:

git clone https://github.com/botlabs-gg/yagpdb
cp yagpdb/yagpdb_docker/{app.example.env,app.env}
cp yagpdb/yagpdb_docker/{db.example.env,db.env}

Edit both env files accordingly. Make sure ports 80 and 443 are accessible on your network and that you have a proper image in docker-compose.yml:

docker-compose -f yagpdb/yagpdb_docker/docker-compose.yml up

Alternatively, you can run the bot behind a proxy:

docker network create proxy-tier
docker-compose -p proxy yagpdb/yagpdb_docker/docker-compose.proxy.yml up
docker-compose -f yagpdb/yagpdb_docker/docker-compose.proxied.yml up

During development, use the docker-compose.dev.yml file:

docker-compose -f yagpdb/yagpdb_docker/docker-compose.dev.yml up

Hosting Standalone

Requirements

  • Golang 1.23 or above
  • PostgreSQL 9.6 or later
  • Redis version 5.x or later

Setting Up

Configure Redis and Postgres with your desired settings.

In postgres, create a new user yagpdb and database yagpdb and grant that user access to that database.

Set up the environment variables with the credentials from the general setup. See the sample env file for a list of all enviroment variables.

Afterwards, run the build script located at /cmd/yagpdb/build.sh and start the bot using ./yagpdb:

git clone https://github.com/botlabs-gg/yagpdb
cd yagpdb/cmd/yagpdb
sh build.sh
./yagpdb -all

See ./yagpdb -help for all usable run flags. The webserver listens by default on ports 5000 (HTTP) and 5001 (HTTPS).

Databases

YAGPDB uses Redis for light data and caching, and postgresql for most configurations and heavy data, such as logs.

Updating

Updating with v1 and higher should migrate schemas automatically, but you should always make backups.

Breaking changes can be found in breaking_changes.md, which should always be consulted before updating.

Contributing

Please view the contributing guidelines before submitting any contributions.

See bot/plugin for info about bot plugins, web/plugin for web plugins and feeds/plugin for feeds if you wanna make a new fully fledged plugin.

Expect web, bot and feed instances to be run separately.

For basic utility/fun commands, you can just jam them in stdcommands. Use the existing commands there as an example of how to add one.

Please check CONTRIBUTING.md for further details.