A Discord bot to aid in group-based decision-making
Report Bug
·
Request Feature
Table of Contents
Clotho is a Discord bot that I made to help my friends and I suggest things, vote on said things, and determine which thing wins via anonymous surveys. The surveys are supplied using StrawPoll and their free API (thanks StrawPoll!).
I actually followed a pretty straight-forward tutorial to get the bot itself set up in Discord. I highly recommend it if you're looking to build your own!
As of right now, I don't have this bot hosted anywhere for public use. To get a local copy up and running follow these simple steps.
You'll need the latest version of Node, and that's about it.
npm install npm@latest -g
- Clone the repo
git clone https://github.com/ShowMeTheRoapes/clotho.git
- Install NPM packages
# if you use npm npm install # if you use yarn yarn
- Create a bot account on Discord, generate a token, and invite it to your channel
- Create a StrawPoll account and generate an API key by going to Settings => API Key
- In the root directory of Clotho, create a file called
config.json
that looks like this:{ "BOT_TOKEN": "Your bot's token", "STRAWPOLL_KEY": "Your StrawPoll API key" }
- Go to the root directory
yarn && yarn start
- Your terminal should say "Clotho is up and running!"
- If you also see that the bot account you put in your channel is active with a green dot next to it, then you're good to go!
"Great, the bot is running. Now how do I use it??" - You, probably
All of Clotho's commands begin with !!
, and you can always get a printed summary of every command with !!help
. Clotho's status in Discord displays as "Playing !!help", so you can look at the bot's avatar in the server if you forget the help command. 👍
Command | Parameters | Explanation |
---|---|---|
!!ping |
None | Clotho replies with a message to let you know she is up and running. |
!!help |
None | Clotho will reply with a list of all commands and how to use them. |
!!startpoll |
Poll Title | Clotho will begin recording information for a poll with the given title. Users will now be able to use the !!submit command. |
!!submit |
Candidate | Clotho will record your candidate and user information for the open poll. If you submit another candidate, it will replace your current one. Clotho will send you a private message to show you what she received/saved as your submission. |
!!closepoll |
None | Clotho will no longer accept submissions for the open poll. Clotho will use the StrawPoll API to create a poll with all of the submitted candidates and post the link to it. |
!!declare |
None | Clotho will inspect the StrawPoll, determine which candidate is the winner, and post a message about it. All poll information will be cleared and a new one may be started. NOTE: If there is a tie between candidates, a new StrawPoll will be created with only those candidates. |
!!reset |
None | Reset all poll information to nothing. You'll have a clean slate! |
As of right now, there isn't much else that I want to add. I have one or two quality-of-life things that I would like to add, and I may come up with a better/more efficient way for the bot to perform its utilities, but at the moment it's working perfectly for my friends and I!
See the open issues for a list of proposed features (and known issues). You can also check out my project here on GitHub so you can see what I'm currently working on.
Or rather, what I'm anticipating people will ask. 🤷
Clotho is one of the three Sisters of Fate in Greek mythology. Specifically, she's the one who spins the thread of human life and thus makes all major decisions. It seemed to fit the goal, however dramatic it may be. :)
At the moment I don't have a publicly hosted version of the bot available, but if there's enough interest I would be willing to put some work towards that!
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the GPL 2.0 License. See LICENSE
for more information.
Author: Alex Hoopes