3 releases

0.1.0-rc.3 Dec 8, 2022
0.1.0-rc.2 Jun 27, 2022
0.1.0-rc.1 Jun 15, 2022

#648 in Web programming

MIT license

742 lines


GitHub license crates.io docs.rs Main

API wrapper for the tankerkoenig-api written in rust.

The API of tankerkoenig gives you realtime fuel prices for germany with Creative Commons License. This rust wrapper provides you ready deserialized structs and an easy to use and strictly typed api.


This crate is under development. Especially the response parsing needs some more testing. However, if you still want to use it, you can install it by adding this to your Cargo.toml:

tankerkoenig = "0.1.0-rc.3"
# If you want to use the latest unreleased version:
tankerkoenig = { git = "https://github.com/jontze/tankerkoenig-rs" }


  1. Api Token for the tankerkoenig-api
  2. Async runtime like tokio


use tankerkoenig::Tankerkoenig;
use tankerkoenig::models;

async fn request_station_details() -> Result<models::station::DetailsResponse, tankerkoenig::Error> {
    let tanker = Tankerkoenig::new("<your-api-key>")?;
    let details = tanker.station.fetch_details("id-of-a-fuel-station").await?;


~262K SLoC