An open API service indexing awesome lists of open source software.

https://github.com/siketyan/schetube

A library to fetch upcoming live streams from a YouTube channel.
https://github.com/siketyan/schetube

live-streams rust-library youtube

Last synced: 27 days ago
JSON representation

A library to fetch upcoming live streams from a YouTube channel.

Awesome Lists containing this project

README

        

# schetube
![Rust](https://github.com/siketyan/schetube/workflows/Rust/badge.svg)

A library to fetch upcoming live streams from a YouTube channel.

## 📦 Installation
```toml
[dependencies]
schetube = "0.1"
```

## 💚 Example
```
$ cd ./example
$ cargo run [Channel ID]
```

## 🔌 API
📝 List of structs and functions are available at [docs.rs](https://docs.rs/schetube/latest/schetube/) .

```rust
pub async fn fetch_upcoming_videos(channel_id: &str) -> Result<(Channel, Vec), Box>;
pub fn response_to_videos(response: &ApiResponse) -> Option>;
pub fn response_to_channel(response: &ApiResponse) -> Option;

impl Client {
pub fn new(client: reqwest::Client) -> Self;
pub fn create(name: &str, version: &str) -> Result>;
pub async fn build() -> Result>;
pub async fn fetch_upcoming_live_streams(&self, channel_id: &str) -> Result>;
}
```