rustio 0.0.2

Rust API wrapper for radio-browser.info
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use restson::{Error, RestPath};

#[derive(Serialize, Deserialize, Debug, Clone)]
pub struct Stats {
    pub stations: String,
    pub stations_broken: String,
    pub tags: String,
    pub clicks_last_hour: String,
    pub clicks_last_day: String,
    pub languages: String,
    pub countries: String,
}

impl RestPath<()> for Stats {
    fn get_path(_: ()) -> Result<String, Error> {
        Ok(format!("webservice/json/stats"))
    }
}