mirror of
https://github.com/teloxide/teloxide.git
synced 2024-12-23 06:51:01 +01:00
Remove #[macro_use]
and use use
instead
This commit is contained in:
parent
0c0e1014c1
commit
51703b16b1
153 changed files with 292 additions and 23 deletions
|
@ -1,4 +1,6 @@
|
|||
use derive_more::From;
|
||||
use reqwest::StatusCode;
|
||||
use thiserror::Error;
|
||||
|
||||
//<editor-fold desc="download">
|
||||
#[derive(Debug, Error, From)]
|
||||
|
|
|
@ -5,13 +5,6 @@
|
|||
html_favicon_url = "https://github.com/teloxide/teloxide/raw/dev/ICON.png"
|
||||
)]
|
||||
|
||||
#[macro_use]
|
||||
extern crate derive_more;
|
||||
#[macro_use]
|
||||
extern crate serde;
|
||||
#[macro_use]
|
||||
extern crate thiserror;
|
||||
|
||||
pub use bot::Bot;
|
||||
pub use errors::{DownloadError, RequestError};
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
use reqwest::StatusCode;
|
||||
use serde::Deserialize;
|
||||
|
||||
use crate::{
|
||||
requests::ResponseResult,
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::True,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::InlineQueryResult,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::True,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ShippingOption, True},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
};
|
||||
use crate::types::{ChatId, True};
|
||||
|
||||
/// Use this method to delete a chat photo. Photos can't be changed for private chats. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns True on success.
|
||||
#[serde_with_macros::skip_serializing_none]
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::True,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::True,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ParseMode, InlineKeyboardMarkup, Message},
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ParseMode, InlineKeyboardMarkup},
|
||||
types::{ParseMode, InlineKeyboardMarkup, Message},
|
||||
};
|
||||
use crate::types::Message;
|
||||
|
||||
/// Use this method to edit captions of messages. On success, if edited message is sent by the bot, the edited Message is returned, otherwise True is returned.
|
||||
#[serde_with_macros::skip_serializing_none]
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, InlineKeyboardMarkup, Message},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, InlineKeyboardMarkup, Message},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ParseMode, InlineKeyboardMarkup, Message},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ParseMode, InlineKeyboardMarkup, Message},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::ChatId,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, Message},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, Chat},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ChatMember},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ChatMember},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::ChatId,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::File,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::GameHighScore,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::GameHighScore,
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::User,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::StickerSet,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::Update,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::UserProfilePhotos,
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::WebhookInfo,
|
||||
};
|
||||
use crate::types::WebhookInfo;
|
||||
|
||||
/// Use this method to get current webhook status. Requires no parameters. On success, returns a WebhookInfo object. If the bot is using getUpdates, will return an object with the url field empty.
|
||||
#[derive(Debug, PartialEq, Eq, Hash, Clone, Deserialize, Serialize, Default)]
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
};
|
||||
use crate::types::{ChatId, True};
|
||||
|
||||
/// Use this method to pin a message in a group, a supergroup, or a channel. The bot must be an administrator in the chat for this to work and must have the ‘can_pin_messages’ admin right in the supergroup or ‘can_edit_messages’ admin right in the channel. Returns True on success.
|
||||
#[serde_with_macros::skip_serializing_none]
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
};
|
||||
use crate::types::{ChatId, True};
|
||||
|
||||
/// Use this method to promote or demote a user in a supergroup or a channel. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Pass False for all boolean parameters to demote a user. Returns True on success.
|
||||
#[serde_with_macros::skip_serializing_none]
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ChatPermissions, True},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ReplyMarkup, Message},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{InlineKeyboardMarkup, Message},
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{LabeledPrice, InlineKeyboardMarkup, Message},
|
||||
};
|
||||
use crate::types::{LabeledPrice, InlineKeyboardMarkup, Message};
|
||||
|
||||
/// Use this method to send invoices. On success, the sent Message is returned.
|
||||
#[serde_with_macros::skip_serializing_none]
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ReplyMarkup, Message},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, Message, ParseMode, ReplyMarkup},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ReplyMarkup, Message},
|
||||
};
|
||||
use crate::types::{ChatId, ReplyMarkup, Message};
|
||||
|
||||
/// Use this method to send a native poll. A native poll can't be sent to a private chat. On success, the sent Message is returned.
|
||||
#[serde_with_macros::skip_serializing_none]
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ReplyMarkup, Message},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
use reqwest::multipart::Form;
|
||||
|
||||
use crate::{
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, ChatPermissions, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, InputFile, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{Message, ChatId},
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::True,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{InputFile, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, InlineKeyboardMarkup, Message},
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, InlineKeyboardMarkup},
|
||||
types::{ChatId, InlineKeyboardMarkup, Poll},
|
||||
};
|
||||
use crate::types::Poll;
|
||||
|
||||
/// Use this method to stop a poll which was sent by the bot. On success, the stopped Poll with the final results is returned.
|
||||
#[serde_with_macros::skip_serializing_none]
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{ChatId, True},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::{
|
||||
requests::{dynamic, json, Method},
|
||||
types::{InputFile, File},
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::PhotoSize;
|
||||
|
||||
/// This object represents an animation file (GIF or H.264/MPEG-4 AVC video
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::PhotoSize;
|
||||
|
||||
/// This object represents an audio file to be treated as music by the Telegram
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{Message, User};
|
||||
|
||||
/// This object represents an incoming callback query from a callback button in
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{ChatPermissions, ChatPhoto, Message};
|
||||
|
||||
/// This object represents a chat.
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
#[derive(Clone, Debug, Deserialize, Eq, Hash, PartialEq, Serialize)]
|
||||
#[serde(rename_all = "snake_case")]
|
||||
pub enum ChatAction {
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
use derive_more::{Display, From};
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// A unique identifier for the target chat or username of the target channel
|
||||
/// (in the format `@channelusername`).
|
||||
#[derive(
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::User;
|
||||
|
||||
/// This object contains information about one member of the chat.
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// Describes actions that a non-administrator user is allowed to take in a
|
||||
/// chat.
|
||||
///
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// This object represents a chat photo.
|
||||
///
|
||||
/// [The official docs](https://core.telegram.org/bots/api#chatphoto).
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{Location, User};
|
||||
|
||||
/// Represents a [result] of an inline query that was chosen by the user and
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// This object represents a phone contact.
|
||||
///
|
||||
/// [The official docs](https://core.telegram.org/bots/api#contact).
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::PhotoSize;
|
||||
|
||||
/// This object represents a general file (as opposed to [photos], [voice
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// Contains data required for decrypting and authenticating
|
||||
/// [`EncryptedPassportElement`]. See the [Telegram Passport Documentation] for
|
||||
/// a complete description of the data decryption and authentication processes.
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use super::PassportFile;
|
||||
|
||||
/// Contains information about documents or other Telegram Passport elements
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// This object represents a file ready to be downloaded. The file can be
|
||||
/// downloaded via the link `https://api.telegram.org/file/bot<token>/<file_path>`.
|
||||
/// It is guaranteed that the link will be valid for at least 1 hour. When the
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::True;
|
||||
|
||||
/// Upon receiving a message with this object, Telegram clients will display a
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
use serde::Deserialize;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{Animation, MessageEntity, PhotoSize};
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
use serde::Deserialize;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::user::User;
|
||||
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
/// This object represents one button of an inline keyboard.
|
||||
///
|
||||
/// [The official docs](https://core.telegram.org/bots/api#inlinekeyboardbutton).
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::InlineKeyboardButton;
|
||||
|
||||
/// This object represents an [inline keyboard] that appears right next to the
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{Location, User};
|
||||
|
||||
/// This object represents an incoming inline query. When the user sends an
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
#![allow(clippy::large_enum_variant)]
|
||||
|
||||
use derive_more::From;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{
|
||||
InlineQueryResultArticle, InlineQueryResultAudio,
|
||||
InlineQueryResultCachedAudio, InlineQueryResultCachedDocument,
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{InlineKeyboardMarkup, InputMessageContent};
|
||||
|
||||
/// Represents a link to an article or web page.
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{InlineKeyboardMarkup, InputMessageContent, ParseMode};
|
||||
|
||||
/// Represents a link to an MP3 audio file. By default, this audio file will be
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::types::{InlineKeyboardMarkup, InputMessageContent, ParseMode};
|
||||
|
||||
/// Represents a link to an MP3 audio file stored on the Telegram servers. By
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue