Skip to main content

Python API wrapper for weather-api

Project description

Taranis

Version Build License

Taranis is a Python API wrapper for weather-api. It provides quick and easy retrieval of weather data for a given city.

Installation:

Install and update using pip:

pip install -U taranis

Usage:

Import the module:

>>> import taranis

Then call any of the below functions:

>>> taranis.get_weather('San Francisco')
{'temperature': '+15 °C', 'wind': '24 km/h', 'description': 'Partly cloudy', 'forecast': [{'day': '1', 'temperature': '20 °C', 'wind': '18 km/h'}, {'day': '2', 'temperature': '16 °C', 'wind': '22 km/h'}, {'day': '3', 'temperature': '17 °C', 'wind': '12 km/h'}]}
>>> taranis.get_temperature('San Francisco')
'+15 °C'
>>> taranis.get_wind('San Francisco')
'24 km/h'
>>> taranis.get_description('San Francisco')
'Partly cloudy'
>>> taranis.get_forecast('San Francisco')
[{'day': '1', 'temperature': '20 °C', 'wind': '18 km/h'}, {'day': '2', 'temperature': '16 °C', 'wind': '22 km/h'}, {'day': '3', 'temperature': '17 °C', 'wind': '12 km/h'}]

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

taranis-0.2.0.tar.gz (2.8 kB view hashes)

Uploaded Source

Built Distribution

taranis-0.2.0-py3-none-any.whl (3.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page