
    _j$                    ,   S SK Jr  S SKrSSKJr  SSKJrJrJrJ	r	J
r
JrJr  SSKJrJr  SSKJr  SSKJr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/r " S S\5      r " S S\5      r  " S S5      r! " S S5      r" " S S5      r# " S S5      r$g)    )annotationsN   )_legacy_response)BodyOmitQueryHeadersNotGivenomit	not_given)maybe_transformasync_maybe_transform)cached_property)SyncAPIResourceAsyncAPIResource)to_streamed_response_wrapper"async_to_streamed_response_wrapper)make_request_options)client_secret_create_params)ClientSecretCreateResponseClientSecretsAsyncClientSecretsc                  r    \ rS rSr\SS j5       r\S	S j5       r\\SSS\S.             S
S jjr	Sr
g)r      c                    [        U 5      $ z
This property can be used as a prefix for any HTTP method call to return
the raw response object instead of the parsed content.

For more information, see https://www.github.com/openai/openai-python#accessing-raw-response-data-eg-headers
)ClientSecretsWithRawResponseselfs    ]/home/rurouni/.local/lib/python3.13/site-packages/openai/resources/realtime/client_secrets.pywith_raw_responseClientSecrets.with_raw_response   s     ,D11    c                    [        U 5      $ z
An alternative to `.with_raw_response` that doesn't eagerly read the response body.

For more information, see https://www.github.com/openai/openai-python#with_streaming_response
)"ClientSecretsWithStreamingResponser   s    r    with_streaming_response%ClientSecrets.with_streaming_response   s     2$77r#   Nexpires_aftersessionextra_headersextra_query
extra_bodytimeoutc               ~    U R                  S[        UUS.[        R                  5      [	        UUUUSS0S9[
        S9$ )  
Create a Realtime client secret with an associated session configuration.

Client secrets are short-lived tokens that can be passed to a client app, such
as a web frontend or mobile client, which grants access to the Realtime API
without leaking your main API key. You can configure a custom TTL for each
client secret.

You can also attach session configuration options to the client secret, which
will be applied to any sessions created using that client secret, but these can
also be overridden by the client connection.

[Learn more about authentication with client secrets over WebRTC](https://platform.openai.com/docs/guides/realtime-webrtc).

Returns the created client secret and the effective session object. The client
secret is a string that looks like `ek_1234`.

Args:
  expires_after: Configuration for the client secret expiration. Expiration refers to the time
      after which a client secret will no longer be valid for creating sessions. The
      session itself may continue after that time once started. A secret can be used
      to create multiple sessions until it expires.

  session: Session configuration to use for the client secret. Choose either a realtime
      session or a transcription session.

  extra_headers: Send extra headers

  extra_query: Add additional query parameters to the request

  extra_body: Add additional JSON properties to the request

  timeout: Override the client-level default timeout for this request, in seconds
/realtime/client_secretsr*   r+   bearer_authTr,   r-   r.   r/   securitybodyoptionscast_to)_postr   r   ClientSecretCreateParamsr   r   r   r*   r+   r,   r-   r.   r/   s          r    createClientSecrets.create(   s_    \ zz& %2& ,DD )+'%'. /!  
 	
r#    )returnr   )rA   r&   r*   z/client_secret_create_params.ExpiresAfter | Omitr+   z*client_secret_create_params.Session | Omitr,   zHeaders | Noner-   zQuery | Noner.   zBody | Noner/   z'float | httpx.Timeout | None | NotGivenrA   r   __name__
__module____qualname____firstlineno__r   r!   r'   r   r   r>   __static_attributes__r@   r#   r    r   r      s    2 2 8 8 JN>B )-$("&;D?
 G?
 <	?
 &?
 "?
  ?
 9?
 
$?
 ?
r#   c                  r    \ rS rSr\SS j5       r\S	S j5       r\\SSS\S.             S
S jjr	Sr
g)r   j   c                    [        U 5      $ r   )!AsyncClientSecretsWithRawResponser   s    r    r!   $AsyncClientSecrets.with_raw_responsek   s     166r#   c                    [        U 5      $ r%   )'AsyncClientSecretsWithStreamingResponser   s    r    r'   *AsyncClientSecrets.with_streaming_responseu   s     7t<<r#   Nr)   c                  #    U R                  S[        UUS.[        R                  5      I Sh  vN [	        UUUUSS0S9[
        S9I Sh  vN $  N! N7f)r1   r2   r3   Nr4   Tr5   r7   )r;   r   r   r<   r   r   r=   s          r    r>   AsyncClientSecrets.create~   sv     \ ZZ&,%2& ,DD  )+'%'. /!   
 
 	

s!   -AA
AAAAr@   )rA   rL   )rA   rO   rB   rC   r@   r#   r    r   r   j   s    7 7 = = JN>B )-$("&;D?
 G?
 <	?
 &?
 "?
  ?
 9?
 
$?
 ?
r#   c                      \ rS rSrSS jrSrg)r      c                Z    Xl         [        R                  " UR                  5      U l        g N)_client_secretsr   to_raw_response_wrapperr>   r   client_secretss     r    __init__%ClientSecretsWithRawResponse.__init__   s#    -&>>!!
r#   rW   r>   NrZ   r   rA   NonerD   rE   rF   rG   r[   rH   r@   r#   r    r   r          
r#   r   c                      \ rS rSrSS jrSrg)rL      c                Z    Xl         [        R                  " UR                  5      U l        g rV   )rW   r   async_to_raw_response_wrapperr>   rY   s     r    r[   *AsyncClientSecretsWithRawResponse.__init__   s#    -&DD!!
r#   r]   NrZ   r   rA   r_   r`   r@   r#   r    rL   rL      ra   r#   rL   c                      \ rS rSrSS jrSrg)r&      c                D    Xl         [        UR                  5      U l        g rV   )rW   r   r>   rY   s     r    r[   +ClientSecretsWithStreamingResponse.__init__   s    -2!!
r#   r]   Nr^   r`   r@   r#   r    r&   r&      ra   r#   r&   c                      \ rS rSrSS jrSrg)rO      c                D    Xl         [        UR                  5      U l        g rV   )rW   r   r>   rY   s     r    r[   0AsyncClientSecretsWithStreamingResponse.__init__   s    -8!!
r#   r]   Nrg   r`   r@   r#   r    rO   rO      ra   r#   rO   )%
__future__r   httpx r   _typesr   r   r   r	   r
   r   r   _utilsr   r   _compatr   	_resourcer   r   	_responser   r   _base_clientr   types.realtimer   ,types.realtime.client_secret_create_responser   __all__r   r   r   rL   r&   rO   r@   r#   r    <module>r|      s    #    K K K < & : Y 0 9 V0
1S
O S
lS
) S
l
 

 

 

 
r#   