Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/terieyenike/weatherapi-with-python
This Flask application integrates with a weather API (Open Weather Map) to provide real-time weather information of a location based on the city name, state code, and country code. It also sends SMS using Infobip Python SDK to your phone.
https://github.com/terieyenike/weatherapi-with-python
flask infobip infobip-sdk python python-dotenv
Last synced: about 8 hours ago
JSON representation
This Flask application integrates with a weather API (Open Weather Map) to provide real-time weather information of a location based on the city name, state code, and country code. It also sends SMS using Infobip Python SDK to your phone.
- Host: GitHub
- URL: https://github.com/terieyenike/weatherapi-with-python
- Owner: Terieyenike
- Created: 2024-04-03T17:30:34.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-04-13T20:05:16.000Z (7 months ago)
- Last Synced: 2024-04-24T09:41:11.254Z (7 months ago)
- Topics: flask, infobip, infobip-sdk, python, python-dotenv
- Language: Python
- Homepage:
- Size: 20.5 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Weather API and Infobip SMS Integration
This Flask application integrates with a weather API ([Open Weather Map](https://openweathermap.org/)) to provide real-time weather information of a location based on the city name, state code, and country code. It also sends [SMS](https://www.infobip.com/docs/api/channels/sms) using Infobip Python SDK to your phone.
![Weather SMS report](https://github.com/Terieyenike/weatherapi-with-python/assets/25850598/f6247b7e-7bd8-4204-ab10-ec8d05952932)
## Prerequisites
Before running the application, ensure you have the following:
- Python installed on your system
- Flask framework installed (`pip install Flask`)
- Weather API credentials
- Infobip API credentials
- Destination phone number for SMS notifications## Running locally
### Clone this repository:
```
git clone https://github.com/Terieyenike/weatherapi-with-python
cd weatherapi-with-python
```### Install dependencies
```
pip install -r requirements.txt
```### Set up environment variables:
In the `.env` file, replace the value of your openweathermap API key
```
OWM_API_KEY=""
IB_BASE_URL=""
IB_API_KEY=""
DESTINATION_NUMBER=""
```## Tech stack
- Python
- Flask
- Infobip Python SDK
- Tailwind CSS## Usage
Once you have the requirements installed, `flask run` from the top-level directory will serve the app on `127.0.0.1:5000`.
## Contributors
- [Teri Eyenike](https://x.com/terieyenike)
## License
This project is licensed under the MIT License