Skip to content

Jezza34000/veolia-api

Repository files navigation

Async Python client for the Veolia water portal API (eau.veolia.fr and compatible portals).

Table of contents

Installation

pip install veolia-api

For a development environment, install devbox then run:

devbox shell

Usage

import asyncio
from datetime import date

import aiohttp

from veolia_api import VeoliaAPI


async def main() -> None:
    async with aiohttp.ClientSession() as session:
        client_api = VeoliaAPI("your@email.com", "password", session)

        # Optional: specify a portal other than the default
        # client_api = VeoliaAPI("your@email.com", "password", session, portal_url="eaudetm.monespace.eau.veolia.fr")

        await client_api.fetch_all_data(date(2025, 1, 1), date(2025, 9, 1))

        print(client_api.account_data.daily_consumption)
        print(client_api.account_data.monthly_consumption)
        print(client_api.account_data.alert_settings.daily_enabled)


if __name__ == "__main__":
    asyncio.run(main())

A runnable example with logging is available in usage_example.py.

Supported portals

Portal Region
eau.veolia.fr France (national)
eaudetm.monespace.eau.veolia.fr Eau de Toulouse Metropole

Your portal is missing? See Adding a portal — it only requires editing one file.

Contributing

Contributions are welcome. Please read CONTRIBUTING.md for guidelines on reporting bugs, suggesting features, and submitting pull requests.

Credits

Inspired by the original work of @CorentinGrard.

License

MIT — see LICENSE.

About

Veolia API client

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages