meteocatpy
v0.0.15
Published
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0) [![Python version compatibility](https://img.shields.io/pypi/pyversions/meteocatpy)](https://pypi.org/project/meteocatpy) [![pipeline st
Downloads
619
Readme
Meteocat Python Package for Meteocat Home Assistant Integration
meteocatpy
is a Python package to interact with the Meteocat API. Allows you to obtain meteorological data and lists of municipalities from the Meteocat API.
NOTE: Meteocat API requires to use an API_KEY, you should ask to (https://apidocs.meteocat.gencat.cat/documentacio/acces-ciutada-i-administracio/)
Installation
You can install the package from PyPI using pip
:
pip install meteocatpy
from meteocatpy.client import MeteocatClient
# Replace 'tu_api_key' with your actual API key
api_key = "tu_api_key"
client = MeteocatClient(api_key)
# Get a list of municipalities (asynchronous call)
municipis = await client.get_municipis()
print(municipis)
Credits
This is a personal project.
Authors:
- Figorr
Contributing
If you would like to contribute to this project, please open an issue or create a pull request. I'd be happy to review your contributions!
- Check for open features/bugs or initiate a discussion on one.
- Fork the repository.
- Install the dev environment:
make init
. - Enter the virtual environment:
pipenv shell
- Code your new feature or bug fix.
- Write a test that covers your new functionality.
- Update
README.md
with any new documentation. - Run tests and ensure 100% code coverage for your contribution:
make coverage
- Ensure you have no linting errors:
make lint
- Ensure you have typed your code correctly:
make typing
- Add yourself to
AUTHORS.md
. - Submit a pull request!
License
Apache-2.0. By providing a contribution, you agree the contribution is licensed under Apache-2.0.