An app that connects with the Twilio API and Slack API to create restaurant reservations via SMS or slash command.
You can send a message in the format
[Name] [MM-DD] [TTam] to make a reservation. For example, if John wants a reservation at 4pm on August 28, he would send
John 08-28 4pm via SMS or Slack.
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
Please make sure you have the following:
- Twilio create a phone number to use with their Programmable SMS service
- ngrok allows you to test out webhooks locally
- npm The Node.js installer should include this
- Slack App create a Slack app to
Create a Postgres database for the project and save its connection URL as a
DATABASE_URL environment variable.
Run the following terminal commands to get the app running:
Clone this repository onto your local machine:
git clone https://github.com/shahidsarker/reservation_bot.git
Move into the project directory:
Run the following commands to install Node modules, migrate the database, and start the server:
In a separate terminal, move into the client directory then run the following commands to install Node modules and start the client:
In a separate terminal window, move into the directory containing
ngrok and run:
./ngrok http 3001
Copy the forwarding address ending in
Add the following as a Messaging webhook in Twilio:
Add the following as a slash command Request URL for your Slack app:
To run tests locally, run the following command from the parent directory:
- Express - The Node.js web framework used
- Twilio API
- Slack API
- Shahid Sarker - shahidsarker Reservation functions, Postgres setup, Travis CI integration
- Cindy Song - zs0606 Initial setup, tests, reservation helpers