Ë
    <@‹g3  ã                   ó   — 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	m
Z
mZ d dlmZmZ erd dlmZ d dlmZ  G d	„ d
ed
   «      Zy)é    )ÚAPIResource)ÚCustomer)ÚExpandableField)Úsanitize_id)ÚClassVarÚDictÚOptional)ÚLiteralÚTYPE_CHECKING)Ú
CreditNote)ÚInvoicec                   ó   — e Zd ZU dZdZeed      ed<   eed<   	 eed<   	 e	e
d      ed<   	 eed<   	 e
d	   ed
<   	 e	e   ed<   	 eed<   	 eed<   	 e	e
d      ed<   	 eed<   	 e	eeef      ed<   	 ed   ed<   	 ed   ed<   	 d„ Zedd„«       Zy)ÚCustomerBalanceTransactiona5  
    Each customer has a [Balance](https://stripe.com/docs/api/customers/object#customer_object-balance) value,
    which denotes a debit or credit that's automatically applied to their next invoice upon finalization.
    You may modify the value directly by using the [update customer API](https://stripe.com/docs/api/customers/update),
    or by creating a Customer Balance Transaction, which increments or decrements the customer's `balance` by the specified `amount`.

    Related guide: [Customer balance](https://stripe.com/docs/billing/customer/balance)
    Úcustomer_balance_transactionÚOBJECT_NAMEÚamountÚcreatedr   Úcredit_noteÚcurrencyr   ÚcustomerÚdescriptionÚending_balanceÚidr   ÚinvoiceÚlivemodeÚmetadataÚobject)
Ú
adjustmentÚapplied_to_invoicer   ÚinitialÚinvoice_overpaidÚinvoice_too_largeÚinvoice_too_smallÚ	migrationÚunapplied_from_invoiceÚunspent_receiver_creditÚtypec                 óÒ   — | j                   }| j                  }t        |t        «      r|j                   }t        j                  «       }t        |«      }t        |«      }|›d|›d|›S )Nú/z/balance_transactions/)r   r   Ú
isinstancer   Ú	class_urlr   )ÚselfÚtokenr   ÚbaseÚ	cust_extnÚextns         úc/var/www/html/AdoubleTech/venv/lib/python3.12/site-packages/stripe/_customer_balance_transaction.pyÚinstance_urlz'CustomerBalanceTransaction.instance_url\   sV   € Ø—‘ˆØ—=‘=ˆÜh¤Ô)Ø—{‘{ˆHÜ×!Ñ!Ó#ˆÜ Ó)ˆ	Ü˜5Ó!ˆÚ26º	Á4ÐHÐHó    c                 ó   — t        d«      ‚)NzCan't retrieve a Customer Balance Transaction without a Customer ID. Use Customer.retrieve_customer_balance_transaction('cus_123', 'cbtxn_123'))ÚNotImplementedError)Úclsr   Úparamss      r1   Úretrievez#CustomerBalanceTransaction.retrievef   s   € ä!ðYó
ð 	
r3   N)Úreturnr   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r
   Ú__annotations__Úintr	   r   ÚstrÚboolr   r2   Úclassmethodr8   © r3   r1   r   r      s  … ñð 	'ð ˜'Ð"@ÑAÑBó ð ƒKðð ƒLðð ˜/¨,Ñ7Ñ8Ó8ðð ƒMðð ˜jÑ)Ó)ðð ˜#‘Óðð Óðð 	ƒGðð o iÑ0Ñ1Ó1ðð ƒNðð t˜C ˜H‘~Ñ&Ó&ðð Ð2Ñ3Ó3ðð ð		#ñó ðòIð ò
ó ñ
r3   r   N)Ústripe._api_resourcer   Ústripe._customerr   Ústripe._expandable_fieldr   Ústripe._utilr   Útypingr   r   r	   Útyping_extensionsr
   r   Ústripe._credit_noter   Ústripe._invoicer   r   rC   r3   r1   ú<module>rL      s9   ðõ -Ý %Ý 4Ý $ß +Ñ +ß 4áÝ.Ý'ô\
 Ð-IÑ!Jõ \
r3   