o
    i                     @   s   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 G d
d deZdS )    )StripeService)sanitize_id)Optionalcast)TYPE_CHECKING)BalanceTransaction)
ListObject)RequestOptions)BalanceTransactionListParams) BalanceTransactionRetrieveParamsc                	   @   s   e Zd Z		dded ded ddfdd	Z		dded ded ddfd
dZ		ddeded ded ddfddZ		ddeded ded ddfddZdS )BalanceTransactionServiceNparamsr
   optionsr	   returnListObject[BalanceTransaction]c              	   C   s   t d| jddd||dS )d  
        Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.

        Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history.
        r   get/v1/balance_transactionsapibase_addressr   r   )r   _requestselfr   r    r   /var/www/snowflake_co_dev_github/snow_flake_back_end_deploy/env/lib/python3.10/site-packages/stripe/_balance_transaction_service.pylist   s   
zBalanceTransactionService.listc              	      s"   t d| jddd||dI dH S )r   r   r   r   r   r   N)r   _request_asyncr   r   r   r   
list_async*   s   

z$BalanceTransactionService.list_asyncidr   r   c              	   C   s&   t d| jddjt|dd||dS )
        Retrieves the balance transaction with the given ID.

        Note that this endpoint previously used the path /v1/balance/history/:id.
        r   r   /v1/balance_transactions/{id}r   r   r   )r   r   formatr   r   r   r   r   r   r   r   retrieve?   s   z"BalanceTransactionService.retrievec              	      s.   t d| jddjt|dd||dI dH S )r    r   r   r!   r"   r   r   N)r   r   r#   r   r$   r   r   r   retrieve_asyncU   s   
z(BalanceTransactionService.retrieve_async)NN)	__name__
__module____qualname__r   r   r   strr%   r&   r   r   r   r   r      sR    


r   N)stripe._stripe_servicer   stripe._utilr   typingr   r   typing_extensionsr   stripe._balance_transactionr   stripe._list_objectr   stripe._request_optionsr	   .stripe.params._balance_transaction_list_paramsr
   2stripe.params._balance_transaction_retrieve_paramsr   r   r   r   r   r   <module>   s   