o
    f>h&                     @   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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 - Messaging
    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                -       sx  e Zd ZG dd deZG dd deZ	 	d3dedeee	f de
e f fd	d
Zed4ddZdefddZdefddZd5ddZd5d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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 ef deeef deeef deee ef ded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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 ef deeef deeef deee ef ded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/d0Zdefd1d2Z  ZS )6TollfreeVerificationInstancec                   @   s(   e Zd ZdZdZdZdZdZdZdZ	dS )	&TollfreeVerificationInstance.OptInTypeVERBALWEB_FORM
PAPER_FORMVIA_TEXTMOBILE_QR_CODEIMPORTIMPORT_PLEASE_REPLACEN)
__name__
__module____qualname__r   r   r   r   r   r   r    r   r   a/var/www/html/venv/lib/python3.10/site-packages/twilio/rest/messaging/v1/tollfree_verification.py	OptInType   s    r    c                   @   s   e Zd ZdZdZdZdZdS )#TollfreeVerificationInstance.StatusPENDING_REVIEW	IN_REVIEWTWILIO_APPROVEDTWILIO_REJECTEDN)r   r   r   r"   r#   r$   r%   r   r   r   r   Status$   s
    r&   Nversionpayloadsidc                    s  t  | |d| _|d| _|d| _|d| _t|d| _	t|d| _
|d| _|d| _|d	| _|d
| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _|d| _ |d| _!|d| _"|d| _#t$|d | _%t|d!| _&|d"| _'|d#| _(|d$| _)|d%| _*d|p| ji| _+d | _,d S )&Nr)   account_sidcustomer_profile_sidtrust_product_siddate_createddate_updatedregulated_item_sidbusiness_namebusiness_street_addressbusiness_street_address2business_citybusiness_state_province_regionbusiness_postal_codebusiness_countrybusiness_websitebusiness_contact_first_namebusiness_contact_last_namebusiness_contact_emailbusiness_contact_phonenotification_emailuse_case_categoriesuse_case_summaryproduction_message_sampleopt_in_image_urlsopt_in_typemessage_volumeadditional_informationtollfree_phone_number_sidstatusurlrejection_reason
error_codeedit_expirationedit_allowedrejection_reasonsresource_linksexternal_reference_id)-super__init__getr)   r*   r+   r,   r
   iso8601_datetimer-   r.   r/   r0   r1   r2   r3   r4   r5   r6   r7   r8   r9   r:   r;   r<   r=   r>   r?   r@   rA   rB   rC   rD   rE   rF   rG   integerrH   rI   rJ   rK   rL   rM   	_solution_context)selfr'   r(   r)   	__class__r   r   rO   R   s   

z%TollfreeVerificationInstance.__init__returnTollfreeVerificationContextc                 C   s&   | j du rt| j| jd d| _ | j S )a  
        Generate an instance context for the instance, the context is capable of
        performing various actions. All instance actions are proxied to the context

        :returns: TollfreeVerificationContext for this TollfreeVerificationInstance
        Nr)   r)   )rT   rY   _versionrS   rU   r   r   r   _proxy   s   
z#TollfreeVerificationInstance._proxyc                 C   
   | j  S )w
        Deletes the TollfreeVerificationInstance


        :returns: True if delete succeeds, False otherwise
        )r]   deleter\   r   r   r   r`         
z#TollfreeVerificationInstance.deletec                       | j  I dH S )
        Asynchronous coroutine that deletes the TollfreeVerificationInstance


        :returns: True if delete succeeds, False otherwise
        N)r]   delete_asyncr\   r   r   r   rd         z)TollfreeVerificationInstance.delete_asyncc                 C   r^   )u
        Fetch the TollfreeVerificationInstance


        :returns: The fetched TollfreeVerificationInstance
        )r]   fetchr\   r   r   r   rg      ra   z"TollfreeVerificationInstance.fetchc                    rb   )
        Asynchronous coroutine to fetch the TollfreeVerificationInstance


        :returns: The fetched TollfreeVerificationInstance
        N)r]   fetch_asyncr\   r   r   r   ri      re   z(TollfreeVerificationInstance.fetch_asyncr0   r7   r<   r=   r>   r?   r@   rA   r   rB   r1   r2   r3   r4   r5   r6   rC   r8   r9   r:   r;   edit_reasonc                 C   s   | j jdi d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|d|d|d|d|d|d|d|S )2
  
        Update the TollfreeVerificationInstance

        :param business_name: The name of the business or organization using the Tollfree number.
        :param business_website: The website of the business or organization using the Tollfree number.
        :param notification_email: The email address to receive the notification about the verification result. .
        :param use_case_categories: The category of the use case for the Tollfree Number. List as many are applicable..
        :param use_case_summary: Use this to further explain how messaging is used by the business or organization.
        :param production_message_sample: An example of message content, i.e. a sample message.
        :param opt_in_image_urls: Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
        :param opt_in_type:
        :param message_volume: Estimate monthly volume of messages from the Tollfree Number.
        :param business_street_address: The address of the business or organization using the Tollfree number.
        :param business_street_address2: The address of the business or organization using the Tollfree number.
        :param business_city: The city of the business or organization using the Tollfree number.
        :param business_state_province_region: The state/province/region of the business or organization using the Tollfree number.
        :param business_postal_code: The postal code of the business or organization using the Tollfree number.
        :param business_country: The country of the business or organization using the Tollfree number.
        :param additional_information: Additional information to be provided for verification.
        :param business_contact_first_name: The first name of the contact for the business or organization using the Tollfree number.
        :param business_contact_last_name: The last name of the contact for the business or organization using the Tollfree number.
        :param business_contact_email: The email address of the contact for the business or organization using the Tollfree number.
        :param business_contact_phone: The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
        :param edit_reason: Describe why the verification is being edited. If the verification was rejected because of a technical issue, such as the website being down, and the issue has been resolved this parameter should be set to something similar to 'Website fixed'.

        :returns: The updated TollfreeVerificationInstance
        r0   r7   r<   r=   r>   r?   r@   rA   rB   r1   r2   r3   r4   r5   r6   rC   r8   r9   r:   r;   rj   Nr   )r]   updaterU   r0   r7   r<   r=   r>   r?   r@   rA   rB   r1   r2   r3   r4   r5   r6   rC   r8   r9   r:   r;   rj   r   r   r   rl      sV   5	
z#TollfreeVerificationInstance.updatec                    s   | j jdi d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|d|d|d|d|d|d|d|I dH S )L
  
        Asynchronous coroutine to update the TollfreeVerificationInstance

        :param business_name: The name of the business or organization using the Tollfree number.
        :param business_website: The website of the business or organization using the Tollfree number.
        :param notification_email: The email address to receive the notification about the verification result. .
        :param use_case_categories: The category of the use case for the Tollfree Number. List as many are applicable..
        :param use_case_summary: Use this to further explain how messaging is used by the business or organization.
        :param production_message_sample: An example of message content, i.e. a sample message.
        :param opt_in_image_urls: Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
        :param opt_in_type:
        :param message_volume: Estimate monthly volume of messages from the Tollfree Number.
        :param business_street_address: The address of the business or organization using the Tollfree number.
        :param business_street_address2: The address of the business or organization using the Tollfree number.
        :param business_city: The city of the business or organization using the Tollfree number.
        :param business_state_province_region: The state/province/region of the business or organization using the Tollfree number.
        :param business_postal_code: The postal code of the business or organization using the Tollfree number.
        :param business_country: The country of the business or organization using the Tollfree number.
        :param additional_information: Additional information to be provided for verification.
        :param business_contact_first_name: The first name of the contact for the business or organization using the Tollfree number.
        :param business_contact_last_name: The last name of the contact for the business or organization using the Tollfree number.
        :param business_contact_email: The email address of the contact for the business or organization using the Tollfree number.
        :param business_contact_phone: The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
        :param edit_reason: Describe why the verification is being edited. If the verification was rejected because of a technical issue, such as the website being down, and the issue has been resolved this parameter should be set to something similar to 'Website fixed'.

        :returns: The updated TollfreeVerificationInstance
        r0   r7   r<   r=   r>   r?   r@   rA   rB   r1   r2   r3   r4   r5   r6   rC   r8   r9   r:   r;   rj   Nr   )r]   update_asyncrm   r   r   r   ro   $  sX   5	

z)TollfreeVerificationInstance.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vr   r   r   	<genexpr>w      z8TollfreeVerificationInstance.__repr__.<locals>.<genexpr>z5<Twilio.Messaging.V1.TollfreeVerificationInstance {}>joinrS   itemsrv   rU   contextr   r   r   __repr__q     
z%TollfreeVerificationInstance.__repr__N)rX   rY   )rX   r   )r   r   r   objectr    r&   r   r   strr   r   rO   propertyr]   boolr`   rd   rg   ri   r   unsetr   r   rl   ro   r   __classcell__r   r   rV   r   r      s6   	)
R	
	
	




	













O




	













Mr   c                -       s<  e Zd Z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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 ef deeef deeef deee ef ded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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 ef deeef deeef deee ef ded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 )*rY   r'   r)   c                    s.   t  | d|i| _djdi | j| _dS )z
        Initialize the TollfreeVerificationContext

        :param version: Version that contains the resource
        :param sid: The unique string to identify Tollfree Verification.
        r)   z/Tollfree/Verifications/{sid}Nr   )rN   rO   rS   rv   _uri)rU   r'   r)   rV   r   r   rO   }  s   z$TollfreeVerificationContext.__init__rX   c                 C   s   t i }| jjd| j|dS )r_   DELETEmethoduriheaders)r   ofr[   r`   r   rU   r   r   r   r   r`     s   
z"TollfreeVerificationContext.deletec                    s&   t i }| jjd| j|dI dH S )rc   r   r   N)r   r   r[   rd   r   r   r   r   r   rd     s
   
z(TollfreeVerificationContext.delete_asyncc                 C   s<   t i }d|d< | jjd| j|d}t| j|| jd dS )rf   application/jsonAcceptGETr   r)   rZ   )r   r   r[   rg   r   r   rS   rU   r   r(   r   r   r   rg     s   
z!TollfreeVerificationContext.fetchc                    sD   t i }d|d< | jjd| j|dI dH }t| j|| jd dS )rh   r   r   r   r   Nr)   rZ   )r   r   r[   ri   r   r   rS   r   r   r   r   ri     s   
z'TollfreeVerificationContext.fetch_asyncr0   r7   r<   r=   r>   r?   r@   rA   r   rB   r1   r2   r3   r4   r5   r6   rC   r8   r9   r:   r;   rj   c              	   C   s   t i d|d|d|dt|dd d|d|d	t|d
d d|d|	d|
d|d|d|d|d|d|d|||||d}t i }d|d< d|d< | jjd| j||d}t| j|| jd dS )rk   BusinessNameBusinessWebsiteNotificationEmailUseCaseCategoriesc                 S      | S r   r   er   r   r   <lambda>      z4TollfreeVerificationContext.update.<locals>.<lambda>UseCaseSummaryProductionMessageSampleOptInImageUrlsc                 S   r   r   r   r   r   r   r   r     r   r    MessageVolumeBusinessStreetAddressBusinessStreetAddress2BusinessCityBusinessStateProvinceRegionBusinessPostalCodeBusinessCountryAdditionalInformationBusinessContactFirstNameBusinessContactLastNameBusinessContactEmailBusinessContactPhone
EditReason!application/x-www-form-urlencodedContent-Typer   r   POSTr   r   datar   r)   rZ   )	r   r   r   mapr[   rl   r   r   rS   rU   r0   r7   r<   r=   r>   r?   r@   rA   rB   r1   r2   r3   r4   r5   r6   rC   r8   r9   r:   r;   rj   r   r   r(   r   r   r   rl     sf   6	


z"TollfreeVerificationContext.updatec              	      s   t i d|d|d|dt|dd d|d|d	t|d
d d|d|	d|
d|d|d|d|d|d|d|||||d}t i }d|d< d|d< | jjd| j||dI dH }t| j|| jd dS )rn   r   r   r   r   c                 S   r   r   r   r   r   r   r   r   h  r   z:TollfreeVerificationContext.update_async.<locals>.<lambda>r   r   r   c                 S   r   r   r   r   r   r   r   r   k  r   r    r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   Nr)   rZ   )	r   r   r   r   r[   ro   r   r   rS   r   r   r   r   ro   -  sh   6	


z(TollfreeVerificationContext.update_asyncc                 C   rp   )rq   rr   c                 s   rs   rt   ru   rw   r   r   r   r{     r|   z7TollfreeVerificationContext.__repr__.<locals>.<genexpr>z4<Twilio.Messaging.V1.TollfreeVerificationContext {}>r}   r   r   r   r   r     r   z$TollfreeVerificationContext.__repr__)r   r   r   r   r   rO   r   r`   rd   r   rg   ri   r   r   r   r   r   rl   ro   r   r   r   r   rV   r   rY   {  s   




	













_




	













]rY   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 )TollfreeVerificationPager(   rX   c                 C   s   t | j|S )zz
        Build an instance of TollfreeVerificationInstance

        :param payload: Payload response from the API
        )r   r[   )rU   r(   r   r   r   get_instance  s   z%TollfreeVerificationPage.get_instancec                 C      dS )rq   z.<Twilio.Messaging.V1.TollfreeVerificationPage>r   r\   r   r   r   r        z!TollfreeVerificationPage.__repr__N)	r   r   r   r   r   r   r   r   r   r   r   r   r   r     s    r   c                1       s8  e Zd Z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fdedededee ded	ed
ee dddede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f0d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fdedededee ded	ed
ee dddede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f0dd Zejejejejd!d!fde	ee
f d"e	d#e
f de	ee
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d!d!fde	ee
f d"e	d#e
f de	ee
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d!d!fde	ee
f d"e	d#e
f de	ee
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d!d!fde	ee
f d"e	d#e
f de	ee
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ejejejfde	ee
f d"e	d#e
f de	ee
f d$e	ee
f d/e	ee
f d0e	ee
f d&e	ee
f defd1d2Zejejejejejejejfde	ee
f d"e	d#e
f de	ee
f d$e	ee
f d/e	ee
f d0e	ee
f d&e	ee
f defd3d4Zd5edefd6d7Zd5edefd8d9Zd:edefd;d<Zd:edefd=d>Zdefd?d@Z  Z S )ATollfreeVerificationListr'   c                    s   t  | d| _dS )zv
        Initialize the TollfreeVerificationList

        :param version: Version that contains the resource

        z/Tollfree/VerificationsN)rN   rO   r   )rU   r'   rV   r   r   rO     s   
z!TollfreeVerificationList.__init__r0   r7   r<   r=   r>   r?   r@   rA   r   rB   rD   r+   r1   r2   r3   r4   r5   r6   rC   r8   r9   r:   r;   rM   rX   c              
   C   s   t i d|d|d|dt|dd d|d|d	t|d
d d|d|	d|
d|d|d|d|d|d|d|||||||d}t ddi}d|d< d|d< | jjd| j||d}t| j|S )a_
  
        Create the TollfreeVerificationInstance

        :param business_name: The name of the business or organization using the Tollfree number.
        :param business_website: The website of the business or organization using the Tollfree number.
        :param notification_email: The email address to receive the notification about the verification result. .
        :param use_case_categories: The category of the use case for the Tollfree Number. List as many are applicable..
        :param use_case_summary: Use this to further explain how messaging is used by the business or organization.
        :param production_message_sample: An example of message content, i.e. a sample message.
        :param opt_in_image_urls: Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
        :param opt_in_type:
        :param message_volume: Estimate monthly volume of messages from the Tollfree Number.
        :param tollfree_phone_number_sid: The SID of the Phone Number associated with the Tollfree Verification.
        :param customer_profile_sid: Customer's Profile Bundle BundleSid.
        :param business_street_address: The address of the business or organization using the Tollfree number.
        :param business_street_address2: The address of the business or organization using the Tollfree number.
        :param business_city: The city of the business or organization using the Tollfree number.
        :param business_state_province_region: The state/province/region of the business or organization using the Tollfree number.
        :param business_postal_code: The postal code of the business or organization using the Tollfree number.
        :param business_country: The country of the business or organization using the Tollfree number.
        :param additional_information: Additional information to be provided for verification.
        :param business_contact_first_name: The first name of the contact for the business or organization using the Tollfree number.
        :param business_contact_last_name: The last name of the contact for the business or organization using the Tollfree number.
        :param business_contact_email: The email address of the contact for the business or organization using the Tollfree number.
        :param business_contact_phone: The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
        :param external_reference_id: An optional external reference ID supplied by customer and echoed back on status retrieval.

        :returns: The created TollfreeVerificationInstance
        r   r   r   r   c                 S   r   r   r   r   r   r   r   r     r   z1TollfreeVerificationList.create.<locals>.<lambda>r   r   r   c                 S   r   r   r   r   r   r   r   r     r   r    r   TollfreePhoneNumberSidCustomerProfileSidr   r   r   r   r   r   r   r   r   r   r   ExternalReferenceIdr   r   r   r   r   r   )r   r   r   r   r[   creater   r   rU   r0   r7   r<   r=   r>   r?   r@   rA   rB   rD   r+   r1   r2   r3   r4   r5   r6   rC   r8   r9   r:   r;   rM   r   r   r(   r   r   r   r     sf   8	

zTollfreeVerificationList.createc              
      s   t i d|d|d|dt|dd d|d|d	t|d
d d|d|	d|
d|d|d|d|d|d|d|||||||d}t ddi}d|d< d|d< | jjd| j||dI dH }t| j|S )an
  
        Asynchronously create the TollfreeVerificationInstance

        :param business_name: The name of the business or organization using the Tollfree number.
        :param business_website: The website of the business or organization using the Tollfree number.
        :param notification_email: The email address to receive the notification about the verification result. .
        :param use_case_categories: The category of the use case for the Tollfree Number. List as many are applicable..
        :param use_case_summary: Use this to further explain how messaging is used by the business or organization.
        :param production_message_sample: An example of message content, i.e. a sample message.
        :param opt_in_image_urls: Link to an image that shows the opt-in workflow. Multiple images allowed and must be a publicly hosted URL.
        :param opt_in_type:
        :param message_volume: Estimate monthly volume of messages from the Tollfree Number.
        :param tollfree_phone_number_sid: The SID of the Phone Number associated with the Tollfree Verification.
        :param customer_profile_sid: Customer's Profile Bundle BundleSid.
        :param business_street_address: The address of the business or organization using the Tollfree number.
        :param business_street_address2: The address of the business or organization using the Tollfree number.
        :param business_city: The city of the business or organization using the Tollfree number.
        :param business_state_province_region: The state/province/region of the business or organization using the Tollfree number.
        :param business_postal_code: The postal code of the business or organization using the Tollfree number.
        :param business_country: The country of the business or organization using the Tollfree number.
        :param additional_information: Additional information to be provided for verification.
        :param business_contact_first_name: The first name of the contact for the business or organization using the Tollfree number.
        :param business_contact_last_name: The last name of the contact for the business or organization using the Tollfree number.
        :param business_contact_email: The email address of the contact for the business or organization using the Tollfree number.
        :param business_contact_phone: The E.164 formatted phone number of the contact for the business or organization using the Tollfree number.
        :param external_reference_id: An optional external reference ID supplied by customer and echoed back on status retrieval.

        :returns: The created TollfreeVerificationInstance
        r   r   r   r   c                 S   r   r   r   r   r   r   r   r   P  r   z7TollfreeVerificationList.create_async.<locals>.<lambda>r   r   r   c                 S   r   r   r   r   r   r   r   r   S  r   r    r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   N)r   r   r   r   r[   create_asyncr   r   r   r   r   r   r     sh   8	

z%TollfreeVerificationList.create_asyncNrE   r!   include_sub_accountslimit	page_sizec           	      C   s8   | j ||}| j|||||d d}| j ||d S )aH  
        Streams TollfreeVerificationInstance 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 tollfree_phone_number_sid: The SID of the Phone Number associated with the Tollfree Verification.
        :param &quot;TollfreeVerificationInstance.Status&quot; status: The compliance status of the Tollfree Verification record.
        :param str external_reference_id: Customer supplied reference id for the Tollfree Verification record.
        :param bool include_sub_accounts: Whether to include Tollfree Verifications from sub accounts in list response.
        :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   rD   rE   rM   r   r   r   )r[   read_limitspagestream	rU   rD   rE   rM   r   r   r   limitsr   r   r   r   r   r  s   zTollfreeVerificationList.streamc           	         s@   | j ||}| j|||||d dI dH }| j ||d S )aW  
        Asynchronously streams TollfreeVerificationInstance 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 tollfree_phone_number_sid: The SID of the Phone Number associated with the Tollfree Verification.
        :param &quot;TollfreeVerificationInstance.Status&quot; status: The compliance status of the Tollfree Verification record.
        :param str external_reference_id: Customer supplied reference id for the Tollfree Verification record.
        :param bool include_sub_accounts: Whether to include Tollfree Verifications from sub accounts in list response.
        :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   )r[   r   
page_asyncstream_asyncr   r   r   r   r     s   z%TollfreeVerificationList.stream_asyncc              	   C   s   t | j||||||dS )a  
        Lists TollfreeVerificationInstance records from the API as a list.
        Unlike stream(), this operation is eager and will load `limit` records into
        memory before returning.

        :param str tollfree_phone_number_sid: The SID of the Phone Number associated with the Tollfree Verification.
        :param &quot;TollfreeVerificationInstance.Status&quot; status: The compliance status of the Tollfree Verification record.
        :param str external_reference_id: Customer supplied reference id for the Tollfree Verification record.
        :param bool include_sub_accounts: Whether to include Tollfree Verifications from sub accounts in list response.
        :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
        rD   rE   rM   r   r   r   )listr   rU   rD   rE   rM   r   r   r   r   r   r   r     s   zTollfreeVerificationList.listc              	      s.   dd | j ||||||dI dH 2 I dH S )a  
        Asynchronously lists TollfreeVerificationInstance records from the API as a list.
        Unlike stream(), this operation is eager and will load `limit` records into
        memory before returning.

        :param str tollfree_phone_number_sid: The SID of the Phone Number associated with the Tollfree Verification.
        :param &quot;TollfreeVerificationInstance.Status&quot; status: The compliance status of the Tollfree Verification record.
        :param str external_reference_id: Customer supplied reference id for the Tollfree Verification record.
        :param bool include_sub_accounts: Whether to include Tollfree Verifications from sub accounts in list response.
        :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   r   )rx   recordr   r   r   
<listcomp>  s
    z7TollfreeVerificationList.list_async.<locals>.<listcomp>r   N)r   r   r   r   r   
list_async  s   
z#TollfreeVerificationList.list_async
page_tokenpage_numberc              
   C   sX   t |||t||||d}t ddi}	d|	d< | jjd| j||	d}
t| j|
S )a.  
        Retrieve a single page of TollfreeVerificationInstance records from the API.
        Request is executed immediately

        :param tollfree_phone_number_sid: The SID of the Phone Number associated with the Tollfree Verification.
        :param status: The compliance status of the Tollfree Verification record.
        :param external_reference_id: Customer supplied reference id for the Tollfree Verification record.
        :param include_sub_accounts: Whether to include Tollfree Verifications from sub accounts in list response.
        :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 TollfreeVerificationInstance
        r   r&   r   IncludeSubAccounts	PageTokenr   PageSizer   r   r   r   r   r   r   paramsr   )r   r   r   boolean_to_stringr[   r   r   r   rU   rD   rE   rM   r   r   r   r   r   r   responser   r   r   r     s    
zTollfreeVerificationList.pagec              
      s`   t |||t||||d}t ddi}	d|	d< | jjd| j||	dI dH }
t| j|
S )	a=  
        Asynchronously retrieve a single page of TollfreeVerificationInstance records from the API.
        Request is executed immediately

        :param tollfree_phone_number_sid: The SID of the Phone Number associated with the Tollfree Verification.
        :param status: The compliance status of the Tollfree Verification record.
        :param external_reference_id: Customer supplied reference id for the Tollfree Verification record.
        :param include_sub_accounts: Whether to include Tollfree Verifications from sub accounts in list response.
        :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 TollfreeVerificationInstance
        r   r   r   r   r   r   r   N)r   r   r   r   r[   r   r   r   r   r   r   r   r   :  s"   
z#TollfreeVerificationList.page_async
target_urlc                 C   s   | j jjd|}t| j |S )a  
        Retrieve a specific page of TollfreeVerificationInstance records from the API.
        Request is executed immediately

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

        :returns: Page of TollfreeVerificationInstance
        r   )r[   domaintwiliorequestr   rU   r   r   r   r   r   get_pageg  s   	z!TollfreeVerificationList.get_pagec                    s&   | j jjd|I dH }t| j |S )a  
        Asynchronously retrieve a specific page of TollfreeVerificationInstance records from the API.
        Request is executed immediately

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

        :returns: Page of TollfreeVerificationInstance
        r   N)r[   r   r   request_asyncr   r   r   r   r   get_page_asyncs  s   	z'TollfreeVerificationList.get_page_asyncr)   c                 C      t | j|dS z
        Constructs a TollfreeVerificationContext

        :param sid: The unique string to identify Tollfree Verification.
        rZ   rY   r[   rU   r)   r   r   r   rP        zTollfreeVerificationList.getc                 C   r   r   r   r   r   r   r   __call__  r   z!TollfreeVerificationList.__call__c                 C   r   )rq   z.<Twilio.Messaging.V1.TollfreeVerificationList>r   r\   r   r   r   r     r   z!TollfreeVerificationList.__repr__)!r   r   r   r   rO   r   r   r   r   r   r   r   r   r   r   r   intr   r   r	   r   r   r   r   r   r   r   r   rY   rP   r   r   r   r   r   rV   r   r     s   	














k	














a




)




)




(




)






	
/






	
-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   rY   r   r   r   r   r   r   <module>   s"    $  d  