Skip to main content

A lightweight async Python wrapper for school.mos.ru APIs

Project description

Badge Python License

📕 SchoolMosPy

SchoolMosPy is a lightweight async Python wrapper for school.mos.ru APIs. It provides a simple and intuitive interface to interact with the Moscow School Electronic Diary platform.

✨ Features

  • Async architecture - built on aiohttp and httpx for high performance
  • Type safety - uses pydantic for data validation
  • Simple API - intuitive interface for working with data
  • Full-featured - access to marks, homeworks, events, and profile data

📋 Requirements

  • Python 3.12+
  • aiohttp >= 3.12.15
  • pydantic >= 2.11.9
  • httpx >= 0.28.1

📦 Installation

pip install schoolmospy

🚀 Quick Start

import asyncio
from schoolmospy import StudentClient

async def main():
    # Create client
    client = StudentClient(
        token="your_token",
        profile_id=12345
    )

    # Get profile
    profile = await client.get_me()
    print(f"Name: {profile.name}")

    # Get marks
    marks = await client.marks.get(
        from_date="2024-01-01",
        to_date="2024-12-31"
    )

    # Get homeworks
    homeworks = await client.homeworks.get(
        from_date="2024-01-01",
        to_date="2024-12-31"
    )

    # Get events/schedule
    events = await client.events.get(
        from_date="2024-01-01",
        to_date="2024-12-31"
    )

    await client.close()

asyncio.run(main())

📝 License

This project is licensed under the GPL-3.0 License. See the LICENSE file for details.

🔗 Links

👨‍💻 Author

Ivan Kriventsev - xd2dd@icloud.com


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

schoolmospy-0.2.3.tar.gz (19.0 kB view details)

Uploaded Source

Built Distribution

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

schoolmospy-0.2.3-py3-none-any.whl (22.9 kB view details)

Uploaded Python 3

File details

Details for the file schoolmospy-0.2.3.tar.gz.

File metadata

  • Download URL: schoolmospy-0.2.3.tar.gz
  • Upload date:
  • Size: 19.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.2 CPython/3.12.12 Linux/6.11.0-1018-azure

File hashes

Hashes for schoolmospy-0.2.3.tar.gz
Algorithm Hash digest
SHA256 f9057fde76cc86d30279e3c37c210507ea28ed6d6b17918f5a1d23343738b127
MD5 c361257b4b0b2871ca986d95d9e394c4
BLAKE2b-256 f7d7a75b469b1e8cd2a2ac5be52d2e9578aa2527250cf27bc698798b3910573d

See more details on using hashes here.

File details

Details for the file schoolmospy-0.2.3-py3-none-any.whl.

File metadata

  • Download URL: schoolmospy-0.2.3-py3-none-any.whl
  • Upload date:
  • Size: 22.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.2 CPython/3.12.12 Linux/6.11.0-1018-azure

File hashes

Hashes for schoolmospy-0.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 ef43d3c2aa266320e939c4d670cedf60d0d39cc20e4216cdc007edb46e13b30e
MD5 2d5dc94e6ee36b71fbe4d768bd9e8c3a
BLAKE2b-256 be7706e6f0546f678e3f8a176e4e870bb401fbc4c2bc700f396d61cbe70c88ee

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