
    g2e                         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 - Monitor
 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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$ )EventInstance   a  
:ivar account_sid: The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the Event resource.
:ivar actor_sid: The SID of the actor that caused the event, if available. Can be `null`.
:ivar actor_type: The type of actor that caused the event. Can be: `user` for a change made by a logged-in user in the Twilio Console, `account` for an event caused by an API request by an authenticating Account, `twilio-admin` for an event caused by a Twilio employee, and so on.
:ivar description: A description of the event. Can be `null`.
:ivar event_data: An object with additional data about the event. The  contents depend on `event_type`. For example, event-types of the form `RESOURCE.updated`, this value contains a `resource_properties` dictionary that describes the previous and updated properties of the resource.
:ivar event_date: The date and time in GMT when the event was recorded specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
:ivar event_type: The event's type. Event-types are typically in the form: `RESOURCE_TYPE.ACTION`, where `RESOURCE_TYPE` is the type of resource that was affected and `ACTION` is what happened to it. For example, `phone-number.created`. For a full list of all event-types, see the [Monitor Event Types](https://www.twilio.com/docs/usage/monitor-events#event-types).
:ivar resource_sid: The SID of the resource that was affected.
:ivar resource_type: The type of resource that was affected. For a full list of all resource-types, see the [Monitor Event Types](https://www.twilio.com/docs/usage/monitor-events#event-types).
:ivar sid: The unique string that we created to identify the Event resource.
:ivar source: The originating system or interface that caused the event.  Can be: `web` for events caused by user action in the Twilio Console, `api` for events caused by a request to our API, or   `twilio` for events caused by an automated or internal Twilio system.
:ivar source_ip_address: The IP address of the source, if the source is outside the Twilio cloud. This value is `null` for events with `source` of `twilio`
:ivar url: The absolute URL of the resource that was affected. Can be `null`.
:ivar links: The absolute URLs of related resources.
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        UR                  S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        UR                  S5      U l        UR                  S5      U l        S
U=(       d    U R                  0U l        S U l        g )Naccount_sid	actor_sid
actor_typedescription
event_data
event_date
event_typeresource_sidresource_typer   sourcesource_ip_addressurllinks)super__init__getr   r   r   r   r   r   iso8601_datetimer   r    r!   r"   r   r#   r$   r%   r&   	_solution_context)selfr   r   r   	__class__s       d/Users/Alptekin/Desktop/izin_takip/venv/lib/python3.13/site-packages/twilio/rest/monitor/v1/event.pyr(   EventInstance.__init__+   s)    	!*1++m*D(/K(@)0\)B*1++m*D7>{{<7P.9.J.JKK%/
 *1\)B+2;;~+F,3KK,H")++e"4%,[[%:07<O0P")++e"429++g2F
 3?$((
 15    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: EventContext for this EventInstance
r   r   )r,   EventContext_versionr+   r-   s    r/   _proxyEventInstance._proxyF   s9     == (NN5)DM }}r1   c                 6    U R                   R                  5       $ )?
Fetch the EventInstance


:returns: The fetched EventInstance
)r8   fetchr7   s    r/   r<   EventInstance.fetchU   s     {{  ""r1   c                 R   #    U R                   R                  5       I Sh  vN $  N7f)Y
Asynchronous coroutine to fetch the EventInstance


:returns: The fetched EventInstance
N)r8   fetch_asyncr7   s    r/   r@   EventInstance.fetch_async^   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>)EventInstance.__repr__.<locals>.<genexpr>m         S<RDA7>>!//<R    "z$<Twilio.Monitor.V1.EventInstance {}>joinr+   itemsrH   r-   contexts     r/   __repr__EventInstance.__repr__g   s6     ((SDNN<P<P<RSS5<<WEEr1   )r,   r+   r   r   r   r   r   r   r    r&   r!   r"   r   r#   r$   r%   )N)r2   r5   )r2   r   )__name__
__module____qualname____firstlineno____doc__r   r   strr   r   r(   propertyr8   r<   r@   rV   __static_attributes____classcell__r.   s   @r/   r   r      so    $ OS55)-c3h5>Fsm5 56  #/F# F Fr1   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$ )
r5   q   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 EventContext

:param version: Version that contains the resource
:param sid: The SID of the Event resource to fetch.
r   z/Events/{sid}N )r'   r(   r+   rH   _uri)r-   r   r   r.   s      r/   r(   EventContext.__init__s   s=     	! 3
 $**<T^^<	r1   r2   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   r4   )r   ofr6   r<   rf   r   r+   r-   ro   r   s      r/   r<   EventContext.fetch   s]     ))B-.--%%U		7%SMMu%
 	
r1   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)r?   ri   rj   rk   rl   Nr   r4   )r   rp   r6   r@   rf   r   r+   rq   s      r/   r@   EventContext.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      $ )rC   rD   c              3   H   #    U  H  u  pS R                  X5      v   M     g7frF   rG   rI   s      r/   rM   (EventContext.__repr__.<locals>.<genexpr>   rO   rP   z#<Twilio.Monitor.V1.EventContext {}>rQ   rT   s     r/   rV   EventContext.__repr__   s6     ((SDNN<P<P<RSS4;;GDDr1   )r+   rf   )rX   rY   rZ   r[   r   r]   r(   r   r<   r@   rV   r_   r`   ra   s   @r/   r5   r5   q   sB    = =c =
} 
(
= 
,E# E Er1   r5   c                   >    \ rS rSrS\\\4   S\4S jrS\4S jr	Sr
g)	EventPage   r   r2   c                 .    [        U R                  U5      $ )zS
Build an instance of EventInstance

:param payload: Payload response from the API
)r   r6   )r-   r   s     r/   get_instanceEventPage.get_instance   s     T]]G44r1   c                     g)rC   z<Twilio.Monitor.V1.EventPage>re   r7   s    r/   rV   EventPage.__repr__        /r1   re   N)rX   rY   rZ   r[   r   r]   r   r   r}   rV   r_   re   r1   r/   rz   rz      s)    5DcN 5} 5/# /r1   rz   c                   R  ^  \ rS rSrS\4U 4S jjr\R                  \R                  \R                  \R                  \R                  \R                  SS4S\\	\
4   S\\	\
4   S\\	\
4   S\\	\
4   S	\\\
4   S
\\\
4   S\\   S\\   S\\   4S jjr\R                  \R                  \R                  \R                  \R                  \R                  SS4S\\	\
4   S\\	\
4   S\\	\
4   S\\	\
4   S	\\\
4   S
\\\
4   S\\   S\\   S\\   4S jjr\R                  \R                  \R                  \R                  \R                  \R                  SS4S\\	\
4   S\\	\
4   S\\	\
4   S\\	\
4   S	\\\
4   S
\\\
4   S\\   S\\   S\\   4S jjr\R                  \R                  \R                  \R                  \R                  \R                  SS4S\\	\
4   S\\	\
4   S\\	\
4   S\\	\
4   S	\\\
4   S
\\\
4   S\\   S\\   S\\   4S jjr\R                  \R                  \R                  \R                  \R                  \R                  \R                  \R                  \R                  4	S\\	\
4   S\\	\
4   S\\	\
4   S\\	\
4   S	\\\
4   S
\\\
4   S\\	\
4   S\\\
4   S\\\
4   S\4S jjr\R                  \R                  \R                  \R                  \R                  \R                  \R                  \R                  \R                  4	S\\	\
4   S\\	\
4   S\\	\
4   S\\	\
4   S	\\\
4   S
\\\
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 $ )	EventList   r   c                 2   > [         TU ]  U5        SU l        g)zO
Initialize the EventList

:param version: Version that contains the resource

z/EventsN)r'   r(   rf   )r-   r   r.   s     r/   r(   EventList.__init__   s     	!	r1   Nr   r    r!   r$   
start_dateend_datelimit	page_sizer2   c	           
          U R                   R                  Xx5      n	U R                  UUUUUUU	S   S9n
U R                   R                  XS   5      $ )a  
Streams EventInstance 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 str actor_sid: Only include events initiated by this Actor. Useful for auditing actions taken by specific users or API credentials.
:param str event_type: Only include events of this [Event Type](https://www.twilio.com/docs/usage/monitor-events#event-types).
:param str resource_sid: Only include events that refer to this resource. Useful for discovering the history of a specific resource.
:param str source_ip_address: Only include events that originated from this IP address. Useful for tracking suspicious activity originating from the API or the Twilio Console.
:param datetime start_date: Only include events that occurred on or after this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
:param datetime end_date: Only include events that occurred on or before this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
: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    r!   r$   r   r   r   r   )r6   read_limitspagestreamr-   r   r    r!   r$   r   r   r   r   limitsr   s              r/   r   EventList.stream   sa    @ **5<yy!%/![)  
 }}##D/::r1   c	           
         #    U R                   R                  Xx5      n	U R                  UUUUUUU	S   S9I Sh  vN n
U R                   R                  XS   5      $  N"7f)a  
Asynchronously streams EventInstance 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 str actor_sid: Only include events initiated by this Actor. Useful for auditing actions taken by specific users or API credentials.
:param str event_type: Only include events of this [Event Type](https://www.twilio.com/docs/usage/monitor-events#event-types).
:param str resource_sid: Only include events that refer to this resource. Useful for discovering the history of a specific resource.
:param str source_ip_address: Only include events that originated from this IP address. Useful for tracking suspicious activity originating from the API or the Twilio Console.
:param datetime start_date: Only include events that occurred on or after this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
:param datetime end_date: Only include events that occurred on or before this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
: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   )r6   r   
page_asyncstream_asyncr   s              r/   r   EventList.stream_async  sn     @ **5<__!%/![) % 
 
 }}))$w@@
s   7AA#Ac	                 @    [        U R                  UUUUUUUUS95      $ )a6  
Lists EventInstance records from the API as a list.
Unlike stream(), this operation is eager and will load `limit` records into
memory before returning.

:param str actor_sid: Only include events initiated by this Actor. Useful for auditing actions taken by specific users or API credentials.
:param str event_type: Only include events of this [Event Type](https://www.twilio.com/docs/usage/monitor-events#event-types).
:param str resource_sid: Only include events that refer to this resource. Useful for discovering the history of a specific resource.
:param str source_ip_address: Only include events that originated from this IP address. Useful for tracking suspicious activity originating from the API or the Twilio Console.
:param datetime start_date: Only include events that occurred on or after this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
:param datetime end_date: Only include events that occurred on or before this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
: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    r!   r$   r   r   r   r   )listr   )	r-   r   r    r!   r$   r   r   r   r   s	            r/   r   EventList.list0  s:    > KK#%)"3%!#  	
 	
r1   c	                    #    U R                  UUUUUU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)aE  
Asynchronously lists EventInstance records from the API as a list.
Unlike stream(), this operation is eager and will load `limit` records into
memory before returning.

:param str actor_sid: Only include events initiated by this Actor. Useful for auditing actions taken by specific users or API credentials.
:param str event_type: Only include events of this [Event Type](https://www.twilio.com/docs/usage/monitor-events#event-types).
:param str resource_sid: Only include events that refer to this resource. Useful for discovering the history of a specific resource.
:param str source_ip_address: Only include events that originated from this IP address. Useful for tracking suspicious activity originating from the API or the Twilio Console.
:param datetime start_date: Only include events that occurred on or after this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
:param datetime end_date: Only include events that occurred on or before this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
: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-   r   r    r!   r$   r   r   r   r   records
             r/   
list_asyncEventList.list_async\  sd     B '+&7&7#%)"3%!# '8 	' 	! 	!
 
 	!
 	
 
s0   ?2?:64
6:?6:?
page_tokenpage_numberc
                 B   [         R                  " UUUU[        R                  " U5      [        R                  " U5      UUU	S.	5      n
[         R                  " SS05      nSUS'   U R                  R                  SU R                  XS9n[        U R                  U5      $ )a  
Retrieve a single page of EventInstance records from the API.
Request is executed immediately

:param actor_sid: Only include events initiated by this Actor. Useful for auditing actions taken by specific users or API credentials.
:param event_type: Only include events of this [Event Type](https://www.twilio.com/docs/usage/monitor-events#event-types).
:param resource_sid: Only include events that refer to this resource. Useful for discovering the history of a specific resource.
:param source_ip_address: Only include events that originated from this IP address. Useful for tracking suspicious activity originating from the API or the Twilio Console.
:param start_date: Only include events that occurred on or after this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
:param end_date: Only include events that occurred on or before this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
: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 EventInstance
	ActorSid	EventTypeResourceSidSourceIpAddress	StartDateEndDate	PageTokenr   PageSizeContent-Type!application/x-www-form-urlencodedri   rj   rk   rm   rn   paramsro   )r   rp   r   r*   r6   r   rf   rz   r-   r   r    r!   r$   r   r   r   r   r   dataro   responses                r/   r   EventList.page  s    8 yy%'+#4&77
C$55h?'#%

 ))^-PQR.==%%dii & 
 11r1   c
                 ^  #    [         R                  " UUUU[        R                  " U5      [        R                  " U5      UUU	S.	5      n
[         R                  " SS05      nSUS'   U R                  R                  SU R                  XS9I Sh  vN n[        U R                  U5      $  N7f)	a  
Asynchronously retrieve a single page of EventInstance records from the API.
Request is executed immediately

:param actor_sid: Only include events initiated by this Actor. Useful for auditing actions taken by specific users or API credentials.
:param event_type: Only include events of this [Event Type](https://www.twilio.com/docs/usage/monitor-events#event-types).
:param resource_sid: Only include events that refer to this resource. Useful for discovering the history of a specific resource.
:param source_ip_address: Only include events that originated from this IP address. Useful for tracking suspicious activity originating from the API or the Twilio Console.
:param start_date: Only include events that occurred on or after this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
:param end_date: Only include events that occurred on or before this date. Specify the date in GMT and [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
: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 EventInstance
r   r   r   ri   rj   rk   r   N)r   rp   r   r*   r6   r   rf   rz   r   s                r/   r   EventList.page_async  s     8 yy%'+#4&77
C$55h?'#%

 ))^-PQR.11dii 2 
 
 11
s   BB-B+B-
target_urlc                     U R                   R                  R                  R                  SU5      n[	        U R                   U5      $ )z
Retrieve a specific page of EventInstance records from the API.
Request is executed immediately

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

:returns: Page of EventInstance
rk   )r6   domaintwiliorequestrz   r-   r   r   s      r/   get_pageEventList.get_page  s7     ==''..66ujI11r1   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 EventInstance records from the API.
Request is executed immediately

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

:returns: Page of EventInstance
rk   N)r6   r   r   request_asyncrz   r   s      r/   get_page_asyncEventList.get_page_async  sC      --44BB5*UU11 Vs   4AAAr   c                 *    [        U R                  US9$ zP
Constructs a EventContext

:param sid: The SID of the Event resource to fetch.
r4   r5   r6   r-   r   s     r/   r)   EventList.get       DMMs33r1   c                 *    [        U R                  US9$ r   r   r   s     r/   __call__EventList.__call__  r   r1   c                     g)rC   z<Twilio.Monitor.V1.EventList>re   r7   s    r/   rV   EventList.__repr__  r   r1   )rf   )!rX   rY   rZ   r[   r   r(   r   unsetr   r]   objectr   r   intr	   r   r   r
   r   r   r   r   rz   r   r   r   r   r5   r)   r   rV   r_   r`   ra   s   @r/   r   r      s   	 	 )/)/+1<<06.4ll,2LL##'+;f%+; #v+&+; CK(	+;
 !f-+; (F*++; &()+; }+; C=+; 
-	 +;^ )/)/+1<<06.4ll,2LL##'+Af%+A #v+&+A CK(	+A
 !f-+A (F*++A &()+A }+A C=+A 
}	%+A^ )/)/+1<<06.4ll,2LL##'*
f%*
 #v+&*
 CK(	*

 !f-*
 (F*+*
 &()*
 }*
 C=*
 
m	*
\ )/)/+1<<06.4ll,2LL##'+
f%+
 #v+&+
 CK(	+

 !f-+
 (F*++
 &()+
 }+
 C=+
 
m	+
^ )/)/+1<<06.4ll,2LL)/*0,,(.12f%12 #v+&12 CK(	12
 !f-12 (F*+12 &()12 #v+&12 3;'12 f%12 
12j )/)/+1<<06.4ll,2LL)/*0,,(.12f%12 #v+&12 CK(	12
 !f-12 (F*+12 &()12 #v+&12 3;'12 f%12 
12f
23 
29 
2
2s 
2y 
24s 4| 44C 4L 4/# / /r1   r   N)r\   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   r5   rz   r   re   r1   r/   <module>r      sj     L L L 6 6 8 : 2 ' !UF$ UFpBE? BEJ/ /&T/ T/r1   