
    b6i                     l    d dl Z ddlmZmZ ddlmZ ddlmZ ddlm	Z	m
Z
  G d d	      Z G d
 d      Zy)    N   )AsyncClientWrapperSyncClientWrapper)RequestOptions)%GetConversationUsersPageResponseModel   )AsyncRawUsersClientRawUsersClientc                      e Zd ZdefdZedefd       Zdddddddddej                  e
   dej                  e   d	ej                  e   d
ej                  e
   dej                  e   dej                  e
   dej                  e   defdZy)UsersClientclient_wrapperc                &    t        |      | _        y N)r   )r
   _raw_clientselfr   s     t/root/.openclaw/workspace/visionaryfx/venv/lib/python3.12/site-packages/elevenlabs/conversational_ai/users/client.py__init__zUsersClient.__init__   s    )H    returnc                     | j                   S )z
        Retrieves a raw implementation of this client that returns raw responses.

        Returns
        -------
        RawUsersClient
        r   r   s    r   with_raw_responsezUsersClient.with_raw_response        r   Nagent_idcall_start_before_unixcall_start_after_unixsearch	page_sizecursorrequest_optionsr   r   r   r    r!   r"   r#   c          	      ^    | j                   j                  |||||||      }|j                  S )a  
        Get distinct users from conversations with pagination.

        Parameters
        ----------
        agent_id : typing.Optional[str]
            The id of the agent you're taking the action on.

        call_start_before_unix : typing.Optional[int]
            Unix timestamp (in seconds) to filter conversations up to this start date.

        call_start_after_unix : typing.Optional[int]
            Unix timestamp (in seconds) to filter conversations after to this start date.

        search : typing.Optional[str]
            Search/filter by user ID (exact match).

        page_size : typing.Optional[int]
            How many users to return at maximum. Defaults to 30.

        cursor : typing.Optional[str]
            Used for fetching next page. Cursor is returned in the response.

        request_options : typing.Optional[RequestOptions]
            Request-specific configuration.

        Returns
        -------
        GetConversationUsersPageResponseModel
            Successful Response

        Examples
        --------
        from elevenlabs import ElevenLabs

        client = ElevenLabs(
            api_key="YOUR_API_KEY",
        )
        client.conversational_ai.users.list(
            agent_id="agent_id",
            call_start_before_unix=1,
            call_start_after_unix=1,
            search="search",
            page_size=1,
            cursor="cursor",
        )
        r   r   listdata	r   r   r   r   r    r!   r"   r#   	_responses	            r   r&   zUsersClient.list   sA    t $$))#9"7+ * 
	 ~~r   )__name__
__module____qualname__r   r   propertyr
   r   typingOptionalstrintr   r   r&    r   r   r   r      s    I*; I  >     *.7;6:'+*.'+;?C //#&C !' 4	C
  &s3C $C ??3'C $C  8C 
/Cr   r   c                      e Zd ZdefdZedefd       Zdddddddddej                  e
   dej                  e   d	ej                  e   d
ej                  e
   dej                  e   dej                  e
   dej                  e   defdZy)AsyncUsersClientr   c                &    t        |      | _        y r   )r	   r   r   s     r   r   zAsyncUsersClient.__init__a   s    .nMr   r   c                     | j                   S )z
        Retrieves a raw implementation of this client that returns raw responses.

        Returns
        -------
        AsyncRawUsersClient
        r   r   s    r   r   z"AsyncUsersClient.with_raw_responsed   r   r   Nr   r   r   r   r    r!   r"   r#   c          	      z   K   | j                   j                  |||||||       d{   }|j                  S 7 w)a  
        Get distinct users from conversations with pagination.

        Parameters
        ----------
        agent_id : typing.Optional[str]
            The id of the agent you're taking the action on.

        call_start_before_unix : typing.Optional[int]
            Unix timestamp (in seconds) to filter conversations up to this start date.

        call_start_after_unix : typing.Optional[int]
            Unix timestamp (in seconds) to filter conversations after to this start date.

        search : typing.Optional[str]
            Search/filter by user ID (exact match).

        page_size : typing.Optional[int]
            How many users to return at maximum. Defaults to 30.

        cursor : typing.Optional[str]
            Used for fetching next page. Cursor is returned in the response.

        request_options : typing.Optional[RequestOptions]
            Request-specific configuration.

        Returns
        -------
        GetConversationUsersPageResponseModel
            Successful Response

        Examples
        --------
        import asyncio

        from elevenlabs import AsyncElevenLabs

        client = AsyncElevenLabs(
            api_key="YOUR_API_KEY",
        )


        async def main() -> None:
            await client.conversational_ai.users.list(
                agent_id="agent_id",
                call_start_before_unix=1,
                call_start_after_unix=1,
                search="search",
                page_size=1,
                cursor="cursor",
            )


        asyncio.run(main())
        r   Nr%   r(   s	            r   r&   zAsyncUsersClient.listo   sO     D **//#9"7+ 0 
 
	 ~~
s   &;9;)r*   r+   r,   r   r   r-   r	   r   r.   r/   r0   r1   r   r   r&   r2   r   r   r4   r4   `   s    N*< N  #6     *.7;6:'+*.'+;?K //#&K !' 4	K
  &s3K $K ??3'K $K  8K 
/Kr   r4   )r.   core.client_wrapperr   r   core.request_optionsr   0types.get_conversation_users_page_response_modelr   
raw_clientr	   r
   r   r4   r2   r   r   <module>r<      s/     H 2 e ;R RjZ Zr   