Client library for radio-browser.info and other radio-browser-rust servers
Find a file
2022-04-21 23:07:46 +02:00
src added tags, changed name 2022-04-21 22:47:23 +02:00
.gitignore nicer test 2022-04-19 02:03:53 +02:00
Cargo.toml description 2022-04-21 23:07:46 +02:00
README.md readme 2022-04-21 23:03:49 +02:00

Radiobrowser Lib Rust

Client library for radio-browser.info and other radio-browser-rust servers

Getting started

Cargo.toml entry

radiobrowser = "*"

Example:

use radiobrowser::RadioBrowserAPI;
use radiobrowser::StationOrder;
use std::error::Error;

#[async_std::main]
async fn main() -> Result<(), Box<dyn Error>> {
    let mut api = RadioBrowserAPI::new().await?;
    let stations = api
        .get_stations()
        .name("jazz")
        .reverse(true)
        .order(StationOrder::Clickcount)
        .send()
        .await?;

    println!("Stations found: {}", stations?.len());
    Ok(())
}

Usage

Documentation is at https://docs.rs/radiobrowser

License

This project is MIT licensed.