Skip to main content

API to gather the current pollen load from MeteoSchweiz

Project description

Swiss-Pollen

PyPI PyPI - Python Version

Project Maintenance License

Build Status Deploy Status

Python API to gather the current pollen load from MeteoSchweiz for the following plants:

  • birch
  • beech
  • oak
  • alder
  • ash
  • grasses
  • hazel

For the use within Home Assistant use the custom component hass-swiss-pollen.

This module is not officially developed, supported or endorsed by MeteoSchweiz.

Installation

Using pip

  1. Install python3.9 or higher
  2. Install swiss-pollen with pip install swiss-pollen.
  3. Run swiss-pollen test with swiss-pollen.

Usage

API

class PollenService:
    @staticmethod
    def load(plants : list[Plant] = Plant) -> PollenResult

Example

from swiss_pollen import (PollenService, Plant)

# get pollen data for all available plants (requires 7 remote calls, one for each plant)
all_pollen_data_per_station = PollenService.load()

# get pollen data for a restricted list of plants (requires 2 remote calls, one for each plant)
specific_pollen_data_per_station = PollenService.load(plants = [Plant.HAZEL, Plant.GRASSES])

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

swiss_pollen-1.2.0.tar.gz (10.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

swiss_pollen-1.2.0-py3-none-any.whl (11.9 kB view details)

Uploaded Python 3

File details

Details for the file swiss_pollen-1.2.0.tar.gz.

File metadata

  • Download URL: swiss_pollen-1.2.0.tar.gz
  • Upload date:
  • Size: 10.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for swiss_pollen-1.2.0.tar.gz
Algorithm Hash digest
SHA256 5693aa89ee6aba853b4e296ccdcb739943de541cfded066dfe4d1b106760bae3
MD5 9161216f3925b2e61b8a5629b75c9d69
BLAKE2b-256 5fccab224dee0f71e61e9b4145b4e12fd3293f69e15f717d85030b2f20bb2cea

See more details on using hashes here.

File details

Details for the file swiss_pollen-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: swiss_pollen-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 11.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for swiss_pollen-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f64d3a9c27ebc976d380f77a0456f131201346d65616222cc8e9799135a0992c
MD5 cdd29cc261a9461d01865a2f1f6cd3bf
BLAKE2b-256 3295fecf4274c3f2625bb7d68eb1a38697663f016442a6810708a7a0d4b6bd18

See more details on using hashes here.

Supported by

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