Struct botapi::gen_types::EncryptedPassportElement
source · pub struct EncryptedPassportElement { /* private fields */ }
Expand description
Describes documents or other Telegram Passport elements shared with the bot by the user.
Implementations§
source§impl EncryptedPassportElement
impl EncryptedPassportElement
pub fn noskip(self) -> NoSkipEncryptedPassportElement
source§impl EncryptedPassportElement
impl EncryptedPassportElement
pub fn new(hash: String) -> Self
sourcepub fn get_tg_type<'a>(&'a self) -> Cow<'a, str>
pub fn get_tg_type<'a>(&'a self) -> Cow<'a, str>
Element type. One of “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport”, “address”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration”, “phone_number”, “email”.
sourcepub fn get_tg_type_ref<'a>(&'a self) -> &'a str
pub fn get_tg_type_ref<'a>(&'a self) -> &'a str
Element type. One of “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport”, “address”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration”, “phone_number”, “email”.
sourcepub fn get_data<'a>(&'a self) -> Option<Cow<'a, str>>
pub fn get_data<'a>(&'a self) -> Option<Cow<'a, str>>
Optional. Base64-encoded encrypted Telegram Passport element data provided by the user, available for “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport” and “address” types. Can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_data_ref<'a>(&'a self) -> Option<&'a str>
pub fn get_data_ref<'a>(&'a self) -> Option<&'a str>
Optional. Base64-encoded encrypted Telegram Passport element data provided by the user, available for “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport” and “address” types. Can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_phone_number<'a>(&'a self) -> Option<Cow<'a, str>>
pub fn get_phone_number<'a>(&'a self) -> Option<Cow<'a, str>>
Optional. User’s verified phone number, available only for “phone_number” type
sourcepub fn get_phone_number_ref<'a>(&'a self) -> Option<&'a str>
pub fn get_phone_number_ref<'a>(&'a self) -> Option<&'a str>
Optional. User’s verified phone number, available only for “phone_number” type
sourcepub fn get_email<'a>(&'a self) -> Option<Cow<'a, str>>
pub fn get_email<'a>(&'a self) -> Option<Cow<'a, str>>
Optional. User’s verified email address, available only for “email” type
sourcepub fn get_email_ref<'a>(&'a self) -> Option<&'a str>
pub fn get_email_ref<'a>(&'a self) -> Option<&'a str>
Optional. User’s verified email address, available only for “email” type
sourcepub fn get_files<'a>(&'a self) -> Option<Cow<'a, Vec<PassportFile>>>
pub fn get_files<'a>(&'a self) -> Option<Cow<'a, Vec<PassportFile>>>
Optional. Array of encrypted files with documents provided by the user, available for “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_files_ref<'a>(&'a self) -> Option<&'a Vec<PassportFile>>
pub fn get_files_ref<'a>(&'a self) -> Option<&'a Vec<PassportFile>>
Optional. Array of encrypted files with documents provided by the user, available for “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_front_side<'a>(&'a self) -> Option<Cow<'a, PassportFile>>
pub fn get_front_side<'a>(&'a self) -> Option<Cow<'a, PassportFile>>
Optional. Encrypted file with the front side of the document, provided by the user. Available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_front_side_ref<'a>(&'a self) -> Option<&'a PassportFile>
pub fn get_front_side_ref<'a>(&'a self) -> Option<&'a PassportFile>
Optional. Encrypted file with the front side of the document, provided by the user. Available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_reverse_side<'a>(&'a self) -> Option<Cow<'a, PassportFile>>
pub fn get_reverse_side<'a>(&'a self) -> Option<Cow<'a, PassportFile>>
Optional. Encrypted file with the reverse side of the document, provided by the user. Available for “driver_license” and “identity_card”. The file can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_reverse_side_ref<'a>(&'a self) -> Option<&'a PassportFile>
pub fn get_reverse_side_ref<'a>(&'a self) -> Option<&'a PassportFile>
Optional. Encrypted file with the reverse side of the document, provided by the user. Available for “driver_license” and “identity_card”. The file can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_selfie<'a>(&'a self) -> Option<Cow<'a, PassportFile>>
pub fn get_selfie<'a>(&'a self) -> Option<Cow<'a, PassportFile>>
Optional. Encrypted file with the selfie of the user holding a document, provided by the user; available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_selfie_ref<'a>(&'a self) -> Option<&'a PassportFile>
pub fn get_selfie_ref<'a>(&'a self) -> Option<&'a PassportFile>
Optional. Encrypted file with the selfie of the user holding a document, provided by the user; available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_translation<'a>(&'a self) -> Option<Cow<'a, Vec<PassportFile>>>
pub fn get_translation<'a>(&'a self) -> Option<Cow<'a, Vec<PassportFile>>>
Optional. Array of encrypted files with translated versions of documents provided by the user. Available if requested for “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_translation_ref<'a>(&'a self) -> Option<&'a Vec<PassportFile>>
pub fn get_translation_ref<'a>(&'a self) -> Option<&'a Vec<PassportFile>>
Optional. Array of encrypted files with translated versions of documents provided by the user. Available if requested for “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials.
sourcepub fn get_hash<'a>(&'a self) -> Cow<'a, str>
pub fn get_hash<'a>(&'a self) -> Cow<'a, str>
Base64-encoded element hash for using in PassportElementErrorUnspecified
sourcepub fn get_hash_ref<'a>(&'a self) -> &'a str
pub fn get_hash_ref<'a>(&'a self) -> &'a str
Base64-encoded element hash for using in PassportElementErrorUnspecified
Trait Implementations§
source§impl Clone for EncryptedPassportElement
impl Clone for EncryptedPassportElement
source§fn clone(&self) -> EncryptedPassportElement
fn clone(&self) -> EncryptedPassportElement
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more