This is a simple dice rolling bot, to be used as a backend for a slack bot.
Clone the repository and install the dependencies
pipenv install
Then start the api with
pipenv run python flask_api.py -p 8080
You can now roll the dice with curl
curl -d "command=/roll&text=2d6+4" localhost:8080/
For deployment on heroku there is a Procfile in the repository. Refer to Heroku how to deploy.
On slack you need to need to create an app on https://api.slack.com/apps. There add a 'slash command' with name '/roll' and set its request URL to 'https://.herokuapp.com/'. Deploy the slack app to your workspace and that should hopefully be enough.
I had this api deployed on Heroku, so you might try
curl -d "command=/roll&text=2d6+4" https://salapi.herokuapp.com/