§
    ¬eîi„  ã                   óŽ   — d Z ddlmZ ddlmZ ddlmZ ddlmZ ddl	m
Z
 ddlmZ ddlmZmZ erdd	lmZ  G d
„ de¦  «        ZdS )zKThis module contains an object that represents a Telegram PreCheckoutQuery.é    )ÚTYPE_CHECKING)Ú	OrderInfo)ÚTelegramObject)ÚUser)Úde_json_optional)ÚDEFAULT_NONE)ÚJSONDictÚODVInput)ÚBotc                   ó  ‡ — e Zd ZdZdZ	 	 dddœdedededed	ed
edz  dedz  de	dz  fˆ fd„Z
edde	dddd fˆ fd„¦   «         Z	 deeeeddœdededz  dee         dee         dee         dee         de	dz  defd„Zˆ xZS )ÚPreCheckoutQueryaù  This object contains information about an incoming pre-checkout query.

    Objects of this class are comparable in terms of equality. Two objects of this class are
    considered equal, if their :attr:`id` is equal.

    Note:
        In Python :keyword:`from` is a reserved word. Use :paramref:`from_user` instead.

    Args:
        id (:obj:`str`): Unique query identifier.
        from_user (:class:`telegram.User`): User who sent the query.
        currency (:obj:`str`): Three-letter ISO 4217 currency code, or ``XTR`` for payments in
            |tg_stars|.
        total_amount (:obj:`int`): Total price in the smallest units of the currency (integer,
            **not** float/double). For example, for a price of ``US$ 1.45`` pass ``amount = 145``.
            See the ``exp`` parameter in
            `currencies.json <https://core.telegram.org/bots/payments/currencies.json>`_,
            it shows the number of digits past the decimal point for each currency
            (2 for the majority of currencies).
        invoice_payload (:obj:`str`): Bot-specified invoice payload.
        shipping_option_id (:obj:`str`, optional): Identifier of the shipping option chosen by the
            user.
        order_info (:class:`telegram.OrderInfo`, optional): Order info provided by the user.

    Attributes:
        id (:obj:`str`): Unique query identifier.
        from_user (:class:`telegram.User`): User who sent the query.
        currency (:obj:`str`): Three-letter ISO 4217 currency code, or ``XTR`` for payments in
            |tg_stars|.
        total_amount (:obj:`int`): Total price in the smallest units of the currency (integer,
            **not** float/double). For example, for a price of ``US$ 1.45`` pass ``amount = 145``.
            See the ``exp`` parameter in
            `currencies.json <https://core.telegram.org/bots/payments/currencies.json>`_,
            it shows the number of digits past the decimal point for each currency
            (2 for the majority of currencies).
        invoice_payload (:obj:`str`): Bot-specified invoice payload.
        shipping_option_id (:obj:`str`): Optional. Identifier of the shipping option chosen by the
            user.
        order_info (:class:`telegram.OrderInfo`): Optional. Order info provided by the user.


    )ÚcurrencyÚ	from_userÚidÚinvoice_payloadÚ
order_infoÚshipping_option_idÚtotal_amountN©Ú
api_kwargsr   r   r   r   r   r   r   r   c                óð   •— t          ¦   «                              |¬¦  «         || _        || _        || _        || _        || _        || _        || _        | j        f| _	        |  
                    ¦   «          d S )Nr   )ÚsuperÚ__init__r   r   r   r   r   r   r   Ú	_id_attrsÚ_freeze)
Úselfr   r   r   r   r   r   r   r   Ú	__class__s
            €úf/home/div/.hermes/hermes-agent/venv/lib/python3.11/site-packages/telegram/_payment/precheckoutquery.pyr   zPreCheckoutQuery.__init__X   sp   ø€ õ 	‰Œ×Ò JÐÑ/Ô/Ð/ØˆŒØ(ˆŒØ%ˆŒØ!-ˆÔØ$3ˆÔØ.@ˆÔØ,6ˆŒàœ'˜ˆŒà�Š‰Œˆˆˆó    ÚdataÚbotz
Bot | NoneÚreturnc                 ó&  •— |                       |¦  «        }t          |                     dd¦  «        t          |¦  «        |d<   t          |                     d¦  «        t
          |¦  «        |d<   t          ¦   «                              ||¬¦  «        S )z,See :meth:`telegram.TelegramObject.de_json`.ÚfromNr   r   )r    r!   )Ú_parse_datar   Úpopr   Úgetr   r   Úde_json)Úclsr    r!   r   s      €r   r(   zPreCheckoutQuery.de_jsonq   sw   ø€ ð �Š˜tÑ$Ô$ˆå,¨T¯XªX°f¸dÑ-CÔ-CÅTÈ3ÑOÔOˆˆ[ÑÝ-¨d¯hªh°|Ñ.DÔ.DÅiÐQTÑUÔUˆˆ\Ñå‰wŒw�Š D¨cˆÑ2Ô2Ð2r   )Úread_timeoutÚwrite_timeoutÚconnect_timeoutÚpool_timeoutr   ÚokÚerror_messager*   r+   r,   r-   c          
   ƒ   óz   K  — |                       ¦   «                              | j        |||||||¬¦  «        ƒ d{V —†S )zíShortcut for::

             await bot.answer_pre_checkout_query(update.pre_checkout_query.id, *args, **kwargs)

        For the documentation of the arguments, please see
        :meth:`telegram.Bot.answer_pre_checkout_query`.

        )Úpre_checkout_query_idr.   r/   r*   r+   r,   r-   r   N)Úget_botÚanswer_pre_checkout_queryr   )r   r.   r/   r*   r+   r,   r-   r   s           r   ÚanswerzPreCheckoutQuery.answer{   se   è è € ð& —\’\‘^”^×=Ò=Ø"&¤'ØØ'Ø%Ø'Ø+Ø%Ø!ð >ñ 	
ô 	
ð 	
ð 	
ð 	
ð 	
ð 	
ð 	
ð 		
r   )NN)N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ú	__slots__Ústrr   Úintr   r	   r   Úclassmethodr(   r   Úboolr
   Úfloatr4   Ú__classcell__)r   s   @r   r   r   "   sª  ø€ € € € € ð)ð )ðV€Ið" *.Ø'+ðð '+ðð ð àðð ðð ð	ð
 ðð ðð   $™Jðð  Ñ$ðð ˜t‘Oðð ð ð ð ð ð2 ð3ð 3˜8ð 3¨,ð 3ÐBTð 3ð 3ð 3ð 3ð 3ñ „[ð3ð %)ð
ð
 )5Ø)5Ø+7Ø(4Ø&*ð
ð 
ð 
àð
ð ˜T‘zð
ð
 ˜u”oð
ð   ”ð
ð " %œð
ð ˜u”oð
ð ˜t‘Oð
ð 
ð
ð 
ð 
ð 
ð 
ð 
ð 
ð 
r   r   N)r8   Útypingr   Útelegram._payment.orderinfor   Útelegram._telegramobjectr   Útelegram._userr   Útelegram._utils.argumentparsingr   Útelegram._utils.defaultvaluer   Útelegram._utils.typesr	   r
   Útelegramr   r   © r   r   ú<module>rI      sê   ðð& RÐ Qà  Ð  Ð  Ð  Ð  Ð  à 1Ð 1Ð 1Ð 1Ð 1Ð 1Ø 3Ð 3Ð 3Ð 3Ð 3Ð 3Ø Ð Ð Ð Ð Ð Ø <Ð <Ð <Ð <Ð <Ð <Ø 5Ð 5Ð 5Ð 5Ð 5Ð 5Ø 4Ð 4Ð 4Ð 4Ð 4Ð 4Ð 4Ð 4àð ØÐÐÐÐÐðu
ð u
ð u
ð u
ð u
�~ñ u
ô u
ð u
ð u
ð u
r   