
    N[iX                     H    d dl mZmZ d dlZd dlmZ d dlmZ  G d d      Zy)    )ListUnionN)raw)typesc                   0    e Zd Zdddeeef   ded   fdZy)GetSendAsChatsselfzpyrogram.Clientchat_idreturnz
types.Chatc                   K   | j                  t        j                  j                  j	                  | j                  |       d{                d{   }|j                  D ci c]  }|j                  | }}|j                  D ci c]  }|j                  | }}t        j                         }|j                  D ]  }t        |t        j                  j                        r=|j                  t        j                  j!                  | ||j"                                  d|j                  t        j                  j!                  | ||j$                                   |S 7 "7 c c}w c c}w w)a  Get the list of "send_as" chats available.

        .. include:: /_includes/usable-by/users.rst

        Parameters:
            chat_id (``int`` | ``str``):
                Unique identifier (int) or username (str) of the target chat.

        Returns:
            List[:obj:`~pyrogram.types.Chat`]: The list of chats.

        Example:
            .. code-block:: python

                chats = await app.get_send_as_chats(chat_id)
                print(chats)
        N)peer)invoker   	functionschannels	GetSendAsresolve_peerusersidchatsr   r   peers
isinstancePeerUserappendChat_parse_chatuser_id
channel_id)	r	   r
   rur   cr   send_as_chatsps	            [/var/www/files/kim/lib/python3.12/site-packages/pyrogram/methods/chats/get_send_as_chats.pyget_send_as_chatsz GetSendAsChats.get_send_as_chats   s(    * ++MM"",,,,W55 - 
 
 #$''*Qq**"#''*Qq**

 	XA!SYY//0$$UZZ%;%;D%		BR%ST$$UZZ%;%;D%BU%VW		X  6
 +*sC   AE7E'E7E*E7)E-=E7E2!CE7*E7-
E7N)__name__
__module____qualname__r   intstrr   r$        r#   r   r      s.    &&sCx& 
l	&r+   r   )typingr   r   pyrogramr   r   r   r*   r+   r#   <module>r.      s   &    ' 'r+   