From 9d9f038de119e53a6f468335663a4c62f06b99b6 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Sun, 14 Jul 2024 20:20:42 +0300 Subject: [PATCH] telegram bot api 7.7 (#177) --- src/objects.rs | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/src/objects.rs b/src/objects.rs index c97db5e..b4329c8 100644 --- a/src/objects.rs +++ b/src/objects.rs @@ -930,6 +930,10 @@ pub struct Message { #[builder(setter(into, strip_option), default)] pub successful_payment: Option>, + #[serde(skip_serializing_if = "Option::is_none")] + #[builder(setter(into, strip_option), default)] + pub refunded_payment: Option>, + #[serde(skip_serializing_if = "Option::is_none")] #[builder(setter(into, strip_option), default)] pub users_shared: Option>, @@ -3676,6 +3680,23 @@ pub struct SuccessfulPayment { pub provider_payment_charge_id: String, } +#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Builder)] +pub struct RefundedPayment { + #[builder(setter(into))] + pub currency: String, + + pub total_amount: u32, + + #[builder(setter(into))] + pub invoice_payload: String, + + #[builder(setter(into))] + pub telegram_payment_charge_id: String, + + #[builder(setter(into))] + pub provider_payment_charge_id: Option, +} + #[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq, Builder)] pub struct ShippingQuery { #[builder(setter(into))]