- Overview
- Learning-Objective
- Technologies-used
- Technical-aspect
- Design and Artitecture
- installation
- Steps to write python flask app
- Output
we created a bot around the whatsapp platform which interact with users and used twilio which is used to utilize the the service because it offers an API in whatsapp and whenever we create bot we always need to send the response back for the given message and for that we used python language and flask framework.
The following points were the objective of the project . If you are looking for all the following points in this repo then i have not covered all in this repo. I'm working on blog about this mini project and I'll update the link of blog about all the points in details later . (The main intention was to create an end-to-end chatbot application. )
- Setting up whatsapp chastbot.
- Integrate with twillio API.
- Setting up Webhooks securely using flask.
- Wrtitng python handlers.
- Fetching stock data with Marketstack.
- created a bot around the whatsapp platform which interact with users
- used twilio which is used to utilize the the service because it offers an API in whatsapp.
- Twilio can only send data over https for the security stacke.
- so to overcome this we used Ngrok, it help us to create an HTTP turnel, it basically turnels the https traffic to our local host.
- whenever we create bot we always need to send the response back for the given message and for that we used python language and flask framework.
- flask app created now will help use to talk to markert stack API.
- 2 Billion users base.
- Most popular messaging app.
- end to end encrytion of security.
- easy to integrate for developers.
- backed by facebook for buisness users.
- HTTPS and API endpoints, which recieves data in json format or any format which is supported by HTTPS.
- Recieve HTTP request over TLS/SSL.
- call the revelant handlers.
- performed Buisness Logic.
- Returns the response.
- few lines require to write webapp.
- Easy to understand.
- Quick to setup and get going.
- very light weight
- can be easily extended with more packages as app evolves.
- easy to get started.
- includes 72 stock exchanges.
- Light weight json API.
- Extensive documentation.
- Easy support for python.
- User sends message to twilio provided sandbox url & twilio recieves the message.
- calls thew registered webhooks and sends data & flaskapp recives the Requerst.
- parse data and gets stock data from Marketstack & marketstack API returns the stack price data.
- Clone this repository and unzip it.
- After downloading, cd into the flask directory.
- Begin a new virtual environment with Python 3 and activate it.
- Install the required packages using pip install -r requirements.txt
- Execute the command: python app.py.
- Installed python
- created the virtual environment
- created a requirement.txt files for dependencies.
- Installed flask
- Installed requests (useful when we integrate market stack)
- installed twilio (for interacting with twilio)