
    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)VoiceSamplePreviewResponseModel   )AsyncRawAudioClientRawAudioClientc                       e Zd ZdefdZedefd       Zddddeded	e	j                  e   d
e	j                  e   def
dZy)AudioClientclient_wrapperc                &    t        |      | _        y N)r   )r
   _raw_clientselfr   s     u/root/.openclaw/workspace/visionaryfx/venv/lib/python3.12/site-packages/elevenlabs/voices/pvc/samples/audio/client.py__init__zAudioClient.__init__   s    )H    returnc                     | j                   S )z
        Retrieves a raw implementation of this client that returns raw responses.

        Returns
        -------
        RawAudioClient
        r   r   s    r   with_raw_responsezAudioClient.with_raw_response        r   Nremove_background_noiserequest_optionsvoice_id	sample_idr   r   c                X    | j                   j                  ||||      }|j                  S )a_  
        Retrieve the first 30 seconds of voice sample audio with or without noise removal.

        Parameters
        ----------
        voice_id : str
            Voice ID to be used, you can use https://api.elevenlabs.io/v1/voices to list all the available voices.

        sample_id : str
            Sample ID to be used

        remove_background_noise : typing.Optional[bool]
            If set will remove background noise for voice samples using our audio isolation model. If the samples do not include background noise, it can make the quality worse.

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

        Returns
        -------
        VoiceSamplePreviewResponseModel
            Successful Response

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

        client = ElevenLabs(
            api_key="YOUR_API_KEY",
        )
        client.voices.pvc.samples.audio.get(
            voice_id="21m00Tcm4TlvDq8ikWAM",
            sample_id="VW7YKqPnjY4h39yTbx2L",
            remove_background_noise=True,
        )
        r   r   getdatar   r   r    r   r   	_responses         r   r#   zAudioClient.get   s7    V $$((i9Pbq ) 
	 ~~r   )__name__
__module____qualname__r   r   propertyr
   r   strtypingOptionalboolr   r   r#    r   r   r   r      s{    I*; I  >     :>;?.. .
 "(!6.  8. 
).r   r   c                       e Zd ZdefdZedefd       Zddddeded	e	j                  e   d
e	j                  e   def
dZy)AsyncAudioClientr   c                &    t        |      | _        y r   )r	   r   r   s     r   r   zAsyncAudioClient.__init__L   s    .nMr   r   c                     | j                   S )z
        Retrieves a raw implementation of this client that returns raw responses.

        Returns
        -------
        AsyncRawAudioClient
        r   r   s    r   r   z"AsyncAudioClient.with_raw_responseO   r   r   Nr   r   r    r   r   c                t   K   | j                   j                  ||||       d{   }|j                  S 7 w)a  
        Retrieve the first 30 seconds of voice sample audio with or without noise removal.

        Parameters
        ----------
        voice_id : str
            Voice ID to be used, you can use https://api.elevenlabs.io/v1/voices to list all the available voices.

        sample_id : str
            Sample ID to be used

        remove_background_noise : typing.Optional[bool]
            If set will remove background noise for voice samples using our audio isolation model. If the samples do not include background noise, it can make the quality worse.

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

        Returns
        -------
        VoiceSamplePreviewResponseModel
            Successful Response

        Examples
        --------
        import asyncio

        from elevenlabs import AsyncElevenLabs

        client = AsyncElevenLabs(
            api_key="YOUR_API_KEY",
        )


        async def main() -> None:
            await client.voices.pvc.samples.audio.get(
                voice_id="21m00Tcm4TlvDq8ikWAM",
                sample_id="VW7YKqPnjY4h39yTbx2L",
                remove_background_noise=True,
            )


        asyncio.run(main())
        r   Nr"   r%   s         r   r#   zAsyncAudioClient.getZ   sE     f **..i9Pbq / 
 
	 ~~
s   #868)r'   r(   r)   r   r   r*   r	   r   r+   r,   r-   r.   r   r   r#   r/   r   r   r1   r1   K   s|    N*< N  #6     :>;?66 6
 "(!66  86 
)6r   r1   )r,   core.client_wrapperr   r   core.request_optionsr   )types.voice_sample_preview_response_modelr   
raw_clientr	   r
   r   r1   r/   r   r   <module>r9      s-     J 4 Z ;= =@E Er   