Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/decentfox/async-weather-sdk
Async weather API wrapper for fetching weather and forecast data
https://github.com/decentfox/async-weather-sdk
asyncio forecast python3 weather
Last synced: 4 days ago
JSON representation
Async weather API wrapper for fetching weather and forecast data
- Host: GitHub
- URL: https://github.com/decentfox/async-weather-sdk
- Owner: decentfox
- License: mit
- Created: 2020-05-28T03:54:36.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-06-02T05:54:26.000Z (over 4 years ago)
- Last Synced: 2025-01-18T07:29:03.348Z (7 days ago)
- Topics: asyncio, forecast, python3, weather
- Language: Python
- Size: 40 KB
- Stars: 1
- Watchers: 6
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: HISTORY.rst
- License: LICENSE
Awesome Lists containing this project
README
# Async Weather SDK
[![PyPI version](https://img.shields.io/pypi/v/async-weather-sdk?logo=python&logoColor=white)](https://badge.fury.io/py/async-weather-sdk)
[![GitHub Workflow Status for tests](https://img.shields.io/github/workflow/status/decentfox/async-weather-sdk/test?logo=github&logoColor=white)](https://github.com/decentfox/async-weather-sdk/actions?query=workflow%3Atest)
[![Codacy Badge](https://img.shields.io/codacy/coverage/f548667427c24fc394204b440166c26d?logo=Codacy)](https://www.codacy.com/gh/decentfox/async-weather-sdk?utm_source=github.com&utm_medium=referral&utm_content=decentfox/async-weather-sdk&utm_campaign=Badge_Coverage)Async weather API wrapper for fetching weather and forecast data
## Core Dependencies
**Asyncio:** a library to write concurrent code using the async/await syntax.
**Aiohttp:** an asynchronous HTTP Client/Server for asyncio and Python.
## Install
```bash
pip install async-weather-sdkOR
poetry add async-weather-sdk
```## Usage
### QQ Weather API SDK
Get current weather/forecast data by province and city.
```python
from async_weather_sdk.qq import QQWeatherweather = QQWeather()
await weather.fetch_current_weather('北京市', '北京市')
await weather.fetch_weather_forecast('北京市', '北京市', 3)
```Query current weather/forecast data with tencent map api key.
```python
from async_weather_sdk.qq import query_current_weather, query_weather_forecastawait query_current_weather('API_KEY', '北京市')
await query_weather_forecast('API_KEY', '39.90469,116.40717')
```