Coder Social home page Coder Social logo

oekoboiler-api's Introduction

oekoboiler-api

oekoboiler-api is a Python library to read out properties like current temperature from your Oekoboiler water heater.

Use at your own risk! You can damage your boiler by setting wrong parameters!

Home Assistant integration based on this library is coming soon.

Disclaimer

  • Use at your own risk! You can damage your boiler by setting wrong parameters!
  • This project is fully private and not affiliated with Oekoboiler or Ayla.

Installation

Use the package manager pip to install oekoboiler-api.

pip install oekoboiler-api

Usage (see src/example/main.py)

  1. Update .example_env with your data and rename it to .env
  2. Run src/example/main.py to see if the connection to your Oekoboiler works. The current water temperature should be printed to console.
#Insert your credentials and rename this file to ".env" (remove "example_env"). 
#Now you can execute main.py to run the example.

#The email used to create an account in your Oekoboiler app
[email protected]

#The password used to create an account in your Oekoboiler app
AYLA_PW=oekoboiler_app_pw

#The app secret for Oekoboiler. If your not able to find it somewhere, ask Oekoboiler!
AYLA_APP_SECRET=ayla_secret_for_oekoboiler

#The device id for your Oekoboiler (Revealed in Oekobiler App). 
OEKOBOILER_SN=YOUR_DEVICE_ID 
import asyncio
import os

from dotenv import load_dotenv

from oekoboilerapi.aylaservice import AylaService, Credentials
from oekoboilerapi.oekoboiler import Oekoboiler


async def main():
    """Example to show how it works. Have fun!"""
    load_dotenv()

    boiler = Oekoboiler(
        AylaService(
            Credentials(
                email=os.getenv("AYLA_EMAIL"),
                password=os.getenv("AYLA_PW"),
                app_secret=os.getenv("AYLA_APP_SECRET"),
            )
        ),
        os.getenv("OEKOBOILER_SN"),
    )

    await boiler.async_update()
    print(f"Current temperature is {boiler.temp_c_current}C°")


asyncio.run(main())

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

Credits

This project was influenced by @johnrichard's work.

oekoboiler-api's People

Contributors

bbmedia avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.