Metadata-Version: 2.1
Name: sunnyside
Version: 1.0.2
Summary: Python wrapper for OpenWeather API
Home-page: https://github.com/junqili259/Sunnyside/
Author: Jun Qi Li
Author-email: JunQi.Li63@myhunter.cuny.com
License: UNKNOWN
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.6
Description-Content-Type: text/markdown

# Sunnyside

[![GitHub release](https://img.shields.io/github/v/release/junqili259/Sunnyside?include_prereleases)](https://github.com/junqili259/Sunnyside/releases)
![Python Version](https://img.shields.io/pypi/pyversions/sunnyside)

## Installation
```
pip3 install sunnyside
```

## Getting Started
### Python Version
Sunnyside only supports python 3.6+
_________________________________________________________________________________________________________________________________________________________________________________

```python
from sunnyside import Sunnyside

ref = Sunnyside("YOUR-API-KEY-HERE", "your-units-here") # Enter your api key here
```

## Current Weather
https://openweathermap.org/current

### Weather by city name
**Note**: Units are by default in Kelvin, to change units to imperial or celsius.

```python
weather = ref.currentWeather()
response = weather.get_current_weather_by_city_name("city_name") # Enter your city name here
```
### Weather by city id
```python
response = weather.get_current_weather_by_city_id("city_id")
```
### Weather by coordinates 
```python
response = weather.get_current_weather_by_geo_coords("lat","lon")
```
### Weather by zip code
```python
response = weather.get_current_weather_by_zip_code("zipcode")
```

_________________________________________________________________________________________________________________________________________________________________________________
## 5 Day Weather Forecast
https://openweathermap.org/forecast5

### Weather by city name

```python
forecast = ref.fiveDayForecast()
response = forecast.get_forecast_by_city_name("some_city_name_here")
```

```python

```
### Weather by city id
```python
response = forecast.get_forecast_by_city_id("city_id")
```
### Weather by coordinates 
```python
response = forecast.get_forecast_by_geo_coords("lat","lon")
```
### Weather by zip code
```python
response = forecast.get_forecast_by_zip_code("zipcode")
```

_________________________________________________________________________________________________________________________________________________________________________________

## Reference
https://openweathermap.org/api

https://openweathermap.org/current

https://openweathermap.org/forecast5


