
    _j<                    l   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  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!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      r0g)    )annotations)LiteralN   )_legacy_response)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)role_list_paramsrole_create_params)RoleListResponse)RoleCreateResponse)RoleDeleteResponseRoles
AsyncRolesc                      \ 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
)RolesWithRawResponseselfs    e/home/rurouni/.local/lib/python3.13/site-packages/openai/resources/admin/organization/groups/roles.pywith_raw_responseRoles.with_raw_response   s     $D))    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
)RolesWithStreamingResponser&   s    r(   with_streaming_responseRoles.with_streaming_response$   s     *$//r+   Nextra_headersextra_query
extra_bodytimeoutc                   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$ )	j  
Assigns an organization role to a group within the organization.

Args:
  role_id: Identifier of the role to assign.

  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}/rolesgroup_idrole_idadmin_api_key_authTr2   r3   r4   r5   securitybodyoptionscast_to)
ValueError_postr   r   r   RoleCreateParamsr   r   r'   r;   r<   r2   r3   r4   r5   s          r(   createRoles.create-   st    4 VW_VbcddzzAHU )W!57I7Z7Z[(+'%.5 '  
 	
r+   afterlimitorderr2   r3   r4   r5   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$ 	aV  
Lists the organization roles assigned to a group within the organization.

Args:
  after: Cursor for pagination. Provide the value from the previous response's `next`
      field to continue listing organization roles.

  limit: A limit on the number of organization role assignments to return.

  order: Sort order for the returned organization roles.

  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
r8   r9   r:   )rK   rL   rM   r=   T)r2   r3   r4   r5   queryr?   )pagerB   model)	rD   _get_api_listr   r   r   r   r   r   RoleListParams	r'   r;   rK   rL   rM   r2   r3   r4   r5   s	            r(   list
Roles.listV   s    B VW_Vbcdd!!AHU#$45(+'%%!&!&!&
 %33 /5 #% " 
 	
r+   c                   U(       d  [        SU< 35      eU(       d  [        SU< 35      eU R                  [        SX!S9[        UUUUSS0S9[        S9$ )	@  
Unassigns an organization role from a group within 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
r8   6Expected a non-empty value for `role_id` but received //organization/groups/{group_id}/roles/{role_id}r;   r<   r=   Tr>   rB   rC   rD   _deleter   r   r   r'   r<   r;   r2   r3   r4   r5   s          r(   deleteRoles.delete   sw    0 VW_VbcddUV]U`abb||KV^p(+'%.5 '  

 
	
r+    )returnr%   )rd   r.   r;   strr<   rf   r2   Headers | Noner3   Query | Noner4   Body | Noner5   'float | httpx.Timeout | None | NotGivenrd   r   )r;   rf   rK   
str | OmitrL   
int | OmitrM   Literal['asc', 'desc'] | Omitr2   rg   r3   rh   r4   ri   r5   rj   rd   z$SyncNextCursorPage[RoleListResponse]r<   rf   r;   rf   r2   rg   r3   rh   r4   ri   r5   rj   rd   r   __name__
__module____qualname____firstlineno__r   r)   r/   r   rH   r   rV   ra   __static_attributes__rc   r+   r(   r   r      sS   * * 0 0 )-$("&;D'
'
 	'
 &'
 "'
  '
 9'
 
'
Z ! /3 )-$("&;D6
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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$   )AsyncRolesWithRawResponser&   s    r(   r)   AsyncRoles.with_raw_response   s     )..r+   c                    [        U 5      $ r-   )AsyncRolesWithStreamingResponser&   s    r(   r/   "AsyncRoles.with_streaming_response   s     /t44r+   Nr1   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)
r7   r8   r9   r:   r<   Nr=   Tr>   r@   )rD   rE   r   r   r   rF   r   r   rG   s          r(   rH   AsyncRoles.create   s     4 VW_VbcddZZAHU,i-ACUCfCfgg(+'%.5 '   
 
 	
g
s$   A
A2A.
A2)A0*A20A2rJ   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$ rO   )	rD   rS   r   r   r   r   r   r   rT   rU   s	            r(   rV   AsyncRoles.list   s    B VW_Vbcdd!!AHU$%56(+'%%!&!&!&
 %33 /5 #% " 
 	
r+   c                  #    U(       d  [        SU< 35      eU(       d  [        SU< 35      eU R                  [        SX!S9[        UUUUSS0S9[        S9I S	h  vN $  N7f)
rY   r8   rZ   r[   r\   r=   Tr>   r]   Nr^   r`   s          r(   ra   AsyncRoles.delete,  s     0 VW_VbcddUV]U`abb\\KV^p(+'%.5 ' " 

 

 
	
 

s   AA#A!A#rc   )rd   rx   )rd   r{   re   )r;   rf   rK   rk   rL   rl   rM   rm   r2   rg   r3   rh   r4   ri   r5   rj   rd   zGAsyncPaginator[RoleListResponse, AsyncNextCursorPage[RoleListResponse]]rn   ro   rc   r+   r(   r    r       sT   / / 5 5 )-$("&;D'
'
 	'
 &'
 "'
  '
 9'
 
'
Z ! /3 )-$("&;D6
6
 	6

 6
 -6
 &6
 "6
  6
 96
 
Q6
~ )-$("&;D&
&
 	&
 &&
 "&
  &
 9&
 
&
 &
r+   c                      \ rS rSrSS jrSrg)r%   iU  c                    Xl         [        R                  " UR                  5      U l        [        R                  " UR                  5      U l        [        R                  " UR
                  5      U l        g N)_rolesr   to_raw_response_wrapperrH   rV   ra   r'   roless     r(   __init__RolesWithRawResponse.__init__V  sV    &>>LL
 %<<JJ
	 '>>LL
r+   r   rH   ra   rV   Nr   r   rd   Nonerp   rq   rr   rs   r   rt   rc   r+   r(   r%   r%   U      
r+   r%   c                      \ rS rSrSS jrSrg)rx   id  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_wrapperrH   rV   ra   r   s     r(   r   "AsyncRolesWithRawResponse.__init__e  sV    &DDLL
 %BBJJ
	 'DDLL
r+   r   Nr   r    rd   r   r   rc   r+   r(   rx   rx   d  r   r+   rx   c                      \ rS rSrSS jrSrg)r.   is  c                    Xl         [        UR                  5      U l        [        UR                  5      U l        [        UR                  5      U l        g r   )r   r   rH   rV   ra   r   s     r(   r   #RolesWithStreamingResponse.__init__t  sD    2LL
 1JJ
	 3LL
r+   r   Nr   r   rc   r+   r(   r.   r.   s  r   r+   r.   c                      \ rS rSrSS jrSrg)r{   i  c                    Xl         [        UR                  5      U l        [        UR                  5      U l        [        UR                  5      U l        g r   )r   r   rH   rV   ra   r   s     r(   r   (AsyncRolesWithStreamingResponse.__init__  sD    8LL
 7JJ
	 9LL
r+   r   Nr   r   rc   r+   r(   r{   r{     r   r+   r{   )1
__future__r   typing_extensionsr   httpx r   _typesr   r   r	   r
   r   r   r   _utilsr   r   r   _compatr   	_resourcer   r   	_responser   r   
paginationr   r   _base_clientr   r   types.admin.organization.groupsr   r   2types.admin.organization.groups.role_list_responser   4types.admin.organization.groups.role_create_responser   4types.admin.organization.groups.role_delete_responser   __all__r   r    r%   rx   r.   r{   rc   r+   r(   <module>r      s    # %  " M M M M M ( < [ C B U T X XL
![
O [
|[
! [
|
 

 

 

 
r+   