Commit Graph

9 Commits

Author SHA1 Message Date
Paul van Tilburg 35209b6303
Bump the version to 0.2.1 2023-01-16 20:16:30 +01:00
Paul van Tilburg e6b0357670
Add serde from rocket; drop depend on serde 2023-01-16 20:07:56 +01:00
Paul van Tilburg ddcb375345
Introduce an error type for services
As a result, services don't always have to provide a `reqwest::Error`
but also return other errors. The error variant `Error::NotAuthorized`
in particular specifies that requests are not or no longer allowed and a
login should be (re)attempted. This way, services can indicate that it
is in this state and not have to provided a 403 status code
`reqwest::Error` to show this.

Add a depend on the `thiserror` crate for this.
2023-01-15 16:31:37 +01:00
Paul van Tilburg e0151c3cde
Set last updated field to what is returned by API
In Hoymiles, the date of the last update is part of the API response.
Parse it and use that in `Status` instead of the timestamp provided by
the update loop.

Add a depend on the `chrono` crate for this.
2023-01-15 14:48:24 +01:00
Paul van Tilburg 4088c37cd2
Bump the version to 0.2.0 2023-01-13 19:47:14 +01:00
Paul van Tilburg 69f34e3243
Add Debian packaging via cargo-deb (closes: #4)
* Add the required metadata to `Cargo.toml`
* Add a systemd service unit file
* Use `Rocket.toml.example` as the default configuration
2023-01-10 16:59:20 +01:00
Paul van Tilburg b1dfea651f
Add first version of the Hoymiles service 2023-01-10 15:38:24 +01:00
Paul van Tilburg 87394f9fb9 Add service implementation; split off My Autarco support 2023-01-09 21:23:43 +01:00
Paul van Tilburg 5bf7f5d8de Initial import into Git
This project is based on [Autarco
Scraper](https://git.luon.net/paul/autarco-scraper) but will support
multiple services, not just My Autarco.
2023-01-08 15:39:14 +01:00