{"id":28154086,"url":"https://github.com/spongejump/go-discord-bot","last_synced_at":"2025-05-15T06:12:48.943Z","repository":{"id":282613020,"uuid":"863496466","full_name":"spongejump/go-discord-bot","owner":"spongejump","description":"Discord Multi-tenant bot that provides chatgpt replying, message listing, invited server listing, adding and removing roles.","archived":false,"fork":false,"pushed_at":"2024-09-26T12:08:43.000Z","size":181,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-20T08:41:21.773Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"isc","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/spongejump.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-26T11:54:58.000Z","updated_at":"2024-09-26T12:08:47.000Z","dependencies_parsed_at":"2025-03-22T00:15:39.600Z","dependency_job_id":null,"html_url":"https://github.com/spongejump/go-discord-bot","commit_stats":null,"previous_names":["spongepump/go-discord-bot","spongejump/go-discord-bot"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spongejump%2Fgo-discord-bot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spongejump%2Fgo-discord-bot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spongejump%2Fgo-discord-bot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/spongejump%2Fgo-discord-bot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/spongejump","download_url":"https://codeload.github.com/spongejump/go-discord-bot/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254283286,"owners_count":22045141,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-05-15T06:12:47.348Z","updated_at":"2025-05-15T06:12:48.921Z","avatar_url":"https://github.com/spongejump.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# discord-role-bot\nA really simple bot to manage roles on Discord based on reactions to messages.\n\n## Dependencies\nThe only dependency is Go. This has only been tested on Go 1.18.\n\n## Building\nClone the repository and build the project.\n\n```\nmake\n```\n\nThis should give you an executable in the top level folder called\n`discord-role-bot`.\n\n## Installing\nThe bot is by default installed to `/usr/local/bin`.\n\n```\nmake install\n```\n\n## Configuration\nCopy `configs/config.json.example` to `configs/config.json`. If you plan on\nrunning this on a server as a service, it will look for configs in\n`/etc/discord-role-bot/config.json` as well, if it fails to find it in the\n`configs` folder.\n\n```\ncp configs/config.json.example configs/config.json\n```\n\nGo into Discord settings -\u003e Advanced and turn on Developer Mode.\n\nThen create a discord bot in the [Discord Developer Portal](https://discord.com/developers/applications).\nIf you are unsure of how to do this, there are plenty of tutorials on how to create a bot with Discord.\n\nYou need to invite the bot to your server. It needs two permissions:\n\n* Manage Roles\n* Read Messages/View Channels\n\nThe permission integer should be `268436480`.\n\nCopy the token for your bot and paste it into `discordToken` in `config.json`.\n\n```\n{\n  \"discordToken\": \"your-token\",\n  ...\n}\n```\n\nThen right click on your server in Discord and copy its ID, paste it into\n`guildID` in `config.json`.\n\n```\n{\n  ...\n  \"guildID\": \"your-guild-id\",\n  ...\n}\n```\n\nNext up write a message in a channel on your Discord server to use for\nreactions, then copy its ID and paste it into `config.json`.\n\n```\n{\n  ...\n  \"roleConfig\": {\n    \"your-message-id\": {\n  ...\n}\n```\n\nCreate a role on your Discord server that you want to be added when a user\nreacts to your message. Once you have created the role, copy its ID and paste\nit into `config.json`.\n\n```\n{\n  ...\n  \"roleConfig\": {\n    \"your-message-id\": {\n      \"your-emoji\": \"your-role-id\"\n  ...\n}\n```\n\nFinally, pick an emoji and paste it into `config.json`. This should be the\nactual emoji you want to use, for example 📢.\n\n## Running\nMake sure you've built the bot and configured it, then run the executable.\n\n```\n./discord-role-bot\n```\n\nThe bot doesn't fork into the background, it just runs and logs in the\nforeground and needs to be backgrounded if desired.\n\n## Logging\nLogs get written to stdout. If you have issues, check the logs first.\n\n## Uninstalling\nUse make to uninstall the bot.\n\n```\nmake uninstall\n```\n\n## FAQ\nThe bot has all the permissions but still can't add my role, how come?\nMake sure the bot's role is higher up in the role list than the users it\nwill be modifying.\n\n## Reporting issues\nI don't have a public issue tracker. My email is in the commit history, feel\nfree to drop me an email if you have problems, I'm happy to help.\n\n## Thanks\nLoosely based on [Distortions81/M45-ReactBot](https://github.com/Distortions81/M45-ReactBot).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspongejump%2Fgo-discord-bot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspongejump%2Fgo-discord-bot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspongejump%2Fgo-discord-bot/lists"}