Enum rtdlib::types::PassportElement
source[−]pub enum PassportElement {
Show 15 variants
GetPassportElement(GetPassportElement),
Address(PassportElementAddress),
BankStatement(PassportElementBankStatement),
DriverLicense(PassportElementDriverLicense),
EmailAddress(PassportElementEmailAddress),
IdentityCard(PassportElementIdentityCard),
InternalPassport(PassportElementInternalPassport),
Passport(PassportElementPassport),
PassportRegistration(PassportElementPassportRegistration),
PersonalDetails(PassportElementPersonalDetails),
PhoneNumber(PassportElementPhoneNumber),
RentalAgreement(PassportElementRentalAgreement),
TemporaryRegistration(PassportElementTemporaryRegistration),
UtilityBill(PassportElementUtilityBill),
SetPassportElement(SetPassportElement),
// some variants omitted
}
Expand description
Contains information about a Telegram Passport element
Variants
GetPassportElement(GetPassportElement)
Tuple Fields
Returns one of the available Telegram Passport elements
Address(PassportElementAddress)
Tuple Fields
A Telegram Passport element containing the user’s address
BankStatement(PassportElementBankStatement)
Tuple Fields
A Telegram Passport element containing the user’s bank statement
DriverLicense(PassportElementDriverLicense)
Tuple Fields
A Telegram Passport element containing the user’s driver license
EmailAddress(PassportElementEmailAddress)
Tuple Fields
A Telegram Passport element containing the user’s email address
IdentityCard(PassportElementIdentityCard)
Tuple Fields
A Telegram Passport element containing the user’s identity card
InternalPassport(PassportElementInternalPassport)
Tuple Fields
A Telegram Passport element containing the user’s internal passport
Passport(PassportElementPassport)
Tuple Fields
A Telegram Passport element containing the user’s passport
PassportRegistration(PassportElementPassportRegistration)
Tuple Fields
A Telegram Passport element containing the user’s passport registration pages
PersonalDetails(PassportElementPersonalDetails)
Tuple Fields
A Telegram Passport element containing the user’s personal details
PhoneNumber(PassportElementPhoneNumber)
Tuple Fields
A Telegram Passport element containing the user’s phone number
RentalAgreement(PassportElementRentalAgreement)
Tuple Fields
A Telegram Passport element containing the user’s rental agreement
TemporaryRegistration(PassportElementTemporaryRegistration)
Tuple Fields
A Telegram Passport element containing the user’s temporary registration
UtilityBill(PassportElementUtilityBill)
Tuple Fields
A Telegram Passport element containing the user’s utility bill
SetPassportElement(SetPassportElement)
Tuple Fields
Adds an element to the user’s Telegram Passport. May return an error with a message “PHONE_VERIFICATION_NEEDED” or “EMAIL_VERIFICATION_NEEDED” if the chosen phone number or the chosen email address must be verified first
Implementations
pub fn on_internal_passport<F: FnOnce(&PassportElementInternalPassport)>(
&self,
fnc: F
) -> &Self
pub fn on_passport_registration<F: FnOnce(&PassportElementPassportRegistration)>(
&self,
fnc: F
) -> &Self
pub fn on_personal_details<F: FnOnce(&PassportElementPersonalDetails)>(
&self,
fnc: F
) -> &Self
pub fn on_rental_agreement<F: FnOnce(&PassportElementRentalAgreement)>(
&self,
fnc: F
) -> &Self
pub fn on_temporary_registration<F: FnOnce(&PassportElementTemporaryRegistration)>(
&self,
fnc: F
) -> &Self
Trait Implementations
Performs the conversion.
fn deserialize<D>(deserializer: D) -> Result<PassportElement, D::Error> where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<PassportElement, D::Error> where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for PassportElement
impl Send for PassportElement
impl Sync for PassportElement
impl Unpin for PassportElement
impl UnwindSafe for PassportElement
Blanket Implementations
Mutably borrows from an owned value. Read more