
    d{i*                         d Z ddlmZ ddl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e      Z G d de      Z G d de      Zy)a  
    This code was generated by
   ___ _ _ _ _ _    _ ____    ____ ____ _    ____ ____ _  _ ____ ____ ____ ___ __   __
    |  | | | | |    | |  | __ |  | |__| | __ | __ |___ |\ | |___ |__/ |__|  | |  | |__/
    |  |_|_| | |___ | |__|    |__| |  | |    |__] |___ | \| |___ |  \ |  |  | |__| |  \

    Twilio - Flex
    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OptionalUnion)deserializevalues)ApiResponse)InstanceContext)InstanceResource)ListResource)Versionc                   *    e Zd ZdZ	 ddedeeef   dee   f fdZ	e
dd       Zej                  fdeeef   dd fd	Zej                  fdeeef   dd fd
Zej                  fdeeef   defdZej                  fdeeef   defdZdefdZ xZS )PluginArchiveInstancea  
    :ivar sid: The unique string that we created to identify the Flex Plugin resource.
    :ivar account_sid: The SID of the [Account](https://www.twilio.com/docs/iam/api/account) that created the Flex Plugin resource and owns this resource.
    :ivar unique_name: The name that uniquely identifies this Flex Plugin resource.
    :ivar friendly_name: The friendly name this Flex Plugin resource.
    :ivar description: A descriptive string that you create to describe the plugin resource. It can be up to 500 characters long
    :ivar archived: Whether the Flex Plugin is archived. The default value is false.
    :ivar date_created: The date and time in GMT when the Flex Plugin was created specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
    :ivar date_updated: The date and time in GMT when the Flex Plugin was last updated specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format.
    :ivar url: The absolute URL of the Flex Plugin resource.
    versionpayloadsidc                 8   t         |   |       |j                  d      | _        |j                  d      | _        |j                  d      | _        |j                  d      | _        |j                  d      | _        |j                  d      | _        t        j                  |j                  d            | _        t        j                  |j                  d            | _        |j                  d	      | _        d|xs | j                  i| _        d | _        y )
Nr   account_sidunique_namefriendly_namedescriptionarchiveddate_createddate_updatedurl)super__init__getr   r   r   r   r   r   r   iso8601_datetimer   r   r   	_solution_context)selfr   r   r   	__class__s       d/home/sas/my/fyp/ringai/.venv/lib/python3.12/site-packages/twilio/rest/flex_api/v1/plugin_archive.pyr   zPluginArchiveInstance.__init__&   s     	!")++e"4*1++m*D*1++m*D,3KK,H*1++m*D(/J(?0;0L0LKK'1
 1<0L0LKK'1
 #*++e"4 3?$((
 9=    returnc                     | j                   )t        | j                  | j                  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: PluginArchiveContext for this PluginArchiveInstance
        r   r   )r"   PluginArchiveContext_versionr!   r#   s    r%   _proxyzPluginArchiveInstance._proxy>   s9     == 0NN5)DM }}r&   flex_metadatac                 :    | j                   j                  |      S )
        Update the PluginArchiveInstance

        :param flex_metadata: The Flex-Metadata HTTP request header

        :returns: The updated PluginArchiveInstance
        r.   )r-   updater#   r.   s     r%   r2   zPluginArchiveInstance.updateM   s#     {{!!' " 
 	
r&   c                 V   K   | j                   j                  |       d{   S 7 w)
        Asynchronous coroutine to update the PluginArchiveInstance

        :param flex_metadata: The Flex-Metadata HTTP request header

        :returns: The updated PluginArchiveInstance
        r1   N)r-   update_asyncr3   s     r%   r6   z"PluginArchiveInstance.update_async[   s1      [[--' . 
 
 	
 
    )')c                 :    | j                   j                  |      S )z
        Update the PluginArchiveInstance with HTTP info

        :param flex_metadata: The Flex-Metadata HTTP request header

        :returns: ApiResponse with instance, status code, and headers
        r1   )r-   update_with_http_infor3   s     r%   r9   z+PluginArchiveInstance.update_with_http_infoi   s#     {{00' 1 
 	
r&   c                 V   K   | j                   j                  |       d{   S 7 w)z
        Asynchronous coroutine to update the PluginArchiveInstance with HTTP info

        :param flex_metadata: The Flex-Metadata HTTP request header

        :returns: ApiResponse with instance, status code, and headers
        r1   N)r-   update_with_http_info_asyncr3   s     r%   r;   z1PluginArchiveInstance.update_with_http_info_asyncw   s1      [[<<' = 
 
 	
 
r7   c                     dj                  d | j                  j                         D              }dj                  |      S )f
        Provide a friendly representation

        :returns: Machine friendly representation
         c              3   F   K   | ]  \  }}d j                  ||        ywz{}={}Nformat.0kvs      r%   	<genexpr>z1PluginArchiveInstance.__repr__.<locals>.<genexpr>        SDAq7>>!Q/S   !z,<Twilio.FlexApi.V1.PluginArchiveInstance {}>joinr!   itemsrB   r#   contexts     r%   __repr__zPluginArchiveInstance.__repr__   s6     ((SDNN<P<P<RSS=DDWMMr&   )N)r'   r*   )__name__
__module____qualname____doc__r   r   strr   r   r   propertyr-   r	   unsetr   objectr2   r6   r
   r9   r;   rO   __classcell__r$   s   @r%   r   r      s    
 OS==)-c3h=>Fsm=0   39,,
"3;/
	 
 39,,
"3;/
	 
 39,,
"3;/
	
 39,,
"3;/
	
N# Nr&   r   c                   `    e Zd Zdedef fdZej                  fdeee	f   de
fdZej                  fdeee	f   defdZej                  fdeee	f   defdZej                  fdeee	f   de
fd	Zej                  fdeee	f   defd
Zej                  fdeee	f   defdZdefdZ xZS )r*   r   r   c                 x    t         |   |       d|i| _         dj                  di | j                  | _        y)z
        Initialize the PluginArchiveContext

        :param version: Version that contains the resource
        :param sid: The SID of the Flex Plugin resource to archive.
        r   z$/PluginService/Plugins/{sid}/ArchiveN )r   r   r!   rB   _uri)r#   r   r   r$   s      r%   r   zPluginArchiveContext.__init__   sA     	! 3
 B:AASDNNS	r&   r.   r'   c                    t        j                  i       }t        j                  i       }|t         j                  u st        |t              r|r||d<   d|d<   | j
                  j                  d| j                  ||      S )z{
        Internal helper for update operation

        Returns:
            tuple: (payload, status_code, headers)
        Flex-Metadataapplication/jsonAcceptPOSTmethoduridataheaders)r	   ofrV   
isinstancerT   r+   update_with_response_infor]   r#   r.   rf   rg   s       r%   _updatezPluginArchiveContext._update   su     yy}))B- V\\)=#.}'4GO$.}}66tyytW 7 
 	
r&   c                 x    | j                  |      \  }}}t        | j                  || j                  d         S )r0   r1   r   r)   )rl   r   r+   r!   r#   r.   r   _s       r%   r2   zPluginArchiveContext.update   s7     =AA$T]]GPUAVWWr&   c                     | j                  |      \  }}}t        | j                  || j                  d         }t	        |||      S )z
        Update the PluginArchiveInstance and return response metadata

        :param flex_metadata: The Flex-Metadata HTTP request header

        :returns: ApiResponse with instance, status code, and headers
        r1   r   r)   rf   status_coderg   )rl   r   r+   r!   r
   r#   r.   r   rr   rg   instances         r%   r9   z*PluginArchiveContext.update_with_http_info   sJ     )-=(Q%g(MM7u(=
 k7SSr&   c                    K   t        j                  i       }t        j                  i       }|t         j                  u st        |t              r|r||d<   d|d<   | j
                  j                  d| j                  ||       d{   S 7 w)z
        Internal async helper for update operation

        Returns:
            tuple: (payload, status_code, headers)
        r_   r`   ra   rb   rc   N)r	   rh   rV   ri   rT   r+   update_with_response_info_asyncr]   rk   s       r%   _update_asyncz"PluginArchiveContext._update_async   s      yy}))B- V\\)=#.}'4GO$.]]BBtyytW C 
 
 	
 
s   BBBBc                    K   | j                  |       d{   \  }}}t        | j                  || j                  d         S 7 -w)r5   r1   Nr   r)   )rw   r   r+   r!   rn   s       r%   r6   z!PluginArchiveContext.update_async   sG      #00}0MMA$T]]GPUAVWW Ns   AA.Ac                    K   | j                  |       d{   \  }}}t        | j                  || j                  d         }t	        |||      S 7 ;w)z
        Asynchronous coroutine to update the PluginArchiveInstance and return response metadata

        :param flex_metadata: The Flex-Metadata HTTP request header

        :returns: ApiResponse with instance, status code, and headers
        r1   Nr   r)   rq   )rw   r   r+   r!   r
   rs   s         r%   r;   z0PluginArchiveContext.update_with_http_info_async   sc      /3.@.@' /A /
 )
%g )MM7u(=
 k7SS)
s   AA<Ac                     dj                  d | j                  j                         D              }dj                  |      S )r=   r>   c              3   F   K   | ]  \  }}d j                  ||        ywr@   rA   rC   s      r%   rG   z0PluginArchiveContext.__repr__.<locals>.<genexpr>  rH   rI   z+<Twilio.FlexApi.V1.PluginArchiveContext {}>rJ   rM   s     r%   rO   zPluginArchiveContext.__repr__  s6     ((SDNN<P<P<RSS<CCGLLr&   )rP   rQ   rR   r   rT   r   r	   rV   r   rW   tuplerl   r   r2   r
   r9   rw   r6   r;   rO   rX   rY   s   @r%   r*   r*      s   T Tc T ;A,, 
U3;%7 
5 
0 39,,X"3;/X	X 39,,T"3;/T	T" 39,,
"3;/
	
4 39,,X"3;/X	X 39,,T"3;/T	T$M# Mr&   r*   c                   P     e Zd Zdef fdZdedefdZdedefdZdefdZ	 xZ
S )PluginArchiveListr   c                 $    t         |   |       y)zo
        Initialize the PluginArchiveList

        :param version: Version that contains the resource

        N)r   r   )r#   r   r$   s     r%   r   zPluginArchiveList.__init__  s     	!r&   r   r'   c                 0    t        | j                  |      S zx
        Constructs a PluginArchiveContext

        :param sid: The SID of the Flex Plugin resource to archive.
        r)   r*   r+   r#   r   s     r%   r   zPluginArchiveList.get!       $DMMs;;r&   c                 0    t        | j                  |      S r   r   r   s     r%   __call__zPluginArchiveList.__call__)  r   r&   c                      y)r=   z%<Twilio.FlexApi.V1.PluginArchiveList>r\   r,   s    r%   rO   zPluginArchiveList.__repr__1  s     7r&   )rP   rQ   rR   r   r   rT   r*   r   r   rO   rX   rY   s   @r%   r~   r~     sC    " "<s <3 <<C <$8 <7# 7r&   r~   N)rS   r   typingr   r   r   r   twilio.baser   r	   twilio.base.api_responser
   twilio.base.instance_contextr   twilio.base.instance_resourcer   twilio.base.list_resourcer   twilio.base.versionr   r   r*   r~   r\   r&   r%   <module>r      sV     - - + 0 8 : 2 'sN, sNlDM? DMN!7 !7r&   