This repository aims to implement a chat bot via Whatsapp, using the Twilio API and the ChatGPT API.
- Node.js
- A Twilio account
- A Twilio Whatsapp sandbox phone number
- Ngrok so that you can respond to webhooks in your local development environment
npm install
Use the env.example
file to create your .env
, to set up your own variables.
Start the web server:
npm start
npm run dev
To respond to an incoming webhook your will need a publicly available URL. One alternative is to expose your local server port. Ngrok is a tool that can tunnel through from a public URL to your machine. Once downloaded you can execute the following:
ngrok http 3000
The ngrok terminal will show you a URL, like https://RANDOM_STRING_.ngrok.io
.