A complete messaging bot that sends crypto currency information to a designated groupme. The focus of this project was to enable more discussion about how the crypto market is moving during the current day. It is a fun way to become excited about the movements in the market with fellow crypto enthusiast.
- This command is a very easy way to show a group how a certain token is doing
- Use this to brag about how well your favorite token is doing or be saddened about the downturn the coin took for the day
- Comes with a few built in crypto tickers that it will display all at once
- These tokens change over time to the 10 that the group request the price of most recently
- This is extremely helpful to get a quick idea about how the groups different tokens are doing that day
- Head over to dev.groupme.com and login with your GroupMe credentials
- Go to the
bots
tab and selectCreate Bot
- Choose a group, and avatar uri for the bot. The callback url will be that of the server you are deploying on, use http://localhost:3000 as a placeholder for now
- Select
Submit
to create your bot - Select your bot from the list of bots and save the bot id for later
- Check the group where you added the bot. There should be a message in chat that your bot was added to the group
(Recommended, cleanest steps to have the bot run continually)
Heroku and dokku are great options for deployment but a small cloud server will run this bot with little setup. Some great, inexpensive cloud providers include DigitalOcean, Amazon AWS, Microsoft Azure, Linode, Rackspace, Setting up, deploying, and maintaining your app on your own cloud server is more involved than a Heroku or dokku setup.
1. Install Node.js
2. Install a process manager like forever to run the bot in the background
- Lastly, if all else fails, it is most likely a security group on your webserver not allowing for the correct traffic and I'd recommend looking further into their documentation to resolve the issue
Example using forever:
$ forever start --append -l forever.log -o out.log -e err.log app.js
Heroku is a nice option because of its PaaS 'push and forget' style of deployment. Heroku has a limited free tier that is great for deploying chat bots (the paid tier isn't too bad). Follow these steps to get your machine setup with Heroku and deploy the bot. Heroku even lets you easily set environment variables within their dashbaord or command line interface. This is super useful for setting a bot id configuration variable on Heroku.
Dokku is another great option because its open source! Similar to Heroku, dokku allows you to 'push and forget', but the setup for dokku is more involved as it requires you to setup your own cloud server and install dokku before you can deploy. See this guide for deploying to dokku. Like Heroku, dokku allows you to easily set environment variables like your bot id.
- Crypto Currency information is being pulled from the CryptoCompare API
- The starter bot and the deployment steps came from ACMatUC/groupme-bot-starter
- The Groupme API can be of further help to find other ways to expand upon this bot