Visual Weather api. Returns beautiful pictures with the current weather in python

VWapi

Visual Weather api. Returns beautiful pictures with the current weather.

------

---------

Kyoto

Installation:

sudo apt update -y && sudo apt upgrade -y
sudo apt install -y git python3 python3-pip 
git clone https://github.com/mishailovic/VWapi
cd VWapi
pip3 install -r requirements.txt
python3 -m uvicorn weatherapi:app --reload

Usage:

import requests
import time
language = "en" # can be "en" or "ru"
place = Moscow # can be any city, place, street, or site, geocoder automatically selects location. 
timestamp = round(time()) # optional timestamp, can be any unix timestamp from now to now + plus three days 
r = requests.get(f"https://weather.hotaru.ga/{language}/{place}?timestamp={timestamp}")

Now r.content is an image containing weather for Moscow in English language for the current time.

GitHub

 

To finish reading, please visit source site