
    Yif                         S r SSKJr  SSKJrJr  SSKJr  SSKJ	r	  SSK
Jr  SSKJr  SSKJr  \(       a  SS	KJrJr   " S
 S\5      rg)zRContains information about Telegram Passport data shared with the bot by the user.    )Sequence)TYPE_CHECKINGOptional)EncryptedCredentials)EncryptedPassportElement)TelegramObject)parse_sequence_arg)JSONDict)BotCredentialsc            	          ^  \ rS rSrSrSrSS.S\\   S\S\	\
   4U 4S	 jjjr\ SS\	\
   S
\	S   S\	S    4U 4S jjj5       r\S\\S4   4S j5       r\SS j5       rSrU =r$ )PassportData!   a[  Contains information about Telegram Passport data shared with the bot by the user.

Note:
    To be able to decrypt this object, you must pass your ``private_key`` to either
    :class:`telegram.ext.Updater` or :class:`telegram.Bot`. Decrypted data is then found in
    :attr:`decrypted_data` and the payload can be found in :attr:`decrypted_credentials`'s
    attribute :attr:`telegram.Credentials.nonce`.

Args:
    data (Sequence[:class:`telegram.EncryptedPassportElement`]): Array with encrypted
        information about documents and other Telegram Passport elements that was shared with
        the bot.

        .. versionchanged:: 20.0
            |sequenceclassargs|

    credentials (:class:`telegram.EncryptedCredentials`)): Encrypted credentials.

Attributes:
    data (tuple[:class:`telegram.EncryptedPassportElement`]): Array with encrypted
        information about documents and other Telegram Passport elements that was shared with
        the bot.

        .. versionchanged:: 20.0
            |tupleclassattrs|

    credentials (:class:`telegram.EncryptedCredentials`): Encrypted credentials.


)_decrypted_datacredentialsdataN
api_kwargsr   r   r   c                   > [         TU ]  US9  [        U5      U l        X l        S U l        [        U Vs/ s H  oDR                  PM     snUR                  /-   5      U l	        U R                  5         g s  snf )Nr   )super__init__r	   r   r   r   tupletypehash	_id_attrs_freeze)selfr   r   r   x	__class__s        J/app/.venv/lib/python3.13/site-packages/telegram/_passport/passportdata.pyr   PassportData.__init__C   sh     	J/:LT:R	1<JN5159I9I8JJK  6s   A5botr   returnc                    > U R                  U5      nU(       d  g[        R                  " UR                  S5      U5      US'   [        R
                  " UR                  S5      U5      US'   [        TU ]  XS9$ )z,See :meth:`telegram.TelegramObject.de_json`.Nr   r   )r   r"   )_parse_datar   de_listgetr   de_jsonr   )clsr   r"   r   s      r    r(   PassportData.de_jsonT   sj    
 t$/778H#NV2::488M;RTWX]wD22    .c                 ~   ^  T R                   c$  [        U 4S jT R                   5       5      T l         T R                   $ )a  
tuple[:class:`telegram.EncryptedPassportElement`]: Lazily decrypt and return information
    about documents and other Telegram Passport elements which were shared with the bot.

.. versionchanged:: 20.0
    Returns a tuple instead of a list.

Raises:
    telegram.error.PassportDecryptionError: Decryption failed. Usually due to bad
        private/public key but can also suggest malformed/tampered data.
c              3      >#    U  HC  n[         R                  " UR                  5       TR                  5       TR                  5      v   ME     g 7fN)r   de_json_decryptedto_dictget_botdecrypted_credentials).0elementr   s     r    	<genexpr>.PassportData.decrypted_data.<locals>.<genexpr>q   sF      )  )G )::OO%t||~t7Q7Q   )s   AA)r   r   r   r   s   `r    decrypted_dataPassportData.decrypted_datac   s?     '#( )  $yy	) $D  ###r+   c                 .    U R                   R                  $ )ah  
:class:`telegram.Credentials`: Lazily decrypt and return credentials that were used
    to decrypt the data. This object also contains the user specified payload as
    `decrypted_data.payload`.

Raises:
    telegram.error.PassportDecryptionError: Decryption failed. Usually due to bad
        private/public key but can also suggest malformed/tampered data.
)r   r8   r7   s    r    r2   "PassportData.decrypted_credentialsy   s     ...r+   )r   r   r   r   r.   )r#   r   )__name__
__module____qualname____firstlineno____doc__	__slots__r   r   r   r   r
   r   classmethodr(   propertyr   r8   r2   __static_attributes____classcell__)r   s   @r    r   r   !   s    > ;I *./0 *
 X& " >B3H%3,4UO3	.	!3 3 $&>&C D $ $* 
/ 
/r+   r   N)r@   collections.abcr   typingr   r   telegram._passport.credentialsr   +telegram._passport.encryptedpassportelementr   telegram._telegramobjectr   telegram._utils.argumentparsingr	   telegram._utils.typesr
   telegramr   r   r    r+   r    <module>rO      s4   & Y $ * ? P 3 > *)c/> c/r+   