pyHeatpump API
Welcome to the pyHeatpump API.
Configuration Routes
List of the GET routes.
- /config/ Get configuration as a JSON-formatted dictionary
- /config/mac Get mac address configuration value in plain text format
- /config/last_update Get last update value in plain text format (timestamp in seconds)
List of the POST routes.
The examples in this section are written with "httpie" for readability, you can easily convert the to CURL syntax.
Config
Examples :
echo '{"heatpump": {"mac_address": "00:11:22:33:44:55" }}' | http POST http://rpi-ip/config/
Mac address
Sets the mac address to the value given in text/plain format through the body of the request.
Examples :
echo '00:11:22:33:44:55 | http POST http://rpi-ip/config/mac
Last update
Sets the last_update timestamp relative to the *value* given in seconds and in text/plain format through the body of the request.
If the *value* is 0, last_update is set to now.
If the *value* is below 0, last_update is set to -*value* seconds after now.
If the *value* is above 0, last_update is set to *value* seconds before now.
Examples :
echo '0' | http POST http://rpi-ip/config/last_update
echo '-3000' | http POST http://rpi-ip/config/last_update
An interesting example to set last_update to 0 (epoch):
echo '0' | http POST http://rpi-ip/config/last_update | http POST http://rpi-ip/config/last_update
Heatpump Routes
List of the GET routes.
All of these routes return JSON-formatted dictionaries.
Heatpump
- /heatpump Get all variable values of a heatpump
Variable types
Variables
Variables values