Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- use serde::de::Deserialize;
- // primitive telegram type
- pub type Integer = i64;
- pub type Float = f32;
- #[derive(Serialize, Deserialize)]
- pub struct Response<T: Deserialize> {
- pub ok: bool,
- pub error_code: Option<Integer>,
- pub description: Option<String>,
- pub result: Option<T>,
- }
- #[derive(Serialize, Deserialize)]
- pub struct User {
- pub id: Integer,
- pub firs_name: String,
- pub last_name: Option<String>,
- pub username: Option<String>,
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement