EncryptedPassportElement class abstract

Describes documents or other Telegram Passport elements shared with the bot by the user.

Annotations
  • @freezed

Constructors

EncryptedPassportElement.new({@JsonKey(name: 'type') required PassportType type, @JsonKey(name: 'data') String? data, @JsonKey(name: 'phone_number') String? phoneNumber, @JsonKey(name: 'email') String? email, @JsonKey(name: 'files') List<PassportFile>? files, @JsonKey(name: 'front_side') PassportFile? frontSide, @JsonKey(name: 'reverse_side') PassportFile? reverseSide, @JsonKey(name: 'selfie') PassportFile? selfie, @JsonKey(name: 'translation') List<PassportFile>? translation, @JsonKey(name: 'hash') required String hash})
Creates a new EncryptedPassportElement object.
const
factory
EncryptedPassportElement.fromJson(Map<String, dynamic> json)
Creates a new EncryptedPassportElement object from json.
factory

Properties

copyWith → $EncryptedPassportElementCopyWith<EncryptedPassportElement>
Create a copy of EncryptedPassportElement with the given fields replaced by the non-null parameter values.
no setterinherited
data String?
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.
no setterinherited
email String?
Optional. User's verified email address, available only for “email” type
no setterinherited
files List<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.
no setterinherited
frontSide 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.
no setterinherited
hash String
Base64-encoded element hash for using in PassportElementErrorUnspecified
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
phoneNumber String?
Optional. User's verified phone number, available only for “phone_number” type
no setterinherited
reverseSide 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.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
selfie 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.
no setterinherited
translation List<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.
no setterinherited
type PassportType
Type of Telegram Passport element
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Serializes this EncryptedPassportElement to a JSON map.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited