U
    ^g%i                     @   s   d 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dS )a  
    This code was generated by
   ___ _ _ _ _ _    _ ____    ____ ____ _    ____ ____ _  _ ____ ____ ____ ___ __   __
    |  | | | | |    | |  | __ |  | |__| | __ | __ |___ |\ | |___ |__/ |__|  | |  | |__/
    |  |_|_| | |___ | |__|    |__| |  | |    |__] |___ | \| |___ |  \ |  |  | |__| |  \

    Twilio - Verify
    This is the public Twilio REST API.

    NOTE: This class is auto generated by OpenAPI Generator.
    https://openapi-generator.tech
    Do not edit the class manually.
    )AnyDictOptional)values)InstanceContext)InstanceResource)ListResource)Versionc                       s   e Zd ZG dd deZdeeeef e	e d fddZ
eddd	d
Zd dddZd dddZedddZ  ZS )FormInstancec                   @   s   e Zd ZdZdS )FormInstance.FormTypesz	form-pushN)__name__
__module____qualname__Z	FORM_PUSH r   r   Y/var/www/html/api-medvista/venv/lib/python3.8/site-packages/twilio/rest/verify/v2/form.py	FormTypes   s   r   N)versionpayload	form_typec                    sV   t  | |d| _|d| _|d| _|d| _d|pF| ji| _d | _d S )Nr   forms	form_metaurl)	super__init__getr   r   r   r   	_solution_context)selfr   r   r   	__class__r   r   r   #   s     zFormInstance.__init__FormContextreturnc                 C   s&   | j dkr t| j| 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: FormContext for this FormInstance
        Nr   r   )r   r    _versionr   r   r   r   r   _proxy5   s    
zFormInstance._proxyc                 C   s
   | j  S )U
        Fetch the FormInstance


        :returns: The fetched FormInstance
        )r&   fetchr%   r   r   r   r(   D   s    zFormInstance.fetchc                    s   | j  I dH S )o
        Asynchronous coroutine to fetch the FormInstance


        :returns: The fetched FormInstance
        N)r&   fetch_asyncr%   r   r   r   r*   M   s    zFormInstance.fetch_asyncc                 C   s$   d dd | j D }d|S )f
        Provide a friendly representation

        :returns: Machine friendly representation
         c                 s   s   | ]\}}d  ||V  qdS z{}={}Nformat.0kvr   r   r   	<genexpr>\   s     z(FormInstance.__repr__.<locals>.<genexpr>z"<Twilio.Verify.V2.FormInstance {}>joinr   itemsr/   r   contextr   r   r   __repr__V   s    zFormInstance.__repr__)N)r   r   r   objectr   r	   r   strr   r   r   propertyr&   r(   r*   r:   __classcell__r   r   r   r   r
      s    
		r
   c                       sN   e Zd Zedd fddZedddZeddd	Zedd
dZ	  Z
S )r    r   )r   r   c                    s*   t  | d|i| _djf | j| _dS )z
        Initialize the FormContext

        :param version: Version that contains the resource
        :param form_type: The Type of this Form. Currently only `form-push` is supported.
        r   z/Forms/{form_type}N)r   r   r   r/   _uri)r   r   r   r   r   r   r   b   s
     zFormContext.__init__r!   c                 C   s<   t i }d|d< | jjd| j|d}t| j|| jd dS )r'   application/jsonAcceptGETmethoduriheadersr   r#   )r   ofr$   r(   r?   r
   r   r   rF   r   r   r   r   r(   q   s    
zFormContext.fetchc                    sB   t i }d|d< | jjd| j|dI dH }t| j|| jd dS )r)   r@   rA   rB   rC   Nr   r#   )r   rG   r$   r*   r?   r
   r   rH   r   r   r   r*      s    
  zFormContext.fetch_asyncc                 C   s$   d dd | j D }d|S )r+   r,   c                 s   s   | ]\}}d  ||V  qdS r-   r.   r0   r   r   r   r4      s     z'FormContext.__repr__.<locals>.<genexpr>z!<Twilio.Verify.V2.FormContext {}>r5   r8   r   r   r   r:      s    zFormContext.__repr__)r   r   r   r	   r   r
   r(   r*   r<   r:   r>   r   r   r   r   r    `   s   r    c                       sP   e Zd Zed fddZdedddZdeddd	Zed
ddZ	  Z
S )FormList)r   c                    s   t  | dS )zf
        Initialize the FormList

        :param version: Version that contains the resource

        N)r   r   )r   r   r   r   r   r      s    zFormList.__init__r   )r   r"   c                 C   s   t | j|dS z
        Constructs a FormContext

        :param form_type: The Type of this Form. Currently only `form-push` is supported.
        r#   r    r$   r   r   r   r   r   r      s    zFormList.getc                 C   s   t | j|dS rJ   rK   rL   r   r   r   __call__   s    zFormList.__call__r!   c                 C   s   dS )r+   z<Twilio.Verify.V2.FormList>r   r%   r   r   r   r:      s    zFormList.__repr__)r   r   r   r	   r   r    r   rM   r<   r:   r>   r   r   r   r   rI      s   	rI   N)__doc__typingr   r   r   Ztwilio.baser   Ztwilio.base.instance_contextr   Ztwilio.base.instance_resourcer   Ztwilio.base.list_resourcer   Ztwilio.base.versionr	   r
   r    rI   r   r   r   r   <module>   s   IE