
    _j{                         d dl mZ d dlmZ d dlmZmZ d dlmZ er*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 d d
lmZ d dlmZ  G d de          ZdS )    )StripeService)sanitize_id)Optionalcast)TYPE_CHECKING)InvoiceRenderingTemplate)
ListObject)RequestOptions)%InvoiceRenderingTemplateArchiveParams)"InvoiceRenderingTemplateListParams)&InvoiceRenderingTemplateRetrieveParams)'InvoiceRenderingTemplateUnarchiveParamsc            	          e Zd Z	 	 dded         ded         ddfdZ	 	 dded         ded         ddfd	Z	 	 dd
eded         ded         ddfdZ	 	 dd
eded         ded         ddfdZ	 	 dd
eded         ded         ddfdZ		 	 dd
eded         ded         ddfdZ
	 	 dd
eded         ded         ddfdZ	 	 dd
eded         ded         ddfdZdS )InvoiceRenderingTemplateServiceNparamsr   optionsr
   return$ListObject[InvoiceRenderingTemplate]c           
      R    t          d|                     ddd||                    S )x
        List all templates, ordered by creation date, with the most recently created template appearing first.
        r   get/v1/invoice_rendering_templatesapibase_addressr   r   )r   _requestselfr   r   s      n/var/www/app.qaans.com/backend/venv/lib/python3.11/site-packages/stripe/_invoice_rendering_template_service.pylistz$InvoiceRenderingTemplateService.list   s>     2MM1"   	
 	
 		
    c           
      b   K   t          d|                     ddd||           d{V           S )r   r   r   r   r   r   N)r   _request_asyncr   s      r   
list_asyncz*InvoiceRenderingTemplateService.list_async.   sb       2%%1" &        	
 	
 		
r!   templater   r   c                     t          d|                     dd                    t          |                    d||                    S )
        Retrieves an invoice rendering template with the given ID. It by default returns the latest version of the template. Optionally, specify a version to see previous versions.
        r   r   */v1/invoice_rendering_templates/{template}r%   r   r   r   r   formatr   r   r%   r   r   s       r   retrievez(InvoiceRenderingTemplateService.retrieveA   sa     &MM<CC(22 D   #   
 
 	
r!   c                    K   t          d|                     dd                    t          |                    d||           d{V           S )r'   r   r   r(   r)   r   r   Nr   r#   r+   r   r,   s       r   retrieve_asyncz.InvoiceRenderingTemplateService.retrieve_asyncW   s       &%%<CC(22 D   # &        
 
 	
r!   r   c                     t          d|                     dd                    t          |                    d||                    S )@  
        Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
        r   post2/v1/invoice_rendering_templates/{template}/archiver)   r   r   r*   r,   s       r   archivez'InvoiceRenderingTemplateService.archivem   sa     &MMDKK(22 L   #   
 
 	
r!   c                    K   t          d|                     dd                    t          |                    d||           d{V           S )r2   r   r3   r4   r)   r   r   Nr/   r,   s       r   archive_asyncz-InvoiceRenderingTemplateService.archive_async   s       &%%DKK(22 L   # &        
 
 	
r!   r   c                     t          d|                     dd                    t          |                    d||                    S )h
        Unarchive an invoice rendering template so it can be used on new Stripe objects again.
        r   r3   4/v1/invoice_rendering_templates/{template}/unarchiver)   r   r   r*   r,   s       r   	unarchivez)InvoiceRenderingTemplateService.unarchive   sa     &MMFMM(22 N   #   
 
 	
r!   c                    K   t          d|                     dd                    t          |                    d||           d{V           S )r9   r   r3   r:   r)   r   r   Nr/   r,   s       r   unarchive_asyncz/InvoiceRenderingTemplateService.unarchive_async   s       &%%FMM(22 N   # &        
 
 	
r!   )NN)__name__
__module____qualname__r   r    r$   strr-   r0   r5   r7   r;   r=    r!   r   r   r      s        BF.2
 
=>
 *+
 
0	
 
 
 
* BF.2
 
=>
 *+
 
0	
 
 
 
, FJ.2	
 

 AB
 *+	

 
$
 
 
 
2 FJ.2	
 

 AB
 *+	

 
$
 
 
 
2 EI.2	
 

 @A
 *+	

 
$
 
 
 
2 EI.2	
 

 @A
 *+	

 
$
 
 
 
2 GK.2	
 

 BC
 *+	

 
$
 
 
 
2 GK.2	
 

 BC
 *+	

 
$
 
 
 
 
 
r!   r   N)stripe._stripe_servicer   stripe._utilr   typingr   r   typing_extensionsr   "stripe._invoice_rendering_templater   stripe._list_objectr	   stripe._request_optionsr
   8stripe.params._invoice_rendering_template_archive_paramsr   5stripe.params._invoice_rendering_template_list_paramsr   9stripe.params._invoice_rendering_template_retrieve_paramsr   :stripe.params._invoice_rendering_template_unarchive_paramsr   r   rB   r!   r   <module>rN      sI   1 0 0 0 0 0 $ $ $ $ $ $ ! ! ! ! ! ! ! ! + + + + + + KKKKKK......666666                    
i
 i
 i
 i
 i
m i
 i
 i
 i
 i
r!   