kintsugi-tax-platform-sdk 0.5.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (175) hide show
  1. kintsugi_tax_platform_sdk-0.5.3/PKG-INFO +560 -0
  2. kintsugi_tax_platform_sdk-0.5.3/README-PYPI.md +542 -0
  3. kintsugi_tax_platform_sdk-0.5.3/py.typed +1 -0
  4. kintsugi_tax_platform_sdk-0.5.3/pyproject.toml +56 -0
  5. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/__init__.py +17 -0
  6. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/_hooks/__init__.py +4 -0
  7. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/_hooks/sdkhooks.py +74 -0
  8. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/_hooks/types.py +112 -0
  9. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/_version.py +17 -0
  10. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/addressvalidation.py +570 -0
  11. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/basesdk.py +358 -0
  12. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/customers.py +2201 -0
  13. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/__init__.py +108 -0
  14. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/apierror.py +38 -0
  15. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/backend_src_address_validation_responses_validationerrorresponse.py +30 -0
  16. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/backend_src_customers_responses_validationerrorresponse.py +30 -0
  17. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/backend_src_exemptions_responses_validationerrorresponse.py +30 -0
  18. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/backend_src_products_responses_validationerrorresponse.py +30 -0
  19. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/backend_src_tax_estimation_responses_validationerrorresponse.py +30 -0
  20. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/backend_src_transactions_responses_validationerrorresponse.py +30 -0
  21. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/errorresponse.py +26 -0
  22. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/httpvalidationerror.py +26 -0
  23. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/no_response_error.py +13 -0
  24. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/responsevalidationerror.py +25 -0
  25. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/errors/sdkerror.py +26 -0
  26. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/exemptions.py +1263 -0
  27. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/httpclient.py +126 -0
  28. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/__init__.py +1514 -0
  29. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/address_input.py +158 -0
  30. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/addressbase.py +113 -0
  31. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/addressresponsedata.py +105 -0
  32. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/addresssearchresponse.py +32 -0
  33. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/addressstatus.py +13 -0
  34. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/addresssubmittedresponse.py +105 -0
  35. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/addresstype.py +11 -0
  36. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/appliedto.py +9 -0
  37. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/attachmentread.py +28 -0
  38. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/backend_src_address_validation_responses_validationerroritem.py +36 -0
  39. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/backend_src_customers_responses_validationerroritem.py +36 -0
  40. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/backend_src_exemptions_models_exemptionread.py +150 -0
  41. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/backend_src_exemptions_responses_validationerroritem.py +40 -0
  42. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/backend_src_exemptions_serializers_exemptionread.py +135 -0
  43. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/backend_src_products_responses_validationerroritem.py +40 -0
  44. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/backend_src_tax_estimation_responses_validationerroritem.py +36 -0
  45. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/backend_src_transactions_responses_validationerroritem.py +40 -0
  46. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/body_upload_exemption_certificate_v1_exemptions_exemption_id_attachments_post.py +45 -0
  47. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/countrycodeenum.py +257 -0
  48. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/create_credit_note_by_transaction_id_v1_transactions_original_transaction_id_credit_notes_postop.py +110 -0
  49. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/create_customer_v1_customers_postop.py +96 -0
  50. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/create_exemption_v1_exemptions_postop.py +96 -0
  51. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/create_product_v1_products_postop.py +96 -0
  52. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/create_transaction_by_customer_id_v1_customers_customer_id_transactions_postop.py +112 -0
  53. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/create_transaction_v1_transactions_postop.py +99 -0
  54. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/creditnotecreate.py +191 -0
  55. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/creditnoteitemcreateupdate.py +192 -0
  56. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/currencyenum.py +169 -0
  57. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/customerbase_input.py +172 -0
  58. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/customerbase_output.py +165 -0
  59. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/customerbasebase.py +179 -0
  60. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/customercreate.py +167 -0
  61. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/customerread.py +177 -0
  62. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/customerupdate.py +156 -0
  63. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/discountbuilder.py +64 -0
  64. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/estimate_tax_v1_tax_estimate_postop.py +112 -0
  65. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/exemption.py +160 -0
  66. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/exemptioncreate.py +110 -0
  67. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/exemptionrequired.py +71 -0
  68. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/exemptionstatus.py +12 -0
  69. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/exemptiontype.py +10 -0
  70. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/fastapi_pagination_default_page_exemptionread_2.py +67 -0
  71. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_attachments_for_exemption_v1_exemptions_exemption_id_attachments_getop.py +106 -0
  72. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_customer_by_external_id_v1_customers_external_external_id_getop.py +100 -0
  73. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_customer_by_id_v1_customers_customer_id_getop.py +96 -0
  74. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_customers_v1op.py +178 -0
  75. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_exemption_by_id_v1_exemptions_exemption_id_getop.py +96 -0
  76. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_exemptions_v1_exemptions_getop.py +217 -0
  77. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_nexus_for_org_v1_nexus_getop.py +158 -0
  78. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_product_by_id_v1_products_product_id_getop.py +96 -0
  79. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_product_categories_v1_products_categories_getop.py +88 -0
  80. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_products_v1_products_getop.py +180 -0
  81. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_transaction_by_external_id_v1_transactions_external_external_id_getop.py +100 -0
  82. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_transaction_by_id_v1_transactions_transaction_id_getop.py +96 -0
  83. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_transactions_by_customer_id_v1_customers_customer_id_transactions_getop.py +100 -0
  84. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_transactions_by_filing_id_v1_transactions_filings_filing_id_getop.py +106 -0
  85. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/get_transactions_v1_transactions_getop.py +311 -0
  86. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/jurisdictiontype.py +15 -0
  87. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/nexusresponse.py +286 -0
  88. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/nexusstateenum.py +14 -0
  89. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/nexusstatusenum.py +10 -0
  90. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/nexustypeenum.py +11 -0
  91. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/page_customerread_.py +64 -0
  92. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/page_nexusresponse_.py +64 -0
  93. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/page_productread_.py +64 -0
  94. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/page_transactionestimateresponse_.py +67 -0
  95. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/page_transactionread_.py +64 -0
  96. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/periodmodelenum.py +16 -0
  97. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/processingstatusenum.py +24 -0
  98. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productcategories.py +26 -0
  99. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productcategoryenum.py +12 -0
  100. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productcodeenum.py +69 -0
  101. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productcreatemanual.py +112 -0
  102. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productread.py +117 -0
  103. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productstatusenum.py +10 -0
  104. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productsubcategory.py +35 -0
  105. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productsubcategoryenum.py +88 -0
  106. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productupdate.py +110 -0
  107. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/productupdatev2.py +76 -0
  108. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/registrationsregimeenum.py +9 -0
  109. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/relatedentitytype.py +11 -0
  110. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/salesortransactionsenum.py +11 -0
  111. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/search_v1_address_validation_search_postop.py +38 -0
  112. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/security.py +25 -0
  113. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/sourceenum.py +57 -0
  114. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/statusenum.py +9 -0
  115. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/suggestions_v1_address_validation_suggestions_postop.py +96 -0
  116. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/taxexemptionenum.py +20 -0
  117. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/taxitembuilder.py +132 -0
  118. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/taxitemestimate.py +67 -0
  119. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/taxitemread.py +104 -0
  120. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/taxitemreturnreasonenum.py +14 -0
  121. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/taxitemtypeenum.py +9 -0
  122. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/taxliabilitysourceenum.py +9 -0
  123. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionaddressbuilder.py +135 -0
  124. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionaddresspublic.py +128 -0
  125. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionaddressread_output.py +144 -0
  126. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactioncreate.py +618 -0
  127. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionestimaterequest.py +248 -0
  128. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionestimateresponse.py +233 -0
  129. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionexemptstatusenum.py +16 -0
  130. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionimportcustomer.py +154 -0
  131. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionitembuilder.py +414 -0
  132. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionitemcreateupdate.py +423 -0
  133. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionitemestimatebase.py +165 -0
  134. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionitemestimateresponse.py +176 -0
  135. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionitemread.py +248 -0
  136. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionpublicrequest.py +421 -0
  137. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionread.py +429 -0
  138. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionrefundstatus.py +14 -0
  139. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionstatusenum.py +14 -0
  140. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactiontypeenum.py +12 -0
  141. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/transactionupdate.py +616 -0
  142. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/treatmentenum.py +11 -0
  143. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/update_credit_note_by_transaction_id_v1_transactions_original_transaction_id_credit_notes_credit_note_id_putop.py +115 -0
  144. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/update_customer_v1_customers_customer_id_putop.py +104 -0
  145. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/update_product_v1_products_product_id_putop.py +112 -0
  146. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/update_transaction_v1_transactions_transaction_id_putop.py +102 -0
  147. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/upload_exemption_certificate_v1_exemptions_exemption_id_attachments_postop.py +119 -0
  148. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/validationaddress.py +134 -0
  149. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/models/validationerror.py +26 -0
  150. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/nexus.py +242 -0
  151. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/products.py +1180 -0
  152. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/py.typed +1 -0
  153. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/sdk.py +177 -0
  154. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/sdkconfiguration.py +36 -0
  155. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/taxestimation.py +361 -0
  156. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/transactions.py +2955 -0
  157. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/types/__init__.py +21 -0
  158. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/types/basemodel.py +39 -0
  159. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/__init__.py +184 -0
  160. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/annotations.py +55 -0
  161. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/datetimes.py +23 -0
  162. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/enums.py +74 -0
  163. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/eventstreaming.py +238 -0
  164. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/forms.py +223 -0
  165. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/headers.py +136 -0
  166. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/logger.py +22 -0
  167. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/metadata.py +118 -0
  168. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/queryparams.py +205 -0
  169. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/requestbodies.py +66 -0
  170. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/retries.py +217 -0
  171. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/security.py +174 -0
  172. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/serializers.py +249 -0
  173. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/unmarshal_json_response.py +24 -0
  174. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/url.py +155 -0
  175. kintsugi_tax_platform_sdk-0.5.3/src/kintsugi_tax_platform_sdk/utils/values.py +137 -0
@@ -0,0 +1,560 @@
1
+ Metadata-Version: 2.3
2
+ Name: kintsugi-tax-platform-sdk
3
+ Version: 0.5.3
4
+ Summary: Python Client SDK for Kintsugi Tax Platform API.
5
+ Author: Kintsugi Tax
6
+ Requires-Python: >=3.9.2
7
+ Classifier: Programming Language :: Python :: 3
8
+ Classifier: Programming Language :: Python :: 3.10
9
+ Classifier: Programming Language :: Python :: 3.11
10
+ Classifier: Programming Language :: Python :: 3.12
11
+ Classifier: Programming Language :: Python :: 3.13
12
+ Requires-Dist: httpcore (>=1.0.9)
13
+ Requires-Dist: httpx (>=0.28.1)
14
+ Requires-Dist: pydantic (>=2.11.2)
15
+ Project-URL: Repository, https://github.com/kintsugi-tax/kintsugi-speakeasy.git
16
+ Description-Content-Type: text/markdown
17
+
18
+ # openapi
19
+
20
+ Developer-friendly & type-safe Python SDK specifically catered to leverage Kintsugi's tax API.
21
+
22
+ <div align="left">
23
+ <a href="https://www.speakeasy.com/?utm_source=openapi&utm_campaign=python"><img src="https://custom-icon-badges.demolab.com/badge/-Built%20By%20Speakeasy-212015?style=for-the-badge&logoColor=FBE331&logo=speakeasy&labelColor=545454" /></a>
24
+ <a href="https://opensource.org/licenses/MIT">
25
+ <img src="https://img.shields.io/badge/License-MIT-blue.svg" style="width: 100px; height: 28px;" />
26
+ </a>
27
+ </div>
28
+
29
+
30
+ <br /><br />
31
+ <!-- Start Summary [summary] -->
32
+ ## Summary
33
+
34
+
35
+ <!-- End Summary [summary] -->
36
+
37
+ <!-- Start Table of Contents [toc] -->
38
+ ## Table of Contents
39
+ <!-- $toc-max-depth=2 -->
40
+ * [openapi](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#openapi)
41
+ * [SDK Installation](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#sdk-installation)
42
+ * [IDE Support](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#ide-support)
43
+ * [SDK Example Usage](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#sdk-example-usage)
44
+ * [Authentication](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#authentication)
45
+ * [Available Resources and Operations](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#available-resources-and-operations)
46
+ * [File uploads](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#file-uploads)
47
+ * [Retries](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#retries)
48
+ * [Error Handling](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#error-handling)
49
+ * [Custom HTTP Client](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#custom-http-client)
50
+ * [Resource Management](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#resource-management)
51
+ * [Debugging](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#debugging)
52
+ * [Development](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#development)
53
+ * [Maturity](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#maturity)
54
+ * [Contributions](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#contributions)
55
+
56
+ <!-- End Table of Contents [toc] -->
57
+
58
+ <!-- Start SDK Installation [installation] -->
59
+ ## SDK Installation
60
+
61
+ > [!NOTE]
62
+ > **Python version upgrade policy**
63
+ >
64
+ > Once a Python version reaches its [official end of life date](https://devguide.python.org/versions/), a 3-month grace period is provided for users to upgrade. Following this grace period, the minimum python version supported in the SDK will be updated.
65
+
66
+ The SDK can be installed with either *pip* or *poetry* package managers.
67
+
68
+ ### PIP
69
+
70
+ *PIP* is the default package installer for Python, enabling easy installation and management of packages from PyPI via the command line.
71
+
72
+ ```bash
73
+ pip install kintsugi-tax-platform-sdk
74
+ ```
75
+
76
+ ### Poetry
77
+
78
+ *Poetry* is a modern tool that simplifies dependency management and package publishing by using a single `pyproject.toml` file to handle project metadata and dependencies.
79
+
80
+ ```bash
81
+ poetry add kintsugi-tax-platform-sdk
82
+ ```
83
+
84
+ ### Shell and script usage with `uv`
85
+
86
+ You can use this SDK in a Python shell with [uv](https://docs.astral.sh/uv/) and the `uvx` command that comes with it like so:
87
+
88
+ ```shell
89
+ uvx --from kintsugi-tax-platform-sdk python
90
+ ```
91
+
92
+ It's also possible to write a standalone Python script without needing to set up a whole project like so:
93
+
94
+ ```python
95
+ #!/usr/bin/env -S uv run --script
96
+ # /// script
97
+ # requires-python = ">=3.9"
98
+ # dependencies = [
99
+ # "kintsugi-tax-platform-sdk",
100
+ # ]
101
+ # ///
102
+
103
+ from kintsugi_tax_platform_sdk import SDK
104
+
105
+ sdk = SDK(
106
+ # SDK arguments
107
+ )
108
+
109
+ # Rest of script here...
110
+ ```
111
+
112
+ Once that is saved to a file, you can run it with `uv run script.py` where
113
+ `script.py` can be replaced with the actual file name.
114
+ <!-- End SDK Installation [installation] -->
115
+
116
+ <!-- Start IDE Support [idesupport] -->
117
+ ## IDE Support
118
+
119
+ ### PyCharm
120
+
121
+ Generally, the SDK will work well with most IDEs out of the box. However, when using PyCharm, you can enjoy much better integration with Pydantic by installing an additional plugin.
122
+
123
+ - [PyCharm Pydantic Plugin](https://docs.pydantic.dev/latest/integrations/pycharm/)
124
+ <!-- End IDE Support [idesupport] -->
125
+
126
+ <!-- Start SDK Example Usage [usage] -->
127
+ ## SDK Example Usage
128
+
129
+ ### Example
130
+
131
+ ```python
132
+ # Synchronous Example
133
+ from kintsugi_tax_platform_sdk import SDK, models
134
+
135
+
136
+ with SDK(
137
+ server_url="https://api.example.com",
138
+ ) as sdk:
139
+
140
+ res = sdk.address_validation.search(security=models.SearchV1AddressValidationSearchPostSecurity(
141
+ api_key_header="<YOUR_API_KEY_HERE>",
142
+ ), phone="555-123-4567", street_1="1600 Amphitheatre Parkway", street_2="Building 40", city="Mountain View", county="Santa Clara", state="CA", postal_code="94043", country=models.CountryCodeEnum.US, full_address="1600 Amphitheatre Parkway, Mountain View, CA 94043")
143
+
144
+ # Handle response
145
+ print(res)
146
+ ```
147
+
148
+ </br>
149
+
150
+ The same SDK client can also be used to make asychronous requests by importing asyncio.
151
+ ```python
152
+ # Asynchronous Example
153
+ import asyncio
154
+ from kintsugi_tax_platform_sdk import SDK, models
155
+
156
+ async def main():
157
+
158
+ async with SDK(
159
+ server_url="https://api.example.com",
160
+ ) as sdk:
161
+
162
+ res = await sdk.address_validation.search_async(security=models.SearchV1AddressValidationSearchPostSecurity(
163
+ api_key_header="<YOUR_API_KEY_HERE>",
164
+ ), phone="555-123-4567", street_1="1600 Amphitheatre Parkway", street_2="Building 40", city="Mountain View", county="Santa Clara", state="CA", postal_code="94043", country=models.CountryCodeEnum.US, full_address="1600 Amphitheatre Parkway, Mountain View, CA 94043")
165
+
166
+ # Handle response
167
+ print(res)
168
+
169
+ asyncio.run(main())
170
+ ```
171
+ <!-- End SDK Example Usage [usage] -->
172
+
173
+ <!-- Start Authentication [security] -->
174
+ ## Authentication
175
+
176
+ ### Per-Client Security Schemes
177
+
178
+ This SDK supports the following security scheme globally:
179
+
180
+ | Name | Type | Scheme |
181
+ | ---------------- | ------ | ------- |
182
+ | `api_key_header` | apiKey | API key |
183
+
184
+ To authenticate with the API the `api_key_header` parameter must be set when initializing the SDK client instance. For example:
185
+
186
+
187
+ ### Per-Operation Security Schemes
188
+
189
+ Some operations in this SDK require the security scheme to be specified at the request level. For example:
190
+ ```python
191
+ from kintsugi_tax_platform_sdk import SDK, models
192
+
193
+
194
+ with SDK(
195
+ server_url="https://api.example.com",
196
+ ) as sdk:
197
+
198
+ res = sdk.address_validation.search(security=models.SearchV1AddressValidationSearchPostSecurity(
199
+
200
+ ), phone="555-123-4567", street_1="1600 Amphitheatre Parkway", street_2="Building 40", city="Mountain View", county="Santa Clara", state="CA", postal_code="94043", country=models.CountryCodeEnum.US, full_address="1600 Amphitheatre Parkway, Mountain View, CA 94043")
201
+
202
+ # Handle response
203
+ print(res)
204
+
205
+ ```
206
+ <!-- End Authentication [security] -->
207
+
208
+ <!-- Start Available Resources and Operations [operations] -->
209
+ ## Available Resources and Operations
210
+
211
+ <details open>
212
+ <summary>Available methods</summary>
213
+
214
+ ### [address_validation](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/addressvalidation/README.md)
215
+
216
+ * [search](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/addressvalidation/README.md#search) - Search
217
+ * [suggestions](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/addressvalidation/README.md#suggestions) - Suggestions
218
+
219
+ ### [customers](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/customers/README.md)
220
+
221
+ * [list](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/customers/README.md#list) - Get Customers
222
+ * [create](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/customers/README.md#create) - Create Customer
223
+ * [get](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/customers/README.md#get) - Get Customer By Id
224
+ * [update](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/customers/README.md#update) - Update Customer
225
+ * [get_by_external_id](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/customers/README.md#get_by_external_id) - Get Customer By External Id
226
+ * [get_transactions](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/customers/README.md#get_transactions) - Get Transactions By Customer Id
227
+ * [create_transaction](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/customers/README.md#create_transaction) - Create Transaction By Customer Id
228
+
229
+ ### [exemptions](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/exemptions/README.md)
230
+
231
+ * [list](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/exemptions/README.md#list) - Get Exemptions
232
+ * [create](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/exemptions/README.md#create) - Create Exemption
233
+ * [get](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/exemptions/README.md#get) - Get Exemption By Id
234
+ * [upload_certificate](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/exemptions/README.md#upload_certificate) - Upload Exemption Certificate
235
+ * [get_attachments](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/exemptions/README.md#get_attachments) - Get Attachments For Exemption
236
+
237
+ ### [nexus](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/nexus/README.md)
238
+
239
+ * [list](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/nexus/README.md#list) - Get Nexus For Org
240
+
241
+ ### [products](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/products/README.md)
242
+
243
+ * [list](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/products/README.md#list) - Get Products
244
+ * [create](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/products/README.md#create) - Create Product
245
+ * [get](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/products/README.md#get) - Get Product By Id
246
+ * [update](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/products/README.md#update) - Update Product
247
+ * [list_categories](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/products/README.md#list_categories) - Get Product Categories
248
+
249
+
250
+ ### [tax_estimation](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/taxestimation/README.md)
251
+
252
+ * [estimate_tax](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/taxestimation/README.md#estimate_tax) - Estimate Tax
253
+
254
+ ### [transactions](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md)
255
+
256
+ * [list](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md#list) - Get Transactions
257
+ * [create](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md#create) - Create Transaction
258
+ * [get_by_external_id](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md#get_by_external_id) - Get Transaction By External Id
259
+ * [update](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md#update) - Update Transaction
260
+ * [get_by_id](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md#get_by_id) - Get Transaction By Id
261
+ * [get_by_filing_id](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md#get_by_filing_id) - Get Transactions By Filing Id
262
+ * [create_credit_note](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md#create_credit_note) - Create Credit Note By Transaction Id
263
+ * [update_credit_note](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/docs/sdks/transactions/README.md#update_credit_note) - Update Credit Note By Transaction Id
264
+
265
+ </details>
266
+ <!-- End Available Resources and Operations [operations] -->
267
+
268
+ <!-- Start File uploads [file-upload] -->
269
+ ## File uploads
270
+
271
+ Certain SDK methods accept file objects as part of a request body or multi-part request. It is possible and typically recommended to upload files as a stream rather than reading the entire contents into memory. This avoids excessive memory consumption and potentially crashing with out-of-memory errors when working with very large files. The following example demonstrates how to attach a file stream to a request.
272
+
273
+ > [!TIP]
274
+ >
275
+ > For endpoints that handle file uploads bytes arrays can also be used. However, using streams is recommended for large files.
276
+ >
277
+
278
+ ```python
279
+ from kintsugi_tax_platform_sdk import SDK, models
280
+
281
+
282
+ with SDK(
283
+ server_url="https://api.example.com",
284
+ ) as sdk:
285
+
286
+ res = sdk.exemptions.upload_certificate(security=models.UploadExemptionCertificateV1ExemptionsExemptionIDAttachmentsPostSecurity(
287
+ api_key_header="<YOUR_API_KEY_HERE>",
288
+ ), exemption_id="<id>", x_organization_id="org_12345", file={
289
+ "file_name": "example.file",
290
+ "content": open("example.file", "rb"),
291
+ })
292
+
293
+ # Handle response
294
+ print(res)
295
+
296
+ ```
297
+ <!-- End File uploads [file-upload] -->
298
+
299
+ <!-- Start Retries [retries] -->
300
+ ## Retries
301
+
302
+ Some of the endpoints in this SDK support retries. If you use the SDK without any configuration, it will fall back to the default retry strategy provided by the API. However, the default retry strategy can be overridden on a per-operation basis, or across the entire SDK.
303
+
304
+ To change the default retry strategy for a single API call, simply provide a `RetryConfig` object to the call:
305
+ ```python
306
+ from kintsugi_tax_platform_sdk import SDK, models
307
+ from kintsugi_tax_platform_sdk.utils import BackoffStrategy, RetryConfig
308
+
309
+
310
+ with SDK(
311
+ server_url="https://api.example.com",
312
+ ) as sdk:
313
+
314
+ res = sdk.address_validation.search(security=models.SearchV1AddressValidationSearchPostSecurity(
315
+ api_key_header="<YOUR_API_KEY_HERE>",
316
+ ), phone="555-123-4567", street_1="1600 Amphitheatre Parkway", street_2="Building 40", city="Mountain View", county="Santa Clara", state="CA", postal_code="94043", country=models.CountryCodeEnum.US, full_address="1600 Amphitheatre Parkway, Mountain View, CA 94043",
317
+ RetryConfig("backoff", BackoffStrategy(1, 50, 1.1, 100), False))
318
+
319
+ # Handle response
320
+ print(res)
321
+
322
+ ```
323
+
324
+ If you'd like to override the default retry strategy for all operations that support retries, you can use the `retry_config` optional parameter when initializing the SDK:
325
+ ```python
326
+ from kintsugi_tax_platform_sdk import SDK, models
327
+ from kintsugi_tax_platform_sdk.utils import BackoffStrategy, RetryConfig
328
+
329
+
330
+ with SDK(
331
+ server_url="https://api.example.com",
332
+ retry_config=RetryConfig("backoff", BackoffStrategy(1, 50, 1.1, 100), False),
333
+ ) as sdk:
334
+
335
+ res = sdk.address_validation.search(security=models.SearchV1AddressValidationSearchPostSecurity(
336
+ api_key_header="<YOUR_API_KEY_HERE>",
337
+ ), phone="555-123-4567", street_1="1600 Amphitheatre Parkway", street_2="Building 40", city="Mountain View", county="Santa Clara", state="CA", postal_code="94043", country=models.CountryCodeEnum.US, full_address="1600 Amphitheatre Parkway, Mountain View, CA 94043")
338
+
339
+ # Handle response
340
+ print(res)
341
+
342
+ ```
343
+ <!-- End Retries [retries] -->
344
+
345
+ <!-- Start Error Handling [errors] -->
346
+ ## Error Handling
347
+
348
+ [`SDKError`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/sdkerror.py) is the base class for all HTTP error responses. It has the following properties:
349
+
350
+ | Property | Type | Description |
351
+ | ------------------ | ---------------- | --------------------------------------------------------------------------------------- |
352
+ | `err.message` | `str` | Error message |
353
+ | `err.status_code` | `int` | HTTP response status code eg `404` |
354
+ | `err.headers` | `httpx.Headers` | HTTP response headers |
355
+ | `err.body` | `str` | HTTP body. Can be empty string if no body is returned. |
356
+ | `err.raw_response` | `httpx.Response` | Raw HTTP response |
357
+ | `err.data` | | Optional. Some errors may contain structured data. [See Error Classes](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#error-classes). |
358
+
359
+ ### Example
360
+ ```python
361
+ from kintsugi_tax_platform_sdk import SDK, errors, models
362
+
363
+
364
+ with SDK(
365
+ server_url="https://api.example.com",
366
+ ) as sdk:
367
+ res = None
368
+ try:
369
+
370
+ res = sdk.address_validation.search(security=models.SearchV1AddressValidationSearchPostSecurity(
371
+ api_key_header="<YOUR_API_KEY_HERE>",
372
+ ), phone="555-123-4567", street_1="1600 Amphitheatre Parkway", street_2="Building 40", city="Mountain View", county="Santa Clara", state="CA", postal_code="94043", country=models.CountryCodeEnum.US, full_address="1600 Amphitheatre Parkway, Mountain View, CA 94043")
373
+
374
+ # Handle response
375
+ print(res)
376
+
377
+
378
+ except errors.SDKError as e:
379
+ # The base class for HTTP error responses
380
+ print(e.message)
381
+ print(e.status_code)
382
+ print(e.body)
383
+ print(e.headers)
384
+ print(e.raw_response)
385
+
386
+ # Depending on the method different errors may be thrown
387
+ if isinstance(e, errors.ErrorResponse):
388
+ print(e.data.detail) # str
389
+ ```
390
+
391
+ ### Error Classes
392
+ **Primary error:**
393
+ * [`SDKError`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/sdkerror.py): The base class for HTTP error responses.
394
+
395
+ <details><summary>Less common errors (13)</summary>
396
+
397
+ <br />
398
+
399
+ **Network errors:**
400
+ * [`httpx.RequestError`](https://www.python-httpx.org/exceptions/#httpx.RequestError): Base class for request errors.
401
+ * [`httpx.ConnectError`](https://www.python-httpx.org/exceptions/#httpx.ConnectError): HTTP client was unable to make a request to a server.
402
+ * [`httpx.TimeoutException`](https://www.python-httpx.org/exceptions/#httpx.TimeoutException): HTTP request timed out.
403
+
404
+
405
+ **Inherit from [`SDKError`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/sdkerror.py)**:
406
+ * [`ErrorResponse`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/errorresponse.py): Applicable to 20 of 29 methods.*
407
+ * [`HTTPValidationError`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/httpvalidationerror.py): Validation Error. Status code `422`. Applicable to 9 of 29 methods.*
408
+ * [`BackendSrcExemptionsResponsesValidationErrorResponse`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/backendsrcexemptionsresponsesvalidationerrorresponse.py): Validation issues, such as missing required fields or invalid field values. Status code `422`. Applicable to 5 of 29 methods.*
409
+ * [`BackendSrcTransactionsResponsesValidationErrorResponse`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/backendsrctransactionsresponsesvalidationerrorresponse.py): Status code `422`. Applicable to 5 of 29 methods.*
410
+ * [`BackendSrcProductsResponsesValidationErrorResponse`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/backendsrcproductsresponsesvalidationerrorresponse.py): Validation error. Status code `422`. Applicable to 4 of 29 methods.*
411
+ * [`BackendSrcCustomersResponsesValidationErrorResponse`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/backendsrccustomersresponsesvalidationerrorresponse.py): Query parameters failed validation, such as an out-of-range page number. Status code `422`. Applicable to 3 of 29 methods.*
412
+ * [`BackendSrcAddressValidationResponsesValidationErrorResponse`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/backendsrcaddressvalidationresponsesvalidationerrorresponse.py): Validation error - Address fields failed validation or are incomplete. Status code `422`. Applicable to 2 of 29 methods.*
413
+ * [`BackendSrcTaxEstimationResponsesValidationErrorResponse`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/backendsrctaxestimationresponsesvalidationerrorresponse.py): Validation Error. Status code `422`. Applicable to 1 of 29 methods.*
414
+ * [`ResponseValidationError`](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/./src/kintsugi_tax_platform_sdk/errors/responsevalidationerror.py): Type mismatch between the response data and the expected Pydantic model. Provides access to the Pydantic validation error via the `cause` attribute.
415
+
416
+ </details>
417
+
418
+ \* Check [the method documentation](https://github.com/kintsugi-tax/kintsugi-speakeasy/blob/master/#available-resources-and-operations) to see if the error is applicable.
419
+ <!-- End Error Handling [errors] -->
420
+
421
+ <!-- Start Custom HTTP Client [http-client] -->
422
+ ## Custom HTTP Client
423
+
424
+ The Python SDK makes API calls using the [httpx](https://www.python-httpx.org/) HTTP library. In order to provide a convenient way to configure timeouts, cookies, proxies, custom headers, and other low-level configuration, you can initialize the SDK client with your own HTTP client instance.
425
+ Depending on whether you are using the sync or async version of the SDK, you can pass an instance of `HttpClient` or `AsyncHttpClient` respectively, which are Protocol's ensuring that the client has the necessary methods to make API calls.
426
+ This allows you to wrap the client with your own custom logic, such as adding custom headers, logging, or error handling, or you can just pass an instance of `httpx.Client` or `httpx.AsyncClient` directly.
427
+
428
+ For example, you could specify a header for every request that this sdk makes as follows:
429
+ ```python
430
+ from kintsugi_tax_platform_sdk import SDK
431
+ import httpx
432
+
433
+ http_client = httpx.Client(headers={"x-custom-header": "someValue"})
434
+ s = SDK(client=http_client)
435
+ ```
436
+
437
+ or you could wrap the client with your own custom logic:
438
+ ```python
439
+ from kintsugi_tax_platform_sdk import SDK
440
+ from kintsugi_tax_platform_sdk.httpclient import AsyncHttpClient
441
+ import httpx
442
+
443
+ class CustomClient(AsyncHttpClient):
444
+ client: AsyncHttpClient
445
+
446
+ def __init__(self, client: AsyncHttpClient):
447
+ self.client = client
448
+
449
+ async def send(
450
+ self,
451
+ request: httpx.Request,
452
+ *,
453
+ stream: bool = False,
454
+ auth: Union[
455
+ httpx._types.AuthTypes, httpx._client.UseClientDefault, None
456
+ ] = httpx.USE_CLIENT_DEFAULT,
457
+ follow_redirects: Union[
458
+ bool, httpx._client.UseClientDefault
459
+ ] = httpx.USE_CLIENT_DEFAULT,
460
+ ) -> httpx.Response:
461
+ request.headers["Client-Level-Header"] = "added by client"
462
+
463
+ return await self.client.send(
464
+ request, stream=stream, auth=auth, follow_redirects=follow_redirects
465
+ )
466
+
467
+ def build_request(
468
+ self,
469
+ method: str,
470
+ url: httpx._types.URLTypes,
471
+ *,
472
+ content: Optional[httpx._types.RequestContent] = None,
473
+ data: Optional[httpx._types.RequestData] = None,
474
+ files: Optional[httpx._types.RequestFiles] = None,
475
+ json: Optional[Any] = None,
476
+ params: Optional[httpx._types.QueryParamTypes] = None,
477
+ headers: Optional[httpx._types.HeaderTypes] = None,
478
+ cookies: Optional[httpx._types.CookieTypes] = None,
479
+ timeout: Union[
480
+ httpx._types.TimeoutTypes, httpx._client.UseClientDefault
481
+ ] = httpx.USE_CLIENT_DEFAULT,
482
+ extensions: Optional[httpx._types.RequestExtensions] = None,
483
+ ) -> httpx.Request:
484
+ return self.client.build_request(
485
+ method,
486
+ url,
487
+ content=content,
488
+ data=data,
489
+ files=files,
490
+ json=json,
491
+ params=params,
492
+ headers=headers,
493
+ cookies=cookies,
494
+ timeout=timeout,
495
+ extensions=extensions,
496
+ )
497
+
498
+ s = SDK(async_client=CustomClient(httpx.AsyncClient()))
499
+ ```
500
+ <!-- End Custom HTTP Client [http-client] -->
501
+
502
+ <!-- Start Resource Management [resource-management] -->
503
+ ## Resource Management
504
+
505
+ The `SDK` class implements the context manager protocol and registers a finalizer function to close the underlying sync and async HTTPX clients it uses under the hood. This will close HTTP connections, release memory and free up other resources held by the SDK. In short-lived Python programs and notebooks that make a few SDK method calls, resource management may not be a concern. However, in longer-lived programs, it is beneficial to create a single SDK instance via a [context manager][context-manager] and reuse it across the application.
506
+
507
+ [context-manager]: https://docs.python.org/3/reference/datamodel.html#context-managers
508
+
509
+ ```python
510
+ from kintsugi_tax_platform_sdk import SDK
511
+ def main():
512
+
513
+ with SDK(
514
+ server_url="https://api.example.com",
515
+ ) as sdk:
516
+ # Rest of application here...
517
+
518
+
519
+ # Or when using async:
520
+ async def amain():
521
+
522
+ async with SDK(
523
+ server_url="https://api.example.com",
524
+ ) as sdk:
525
+ # Rest of application here...
526
+ ```
527
+ <!-- End Resource Management [resource-management] -->
528
+
529
+ <!-- Start Debugging [debug] -->
530
+ ## Debugging
531
+
532
+ You can setup your SDK to emit debug logs for SDK requests and responses.
533
+
534
+ You can pass your own logger class directly into your SDK.
535
+ ```python
536
+ from kintsugi_tax_platform_sdk import SDK
537
+ import logging
538
+
539
+ logging.basicConfig(level=logging.DEBUG)
540
+ s = SDK(server_url="https://example.com", debug_logger=logging.getLogger("kintsugi_tax_platform_sdk"))
541
+ ```
542
+ <!-- End Debugging [debug] -->
543
+
544
+ <!-- Placeholder for Future Speakeasy SDK Sections -->
545
+
546
+ # Development
547
+
548
+ ## Maturity
549
+
550
+ This SDK is in beta, and there may be breaking changes between versions without a major version update. Therefore, we recommend pinning usage
551
+ to a specific package version. This way, you can install the same version each time without breaking changes unless you are intentionally
552
+ looking for the latest version.
553
+
554
+ ## Contributions
555
+
556
+ While we value open-source contributions to this SDK, this library is generated programmatically. Any manual changes added to internal files will be overwritten on the next generation.
557
+ We look forward to hearing your feedback. Feel free to open a PR or an issue with a proof of concept and we'll do our best to include it in a future release.
558
+
559
+ ### SDK Created by [Speakeasy](https://www.speakeasy.com/?utm_source=openapi&utm_campaign=python)
560
+