GTubeK/inv.rs

10 lines
313 B
Rust
Raw Normal View History

2022-09-08 14:45:08 +05:30
use invidious::reqwest::blocking::Client;
use std::error::Error;
fn main() -> Result<(), Box<dyn Error>> {
let client = Client::new(String::from("https://vid.puffyan.us"));
let search_results = client.search(Some("q=rust programming"))?.items;
let video = client.video("5C_HPTJg5ek", None)?;
Ok(())
}