The Twitch v5 API is scheduled to be shutdown at the end of February
2022.
A Rust library for the Twitch APIv5 (Kraken).
Help for this project is highly appreciated. This was built against Twitch APIv5 (Kraken). Take a look into the issues if you want to contribute to the project.
Fork it, implement your changes and make a Pull-Request against the feature-dev
branch of this repo.
use libtwitch_rs;
use libtwitch_rs::users;
...
let mut c = libtwitch_rs::new(String::from(CLIENTID));
c.set_oauth_token(TOKEN);
if let Some(user) = match users::get(&c) {
Ok(r) => { assert!(r.email.is_some()); Some(r) },
Err(r) => { println!("{:?}", r); assert!(false); None }
} {
let user_id = user.id.to_string();
match users::get_by_id(&c, &user_id) {
Ok(r) => assert_eq!(r.name, user.name),
Err(r) => { println!("{:?}", r); assert!(false); }
}
}
Important Note: Kraken is deprecated and Helix (the new API version) is out of scope of this repository currently.
Endpoints | Kraken/v5 |
---|---|
Analytics | ➖ |
Bits | ✔️ |
Channels | ✔️ |
Chat | ✔️ |
Clips | ✔️ |
Collections | ✔️ |
Entitlements | ➖ |
Games | ✔️ |
Ingests | ✔️ |
Moderation | ➖ |
Search | ✔️ |
Streams | ✔️ |
Subscriptions | ➖ |
Tags | ➖ |
Teams | ✔️ |
Users | ✔️ |
Videos | ✔️ |
Webhooks | ➖ |
- Twitch library (C#)
- Twitch library (PHP)
- Python Twitch client
- TwitchIO, Twtich Bot/API wrapper (Python)
GNU LGPL-3.0-or-later; see copying.md and legal/LGPL-v3.