conogram/entities/passport_element_error_reverse_side.rs
1use serde::{Deserialize, Serialize};
2
3/// Represents an issue with the reverse side of a document. The error is considered resolved when the file with reverse side of the document changes.
4///
5/// API Reference: [link](https://core.telegram.org/bots/api/#passportelementerrorreverseside)
6#[derive(Debug, Clone, Default, PartialEq, Serialize, Deserialize)]
7pub struct PassportElementErrorReverseSide {
8 /// The section of the user's Telegram Passport which has the issue, one of “driver\_license”, “identity\_card”
9 #[serde(rename = "type")]
10 pub type_: PassportElementErrorReverseSideType,
11
12 /// Base64-encoded hash of the file with the reverse side of the document
13 pub file_hash: String,
14
15 /// Error message
16 pub message: String,
17}
18
19/// The section of the user's Telegram Passport which has the issue, one of “driver\_license”, “identity\_card”
20#[derive(Debug, Clone, Copy, Default, PartialEq, Serialize, Deserialize)]
21pub enum PassportElementErrorReverseSideType {
22 /// `driver_license`
23 #[default]
24 #[serde(rename = "driver_license")]
25 DriverLicense,
26
27 /// `identity_card`
28 #[serde(rename = "identity_card")]
29 IdentityCard,
30}
31
32// Divider: all content below this line will be preserved after code regen