
    g6                         S r SSKJrJrJrJrJrJrJr  SSK	J
r
  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr   " S	 S
\5      r " S S\5      r " S S\5      r " S S\5      rg)a  
 This code was generated by
___ _ _ _ _ _    _ ____    ____ ____ _    ____ ____ _  _ ____ ____ ____ ___ __   __
 |  | | | | |    | |  | __ |  | |__| | __ | __ |___ |\ | |___ |__/ |__|  | |  | |__/
 |  |_|_| | |___ | |__|    |__| |  | |    |__] |___ | \| |___ |  \ |  |  | |__| |  \

 Twilio - Trusthub
 This is the public Twilio REST API.

 NOTE: This class is auto generated by OpenAPI Generator.
 https://openapi-generator.tech
 Do not edit the class manually.
    )AnyDictListOptionalUnionIteratorAsyncIterator)values)InstanceContext)InstanceResource)ListResource)Version)Pagec                      ^  \ rS rSrSr SS\S\\\4   S\	\   4U 4S jjjr
\SS j5       rSS	 jrSS
 jrS\4S jrSrU =r$ )PoliciesInstance   a[  
:ivar sid: The unique string that identifies the Policy resource.
:ivar friendly_name: A human-readable description that is assigned to describe the Policy resource. Examples can include Primary Customer profile policy
:ivar requirements: The SID of an object that holds the policy information
:ivar url: The absolute URL of the Policy resource.
versionpayloadsidc                   > [         TU ]  U5        UR                  S5      U l        UR                  S5      U l        UR                  S5      U l        UR                  S5      U l        SU=(       d    U R                  0U l        S U l        g )Nr   friendly_namerequirementsurl)	super__init__getr   r   r   r   	_solution_context)selfr   r   r   	__class__s       h/Users/Alptekin/Desktop/izin_takip/venv/lib/python3.13/site-packages/twilio/rest/trusthub/v1/policies.pyr   PoliciesInstance.__init__    su     	!")++e"4,3KK,H9@^9T")++e"4 3?$((
 48    returnc                     U R                   c&  [        U R                  U R                  S   S9U l         U R                   $ )z
Generate an instance context for the instance, the context is capable of
performing various actions. All instance actions are proxied to the context

:returns: PoliciesContext for this PoliciesInstance
r   r   )r   PoliciesContext_versionr   r   s    r!   _proxyPoliciesInstance._proxy/   s9     == +NN5)DM }}r#   c                 6    U R                   R                  5       $ )E
Fetch the PoliciesInstance


:returns: The fetched PoliciesInstance
)r*   fetchr)   s    r!   r.   PoliciesInstance.fetch>   s     {{  ""r#   c                 R   #    U R                   R                  5       I Sh  vN $  N7f)_
Asynchronous coroutine to fetch the PoliciesInstance


:returns: The fetched PoliciesInstance
N)r*   fetch_asyncr)   s    r!   r2   PoliciesInstance.fetch_asyncG   s       [[,,....s   '%'c                     SR                  S U R                  R                  5        5       5      nSR                  U5      $ )N
Provide a friendly representation

:returns: Machine friendly representation
 c              3   H   #    U  H  u  pS R                  X5      v   M     g7fz{}={}Nformat.0kvs      r!   	<genexpr>,PoliciesInstance.__repr__.<locals>.<genexpr>V         S<RDA7>>!//<R    "z(<Twilio.Trusthub.V1.PoliciesInstance {}>joinr   itemsr:   r   contexts     r!   __repr__PoliciesInstance.__repr__P   s6     ((SDNN<P<P<RSS9@@IIr#   )r   r   r   r   r   r   )N)r$   r'   )r$   r   )__name__
__module____qualname____firstlineno____doc__r   r   strr   r   r   propertyr*   r.   r2   rH   __static_attributes____classcell__r    s   @r!   r   r      so     OS88)-c3h8>Fsm8 8  #/J# J Jr#   r   c                   ^   ^  \ rS rSrS\S\4U 4S jjrS\4S jrS\4S jr	S\4S jr
S	rU =r$ )
r'   Z   r   r   c                 x   > [         TU ]  U5        SU0U l        SR                  " S0 U R                  D6U l        g)z
Initialize the PoliciesContext

:param version: Version that contains the resource
:param sid: The unique string that identifies the Policy resource.
r   z/Policies/{sid}N )r   r   r   r:   _uri)r   r   r   r    s      r!   r   PoliciesContext.__init__\   s=     	! 3
 &,,>t~~>	r#   r$   c                     [         R                  " 0 5      nSUS'   U R                  R                  SU R                  US9n[        U R                  UU R                  S   S9$ )r-   application/jsonAcceptGETmethoduriheadersr   r&   )r
   ofr(   r.   rX   r   r   r   ra   r   s      r!   r.   PoliciesContext.fetchk   s]     ))B-.--%%U		7%SMMu%
 	
r#   c                    #    [         R                  " 0 5      nSUS'   U R                  R                  SU R                  US9I Sh  vN n[        U R                  UU R                  S   S9$  N&7f)r1   r[   r\   r]   r^   Nr   r&   )r
   rb   r(   r2   rX   r   r   rc   s      r!   r2   PoliciesContext.fetch_async   sq      ))B-.11dii 2 
 
  MMu%
 	
	
s   AA/A-'A/c                     SR                  S U R                  R                  5        5       5      nSR                  U5      $ )r5   r6   c              3   H   #    U  H  u  pS R                  X5      v   M     g7fr8   r9   r;   s      r!   r?   +PoliciesContext.__repr__.<locals>.<genexpr>   rA   rB   z'<Twilio.Trusthub.V1.PoliciesContext {}>rC   rF   s     r!   rH   PoliciesContext.__repr__   s6     ((SDNN<P<P<RSS8??HHr#   )r   rX   )rJ   rK   rL   rM   r   rO   r   r   r.   r2   rH   rQ   rR   rS   s   @r!   r'   r'   Z   sD    ? ?c ?
' 
(
#3 
,I# I Ir#   r'   c                   >    \ rS rSrS\\\4   S\4S jrS\4S jr	Sr
g)PoliciesPage   r   r$   c                 .    [        U R                  U5      $ )zV
Build an instance of PoliciesInstance

:param payload: Payload response from the API
)r   r(   )r   r   s     r!   get_instancePoliciesPage.get_instance   s      w77r#   c                     g)r5   z!<Twilio.Trusthub.V1.PoliciesPage>rW   r)   s    r!   rH   PoliciesPage.__repr__        3r#   rW   N)rJ   rK   rL   rM   r   rO   r   r   ro   rH   rQ   rW   r#   r!   rl   rl      s*    8DcN 87G 83# 3r#   rl   c            	       B  ^  \ rS rSrS\4U 4S jjr  SS\\   S\\   S\\	   4S jjr
  SS\\   S\\   S\\	   4S jjr  SS\\   S\\   S\\	   4S	 jjr  SS\\   S\\   S\\	   4S
 jjr\R"                  \R"                  \R"                  4S\\\4   S\\\4   S\\\4   S\4S jjr\R"                  \R"                  \R"                  4S\\\4   S\\\4   S\\\4   S\4S jjrS\S\4S jrS\S\4S jrS\S\4S jrS\S\4S jrS\4S jrSrU =r$ )PoliciesList   r   c                 2   > [         TU ]  U5        SU l        g)zR
Initialize the PoliciesList

:param version: Version that contains the resource

z	/PoliciesN)r   r   rX   )r   r   r    s     r!   r   PoliciesList.__init__   s     	!	r#   limit	page_sizer$   c                     U R                   R                  X5      nU R                  US   S9nU R                   R                  XCS   5      $ )a  
Streams PoliciesInstance records from the API as a generator stream.
This operation lazily loads records as efficiently as possible until the limit
is reached.
The results are returned as a generator, so this operation is memory efficient.

:param limit: Upper limit for the number of records to return. stream()
              guarantees to never return more than limit.  Default is no limit
:param page_size: Number of records to fetch per request, when not set will use
                  the default value of 50 records.  If no page_size is defined
                  but a limit is defined, stream() will attempt to read the
                  limit with the most efficient page size, i.e. min(limit, 1000)

:returns: Generator that will yield up to limit results
rz   rz   ry   )r(   read_limitspagestreamr   ry   rz   limitsr~   s        r!   r   PoliciesList.stream   sF    ( **5<yy6+#6y7}}##D/::r#   c                    #    U R                   R                  X5      nU R                  US   S9I Sh  vN nU R                   R                  XCS   5      $  N"7f)a  
Asynchronously streams PoliciesInstance records from the API as a generator stream.
This operation lazily loads records as efficiently as possible until the limit
is reached.
The results are returned as a generator, so this operation is memory efficient.

:param limit: Upper limit for the number of records to return. stream()
              guarantees to never return more than limit.  Default is no limit
:param page_size: Number of records to fetch per request, when not set will use
                  the default value of 50 records.  If no page_size is defined
                  but a limit is defined, stream() will attempt to read the
                  limit with the most efficient page size, i.e. min(limit, 1000)

:returns: Generator that will yield up to limit results
rz   r|   Nry   )r(   r}   
page_asyncstream_asyncr   s        r!   r   PoliciesList.stream_async   sR     ( **5<__vk/B_CC}}))$w@@ Ds   1AA#Ac                 4    [        U R                  UUS95      $ )a  
Lists PoliciesInstance records from the API as a list.
Unlike stream(), this operation is eager and will load `limit` records into
memory before returning.

:param limit: Upper limit for the number of records to return. list() guarantees
              never to return more than limit.  Default is no limit
:param page_size: Number of records to fetch per request, when not set will use
                  the default value of 50 records.  If no page_size is defined
                  but a limit is defined, list() will attempt to read the limit
                  with the most efficient page size, i.e. min(limit, 1000)

:returns: list that will contain up to limit results
ry   rz   )listr   )r   ry   rz   s      r!   r   PoliciesList.list   s(    & KK#  
 	
r#   c                 v   #    U R                  UUS9I Sh  vN  Vs/ s Sh  vN nUPM   N N

 sn$ s  snf 7f)a  
Asynchronously lists PoliciesInstance records from the API as a list.
Unlike stream(), this operation is eager and will load `limit` records into
memory before returning.

:param limit: Upper limit for the number of records to return. list() guarantees
              never to return more than limit.  Default is no limit
:param page_size: Number of records to fetch per request, when not set will use
                  the default value of 50 records.  If no page_size is defined
                  but a limit is defined, list() will attempt to read the limit
                  with the most efficient page size, i.e. min(limit, 1000)

:returns: list that will contain up to limit results
r   N)r   )r   ry   rz   records       r!   
list_asyncPoliciesList.list_async  sQ     * '+&7&7# '8 ' ! !
 
 !
 	
 
s0   9,940.
049049
page_tokenpage_numberc                     [         R                  " UUUS.5      n[         R                  " SS05      nSUS'   U R                  R                  SU R                  XES9n[        U R                  U5      $ )a=  
Retrieve a single page of PoliciesInstance records from the API.
Request is executed immediately

:param page_token: PageToken provided by the API
:param page_number: Page Number, this value is simply for client state
:param page_size: Number of records to return, defaults to 50

:returns: Page of PoliciesInstance
	PageTokenr   PageSizeContent-Type!application/x-www-form-urlencodedr[   r\   r]   r_   r`   paramsra   )r
   rb   r(   r~   rX   rl   r   r   r   rz   datara   responses          r!   r~   PoliciesList.page&  sw      yy'#%
 ))^-PQR.==%%dii & 
 DMM844r#   c                   #    [         R                  " UUUS.5      n[         R                  " SS05      nSUS'   U R                  R                  SU R                  XES9I Sh  vN n[        U R                  U5      $  N7f)	aL  
Asynchronously retrieve a single page of PoliciesInstance records from the API.
Request is executed immediately

:param page_token: PageToken provided by the API
:param page_number: Page Number, this value is simply for client state
:param page_size: Number of records to return, defaults to 50

:returns: Page of PoliciesInstance
r   r   r   r[   r\   r]   r   N)r
   rb   r(   r   rX   rl   r   s          r!   r   PoliciesList.page_asyncG  s       yy'#%
 ))^-PQR.11dii 2 
 
 DMM844
s   A A?"A=#A?
target_urlc                     U R                   R                  R                  R                  SU5      n[	        U R                   U5      $ )z
Retrieve a specific page of PoliciesInstance records from the API.
Request is executed immediately

:param target_url: API-generated URL for the requested results page

:returns: Page of PoliciesInstance
r]   )r(   domaintwiliorequestrl   r   r   r   s      r!   get_pagePoliciesList.get_pageh  s7     ==''..66ujIDMM844r#   c                    #    U R                   R                  R                  R                  SU5      I Sh  vN n[	        U R                   U5      $  N7f)z
Asynchronously retrieve a specific page of PoliciesInstance records from the API.
Request is executed immediately

:param target_url: API-generated URL for the requested results page

:returns: Page of PoliciesInstance
r]   N)r(   r   r   request_asyncrl   r   s      r!   get_page_asyncPoliciesList.get_page_asynct  sC      --44BB5*UUDMM844 Vs   4AAAr   c                 *    [        U R                  US9$ zb
Constructs a PoliciesContext

:param sid: The unique string that identifies the Policy resource.
r&   r'   r(   r   r   s     r!   r   PoliciesList.get       t}}#66r#   c                 *    [        U R                  US9$ r   r   r   s     r!   __call__PoliciesList.__call__  r   r#   c                     g)r5   z!<Twilio.Trusthub.V1.PoliciesList>rW   r)   s    r!   rH   PoliciesList.__repr__  rs   r#   )rX   )NN) rJ   rK   rL   rM   r   r   r   intr   r   r   r	   r   r   r   r   r
   unsetr   rO   objectrl   r~   r   r   r   r'   r   r   rH   rQ   rR   rS   s   @r!   ru   ru      s   	  	   $#';}; C=; 
"	#	;6  $#'A}A C=A 
'	(	A6  $#'
}
 C=
 
		
8  $#'
}
 C=
 
		
: *0*0,,(.	5#v+&5 3;'5 f%	5
 
5F *0*0,,(.	5#v+&5 3;'5 f%	5
 
5B
53 
5< 
5
5s 
5| 
57s 7 77C 7O 73# 3 3r#   ru   N)rN   typingr   r   r   r   r   r   r	   twilio.baser
   twilio.base.instance_contextr   twilio.base.instance_resourcer   twilio.base.list_resourcer   twilio.base.versionr   twilio.base.pager   r   r'   rl   ru   rW   r#   r!   <module>r      sc    M L L  8 : 2 ' !?J' ?JDBIo BIJ34 3&d3< d3r#   