
    _jM                       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  SSKJrJrJrJrJr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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+  SSK,J-r-J.r.  SSK/J0r0J1r1J2r2  SSK3J4r4  SSK5J6r6  SSK7J8r8  SS/r9 " 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)     )annotations)LiteralN   )_legacy_response   )Roles
AsyncRolesRolesWithRawResponseAsyncRolesWithRawResponseRolesWithStreamingResponseAsyncRolesWithStreamingResponse)Users
AsyncUsersUsersWithRawResponseAsyncUsersWithRawResponseUsersWithStreamingResponseAsyncUsersWithStreamingResponse)BodyOmitQueryHeadersNotGivenomit	not_given)path_templatemaybe_transformasync_maybe_transform)cached_property)SyncAPIResourceAsyncAPIResource)to_streamed_response_wrapper"async_to_streamed_response_wrapper)SyncNextCursorPageAsyncNextCursorPage)AsyncPaginatormake_request_options)group_list_paramsgroup_create_paramsgroup_update_params)Group)GroupDeleteResponse)GroupUpdateResponseGroupsAsyncGroupsc                  .   \ rS rSr\SS j5       r\SS j5       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SS\	S.           SS jjrSrg)r-   )   c                ,    [        U R                  5      $ N)r   _clientselfs    f/home/rurouni/.local/lib/python3.13/site-packages/openai/resources/admin/organization/groups/groups.pyusersGroups.users*       T\\""    c                ,    [        U R                  5      $ r2   )r   r3   r4   s    r6   rolesGroups.roles.   r9   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
)GroupsWithRawResponser4   s    r6   with_raw_responseGroups.with_raw_response2   s     %T**r:   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
)GroupsWithStreamingResponser4   s    r6   with_streaming_responseGroups.with_streaming_response<   s     +400r:   Nextra_headersextra_query
extra_bodytimeoutc               |    U R                  S[        SU0[        R                  5      [	        UUUUSS0S9[
        S9$ )P  
Creates a new group in the organization.

Args:
  name: Human readable name for the group.

  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
/organization/groupsnameadmin_api_key_authTrI   rJ   rK   rL   securitybodyoptionscast_to)_postr   r(   GroupCreateParamsr&   r*   r5   rP   rI   rJ   rK   rL   s         r6   createGroups.createE   sS    2 zz" &$1D1V1VW(+'%.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9$ )	C  
Updates a group's information.

Args:
  name: New display name for the group.

  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
7Expected a non-empty value for `group_id` but received /organization/groups/{group_id}group_idrP   rQ   TrR   rT   )
ValueErrorrX   r   r   r)   GroupUpdateParamsr&   r,   r5   rb   rP   rI   rJ   rK   rL   s          r6   updateGroups.updatek   ss    4 VW_Vbcddzz;hO &$1D1V1VW(+'%.5 (  
 	
r:   afterlimitorderrI   rJ   rK   rL   c                   U R                  S[        [           [        UUUU[	        UUUS.[
        R                  5      SS0S9[        S9$ a  
Lists all groups in the organization.

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

  limit: A limit on the number of groups to be returned. Limit can range between 0 and
      1000, and the default is 100.

  order: Specifies the sort order of the returned groups.

  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
rO   )ri   rj   rk   rQ   T)rI   rJ   rK   rL   queryrS   )pagerV   model)_get_api_listr#   r*   r&   r   r'   GroupListParamsr5   ri   rj   rk   rI   rJ   rK   rL   s           r6   listGroups.list   sl    F !!"#E*(+'%%!&!&!&
 &55 /5 % " 
 	
r:   c                   U(       d  [        SU< 35      eU R                  [        SUS9[        UUUUSS0S9[        S9$ )"  
Deletes a group from the organization.

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_   r`   ra   rQ   TrR   rV   rW   rc   _deleter   r&   r+   r5   rb   rI   rJ   rK   rL   s         r6   deleteGroups.delete   s^    . VW_Vbcdd||;hO(+'%.5 (  

 
	
r:    )returnr   )r   r   )r   r@   )r   rE   rP   strrI   Headers | NonerJ   Query | NonerK   Body | NonerL   'float | httpx.Timeout | None | NotGivenr   r*   rb   r   rP   r   rI   r   rJ   r   rK   r   rL   r   r   r,   )ri   
str | Omitrj   
int | Omitrk   Literal['asc', 'desc'] | OmitrI   r   rJ   r   rK   r   rL   r   r   zSyncNextCursorPage[Group]rb   r   rI   r   rJ   r   rK   r   rL   r   r   r+   __name__
__module____qualname____firstlineno__r   r7   r<   rA   rF   r   r[   rf   r   rt   r|   __static_attributes__r~   r:   r6   r-   r-   )   s   # # # # + + 1 1 )-$("&;D$
 $
 &$
 "$
  $
 9$
 
$
Z )-$("&;D'
'
 	'
 &'
 "'
  '
 9'
 
'
X ! /3 )-$("&;D6
 6
 	6

 -6
 &6
 "6
  6
 96
 
#6
| )-$("&;D#
#
 &#
 "#
  #
 9#
 
#
 #
r:   c                  .   \ rS rSr\SS j5       r\SS j5       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SS\	S.           SS jjrSrg)r.      c                ,    [        U R                  5      $ r2   )r   r3   r4   s    r6   r7   AsyncGroups.users       $,,''r:   c                ,    [        U R                  5      $ r2   )r	   r3   r4   s    r6   r<   AsyncGroups.roles   r   r:   c                    [        U 5      $ r?   )AsyncGroupsWithRawResponser4   s    r6   rA   AsyncGroups.with_raw_response   s     *$//r:   c                    [        U 5      $ rD   ) AsyncGroupsWithStreamingResponser4   s    r6   rF   #AsyncGroups.with_streaming_response  s     055r:   NrH   c                  #    U R                  S[        SU0[        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)rN   rO   rP   NrQ   TrR   rT   )rX   r   r(   rY   r&   r*   rZ   s         r6   r[   AsyncGroups.create  sf     2 ZZ",fd^=P=b=bcc(+'%.5    
 
 	
c
s!   ,AA
AAAAc                  #    U(       d  [        SU< 35      eU R                  [        SUS9[        SU0[        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)
r^   r_   r`   ra   rP   NrQ   TrR   rT   )rc   rX   r   r   r)   rd   r&   r,   re   s          r6   rf   AsyncGroups.update4  s     4 VW_VbcddZZ;hO,fd^=P=b=bcc(+'%.5 (   
 
 	
c
s$   A
A2A.
A2)A0*A20A2rh   c                   U R                  S[        [           [        UUUU[	        UUUS.[
        R                  5      SS0S9[        S9$ rm   )rq   r$   r*   r&   r   r'   rr   rs   s           r6   rt   AsyncGroups.list]  sl    F !!"$U+(+'%%!&!&!&
 &55 /5 % " 
 	
r:   c                  #    U(       d  [        SU< 35      eU R                  [        SUS9[        UUUUSS0S9[        S9I Sh  vN $  N7f)	rw   r_   r`   ra   rQ   TrR   rx   Nry   r{   s         r6   r|   AsyncGroups.delete  sk     . VW_Vbcdd\\;hO(+'%.5 ( " 

 

 
	
 

s   AAAAr~   )r   r   )r   r	   )r   r   )r   r   r   r   )ri   r   rj   r   rk   r   rI   r   rJ   r   rK   r   rL   r   r   z1AsyncPaginator[Group, AsyncNextCursorPage[Group]]r   r   r~   r:   r6   r.   r.      s   ( ( ( ( 0 0 6 6 )-$("&;D$
 $
 &$
 "$
  $
 9$
 
$
Z )-$("&;D'
'
 	'
 &'
 "'
  '
 9'
 
'
X ! /3 )-$("&;D6
 6
 	6

 -6
 &6
 "6
  6
 96
 
;6
| )-$("&;D#
#
 &#
 "#
  #
 9#
 
#
 #
r:   c                  F    \ rS rSrSS jr\SS j5       r\S	S j5       rSrg)
r@   i  c                8   Xl         [        R                  " UR                  5      U l        [        R                  " UR                  5      U l        [        R                  " UR
                  5      U l        [        R                  " UR                  5      U l        g r2   )_groupsr   to_raw_response_wrapperr[   rf   rt   r|   r5   groupss     r6   __init__GroupsWithRawResponse.__init__  sq    &>>MM
 '>>MM
 %<<KK
	 '>>MM
r:   c                @    [        U R                  R                  5      $ r2   )r   r   r7   r4   s    r6   r7   GroupsWithRawResponse.users      #DLL$6$677r:   c                @    [        U R                  R                  5      $ r2   )r
   r   r<   r4   s    r6   r<   GroupsWithRawResponse.roles  r   r:   r   r[   r|   rt   rf   Nr   r-   r   None)r   r   )r   r
   	r   r   r   r   r   r   r7   r<   r   r~   r:   r6   r@   r@     s/    
  8 8 8 8r:   r@   c                  F    \ rS rSrSS jr\SS j5       r\S	S j5       rSrg)
r   i  c                8   Xl         [        R                  " UR                  5      U l        [        R                  " UR                  5      U l        [        R                  " UR
                  5      U l        [        R                  " UR                  5      U l        g r2   )r   r   async_to_raw_response_wrapperr[   rf   rt   r|   r   s     r6   r   #AsyncGroupsWithRawResponse.__init__  sq    &DDMM
 'DDMM
 %BBKK
	 'DDMM
r:   c                @    [        U R                  R                  5      $ r2   )r   r   r7   r4   s    r6   r7    AsyncGroupsWithRawResponse.users      (););<<r:   c                @    [        U R                  R                  5      $ r2   )r   r   r<   r4   s    r6   r<    AsyncGroupsWithRawResponse.roles  r   r:   r   Nr   r.   r   r   )r   r   )r   r   r   r~   r:   r6   r   r     s/    
  = = = =r:   r   c                  F    \ rS rSrSS jr\SS j5       r\S	S j5       rSrg)
rE   i  c                    Xl         [        UR                  5      U l        [        UR                  5      U l        [        UR                  5      U l        [        UR
                  5      U l        g r2   )r   r!   r[   rf   rt   r|   r   s     r6   r   $GroupsWithStreamingResponse.__init__  sY    2MM
 3MM
 1KK
	 3MM
r:   c                @    [        U R                  R                  5      $ r2   )r   r   r7   r4   s    r6   r7   !GroupsWithStreamingResponse.users       )$,,*<*<==r:   c                @    [        U R                  R                  5      $ r2   )r   r   r<   r4   s    r6   r<   !GroupsWithStreamingResponse.roles  r   r:   r   Nr   )r   r   )r   r   r   r~   r:   r6   rE   rE     s/    
  > > > >r:   rE   c                  F    \ rS rSrSS jr\SS j5       r\S	S j5       rSrg)
r   i	  c                    Xl         [        UR                  5      U l        [        UR                  5      U l        [        UR                  5      U l        [        UR
                  5      U l        g r2   )r   r"   r[   rf   rt   r|   r   s     r6   r   )AsyncGroupsWithStreamingResponse.__init__
  sY    8MM
 9MM
 7KK
	 9MM
r:   c                @    [        U R                  R                  5      $ r2   )r   r   r7   r4   s    r6   r7   &AsyncGroupsWithStreamingResponse.users      .t||/A/ABBr:   c                @    [        U R                  R                  5      $ r2   )r   r   r<   r4   s    r6   r<   &AsyncGroupsWithStreamingResponse.roles  r   r:   r   Nr   )r   r   )r   r   r   r~   r:   r6   r   r   	  s3    
  C C C Cr:   r   )@
__future__r   typing_extensionsr   httpx r   r<   r   r	   r
   r   r   r   r7   r   r   r   r   r   r   _typesr   r   r   r   r   r   r   _utilsr   r   r   _compatr   	_resourcer   r    	_responser!   r"   
paginationr#   r$   _base_clientr%   r&   types.admin.organizationr'   r(   r)   types.admin.organization.groupr*   .types.admin.organization.group_delete_responser+   .types.admin.organization.group_update_responser,   __all__r-   r.   r@   r   rE   r   r~   r:   r6   <module>r      s    # %  "   N M M M M ( < [ C B e e 5 S S]
#F
_ F
RF
" F
R8 84= =4> >4C Cr:   