diff --git a/src/api_params.rs b/src/api_params.rs index 1c3f155..a99d6f0 100644 --- a/src/api_params.rs +++ b/src/api_params.rs @@ -889,6 +889,10 @@ pub struct SendPaidMediaParams { pub media: Vec, + #[serde(skip_serializing_if = "Option::is_none")] + #[builder(setter(into, strip_option), default)] + pub payload: Option, + #[serde(skip_serializing_if = "Option::is_none")] #[builder(setter(into, strip_option), default)] pub caption: Option, diff --git a/src/objects.rs b/src/objects.rs index ea262b0..9eb8099 100644 --- a/src/objects.rs +++ b/src/objects.rs @@ -384,6 +384,7 @@ pub enum UpdateContent { ChatJoinRequest(ChatJoinRequest), ChatBoost(ChatBoostUpdated), RemovedChatBoost(ChatBoostRemoved), + PurchasedPaidMedia(PaidMediaPurchased), } #[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Builder)] @@ -3746,6 +3747,14 @@ pub struct PreCheckoutQuery { pub order_info: Option, } +#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Builder)] +pub struct PaidMediaPurchased { + pub from: User, + + #[builder(setter(into))] + pub paid_media_payload: String, +} + #[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Builder)] pub struct PassportData { pub data: Vec, @@ -3961,7 +3970,10 @@ pub struct GameHighScore { } #[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Builder)] -pub struct GiveawayCreated {} +pub struct GiveawayCreated { + #[serde(skip_serializing_if = "Option::is_none")] + pub prize_star_count: Option, +} #[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Builder)] pub struct Giveaway { @@ -3987,6 +3999,9 @@ pub struct Giveaway { #[builder(setter(into, strip_option), default)] pub country_codes: Option>, + #[serde(skip_serializing_if = "Option::is_none")] + pub prize_star_count: Option, + #[serde(skip_serializing_if = "Option::is_none")] #[builder(setter(into, strip_option), default)] pub premium_subscription_month_count: Option, @@ -4008,6 +4023,9 @@ pub struct GiveawayWinners { #[builder(setter(into, strip_option), default)] pub additional_chat_count: Option, + #[serde(skip_serializing_if = "Option::is_none")] + pub prize_star_count: Option, + #[serde(skip_serializing_if = "Option::is_none")] #[builder(setter(into, strip_option), default)] pub premium_subscription_month_count: Option, @@ -4040,6 +4058,10 @@ pub struct GiveawayCompleted { #[serde(skip_serializing_if = "Option::is_none")] #[builder(setter(into, strip_option), default)] pub giveaway_message: Option>, + + #[serde(skip_serializing_if = "Option::is_none")] + #[builder(setter(into, strip_option), default)] + pub is_star_giveaway: Option, } #[derive(Debug, Clone, Copy, Serialize, Deserialize, PartialEq, Eq, Builder)] @@ -4136,6 +4158,9 @@ pub struct ChatBoostSourceGiveaway { #[builder(setter(into, strip_option), default)] pub user: Option, + #[serde(skip_serializing_if = "Option::is_none")] + pub prize_star_count: Option, + #[serde(skip_serializing_if = "Option::is_none")] #[builder(setter(into, strip_option), default)] pub is_unclaimed: Option,