o
    i_                     @   s|   d dl mZ d dlmZ d dlmZ d dlmZmZ d dl	m
Z
mZmZ er2d dlmZ d dlmZ G dd	 d	ed	 Zd
S )    )
ListObject)ListableAPIResource)StripeObject)ClassVarOptional)LiteralUnpackTYPE_CHECKING)TransactionListParams)TransactionRetrieveParamsc                   @   s4  e Zd ZU dZdZeed  ed< G dd deZ	e
ed< 	 eed< 	 e
ed< 	 e
ed	< 	 e
ed
< 	 eed< 	 ed ed< 	 ed ed< 	 e	ed< eed< 	 e
ed< 	 eed< 	 eded ded  fddZeded ded  fddZed
e
ded dd fddZed
e
ded dd fddZde	iZdS ) Transactionzk
    A Transaction represents a real transaction that affects a Financial Connections Account balance.
    z!financial_connections.transactionOBJECT_NAMEc                   @   s(   e Zd ZU ee ed< 	 ee ed< dS )zTransaction.StatusTransitions	posted_atvoid_atN)__name__
__module____qualname__r   int__annotations__ r   r   /var/www/snowflake_co_dev_github/snow_flake_back_end_deploy/env/lib/python3.10/site-packages/stripe/financial_connections/_transaction.pyStatusTransitions   s
   
 r   accountamountcurrencydescriptionidlivemodeobject)pendingpostedvoidstatusstatus_transitionstransacted_attransaction_refreshupdatedparamsr
   returnc                 K   s4   | j d|  |d}t|tstdt|j |S )N
        Returns a list of Financial Connections Transaction objects.
        getr'   %Expected list object from API, got %s)_static_request	class_url
isinstancer   	TypeErrortyper   clsr'   resultr   r   r   listS   s   
zTransaction.listc                    s<   | j d|  |dI dH }t|tstdt|j |S )r)   r*   r+   Nr,   )_static_request_asyncr.   r/   r   r0   r1   r   r2   r   r   r   
list_asyncg   s   
zTransaction.list_asyncr   c                 K   s   | |fi |}|   |S )N
        Retrieves the details of a Financial Connections Transaction
        )refreshr3   r   r'   instancer   r   r   retrieve{   s   zTransaction.retrievec                    s$   | |fi |}|  I dH  |S )r8   N)refresh_asyncr:   r   r   r   retrieve_async   s   zTransaction.retrieve_asyncN)r   r   r   __doc__r   r   r   r   r   r   strr   boolclassmethodr   r   r5   r7   r<   r>   _inner_class_typesr   r   r   r   r      sr   
 


r   N)stripe._list_objectr   stripe._listable_api_resourcer   stripe._stripe_objectr   typingr   r   typing_extensionsr   r   r	   <stripe.params.financial_connections._transaction_list_paramsr
   @stripe.params.financial_connections._transaction_retrieve_paramsr   r   r   r   r   r   <module>   s   