Python3 library for Tibber.
Read electricity price and consumption.
If you have a Tibber Pulse or Watty you can see your consumption in real time.
Go to developer.tibber.com/ to get your API token.
pip3 install pyTibber
import tibber
access_token = tibber.DEMO_TOKEN
tibber_connection = tibber.Tibber(access_token)
tibber_connection.sync_update_info()
print(tibber_connection.name)
home = tibber_connection.get_homes()[0]
home.sync_update_info()
print(home.address1)
home.sync_update_price_info()
print(home.current_price_info)
tibber_connection.sync_close_connection()
The library is used as part of Home Assitant: https://github.com/home-assistant/home-assistant/tree/dev/homeassistant/components/tibber