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

    Twilio - Preview
    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Union)values)InstanceContext)InstanceResource)ListResource)Versionc                       e Zd ZdZdedeeef   def fdZe	dd       Z
ej                  ej                  fdeeef   d	eeef   dd fd
Zej                  ej                  fdeeef   d	eeef   dd fdZdefdZ xZS )UsageInstancez
    :ivar sim_sid:
    :ivar sim_unique_name:
    :ivar account_sid:
    :ivar period:
    :ivar commands_usage:
    :ivar commands_costs:
    :ivar data_usage:
    :ivar data_costs:
    :ivar url:
    versionpayloadsim_sidc                    t         |   |       |j                  d      | _        |j                  d      | _        |j                  d      | _        |j                  d      | _        |j                  d      | _        |j                  d      | _        |j                  d      | _	        |j                  d      | _
        |j                  d	      | _        d|i| _        d | _        y )
Nr   sim_unique_nameaccount_sidperiodcommands_usagecommands_costs
data_usage
data_costsurl)super__init__getr   r   r   r   r   r   r   r   r   	_solution_context)selfr   r   r   	__class__s       h/opt/services/ai/voice_agent/venv/lib/python3.12/site-packages/twilio/rest/preview/wireless/sim/usage.pyr   zUsageInstance.__init__$   s    !&-kk)&<.5kk:K.L*1++m*D3:;;x3H;B;;GW;X;B;;GW;X7>{{<7P7>{{<7P")++e"4 w
 15    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: UsageContext for this UsageInstance
        r   r   )r   UsageContext_versionr   r   s    r!   _proxyzUsageInstance._proxy6   s9     == (y1DM }}r"   endstartc                 <    | j                   j                  ||      S )
        Fetch the UsageInstance

        :param end:
        :param start:

        :returns: The fetched UsageInstance
        r*   r+   )r)   fetchr   r*   r+   s      r!   r/   zUsageInstance.fetchE   s&     {{   ! 
 	
r"   c                 X   K   | j                   j                  ||       d{   S 7 w)
        Asynchronous coroutine to fetch the UsageInstance

        :param end:
        :param start:

        :returns: The fetched UsageInstance
        r.   N)r)   fetch_asyncr0   s      r!   r3   zUsageInstance.fetch_asyncW   s4      [[,, - 
 
 	
 
s   !*(*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>z)UsageInstance.__repr__.<locals>.<genexpr>o        SDAq7>>!Q/S   !z*<Twilio.Preview.Wireless.UsageInstance {}>joinr   itemsr:   r   contexts     r!   __repr__zUsageInstance.__repr__i   s6     ((SDNN<P<P<RSS;BB7KKr"   )r#   r&   )__name__
__module____qualname____doc__r   r   strr   r   propertyr)   r   unsetr   objectr/   r3   rG   __classcell__r    s   @r!   r   r      s    
5 5$sCx. 53 5$    #),,$*LL
3;
 S&[!
 
	
( #),,$*LL
3;
 S&[!
 
	
$L# Lr"   r   c                        e Zd Zdedef fdZej                  ej                  fdeee	f   deee	f   de
fdZej                  ej                  fdeee	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 UsageContext

        :param version: Version that contains the resource
        :param sim_sid:
        r   z/Sims/{sim_sid}/UsageN )r   r   r   r:   _urir   r   r   r    s      r!   r   zUsageContext.__init__u   s@     	! w
 3+22DT^^D	r"   r*   r+   r#   c                    t        j                  ||d      }t        j                  i       }d|d<   | j                  j                  d| j                  ||      }t        | j                  || j                  d         S )r-   EndStartapplication/jsonAcceptGETmethoduriparamsheadersr   r%   )r   ofr'   r/   rU   r   r   r   r*   r+   ra   rb   r   s         r!   r/   zUsageContext.fetch   s     
 ))B-.--%%dii & 
 MMNN9-
 	
r"   c                   K   t        j                  ||d      }t        j                  i       }d|d<   | j                  j                  d| j                  ||       d{   }t        | j                  || j                  d         S 7 )w)	r2   rX   r[   r\   r]   r^   Nr   r%   )r   rc   r'   r3   rU   r   r   rd   s         r!   r3   zUsageContext.fetch_async   s      
 ))B-.11dii 2 
 
 MMNN9-
 	
	
s   AB!B"*Bc                     dj                  d | j                  j                         D              }dj                  |      S )r5   r6   c              3   F   K   | ]  \  }}d j                  ||        ywr8   r9   r;   s      r!   r?   z(UsageContext.__repr__.<locals>.<genexpr>   r@   rA   z)<Twilio.Preview.Wireless.UsageContext {}>rB   rE   s     r!   rG   zUsageContext.__repr__   s6     ((SDNN<P<P<RSS:AA'JJr"   )rH   rI   rJ   r   rL   r   r   rN   r   rO   r   r/   r3   rG   rP   rQ   s   @r!   r&   r&   s   s    E E# E" #),,$*LL!
3;!
 S&[!!
 
	!
J #),,$*LL!
3;!
 S&[!!
 
	!
FK# Kr"   r&   c                   L     e Zd Zdedef fdZdefdZdefdZdefdZ	 xZ
S )	UsageListr   r   c                 6    t         |   |       d|i| _        y)z
        Initialize the UsageList

        :param version: Version that contains the resource
        :param sim_sid:

        r   N)r   r   r   rV   s      r!   r   zUsageList.__init__   s"     	! w
r"   r#   c                 J    t        | j                  | j                  d         S z,
        Constructs a UsageContext

        r   r%   r&   r'   r   r(   s    r!   r   zUsageList.get       
 DMM4>>)3LMMr"   c                 J    t        | j                  | j                  d         S rl   rm   r(   s    r!   __call__zUsageList.__call__   rn   r"   c                      y)r5   z#<Twilio.Preview.Wireless.UsageList>rT   r(   s    r!   rG   zUsageList.__repr__   s     5r"   )rH   rI   rJ   r   rL   r   r&   r   rp   rG   rP   rQ   s   @r!   ri   ri      s>    
 
# 
N\ NN, N5# 5r"   ri   N)rK   typingr   r   r   r   twilio.baser   twilio.base.instance_contextr   twilio.base.instance_resourcer	   twilio.base.list_resourcer
   twilio.base.versionr   r   r&   ri   rT   r"   r!   <module>rx      sP    . -  8 : 2 'YL$ YLx^K? ^KB%5 %5r"   