
    ge                         S 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  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 - Conversations
 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.
    )datetime)AnyDictListOptionalUnionIteratorAsyncIterator)deserialize	serializevalues)InstanceContext)InstanceResource)ListResource)Version)Pagec            
         ^  \ rS rSr " S S\5      r " S S\5      r  SS\S\\	\
4   S\	S	\\	   4U 4S
 jjjr\SS j5       rS\4S jrS\4S jrSS jrSS jr\R*                  \R*                  \R*                  4S\S\4   S\\\4   S\\\4   SS 4S jjr\R*                  \R*                  \R*                  4S\S\4   S\\\4   S\\\4   SS 4S jjrS\	4S jrSrU =r$ )UserConversationInstance   c                       \ rS rSrSrSrSrg)*UserConversationInstance.NotificationLevel   defaultmuted N)__name__
__module____qualname____firstlineno__DEFAULTMUTED__static_attributes__r       {/Users/Alptekin/Desktop/izin_takip/venv/lib/python3.13/site-packages/twilio/rest/conversations/v1/user/user_conversation.pyNotificationLevelr      s    r#   r%   c                        \ rS rSrSrSrSrSrg)UserConversationInstance.State   inactiveactiveclosedr   N)r   r   r   r   INACTIVEACTIVECLOSEDr"   r   r#   r$   Stater'      s    r#   r/   versionpayloaduser_sidconversation_sidc                 $  > [         TU ]  U5        UR                  S5      U l        UR                  S5      U l        UR                  S5      U l        [        R                  " UR                  S5      5      U l        [        R                  " UR                  S5      5      U l	        UR                  S5      U l
        UR                  S5      U l        UR                  S5      U l        UR                  S	5      U l        UR                  S
5      U l        UR                  S5      U l        [        R                   " UR                  S5      5      U l        [        R                   " UR                  S5      5      U l        UR                  S5      U l        UR                  S5      U l        UR                  S5      U l        UR                  S5      U l        UR                  S5      U l        UU=(       d    U R
                  S.U l        S U l        g )Naccount_sidchat_service_sidr3   unread_messages_countlast_read_message_indexparticipant_sidr2   friendly_nameconversation_statetimers
attributesdate_createddate_updated
created_bynotification_levelunique_nameurllinksr2   r3   )super__init__getr5   r6   r3   r   integerr7   r8   r9   r2   r:   r;   r<   r=   iso8601_datetimer>   r?   r@   rA   rB   rC   rD   	_solution_context)selfr0   r1   r2   r3   	__class__s        r$   rG   !UserConversationInstance.__init__9   s    	!*1++m*D/6{{;M/N/6{{;M/N4?4G4GKK/05
" 7B6I6IKK127
$ /6kk:K.L'.{{:'>,3KK,HKK,- 	 4;;;x3H)0\)B0;0L0LKK'1
 1<0L0LKK'1
 *1\)B KK,- 	 +2++m*D")++e"429++g2F
 ! 0 ID4I4I
 <@r#   returnc                     U R                   c4  [        U R                  U R                  S   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: UserConversationContext for this UserConversationInstance
r2   r3   rE   )rL   UserConversationContext_versionrK   rM   s    r$   _proxyUserConversationInstance._proxyg   sF     == 3
3!%0B!CDM
 }}r#   c                 6    U R                   R                  5       $ )[
Deletes the UserConversationInstance


:returns: True if delete succeeds, False otherwise
)rU   deleterT   s    r$   rY   UserConversationInstance.deletew   s     {{!!##r#   c                 R   #    U R                   R                  5       I Sh  vN $  N7f)w
Asynchronous coroutine that deletes the UserConversationInstance


:returns: True if delete succeeds, False otherwise
N)rU   delete_asyncrT   s    r$   r]   %UserConversationInstance.delete_async   s       [[--////   '%'c                 6    U R                   R                  5       $ )U
Fetch the UserConversationInstance


:returns: The fetched UserConversationInstance
)rU   fetchrT   s    r$   rb   UserConversationInstance.fetch   s     {{  ""r#   c                 R   #    U R                   R                  5       I Sh  vN $  N7f)o
Asynchronous coroutine to fetch the UserConversationInstance


:returns: The fetched UserConversationInstance
N)rU   fetch_asyncrT   s    r$   rf   $UserConversationInstance.fetch_async   s       [[,,....r_   rA   r   last_read_timestampr8   c                 8    U R                   R                  UUUS9$ )W  
Update the UserConversationInstance

:param notification_level:
:param last_read_timestamp: The date of the last message read in conversation by the user, given in ISO 8601 format.
:param last_read_message_index: The index of the last Message in the Conversation that the Participant has read.

:returns: The updated UserConversationInstance
rA   rh   r8   )rU   updaterM   rA   rh   r8   s       r$   rl   UserConversationInstance.update   s)    " {{!!1 3$; " 
 	
r#   c                 T   #    U R                   R                  UUUS9I Sh  vN $  N7f)q  
Asynchronous coroutine to update the UserConversationInstance

:param notification_level:
:param last_read_timestamp: The date of the last message read in conversation by the user, given in ISO 8601 format.
:param last_read_message_index: The index of the last Message in the Conversation that the Participant has read.

:returns: The updated UserConversationInstance
rk   N)rU   update_asyncrm   s       r$   rq   %UserConversationInstance.update_async   s6     " [[--1 3$; . 
 
 	
 
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>4UserConversationInstance.__repr__.<locals>.<genexpr>         S<RDA7>>!//<R    "z5<Twilio.Conversations.V1.UserConversationInstance {}>joinrK   itemsry   rM   contexts     r$   __repr__!UserConversationInstance.__repr__   s6     ((SDNN<P<P<RSSFMMgVVr#   )rL   rK   r5   r=   r6   r3   r;   r@   r>   r?   r:   r8   rD   rA   r9   r<   rB   r7   rC   r2   )N)rP   rR   )rP   r   )r   r   r   r   objectr%   r/   r   r   strr   r   rG   propertyrU   boolrY   r]   rb   rf   r   unsetr   r   intrl   rq   r   r"   __classcell__rN   s   @r$   r   r      sv   F  
4 +/,@,@ c3h,@ 	,@
 #3-,@ ,@\  $ $0D 0#/ LL7=||6<ll
!8&@


 #8V#34
 "'sF{!3
 
$
6 LL7=||6<ll
!8&@


 #8V#34
 "'sF{!3
 
$
.W# W Wr#   r   c            	       z  ^  \ rS rSrS\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\
4S
 jr\R                  \R                  \R                  4S\S\4   S\\\4   S\\\4   S\
4S jjr\R                  \R                  \R                  4S\S\4   S\\\4   S\\\4   S\
4S jjrS\4S jrSrU =r$ )rR      r0   r2   r3   c                 z   > [         TU ]  U5        UUS.U l        SR                  " S0 U R                  D6U l        g)a  
Initialize the UserConversationContext

:param version: Version that contains the resource
:param user_sid: The unique SID identifier of the [User resource](https://www.twilio.com/docs/conversations/api/user-resource). This value can be either the `sid` or the `identity` of the User resource.
:param conversation_sid: The unique SID identifier of the Conversation. This value can be either the `sid` or the `unique_name` of the [Conversation resource](https://www.twilio.com/docs/conversations/api/conversation-resource).
rE   z2/Users/{user_sid}/Conversations/{conversation_sid}Nr   rF   rG   rK   ry   _uri)rM   r0   r2   r3   rN   s       r$   rG    UserConversationContext.__init__   sD     	! ! 0
 IOO 
nn
	r#   rP   c                 x    [         R                  " 0 5      nU R                  R                  SU R                  US9$ )rX   DELETEmethoduriheaders)r   ofrS   rY   r   rM   r   s     r$   rY   UserConversationContext.delete   s1     ))B-}}##8G#TTr#   c                    #    [         R                  " 0 5      nU R                  R                  SU R                  US9I Sh  vN $  N7f)r\   r   r   N)r   r   rS   r]   r   r   s     r$   r]   $UserConversationContext.delete_async   sE      ))B-]]//G 0 
 
 	
 
s   ?AAAc                     [         R                  " 0 5      nSUS'   U R                  R                  SU R                  US9n[        U R                  UU R                  S   U R                  S   S9$ )ra   application/jsonAcceptGETr   r2   r3   rE   )r   r   rS   rb   r   r   rK   rM   r   r1   s      r$   rb   UserConversationContext.fetch  sj     ))B-.--%%U		7%S'MM^^J/!^^,>?	
 	
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   U R                  S   S9$  N47f)	re   r   r   r   r   Nr2   r3   rE   )r   r   rS   rf   r   r   rK   r   s      r$   rf   #UserConversationContext.fetch_async  s~      ))B-.11dii 2 
 
 (MM^^J/!^^,>?	
 	
	
s   AA=A;5A=rA   r   rh   r8   c                 H   [         R                  " U[        R                  " U5      US.5      n[         R                  " 0 5      nSUS'   SUS'   U R                  R                  SU R                  XES9n[        U R                  UU R                  S   U R                  S	   S
9$ )rj   r%   LastReadTimestampLastReadMessageIndex!application/x-www-form-urlencodedContent-Typer   r   POSTr   r   datar   r2   r3   rE   )	r   r   r   rJ   rS   rl   r   r   rK   rM   rA   rh   r8   r   r   r1   s          r$   rl   UserConversationContext.update.  s    $ yy%7%.%?%?@S%T(?
 ))B-"E.--&&tyyt ' 
 (MM^^J/!^^,>?	
 	
r#   c                 d  #    [         R                  " U[        R                  " U5      US.5      n[         R                  " 0 5      nSUS'   SUS'   U R                  R                  SU R                  XES9I Sh  vN n[        U R                  UU R                  S	   U R                  S
   S9$  N47f)rp   r   r   r   r   r   r   r   Nr2   r3   rE   )	r   r   r   rJ   rS   rq   r   r   rK   r   s          r$   rq   $UserConversationContext.update_asyncX  s     $ yy%7%.%?%?@S%T(?
 ))B-"E.22tyyt 3 
 
 (MM^^J/!^^,>?	
 	
	
s   A7B09B.:5B0c                     SR                  S U R                  R                  5        5       5      nSR                  U5      $ )rt   ru   c              3   H   #    U  H  u  pS R                  X5      v   M     g7frw   rx   rz   s      r$   r~   3UserConversationContext.__repr__.<locals>.<genexpr>  r   r   z4<Twilio.Conversations.V1.UserConversationContext {}>r   r   s     r$   r    UserConversationContext.__repr__  s6     ((SDNN<P<P<RSSELLWUUr#   rK   r   )r   r   r   r   r   r   rG   r   rY   r]   r   rb   rf   r   r   r   r   r   r   rl   rq   r   r"   r   r   s   @r$   rR   rR      s+   
 
3 
# 
&
U 
U
D 

/ 
*
#; 
6 LL7=||6<ll(
!8&@
(

 #8V#34(
 "'sF{!3(
 
"(
\ LL7=||6<ll(
!8&@
(

 #8V#34(
 "'sF{!3(
 
"(
TV# V Vr#   rR   c                   >    \ rS rSrS\\\4   S\4S jrS\4S jr	Sr
g)UserConversationPagei  r1   rP   c                 D    [        U R                  XR                  S   S9$ )z^
Build an instance of UserConversationInstance

:param payload: Payload response from the API
r2   )r2   )r   rS   rK   )rM   r1   s     r$   get_instance!UserConversationPage.get_instance  s#     (MM7^^J-G
 	
r#   c                     g)rt   z.<Twilio.Conversations.V1.UserConversationPage>r   rT   s    r$   r   UserConversationPage.__repr__       @r#   r   N)r   r   r   r   r   r   r   r   r   r   r"   r   r#   r$   r   r     s,    
DcN 
7O 
@# @r#   r   c            	       F  ^  \ rS rSrS\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$ )UserConversationListi  r0   r2   c                 x   > [         TU ]  U5        SU0U l        SR                  " S0 U R                  D6U l        g)a%  
Initialize the UserConversationList

:param version: Version that contains the resource
:param user_sid: The unique SID identifier of the [User resource](https://www.twilio.com/docs/conversations/api/user-resource). This value can be either the `sid` or the `identity` of the User resource.

r2   z/Users/{user_sid}/ConversationsNr   r   )rM   r0   r2   rN   s      r$   rG   UserConversationList.__init__  s=     	! 
 6<<Nt~~N	r#   limit	page_sizerP   c                     U R                   R                  X5      nU R                  US   S9nU R                   R                  XCS   5      $ )a  
Streams UserConversationInstance 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
r   r   r   )rS   read_limitspagestreamrM   r   r   limitsr   s        r$   r   UserConversationList.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 UserConversationInstance 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
r   r   Nr   )rS   r   
page_asyncstream_asyncr   s        r$   r   !UserConversationList.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 UserConversationInstance 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   r   )listr   )rM   r   r   s      r$   r   UserConversationList.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 UserConversationInstance 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   )rM   r   r   records       r$   
list_asyncUserConversationList.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                  X`R                  5      $ )aM  
Retrieve a single page of UserConversationInstance 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 UserConversationInstance
	PageTokenr   PageSizer   r   r   r   r   r   r   paramsr   )r   r   rS   r   r   r   rK   rM   r   r   r   r   r   responses          r$   r   UserConversationList.page  s{      yy'#%
 ))^-PQR.==%%dii & 
 $DMM8^^LLr#   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                  X`R                  5      $  N$7f)	a\  
Asynchronously retrieve a single page of UserConversationInstance 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 UserConversationInstance
r   r   r   r   r   r   r   N)r   r   rS   r   r   r   rK   r   s          r$   r   UserConversationList.page_async;  s       yy'#%
 ))^-PQR.11dii 2 
 
 $DMM8^^LL
s   A B	"B#%B	
target_urlc                     U R                   R                  R                  R                  SU5      n[	        U R                   X R
                  5      $ )z
Retrieve a specific page of UserConversationInstance records from the API.
Request is executed immediately

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

:returns: Page of UserConversationInstance
r   )rS   domaintwiliorequestr   rK   rM   r   r   s      r$   get_pageUserConversationList.get_page\  s;     ==''..66ujI#DMM8^^LLr#   c                    #    U R                   R                  R                  R                  SU5      I Sh  vN n[	        U R                   X R
                  5      $  N$7f)z
Asynchronously retrieve a specific page of UserConversationInstance records from the API.
Request is executed immediately

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

:returns: Page of UserConversationInstance
r   N)rS   r   r   request_asyncr   rK   r   s      r$   get_page_async#UserConversationList.get_page_asynch  sG      --44BB5*UU#DMM8^^LL Vs   4AA%Ar3   c                 F    [        U R                  U R                  S   US9$ a  
Constructs a UserConversationContext

:param conversation_sid: The unique SID identifier of the Conversation. This value can be either the `sid` or the `unique_name` of the [Conversation resource](https://www.twilio.com/docs/conversations/api/conversation-resource).
r2   rE   rR   rS   rK   rM   r3   s     r$   rH   UserConversationList.gett  '     'MM^^J/-
 	
r#   c                 F    [        U R                  U R                  S   US9$ r   r   r   s     r$   __call__UserConversationList.__call__  r   r#   c                     g)rt   z.<Twilio.Conversations.V1.UserConversationList>r   rT   s    r$   r   UserConversationList.__repr__  r   r#   r   )NN) r   r   r   r   r   r   rG   r   r   r	   r   r   r
   r   r   r   r   r   r   r   r   r   r   r   r   r   rR   rH   r   r   r"   r   r   s   @r$   r   r     s)   O O3 O$  $#';}; C=; 
*	+	;6  $#'A}A C=A 
/	0	A6  $#'
}
 C=
 
&	'	
8  $#'
}
 C=
 
&	'	
: *0*0,,(.	M#v+&M 3;'M f%	M
 
MF *0*0,,(.	M#v+&M 3;'M f%	M
 
MB
M3 
M+? 
M
Ms 
M7K 
M

C 

,C 



 

1H 

@# @ @r#   r   N)__doc__r   typingr   r   r   r   r   r	   r
   twilio.baser   r   r   twilio.base.instance_contextr   twilio.base.instance_resourcer   twilio.base.list_resourcer   twilio.base.versionr   twilio.base.pager   r   rR   r   r   r   r#   r$   <module>r
     sn     L L L 6 6 8 : 2 ' !wW/ wWtvVo vVr@4 @*q@< q@r#   