
    _jE                    x   S SK Jr  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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JrJrJr  SSK J!r!J"r"  SSK#J$r$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      r0 " S S5      r1 " S S5      r2 " S S5      r3g)    )annotations)LiteralN   )_legacy_response)BodyOmitQueryHeadersNotGivenSequenceNotStromit	not_given)path_templatemaybe_transform)cached_property)SyncAPIResourceAsyncAPIResource)to_streamed_response_wrapper"async_to_streamed_response_wrapper)SyncPage	AsyncPageSyncConversationCursorPageAsyncConversationCursorPage)AsyncPaginatormake_request_options)certificate_list_paramscertificate_activate_paramscertificate_deactivate_params)CertificateListResponse)CertificateActivateResponse)CertificateDeactivateResponseCertificatesAsyncCertificatesc                      \ 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SS\S.             SS jj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
)CertificatesWithRawResponseselfs    n/home/rurouni/.local/lib/python3.13/site-packages/openai/resources/admin/organization/projects/certificates.pywith_raw_responseCertificates.with_raw_response   s     +400    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
)!CertificatesWithStreamingResponser)   s    r+   with_streaming_response$Certificates.with_streaming_response(   s     166r.   Nafterlimitorderextra_headersextra_query
extra_bodytimeoutc                   U(       d  [        SU< 35      eU R                  [        SUS9[        [           [        UUUU[        UUUS.[        R                  5      SS0S9[        S9$ 	aJ  
List certificates for this project.

Args:
  after: A cursor for use in pagination. `after` is an object ID that defines your place
      in the list. For instance, if you make a list request and receive 100 objects,
      ending with obj_foo, your subsequent call can include after=obj_foo in order to
      fetch the next page of the list.

  limit: A limit on the number of objects to be returned. Limit can range between 1 and
      100, and the default is 20.

  order: Sort order by the `created_at` timestamp of the objects. `asc` for ascending
      order and `desc` for descending order.

  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
9Expected a non-empty value for `project_id` but received z0/organization/projects/{project_id}/certificates
project_id)r5   r6   r7   admin_api_key_authT)r8   r9   r:   r;   querysecurity)pageoptionsmodel)	
ValueError_get_api_listr   r   r   r   r   r   CertificateListParams	r*   r@   r5   r6   r7   r8   r9   r:   r;   s	            r+   listCertificates.list1   s    J XYcXfghh!!LYcd+,CD(+'%%!&!&!&
 ,AA /5 *% " 
 	
r.   r8   r9   r:   r;   c                   U(       d  [        SU< 35      eU R                  [        SUS9[        [           [        SU0[        R                  5      [        UUUUSS0S9[        SS	9$ 
av  
Activate certificates at the project level.

You can atomically and idempotently activate up to 10 certificates at a time.

Args:
  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
r>   z9/organization/projects/{project_id}/certificates/activater?   certificate_idsrA   Tr8   r9   r:   r;   rC   postrD   bodyrE   rF   method)	rG   rH   r   r   r    r   r   CertificateActivateParamsr   r*   r@   rP   r8   r9   r:   r;   s          r+   activateCertificates.activatem   s    4 XYcXfghh!!Ublm56 "O46Q6k6k )+'%.5 . " 
 	
r.   c                   U(       d  [        SU< 35      eU R                  [        SUS9[        [           [        SU0[        R                  5      [        UUUUSS0S9[        SS	9$ 
ay  Deactivate certificates at the project level.

You can atomically and
idempotently deactivate up to 10 certificates at a time.

Args:
  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
r>   z;/organization/projects/{project_id}/certificates/deactivater?   rP   rA   TrQ   rR   rS   )	rG   rH   r   r   r!   r   r   CertificateDeactivateParamsr   rW   s          r+   
deactivateCertificates.deactivate   s    4 XYcXfghh!!Wdno78 "O46S6o6o )+'%.5 0 " 
 	
r.    )returnr(   )r`   r1   )r@   strr5   
str | Omitr6   
int | Omitr7   Literal['asc', 'desc'] | Omitr8   Headers | Noner9   Query | Noner:   Body | Noner;   'float | httpx.Timeout | None | NotGivenr`   z3SyncConversationCursorPage[CertificateListResponse])r@   ra   rP   SequenceNotStr[str]r8   re   r9   rf   r:   rg   r;   rh   r`   z%SyncPage[CertificateActivateResponse])r@   ra   rP   ri   r8   re   r9   rf   r:   rg   r;   rh   r`   z'SyncPage[CertificateDeactivateResponse]__name__
__module____qualname____firstlineno__r   r,   r2   r   r   rK   rX   r]   __static_attributes__r_   r.   r+   r"   r"      sS   1 1 7 7 ! /3 )-$("&;D:
:
 	:

 :
 -:
 &:
 ":
  :
 9:
 
=:
F )-$("&;D+
+
 -	+
 &+
 "+
  +
 9+
 
/+
h )-$("&;D+
+
 -	+
 &+
 "+
  +
 9+
 
1+
 +
r.   c                      \ 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SS\S.             SS jjr
SSS\S.             SS	 jjrS
rg)r#      c                    [        U 5      $ r'   ) AsyncCertificatesWithRawResponser)   s    r+   r,   #AsyncCertificates.with_raw_response   s     055r.   c                    [        U 5      $ r0   )&AsyncCertificatesWithStreamingResponser)   s    r+   r2   )AsyncCertificates.with_streaming_response   s     6d;;r.   Nr4   c                   U(       d  [        SU< 35      eU R                  [        SUS9[        [           [        UUUU[        UUUS.[        R                  5      SS0S9[        S9$ r=   )	rG   rH   r   r   r   r   r   r   rI   rJ   s	            r+   rK   AsyncCertificates.list   s    J XYcXfghh!!LYcd,-DE(+'%%!&!&!&
 ,AA /5 *% " 
 	
r.   rM   c                   U(       d  [        SU< 35      eU R                  [        SUS9[        [           [        SU0[        R                  5      [        UUUUSS0S9[        SS	9$ rO   )	rG   rH   r   r   r    r   r   rV   r   rW   s          r+   rX   AsyncCertificates.activate  s    4 XYcXfghh!!Ublm67 "O46Q6k6k )+'%.5 . " 
 	
r.   c                   U(       d  [        SU< 35      eU R                  [        SUS9[        [           [        SU0[        R                  5      [        UUUUSS0S9[        SS	9$ r[   )	rG   rH   r   r   r!   r   r   r\   r   rW   s          r+   r]   AsyncCertificates.deactivateE  s    4 XYcXfghh!!Wdno89 "O46S6o6o )+'%.5 0 " 
 	
r.   r_   )r`   rs   )r`   rv   )r@   ra   r5   rb   r6   rc   r7   rd   r8   re   r9   rf   r:   rg   r;   rh   r`   z]AsyncPaginator[CertificateListResponse, AsyncConversationCursorPage[CertificateListResponse]])r@   ra   rP   ri   r8   re   r9   rf   r:   rg   r;   rh   r`   zSAsyncPaginator[CertificateActivateResponse, AsyncPage[CertificateActivateResponse]])r@   ra   rP   ri   r8   re   r9   rf   r:   rg   r;   rh   r`   zWAsyncPaginator[CertificateDeactivateResponse, AsyncPage[CertificateDeactivateResponse]]rj   r_   r.   r+   r#   r#      sV   6 6 < < ! /3 )-$("&;D:
:
 	:

 :
 -:
 &:
 ":
  :
 9:
 
g:
F )-$("&;D+
+
 -	+
 &+
 "+
  +
 9+
 
]+
h )-$("&;D+
+
 -	+
 &+
 "+
  +
 9+
 
a+
 +
r.   c                      \ rS rSrSS jrSrg)r(   is  c                    Xl         [        R                  " UR                  5      U l        [        R                  " UR                  5      U l        [        R                  " UR
                  5      U l        g N)_certificatesr   to_raw_response_wrapperrK   rX   r]   r*   certificatess     r+   __init__$CertificatesWithRawResponse.__init__t  s]    )$<<
	 )@@!!
 +BB##
r.   r   rX   r]   rK   Nr   r"   r`   Nonerk   rl   rm   rn   r   ro   r_   r.   r+   r(   r(   s      
r.   r(   c                      \ rS rSrSS jrSrg)rs   i  c                    Xl         [        R                  " UR                  5      U l        [        R                  " UR                  5      U l        [        R                  " UR
                  5      U l        g r   )r   r   async_to_raw_response_wrapperrK   rX   r]   r   s     r+   r   )AsyncCertificatesWithRawResponse.__init__  s]    )$BB
	 )FF!!
 +HH##
r.   r   Nr   r#   r`   r   r   r_   r.   r+   rs   rs     r   r.   rs   c                      \ rS rSrSS jrSrg)r1   i  c                    Xl         [        UR                  5      U l        [        UR                  5      U l        [        UR                  5      U l        g r   )r   r   rK   rX   r]   r   s     r+   r   *CertificatesWithStreamingResponse.__init__  sK    )0
	 5!!
 7##
r.   r   Nr   r   r_   r.   r+   r1   r1     r   r.   r1   c                      \ rS rSrSS jrSrg)rv   i  c                    Xl         [        UR                  5      U l        [        UR                  5      U l        [        UR                  5      U l        g r   )r   r   rK   rX   r]   r   s     r+   r   /AsyncCertificatesWithStreamingResponse.__init__  sK    )6
	 ;!!
 =##
r.   r   Nr   r   r_   r.   r+   rv   rv     r   r.   rv   )4
__future__r   typing_extensionsr   httpx r   _typesr   r   r	   r
   r   r   r   r   _utilsr   r   _compatr   	_resourcer   r   	_responser   r   
paginationr   r   r   r   _base_clientr   r   !types.admin.organization.projectsr   r   r   ;types.admin.organization.projects.certificate_list_responser   ?types.admin.organization.projects.certificate_activate_responser    Atypes.admin.organization.projects.certificate_deactivate_responser!   __all__r"   r#   r(   rs   r1   rv   r_   r.   r+   <module>r      s    # %  " ] ] ] 6 ( < [ h h B 
 e l p.
/h
? h
Vh
( h
V
 

 

 

 
r.   