
    i?1im                         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e      Z G d de      Z G d de      Z G d de      Zy)a  
    This code was generated by
   ___ _ _ _ _ _    _ ____    ____ ____ _    ____ ____ _  _ ____ ____ ____ ___ __   __
    |  | | | | |    | |  | __ |  | |__| | __ | __ |___ |\ | |___ |__/ |__|  | |  | |__/
    |  |_|_| | |___ | |__|    |__| |  | |    |__] |___ | \| |___ |  \ |  |  | |__| |  \

    Twilio - Conversations
    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                       e Zd Z G d de      Z	 	 ddedeeef   de	e   f fdZ
edd       Zdefd	Zdefd
ZddZddZej&                  ej&                  ej&                  ej&                  ej&                  ej&                  ej&                  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d fdZej&                  ej&                  ej&                  ej&                  ej&                  ej&                  ej&                  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d fdZdefdZ xZS )CredentialInstancec                       e Zd ZdZdZdZy)CredentialInstance.PushTypeapngcmfcmN)__name__
__module____qualname__APNGCMFCM     q/home/www/therecruiter.miabetepe.com/venv/lib/python3.12/site-packages/twilio/rest/conversations/v1/credential.pyPushTyper      s    r    r"   versionpayloadsidc                    t         |   |       |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friendly_nametypesandboxdate_createddate_updatedurl)super__init__getr%   r'   r(   r)   r*   r   iso8601_datetimer+   r,   r-   	_solution_context)selfr#   r$   r%   	__class__s       r!   r/   zCredentialInstance.__init__+   s     	!")++e"4*1++m*D,3KK,H=D[[=P	&-kk)&<0;0L0LKK'1
 1<0L0LKK'1
 #*++e"4 3?$((
 6:r    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: CredentialContext for this CredentialInstance
        r%   r%   )r3   CredentialContext_versionr2   r4   s    r!   _proxyzCredentialInstance._proxyB   s9     == -NN5)DM }}r    c                 6    | j                   j                         S )m
        Deletes the CredentialInstance


        :returns: True if delete succeeds, False otherwise
        )r<   deleter;   s    r!   r?   zCredentialInstance.deleteQ   s     {{!!##r    c                 R   K   | j                   j                          d{   S 7 w)
        Asynchronous coroutine that deletes the CredentialInstance


        :returns: True if delete succeeds, False otherwise
        N)r<   delete_asyncr;   s    r!   rB   zCredentialInstance.delete_asyncZ   s!      [[--////   '%'c                 6    | j                   j                         S )a
        Fetch the CredentialInstance


        :returns: The fetched CredentialInstance
        )r<   fetchr;   s    r!   rF   zCredentialInstance.fetchc   s     {{  ""r    c                 R   K   | j                   j                          d{   S 7 w){
        Asynchronous coroutine to fetch the CredentialInstance


        :returns: The fetched CredentialInstance
        N)r<   fetch_asyncr;   s    r!   rI   zCredentialInstance.fetch_asyncl   s!      [[,,....rC   r)   r   r(   certificateprivate_keyr*   api_keysecretc           	      F    | j                   j                  |||||||      S )i  
        Update the CredentialInstance

        :param type:
        :param friendly_name: A descriptive string that you create to describe the new resource. It can be up to 64 characters long.
        :param certificate: [APN only] The URL encoded representation of the certificate. For example,  `-----BEGIN CERTIFICATE----- MIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEF.....A== -----END CERTIFICATE-----`.
        :param private_key: [APN only] The URL encoded representation of the private key. For example, `-----BEGIN RSA PRIVATE KEY----- MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fG... -----END RSA PRIVATE KEY-----`.
        :param sandbox: [APN only] Whether to send the credential to sandbox APNs. Can be `true` to send to sandbox APNs or `false` to send to production.
        :param api_key: [GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.
        :param secret: [FCM only] The **Server key** of your project from the Firebase console, found under Settings / Cloud messaging.

        :returns: The updated CredentialInstance
        r)   r(   rJ   rK   r*   rL   rM   )r<   updater4   r)   r(   rJ   rK   r*   rL   rM   s           r!   rQ   zCredentialInstance.updateu   s5    . {{!!'## " 
 	
r    c           	      b   K   | j                   j                  |||||||       d{   S 7 w)  
        Asynchronous coroutine to update the CredentialInstance

        :param type:
        :param friendly_name: A descriptive string that you create to describe the new resource. It can be up to 64 characters long.
        :param certificate: [APN only] The URL encoded representation of the certificate. For example,  `-----BEGIN CERTIFICATE----- MIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEF.....A== -----END CERTIFICATE-----`.
        :param private_key: [APN only] The URL encoded representation of the private key. For example, `-----BEGIN RSA PRIVATE KEY----- MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fG... -----END RSA PRIVATE KEY-----`.
        :param sandbox: [APN only] Whether to send the credential to sandbox APNs. Can be `true` to send to sandbox APNs or `false` to send to production.
        :param api_key: [GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.
        :param secret: [FCM only] The **Server key** of your project from the Firebase console, found under Settings / Cloud messaging.

        :returns: The updated CredentialInstance
        rP   N)r<   update_asyncrR   s           r!   rU   zCredentialInstance.update_async   sC     . [[--'## . 
 
 	
 
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.CredentialInstance.__repr__.<locals>.<genexpr>        SDAq7>>!Q/S   !z/<Twilio.Conversations.V1.CredentialInstance {}>joinr2   itemsr\   r4   contexts     r!   __repr__zCredentialInstance.__repr__   s6     ((SDNN<P<P<RSS@GGPPr    )N)r6   r9   )r6   r   )r   r   r   objectr"   r   r   strr   r   r/   propertyr<   boolr?   rB   rF   rI   r   unsetr   rQ   rU   ri   __classcell__r5   s   @r!   r   r      s   6 
	 OS::)-c3h:>Fsm:.  $ $0D 0#/ >D\\,2LL*0,,*0,,'-||&,ll%+\\
169:
 S&[)
 3;'	

 3;'
 tV|$
 sF{#
 c6k"
 

F >D\\,2LL*0,,*0,,'-||&,ll%+\\
169:
 S&[)
 3;'	

 3;'
 tV|$
 sF{#
 c6k"
 

BQ# Qr    r   c                   x    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
de	fdZej                  ej                  ej                  ej                  ej                  ej                  ej                  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	fdZej                  ej                  ej                  ej                  ej                  ej                  ej                  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	fdZdefdZ xZS )r9   r#   r%   c                 x    t         |   |       d|i| _         dj                  di | j                  | _        y)z
        Initialize the CredentialContext

        :param version: Version that contains the resource
        :param sid: A 34 character string that uniquely identifies this resource.
        r%   z/Credentials/{sid}Nr   )r.   r/   r2   r\   _uri)r4   r#   r%   r5   s      r!   r/   zCredentialContext.__init__   s@     	! 3
 0(//A$..A	r    r6   c                 P    | j                   j                  d| j                        S )r>   DELETEmethoduri)r:   r?   rs   r;   s    r!   r?   zCredentialContext.delete   s*     }}##		 $ 
 	
r    c                 l   K   | j                   j                  d| j                         d{   S 7 w)rA   ru   rv   N)r:   rB   rs   r;   s    r!   rB   zCredentialContext.delete_async   s8      ]]//		 0 
 
 	
 
s   +424c                     | j                   j                  d| j                        }t        | j                   || j                  d         S )rE   GETrv   r%   r8   )r:   rF   rs   r   r2   r4   r$   s     r!   rF   zCredentialContext.fetch   sL     --%%		 & 

 "MMu%
 	
r    c                    K   | j                   j                  d| j                         d{   }t        | j                   || j                  d         S 7 )w)rH   r{   rv   Nr%   r8   )r:   rI   rs   r   r2   r|   s     r!   rI   zCredentialContext.fetch_async   sZ      11		 2 
 

 "MMu%
 	

s   +AA*Ar)   r   r(   rJ   rK   r*   rL   rM   c           
          t        j                  |||||||d      }| j                  j                  d| j                  |      }	t        | j                  |	| j                  d         S )rO   TypeFriendlyNameCertificate
PrivateKeySandboxApiKeySecretPOSTrw   rx   datar%   r8   )r   ofr:   rQ   rs   r   r2   
r4   r)   r(   rJ   rK   r*   rL   rM   r   r$   s
             r!   rQ   zCredentialContext.update  sr    . yy -*)"! 

 --&&		 ' 
 "$--dnnU>STTr    c           
         K   t        j                  |||||||d      }| j                  j                  d| j                  |       d{   }	t        | j                  |	| j                  d         S 7 )w)rT   r   r   r   Nr%   r8   )r   r   r:   rU   rs   r   r2   r   s
             r!   rU   zCredentialContext.update_async:  s     . yy -*)"! 

 22		 3 
 
 "$--dnnU>STT
s   A	A7A5*A7c                     dj                  d | j                  j                         D              }dj                  |      S )rW   rX   c              3   F   K   | ]  \  }}d j                  ||        ywrZ   r[   r]   s      r!   ra   z-CredentialContext.__repr__.<locals>.<genexpr>k  rb   rc   z.<Twilio.Conversations.V1.CredentialContext {}>rd   rg   s     r!   ri   zCredentialContext.__repr__e  s6     ((SDNN<P<P<RSS?FFwOOr    )r   r   r   r   rk   r/   rm   r?   rB   r   rF   rI   r   rn   r   rj   rQ   rU   ri   ro   rp   s   @r!   r9   r9      s   B Bc B

 



D 


) 
&
#5 
* >D\\,2LL*0,,*0,,'-||&,ll%+\\)U169:)U S&[))U 3;'	)U
 3;')U tV|$)U sF{#)U c6k")U 
)UZ >D\\,2LL*0,,*0,,'-||&,ll%+\\)U169:)U S&[))U 3;'	)U
 3;')U tV|$)U sF{#)U c6k")U 
)UVP# Pr    r9   c                   2    e Zd Zdeeef   defdZdefdZy)CredentialPager$   r6   c                 .    t        | j                  |      S )zp
        Build an instance of CredentialInstance

        :param payload: Payload response from the API
        )r   r:   r|   s     r!   get_instancezCredentialPage.get_instancep  s     "$--99r    c                      y)rW   z(<Twilio.Conversations.V1.CredentialPage>r   r;   s    r!   ri   zCredentialPage.__repr__x       :r    N)	r   r   r   r   rk   r   r   r   ri   r   r    r!   r   r   o  s*    :DcN :7I ::# :r    r   c                       e Zd Zdef fdZej                  ej                  ej                  ej                  ej                  ej                  fdd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Zej                  ej                  ej                  ej                  ej                  ej                  fdd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Z	 	 ddee   dee   dee   fdZ	 	 ddee   dee   dee   fdZ	 	 ddee   dee   dee   fdZ	 	 ddee   dee   dee   fdZej                  ej                  ej                  fdeee	f   deee	f   deee	f   defdZej                  ej                  ej                  fdeee	f   deee	f   deee	f   defdZdedefdZdede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 ) CredentialListr#   c                 2    t         |   |       d| _        y)zl
        Initialize the CredentialList

        :param version: Version that contains the resource

        z/CredentialsN)r.   r/   rs   )r4   r#   r5   s     r!   r/   zCredentialList.__init__  s     	!"	r    r)   r   r(   rJ   rK   r*   rL   rM   r6   c           
          t        j                  |||||||d      }| j                  j                  d| j                  |      }	t        | j                  |	      S )ai  
        Create the CredentialInstance

        :param type:
        :param friendly_name: A descriptive string that you create to describe the new resource. It can be up to 64 characters long.
        :param certificate: [APN only] The URL encoded representation of the certificate. For example,  `-----BEGIN CERTIFICATE----- MIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEF.....A== -----END CERTIFICATE-----`.
        :param private_key: [APN only] The URL encoded representation of the private key. For example, `-----BEGIN RSA PRIVATE KEY----- MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fG... -----END RSA PRIVATE KEY-----`.
        :param sandbox: [APN only] Whether to send the credential to sandbox APNs. Can be `true` to send to sandbox APNs or `false` to send to production.
        :param api_key: [GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.
        :param secret: [FCM only] The **Server key** of your project from the Firebase console, found under Settings / Cloud messaging.

        :returns: The created CredentialInstance
        r   r   r   )r   r   r:   creaters   r   r   s
             r!   r   zCredentialList.create  sg    . yy -*)"! 

 --&&		 ' 
 "$--99r    c           
         K   t        j                  |||||||d      }| j                  j                  d| j                  |       d{   }	t        | j                  |	      S 7 w)ax  
        Asynchronously create the CredentialInstance

        :param type:
        :param friendly_name: A descriptive string that you create to describe the new resource. It can be up to 64 characters long.
        :param certificate: [APN only] The URL encoded representation of the certificate. For example,  `-----BEGIN CERTIFICATE----- MIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEF.....A== -----END CERTIFICATE-----`.
        :param private_key: [APN only] The URL encoded representation of the private key. For example, `-----BEGIN RSA PRIVATE KEY----- MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fG... -----END RSA PRIVATE KEY-----`.
        :param sandbox: [APN only] Whether to send the credential to sandbox APNs. Can be `true` to send to sandbox APNs or `false` to send to production.
        :param api_key: [GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.
        :param secret: [FCM only] The **Server key** of your project from the Firebase console, found under Settings / Cloud messaging.

        :returns: The created CredentialInstance
        r   r   r   N)r   r   r:   create_asyncrs   r   r   s
             r!   r   zCredentialList.create_async  su     . yy -*)"! 

 22		 3 
 
 "$--99
s   A	A(A&A(limit	page_sizec                     | j                   j                  ||      }| j                  |d         }| j                   j                  ||d         S )a`  
        Streams CredentialInstance 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 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:   read_limitspagestreamr4   r   r   limitsr   s        r!   r   zCredentialList.stream  sJ    ( **5)<yy6+#6y7}}##D&/::r    c                    K   | j                   j                  ||      }| j                  |d          d{   }| j                   j                  ||d         S 7 #w)ao  
        Asynchronously streams CredentialInstance 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 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   s        r!   r   zCredentialList.stream_async  sW     ( **5)<__vk/B_CC}}))$w@@ Ds   5AA$Ac                 :    t        | j                  ||            S )a  
        Lists CredentialInstance records from the API as a list.
        Unlike stream(), this operation is eager and will load `limit` records into
        memory before returning.

        :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   )listr   )r4   r   r   s      r!   r   zCredentialList.list  s(    & KK#  
 	
r    c                 z   K   | j                  ||       d{   2 cg c3 d{   }|7 7 	6 c}S c c}w w)a  
        Asynchronously lists CredentialInstance records from the API as a list.
        Unlike stream(), this operation is eager and will load `limit` records into
        memory before returning.

        :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   N)r   )r4   r   r   records       r!   
list_asynczCredentialList.list_async/  sT     * '+&7&7# '8 ' !
 
 !
 
 	
 
s0   ;.;620
26;26;
page_tokenpage_numberc                     t        j                  |||d      }| j                  j                  d| j                  |      }t        | j                  |      S )ay  
        Retrieve a single page of CredentialInstance records from the API.
        Request is executed immediately

        :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 CredentialInstance
        	PageTokenr   PageSizer{   rw   rx   params)r   r   r:   r   rs   r   r4   r   r   r   r   responses         r!   r   zCredentialList.pageJ  sR      yy'#%
 ==%%U		$%OdmmX66r    c                    K   t        j                  |||d      }| j                  j                  d| j                  |       d{   }t        | j                  |      S 7 w)a  
        Asynchronously retrieve a single page of CredentialInstance records from the API.
        Request is executed immediately

        :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 CredentialInstance
        r   r{   r   N)r   r   r:   r   rs   r   r   s         r!   r   zCredentialList.page_asynce  sg       yy'#%
 11dii 2 
 
 dmmX66
s   AA$A"A$
target_urlc                     | j                   j                  j                  j                  d|      }t	        | j                   |      S )z
        Retrieve a specific page of CredentialInstance records from the API.
        Request is executed immediately

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

        :returns: Page of CredentialInstance
        r{   )r:   domaintwiliorequestr   r4   r   r   s      r!   get_pagezCredentialList.get_page  s7     ==''..66ujIdmmX66r    c                    K   | j                   j                  j                  j                  d|       d{   }t	        | j                   |      S 7 w)a  
        Asynchronously retrieve a specific page of CredentialInstance records from the API.
        Request is executed immediately

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

        :returns: Page of CredentialInstance
        r{   N)r:   r   r   request_asyncr   r   s      r!   get_page_asynczCredentialList.get_page_async  sD      --44BB5*UUdmmX66 Vs   4AAAr%   c                 0    t        | j                  |      S z
        Constructs a CredentialContext

        :param sid: A 34 character string that uniquely identifies this resource.
        r8   r9   r:   r4   r%   s     r!   r0   zCredentialList.get       !C88r    c                 0    t        | j                  |      S r   r   r   s     r!   __call__zCredentialList.__call__  r   r    c                      y)rW   z(<Twilio.Conversations.V1.CredentialList>r   r;   s    r!   ri   zCredentialList.__repr__  r   r    )NN)!r   r   r   r   r/   r   rn   r   rk   rj   rm   r   r   r   r   intr	   r   r
   r   r   r   r   r   r   r   r   r   r9   r0   r   ri   ro   rp   s   @r!   r   r     so   	# 	# -3LL*0,,*0,,'-||&,ll%+\\):+): S&[)): 3;'	):
 3;'): tV|$): sF{#): c6k"): 
):\ -3LL*0,,*0,,'-||&,ll%+\\):+): S&[)): 3;'	):
 3;'): tV|$): sF{#): c6k"): 
):Z  $#';}; C=; 
$	%	;6  $#'A}A C=A 
)	*	A6  $#'
}
 C=
 
 	!	
8  $#'
}
 C=
 
 	!	
: *0*0,,(.	7#v+&7 3;'7 f%	7
 
7: *0*0,,(.	7#v+&7 3;'7 f%	7
 
7:
73 
7> 
7
7s 
7~ 
79s 90 99C 9$5 9:# :r    r   N)__doc__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   r9   r   r   r   r    r!   <module>r      sg     L L L + 8 : 2 ' !dQ) dQNkP kP\:T :$o:\ o:r    