Skip to main content

API to retrieve data from Eltern-Portal

Project description

pyelternportal

Python client library to retrieve data provided by eltern-portal.org

Install

pip install pyelternportal

Usage by example

Get values

import pyelternportal

api = pyelternportal.ElternPortalAPI()
print(f"timezone:\t{api.timezone.zone}")

api.set_config("demo", "demo", "demo")
print(f"school:\t\t{api.school}")
print(f"username:\t{api.username}")

await api.async_validate_config()
print(f"school_name:\t{api.school_name}")

await api.async_update()
print(f"last_update:\t{api.last_update}")

for pupil in api.pupils:
    print("---")
    print(f"pupil_id:\t{pupil.pupil_id}")
    print(f"fullname:\t{pupil.fullname}")
    print(f"firstname:\t{pupil.firstname}")
    print(f"letters:\t{len(pupil.letters)}")
    for letter in pupil.letters:
        print(f"\tnumber:\t\t{letter.number}")
        print(f"\tsent:\t\t{letter.sent}")
        print(f"\tsubject:\t{letter.subject}")

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

pyelternportal-0.0.6.tar.gz (10.2 kB view details)

Uploaded Source

Built Distribution

pyelternportal-0.0.6-py3-none-any.whl (12.3 kB view details)

Uploaded Python 3

File details

Details for the file pyelternportal-0.0.6.tar.gz.

File metadata

  • Download URL: pyelternportal-0.0.6.tar.gz
  • Upload date:
  • Size: 10.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.13.0

File hashes

Hashes for pyelternportal-0.0.6.tar.gz
Algorithm Hash digest
SHA256 f0f2016c98f8e9edfa6084eb58fd2fdbd2c3af84ad64dfae5ce8c8cf3f30e072
MD5 433b4f36aabd6c699841f6321ea04ea9
BLAKE2b-256 e8788b2a9dabea0ba0514c98c3bd94a3589b707cd7204b03140d4b7c1d471ddc

See more details on using hashes here.

File details

Details for the file pyelternportal-0.0.6-py3-none-any.whl.

File metadata

File hashes

Hashes for pyelternportal-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 5113b0a77df91772fc172a1f9a1199911a8a59ad9f5e9158248080f633d2cb59
MD5 baf1550050b086f34cc820b2157da60e
BLAKE2b-256 535fee763d1dd5473f18dc8708005a6ebe8aa2f0e0926bb692da307788ad9788

See more details on using hashes here.

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