o
    /i                     @   s   d Z ddlmZ ddlmZmZmZmZmZmZm	Z	 ddl
mZmZ ddlmZ ddlmZ ddlmZ ddlmZ dd	lmZ G d
d deZG dd deZG dd deZG dd deZdS )a  
    This code was generated by
   ___ _ _ _ _ _    _ ____    ____ ____ _    ____ ____ _  _ ____ ____ ____ ___ __   __
    |  | | | | |    | |  | __ |  | |__| | __ | __ |___ |\ | |___ |__/ |__|  | |  | |__/
    |  |_|_| | |___ | |__|    |__| |  | |    |__] |___ | \| |___ |  \ |  |  | |__| |  \

    Twilio - Api
    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values)InstanceContext)InstanceResource)ListResource)Version)Pagec                #       s  e Zd ZdZ	d+dedeeef dedee f fddZ	e
d,ddZd	efddZd	efddZd-ddZd-ddZejejejejejejejejejejejejejejejejfdeeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef d eeef d!eeef d"eeef d#eeef d$eeef d	d f"d%d&Zejejejejejejejejejejejejejejejejfdeeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef d eeef d!eeef d"eeef d#eeef d$eeef d	d f"d'd(Zd	efd)d*Z  ZS ).ApplicationInstancea	  
    :ivar account_sid: The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the Application resource.
    :ivar api_version: The API version used to start a new TwiML session.
    :ivar date_created: The date and time in GMT that the resource was created specified in [RFC 2822](https://www.ietf.org/rfc/rfc2822.txt) format.
    :ivar date_updated: The date and time in GMT that the resource was last updated specified in [RFC 2822](https://www.ietf.org/rfc/rfc2822.txt) format.
    :ivar friendly_name: The string that you assigned to describe the resource.
    :ivar message_status_callback: The URL we call using a POST method to send message status information to your application.
    :ivar sid: The unique string that that we created to identify the Application resource.
    :ivar sms_fallback_method: The HTTP method we use to call `sms_fallback_url`. Can be: `GET` or `POST`.
    :ivar sms_fallback_url: The URL that we call when an error occurs while retrieving or executing the TwiML from `sms_url`.
    :ivar sms_method: The HTTP method we use to call `sms_url`. Can be: `GET` or `POST`.
    :ivar sms_status_callback: The URL we call using a POST method to send status information to your application about SMS messages that refer to the application.
    :ivar sms_url: The URL we call when the phone number receives an incoming SMS message.
    :ivar status_callback: The URL we call using the `status_callback_method` to send status information to your application.
    :ivar status_callback_method: The HTTP method we use to call `status_callback`. Can be: `GET` or `POST`.
    :ivar uri: The URI of the resource, relative to `https://api.twilio.com`.
    :ivar voice_caller_id_lookup: Whether we look up the caller's caller-ID name from the CNAM database (additional charges apply). Can be: `true` or `false`.
    :ivar voice_fallback_method: The HTTP method we use to call `voice_fallback_url`. Can be: `GET` or `POST`.
    :ivar voice_fallback_url: The URL that we call when an error occurs retrieving or executing the TwiML requested by `url`.
    :ivar voice_method: The HTTP method we use to call `voice_url`. Can be: `GET` or `POST`.
    :ivar voice_url: The URL we call when the phone number assigned to this application receives a call.
    :ivar public_application_connect_enabled: Whether to allow other Twilio accounts to dial this applicaton using Dial verb. Can be: `true` or `false`.
    Nversionpayloadaccount_sidsidc                    s0  t  | |d| _|d| _t|d| _t|d| _|d| _	|d| _
|d| _|d| _|d	| _|d
| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _||p| jd| _d | _d S )Nr   api_versiondate_createddate_updatedfriendly_namemessage_status_callbackr   sms_fallback_methodsms_fallback_url
sms_methodsms_status_callbacksms_urlstatus_callbackstatus_callback_methodurivoice_caller_id_lookupvoice_fallback_methodvoice_fallback_urlvoice_method	voice_url"public_application_connect_enabledr   r   )super__init__getr   r   r
   rfc2822_datetimer   r   r   r   r   r   r   r   r   r   r    r!   r"   r#   r$   r%   r&   r'   r(   	_solution_context)selfr   r   r   r   	__class__ d/var/www/html/philips/venv/lib/python3.10/site-packages/twilio/rest/api/v2010/account/application.pyr+   4   sL   
zApplicationInstance.__init__returnApplicationContextc                 C   s.   | j du rt| j| jd | jd d| _ | j S )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: ApplicationContext for this ApplicationInstance
        Nr   r   r)   )r/   r6   _versionr.   r0   r3   r3   r4   _proxye   s   
zApplicationInstance._proxyc                 C   
   | j  S )n
        Deletes the ApplicationInstance


        :returns: True if delete succeeds, False otherwise
        )r9   deleter8   r3   r3   r4   r<   u      
zApplicationInstance.deletec                       | j  I dH S )
        Asynchronous coroutine that deletes the ApplicationInstance


        :returns: True if delete succeeds, False otherwise
        N)r9   delete_asyncr8   r3   r3   r4   r@   ~      z ApplicationInstance.delete_asyncc                 C   r:   )c
        Fetch the ApplicationInstance


        :returns: The fetched ApplicationInstance
        )r9   fetchr8   r3   r3   r4   rC      r=   zApplicationInstance.fetchc                    r>   )}
        Asynchronous coroutine to fetch the ApplicationInstance


        :returns: The fetched ApplicationInstance
        N)r9   fetch_asyncr8   r3   r3   r4   rE      rA   zApplicationInstance.fetch_asyncr   r   r'   r&   r%   r$   r    r!   r#   r   r   r   r   r   r   r(   c                 C   sn   | j jdi d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|d|d|S )	  
        Update the ApplicationInstance

        :param friendly_name: A descriptive string that you create to describe the resource. It can be up to 64 characters long.
        :param api_version: The API version to use to start a new TwiML session. Can be: `2010-04-01` or `2008-08-01`. The default value is your account's default API version.
        :param voice_url: The URL we should call when the phone number assigned to this application receives a call.
        :param voice_method: The HTTP method we should use to call `voice_url`. Can be: `GET` or `POST`.
        :param voice_fallback_url: The URL that we should call when an error occurs retrieving or executing the TwiML requested by `url`.
        :param voice_fallback_method: The HTTP method we should use to call `voice_fallback_url`. Can be: `GET` or `POST`.
        :param status_callback: The URL we should call using the `status_callback_method` to send status information to your application.
        :param status_callback_method: The HTTP method we should use to call `status_callback`. Can be: `GET` or `POST`.
        :param voice_caller_id_lookup: Whether we should look up the caller's caller-ID name from the CNAM database (additional charges apply). Can be: `true` or `false`.
        :param sms_url: The URL we should call when the phone number receives an incoming SMS message.
        :param sms_method: The HTTP method we should use to call `sms_url`. Can be: `GET` or `POST`.
        :param sms_fallback_url: The URL that we should call when an error occurs while retrieving or executing the TwiML from `sms_url`.
        :param sms_fallback_method: The HTTP method we should use to call `sms_fallback_url`. Can be: `GET` or `POST`.
        :param sms_status_callback: Same as message_status_callback: The URL we should call using a POST method to send status information about SMS messages sent by the application. Deprecated, included for backwards compatibility.
        :param message_status_callback: The URL we should call using a POST method to send message status information to your application.
        :param public_application_connect_enabled: Whether to allow other Twilio accounts to dial this applicaton using Dial verb. Can be: `true` or `false`.

        :returns: The updated ApplicationInstance
        r   r   r'   r&   r%   r$   r    r!   r#   r   r   r   r   r   r   r(   Nr3   )r9   updater0   r   r   r'   r&   r%   r$   r    r!   r#   r   r   r   r   r   r   r(   r3   r3   r4   rG      sB   )	
zApplicationInstance.updatec                    sv   | j jdi d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|d|d|I dH S )	  
        Asynchronous coroutine to update the ApplicationInstance

        :param friendly_name: A descriptive string that you create to describe the resource. It can be up to 64 characters long.
        :param api_version: The API version to use to start a new TwiML session. Can be: `2010-04-01` or `2008-08-01`. The default value is your account's default API version.
        :param voice_url: The URL we should call when the phone number assigned to this application receives a call.
        :param voice_method: The HTTP method we should use to call `voice_url`. Can be: `GET` or `POST`.
        :param voice_fallback_url: The URL that we should call when an error occurs retrieving or executing the TwiML requested by `url`.
        :param voice_fallback_method: The HTTP method we should use to call `voice_fallback_url`. Can be: `GET` or `POST`.
        :param status_callback: The URL we should call using the `status_callback_method` to send status information to your application.
        :param status_callback_method: The HTTP method we should use to call `status_callback`. Can be: `GET` or `POST`.
        :param voice_caller_id_lookup: Whether we should look up the caller's caller-ID name from the CNAM database (additional charges apply). Can be: `true` or `false`.
        :param sms_url: The URL we should call when the phone number receives an incoming SMS message.
        :param sms_method: The HTTP method we should use to call `sms_url`. Can be: `GET` or `POST`.
        :param sms_fallback_url: The URL that we should call when an error occurs while retrieving or executing the TwiML from `sms_url`.
        :param sms_fallback_method: The HTTP method we should use to call `sms_fallback_url`. Can be: `GET` or `POST`.
        :param sms_status_callback: Same as message_status_callback: The URL we should call using a POST method to send status information about SMS messages sent by the application. Deprecated, included for backwards compatibility.
        :param message_status_callback: The URL we should call using a POST method to send message status information to your application.
        :param public_application_connect_enabled: Whether to allow other Twilio accounts to dial this applicaton using Dial verb. Can be: `true` or `false`.

        :returns: The updated ApplicationInstance
        r   r   r'   r&   r%   r$   r    r!   r#   r   r   r   r   r   r   r(   Nr3   )r9   update_asyncrH   r3   r3   r4   rJ      sD   )	

z ApplicationInstance.update_asyncc                 C   $   d dd | j D }d|S )f
        Provide a friendly representation

        :returns: Machine friendly representation
         c                 s        | ]\}}d  ||V  qdS z{}={}Nformat.0kvr3   r3   r4   	<genexpr>      z/ApplicationInstance.__repr__.<locals>.<genexpr>z)<Twilio.Api.V2010.ApplicationInstance {}>joinr.   itemsrQ   r0   contextr3   r3   r4   __repr__     
zApplicationInstance.__repr__N)r5   r6   )r5   r   )__name__
__module____qualname____doc__r   r   strr   r   r+   propertyr9   boolr<   r@   rC   rE   r   unsetr   objectrG   rJ   r]   __classcell__r3   r3   r1   r4   r      s    
1	
	
	







	









>







	









<r   c                #       s  e Zd Zdededef fddZdefddZdefd	d
Zde	fddZ
de	fddZejejejejejejejejejejejejejejejejfdeeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef de	f"dd Zejejejejejejejejejejejejejejejejfdeeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef deeef de	f"d!d"Zdefd#d$Z  ZS )%r6   r   r   r   c                    s0   t  | ||d| _djdi | j| _dS )ao  
        Initialize the ApplicationContext

        :param version: Version that contains the resource
        :param account_sid: The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the Application resources to update.
        :param sid: The Twilio-provided string that uniquely identifies the Application resource to update.
        r)   z//Accounts/{account_sid}/Applications/{sid}.jsonNr3   r*   r+   r.   rQ   _uri)r0   r   r   r   r1   r3   r4   r+     s   zApplicationContext.__init__r5   c                 C   s   | j jd| jdS )r;   DELETEmethodr"   )r7   r<   rk   r8   r3   r3   r4   r<   /  s   zApplicationContext.deletec                    s   | j jd| jdI dH S )r?   rl   rm   N)r7   r@   rk   r8   r3   r3   r4   r@   ;  s
   zApplicationContext.delete_asyncc                 C   s0   | j jd| jd}t| j || jd | jd dS )rB   GETrm   r   r   r)   )r7   rC   rk   r   r.   r0   r   r3   r3   r4   rC   G  s   zApplicationContext.fetchc                    s8   | j jd| jdI dH }t| j || jd | jd dS )rD   ro   rm   Nr   r   r)   )r7   rE   rk   r   r.   rp   r3   r3   r4   rE   [  s   zApplicationContext.fetch_asyncr   r   r'   r&   r%   r$   r    r!   r#   r   r   r   r   r   r   r(   c                 C   s   t i d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|d|d|}| jjd| j|d}t| j|| jd | jd dS )rF   FriendlyName
ApiVersionVoiceUrlVoiceMethodVoiceFallbackUrlVoiceFallbackMethodStatusCallbackStatusCallbackMethodVoiceCallerIdLookupSmsUrl	SmsMethodSmsFallbackUrlSmsFallbackMethodSmsStatusCallbackMessageStatusCallbackPublicApplicationConnectEnabledPOSTrn   r"   datar   r   r)   )r   ofr7   rG   rk   r   r.   r0   r   r   r'   r&   r%   r$   r    r!   r#   r   r   r   r   r   r   r(   r   r   r3   r3   r4   rG   o  s\   )	
zApplicationContext.updatec                    s   t i d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|d|d|}| jjd| j|dI dH }t| j|| jd | jd dS )rI   rq   rr   rs   rt   ru   rv   rw   rx   ry   rz   r{   r|   r}   r~   r   r   r   r   Nr   r   r)   )r   r   r7   rJ   rk   r   r.   r   r3   r3   r4   rJ     s^   )	
zApplicationContext.update_asyncc                 C   rK   )rL   rM   c                 s   rN   rO   rP   rR   r3   r3   r4   rV     rW   z.ApplicationContext.__repr__.<locals>.<genexpr>z(<Twilio.Api.V2010.ApplicationContext {}>rX   r[   r3   r3   r4   r]     r^   zApplicationContext.__repr__)r`   ra   rb   r   rd   r+   rf   r<   r@   r   rC   rE   r   rg   r   rh   rG   rJ   r]   ri   r3   r3   r1   r4   r6     s    







	









M







	









Kr6   c                   @   s4   e Zd Zdeeef defddZdefddZdS )ApplicationPager   r5   c                 C   s   t | j|| jd dS )zq
        Build an instance of ApplicationInstance

        :param payload: Payload response from the API
        r   r   )r   r7   r.   rp   r3   r3   r4   get_instance     zApplicationPage.get_instancec                 C      dS )rL   z"<Twilio.Api.V2010.ApplicationPage>r3   r8   r3   r3   r4   r]        zApplicationPage.__repr__N)	r`   ra   rb   r   rd   r   r   r   r]   r3   r3   r3   r4   r     s    
r   c                #       s  e Zd Zdedef fddZejejejejejejejejejejejejejejejejfdeee	f deee	f deee	f deee	f d	eee	f d
eee	f deee	f dee
e	f deee	f deee	f deee	f deee	f deee	f deee	f deee	f dee
e	f def"ddZejejejejejejejejejejejejejejejejfdeee	f deee	f deee	f deee	f d	eee	f d
eee	f deee	f dee
e	f deee	f deee	f deee	f deee	f deee	f deee	f deee	f dee
e	f def"ddZejddfdeee	f dee dee dee fddZejddfdeee	f dee dee dee fdd Zejddfdeee	f dee dee dee fd!d"Zejddfdeee	f dee dee dee fd#d$Zejejejejfdeee	f d%eee	f d&eee	f deee	f def
d'd(Zejejejejfdeee	f d%eee	f d&eee	f deee	f def
d)d*Zd+edefd,d-Zd+edefd.d/Zd0edefd1d2Zd0edefd3d4Zdefd5d6Z  Z S )7ApplicationListr   r   c                    s.   t  | d|i| _djdi | j| _dS )z
        Initialize the ApplicationList

        :param version: Version that contains the resource
        :param account_sid: The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the Application resources to read.

        r   z)/Accounts/{account_sid}/Applications.jsonNr3   rj   )r0   r   r   r1   r3   r4   r+   $  s   zApplicationList.__init__r   r'   r&   r%   r$   r    r!   r#   r   r   r   r   r   r   r   r(   r5   c                 C   s   t i d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|d|d|}| jjd| j|d}t| j|| jd dS )a  
        Create the ApplicationInstance

        :param api_version: The API version to use to start a new TwiML session. Can be: `2010-04-01` or `2008-08-01`. The default value is the account's default API version.
        :param voice_url: The URL we should call when the phone number assigned to this application receives a call.
        :param voice_method: The HTTP method we should use to call `voice_url`. Can be: `GET` or `POST`.
        :param voice_fallback_url: The URL that we should call when an error occurs retrieving or executing the TwiML requested by `url`.
        :param voice_fallback_method: The HTTP method we should use to call `voice_fallback_url`. Can be: `GET` or `POST`.
        :param status_callback: The URL we should call using the `status_callback_method` to send status information to your application.
        :param status_callback_method: The HTTP method we should use to call `status_callback`. Can be: `GET` or `POST`.
        :param voice_caller_id_lookup: Whether we should look up the caller's caller-ID name from the CNAM database (additional charges apply). Can be: `true` or `false`.
        :param sms_url: The URL we should call when the phone number receives an incoming SMS message.
        :param sms_method: The HTTP method we should use to call `sms_url`. Can be: `GET` or `POST`.
        :param sms_fallback_url: The URL that we should call when an error occurs while retrieving or executing the TwiML from `sms_url`.
        :param sms_fallback_method: The HTTP method we should use to call `sms_fallback_url`. Can be: `GET` or `POST`.
        :param sms_status_callback: The URL we should call using a POST method to send status information about SMS messages sent by the application.
        :param message_status_callback: The URL we should call using a POST method to send message status information to your application.
        :param friendly_name: A descriptive string that you create to describe the new application. It can be up to 64 characters long.
        :param public_application_connect_enabled: Whether to allow other Twilio accounts to dial this applicaton using Dial verb. Can be: `true` or `false`.

        :returns: The created ApplicationInstance
        rr   rs   rt   ru   rv   rw   rx   ry   rz   r{   r|   r}   r~   r   rq   r   r   r   r   r   )r   r   r7   createrk   r   r.   r0   r   r'   r&   r%   r$   r    r!   r#   r   r   r   r   r   r   r   r(   r   r   r3   r3   r4   r   4  sV   )	
zApplicationList.createc                    s   t i d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|d|d|}| jjd| j|dI dH }t| j|| jd dS )a  
        Asynchronously create the ApplicationInstance

        :param api_version: The API version to use to start a new TwiML session. Can be: `2010-04-01` or `2008-08-01`. The default value is the account's default API version.
        :param voice_url: The URL we should call when the phone number assigned to this application receives a call.
        :param voice_method: The HTTP method we should use to call `voice_url`. Can be: `GET` or `POST`.
        :param voice_fallback_url: The URL that we should call when an error occurs retrieving or executing the TwiML requested by `url`.
        :param voice_fallback_method: The HTTP method we should use to call `voice_fallback_url`. Can be: `GET` or `POST`.
        :param status_callback: The URL we should call using the `status_callback_method` to send status information to your application.
        :param status_callback_method: The HTTP method we should use to call `status_callback`. Can be: `GET` or `POST`.
        :param voice_caller_id_lookup: Whether we should look up the caller's caller-ID name from the CNAM database (additional charges apply). Can be: `true` or `false`.
        :param sms_url: The URL we should call when the phone number receives an incoming SMS message.
        :param sms_method: The HTTP method we should use to call `sms_url`. Can be: `GET` or `POST`.
        :param sms_fallback_url: The URL that we should call when an error occurs while retrieving or executing the TwiML from `sms_url`.
        :param sms_fallback_method: The HTTP method we should use to call `sms_fallback_url`. Can be: `GET` or `POST`.
        :param sms_status_callback: The URL we should call using a POST method to send status information about SMS messages sent by the application.
        :param message_status_callback: The URL we should call using a POST method to send message status information to your application.
        :param friendly_name: A descriptive string that you create to describe the new application. It can be up to 64 characters long.
        :param public_application_connect_enabled: Whether to allow other Twilio accounts to dial this applicaton using Dial verb. Can be: `true` or `false`.

        :returns: The created ApplicationInstance
        rr   rs   rt   ru   rv   rw   rx   ry   rz   r{   r|   r}   r~   r   rq   r   r   r   Nr   r   )r   r   r7   create_asyncrk   r   r.   r   r3   r3   r4   r   |  sX   )	
zApplicationList.create_asyncNlimit	page_sizec                 C   s2   | j ||}| j||d d}| j ||d S )a  
        Streams ApplicationInstance 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 friendly_name: The string that identifies the Application resources to read.
        :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   )r7   read_limitspagestreamr0   r   r   r   limitsr   r3   r3   r4   r     s   zApplicationList.streamc                    s:   | j ||}| j||d dI dH }| j ||d S )a  
        Asynchronously streams ApplicationInstance 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 friendly_name: The string that identifies the Application resources to read.
        :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   )r7   r   
page_asyncstream_asyncr   r3   r3   r4   r     s   zApplicationList.stream_asyncc                 C   s   t | j|||dS )a^  
        Lists ApplicationInstance records from the API as a list.
        Unlike stream(), this operation is eager and will load `limit` records into
        memory before returning.

        :param str friendly_name: The string that identifies the Application resources to read.
        :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   )listr   r0   r   r   r   r3   r3   r4   r     s   zApplicationList.listc                    s(   dd | j |||dI dH 2 I dH S )am  
        Asynchronously lists ApplicationInstance records from the API as a list.
        Unlike stream(), this operation is eager and will load `limit` records into
        memory before returning.

        :param str friendly_name: The string that identifies the Application resources to read.
        :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
        c                    s   g | z3 d H W }|q6 S r_   r3   )rS   recordr3   r3   r4   
<listcomp>.  s
    z.ApplicationList.list_async.<locals>.<listcomp>r   N)r   r   r3   r3   r4   
list_async  s   
zApplicationList.list_async
page_tokenpage_numberc                 C   s8   t ||||d}| jjd| j|d}t| j|| jS )a  
        Retrieve a single page of ApplicationInstance records from the API.
        Request is executed immediately

        :param friendly_name: The string that identifies the Application resources to read.
        :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 ApplicationInstance
        rq   	PageTokenr   PageSizero   rn   r"   params)r   r   r7   r   rk   r   r.   r0   r   r   r   r   r   responser3   r3   r4   r   7  s   	zApplicationList.pagec                    s@   t ||||d}| jjd| j|dI dH }t| j|| jS )a  
        Asynchronously retrieve a single page of ApplicationInstance records from the API.
        Request is executed immediately

        :param friendly_name: The string that identifies the Application resources to read.
        :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 ApplicationInstance
        r   ro   r   N)r   r   r7   r   rk   r   r.   r   r3   r3   r4   r   U  s   	zApplicationList.page_async
target_urlc                 C   s"   | j jjd|}t| j || jS )z
        Retrieve a specific page of ApplicationInstance records from the API.
        Request is executed immediately

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

        :returns: Page of ApplicationInstance
        ro   )r7   domaintwiliorequestr   r.   r0   r   r   r3   r3   r4   get_pageu  s   	zApplicationList.get_pagec                    s*   | j jjd|I dH }t| j || jS )a
  
        Asynchronously retrieve a specific page of ApplicationInstance records from the API.
        Request is executed immediately

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

        :returns: Page of ApplicationInstance
        ro   N)r7   r   r   request_asyncr   r.   r   r3   r3   r4   get_page_async  s   	zApplicationList.get_page_asyncr   c                 C      t | j| jd |dS z
        Constructs a ApplicationContext

        :param sid: The Twilio-provided string that uniquely identifies the Application resource to update.
        r   r)   r6   r7   r.   r0   r   r3   r3   r4   r,     r   zApplicationList.getc                 C   r   r   r   r   r3   r3   r4   __call__  r   zApplicationList.__call__c                 C   r   )rL   z"<Twilio.Api.V2010.ApplicationList>r3   r8   r3   r3   r4   r]     r   zApplicationList.__repr__)!r`   ra   rb   r   rd   r+   r   rg   r   rh   rf   r   r   r   r   intr   r   r	   r   r   r   r   r   r   r   r   r   r6   r,   r   r]   ri   r3   r3   r1   r4   r   #  sv   







	









J







	









J







 




 




 

r   N)rc   r   typingr   r   r   r   r   r   r	   twilio.baser
   r   twilio.base.instance_contextr   twilio.base.instance_resourcer   twilio.base.list_resourcer   twilio.base.versionr   twilio.base.pager   r   r6   r   r   r3   r3   r3   r4   <module>   s     $   u