summaryrefslogtreecommitdiff
path: root/src/emotes.rs
blob: 7242f826681162900dbe8a88b81321703a1d1d93 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use reqwest::Error;
use serde::{Deserialize, Serialize};

#[derive(Deserialize, Serialize, Clone, Debug)]
pub struct Emote {
    pub id: String,
    pub code: String,
    pub original_code: Option<String>,
}

pub trait RetrieveEmoteAPI<T> {
    async fn get_channel_emotes(&self, channel_login: &str) -> Result<Vec<T>, Error>;
    async fn get_global_emotes(&self) -> Result<Vec<T>, Error>;
}