glowmarkt

Crates.ioglowmarkt
lib.rsglowmarkt
version0.5.2
sourcesrc
created_at2022-08-24 07:22:55.7936
updated_at2024-01-14 09:47:36.908191
descriptionAccess to the Glowmarkt API for smart meter data.
homepagehttps://github.com/Mossop/glowmarkt-rs
repositoryhttps://github.com/Mossop/glowmarkt-rs
max_upload_size
id651530
size79,498
Dave Townsend (Mossop)

documentation

README

Glowmarkt

Crates.io docs.rs License

A rust crate for accessing the Glowmarkt API for meter readings.

This contains two parts. A module that other programs can use for programmatic access to the API and a CLI that users can use to query for data. It was developed with the primary purpose of being able to submit meter readings to InfluxDB but along the way a number of other ways of displaying data from the API were added to the CLI.

In order to use this you need to have installed and registered your smart meters with the Bright mobile app. Then you can use the username and password you used there with this tool.

CLI Usage

The CLI should be reasonably well documented with --help.

$> cargo install glowmarkt
$> glowmarkt --username='me@somewhere.com' --password='wibble' device

Module Usage

The API is async so you must set up an async runtime such as tokio. Authenticating with a username and password will generate a token for subsequent requests.

let api = GlowmarktApi::authenticate("me@somewhere.com", "wibble").await?;
let devices = api.devices().await?;

Consult the module docs for more information.

Commit count: 0

cargo fmt