@chrt-inc/typescript-sdk 1.998.0 → 1.999.0

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 (214) hide show
  1. package/dist/cjs/Client.js +2 -2
  2. package/dist/cjs/api/resources/billingNew/client/Client.d.ts +3 -0
  3. package/dist/cjs/api/resources/billingNew/client/Client.js +5 -0
  4. package/dist/cjs/api/resources/billingNew/resources/billingPeriods/client/Client.d.ts +2 -2
  5. package/dist/cjs/api/resources/billingNew/resources/billingPeriods/client/Client.js +1 -1
  6. package/dist/cjs/api/resources/billingNew/resources/chrtGroundProviderRates/client/requests/ChrtGroundProviderRatesClientCreate1.d.ts +0 -3
  7. package/dist/cjs/api/resources/billingNew/resources/chrtGroundProviderRates/client/requests/ChrtGroundProviderRatesClientUpdate1.d.ts +0 -6
  8. package/dist/cjs/api/resources/billingNew/resources/index.d.ts +2 -0
  9. package/dist/cjs/api/resources/billingNew/resources/index.js +3 -1
  10. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/Client.d.ts +17 -73
  11. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/Client.js +50 -193
  12. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/{resources/export/client → client}/requests/InvoiceLineItemExportListReq.d.ts +1 -0
  13. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/index.d.ts +1 -3
  14. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/index.d.ts +0 -1
  15. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/index.js +0 -1
  16. package/dist/cjs/api/resources/billingNew/resources/invoices/client/Client.d.ts +57 -32
  17. package/dist/cjs/api/resources/billingNew/resources/invoices/client/Client.js +169 -89
  18. package/dist/cjs/api/resources/billingNew/resources/invoices/client/requests/index.d.ts +0 -1
  19. package/dist/cjs/api/resources/billingNew/resources/orders/client/Client.d.ts +28 -3
  20. package/dist/cjs/api/resources/billingNew/resources/orders/client/Client.js +126 -5
  21. package/dist/cjs/api/resources/billingNew/resources/orders/client/requests/index.d.ts +1 -0
  22. package/dist/cjs/api/resources/billingNew/resources/orders/index.d.ts +0 -1
  23. package/dist/cjs/api/resources/billingNew/resources/orders/index.js +0 -1
  24. package/dist/cjs/api/resources/billingNew/resources/taxConfigurations/client/Client.d.ts +128 -0
  25. package/dist/cjs/api/resources/billingNew/resources/taxConfigurations/client/Client.js +485 -0
  26. package/dist/cjs/api/resources/billingNew/resources/taxConfigurations/client/requests/TaxConfigurationClientCreate1.d.ts +21 -0
  27. package/dist/cjs/api/resources/billingNew/resources/taxConfigurations/client/requests/TaxConfigurationClientUpdate1.d.ts +12 -0
  28. package/dist/cjs/api/resources/billingNew/resources/taxConfigurations/client/requests/TaxConfigurationResolveReq.d.ts +14 -0
  29. package/dist/cjs/api/resources/billingNew/resources/taxConfigurations/client/requests/TaxConfigurationsListV1Request.d.ts +33 -0
  30. package/dist/cjs/api/resources/billingNew/resources/taxConfigurations/client/requests/index.d.ts +4 -0
  31. package/dist/cjs/api/resources/flights/client/Client.d.ts +1 -1
  32. package/dist/cjs/api/resources/flights/client/Client.js +1 -1
  33. package/dist/cjs/api/types/BillingCurrencyCodeEnum1.d.ts +1 -2
  34. package/dist/cjs/api/types/BillingCurrencyCodeEnum1.js +0 -1
  35. package/dist/cjs/api/types/BillingPeriodCloseRes.d.ts +8 -0
  36. package/dist/cjs/api/types/CalculatedInvoiceTax1.d.ts +12 -0
  37. package/dist/cjs/api/types/ChrtGroundProviderRates1.d.ts +0 -3
  38. package/dist/cjs/api/types/{CreateInvoiceLineItemsFromAwbCostsInvoiceRes1.d.ts → CreateInvoiceLineItemsFromAwbCostsGroupRes1.d.ts} +2 -2
  39. package/dist/cjs/api/types/CreateInvoiceLineItemsFromAwbCostsRes.d.ts +1 -1
  40. package/dist/cjs/api/{resources/billingNew/resources/invoices/client/requests → types}/InvoiceClientCreate1.d.ts +1 -9
  41. package/dist/cjs/api/types/InvoiceCreateFromOrdersReq.d.ts +22 -0
  42. package/dist/cjs/api/types/InvoiceCreateFromOrdersRes.d.ts +14 -0
  43. package/dist/cjs/api/types/InvoiceCreateFromOrdersRes.js +5 -0
  44. package/dist/cjs/api/types/InvoiceCreateReq.d.ts +20 -0
  45. package/dist/cjs/api/types/InvoiceCreateReq.js +5 -0
  46. package/dist/cjs/api/types/InvoiceLineItemExportListItem.d.ts +3 -2
  47. package/dist/cjs/api/types/InvoiceLineItemTypeEnum1.d.ts +2 -4
  48. package/dist/cjs/api/types/InvoiceLineItemTypeEnum1.js +1 -3
  49. package/dist/cjs/api/types/InvoicePreviewFromOrdersRes.d.ts +15 -0
  50. package/dist/cjs/api/types/InvoicePreviewFromOrdersRes.js +5 -0
  51. package/dist/cjs/api/types/InvoicePreviewRes.d.ts +10 -0
  52. package/dist/cjs/api/types/InvoicePreviewRes.js +5 -0
  53. package/dist/cjs/api/types/InvoiceTaxCalculation1.d.ts +12 -0
  54. package/dist/cjs/api/types/InvoiceTaxCalculation1.js +5 -0
  55. package/dist/cjs/api/types/TaxConfiguration1.d.ts +24 -0
  56. package/dist/cjs/api/types/TaxConfiguration1.js +5 -0
  57. package/dist/cjs/api/types/TaxConfigurationListRes.d.ts +8 -0
  58. package/dist/cjs/api/types/TaxConfigurationListRes.js +5 -0
  59. package/dist/cjs/api/types/TaxConfigurationSortByEnum.d.ts +8 -0
  60. package/dist/cjs/api/types/TaxConfigurationSortByEnum.js +10 -0
  61. package/dist/cjs/api/types/{TaxRate1.d.ts → TaxRule1.d.ts} +2 -3
  62. package/dist/cjs/api/types/TaxRule1.js +5 -0
  63. package/dist/cjs/api/types/index.d.ts +14 -6
  64. package/dist/cjs/api/types/index.js +14 -6
  65. package/dist/cjs/version.d.ts +1 -1
  66. package/dist/cjs/version.js +1 -1
  67. package/dist/esm/Client.mjs +2 -2
  68. package/dist/esm/api/resources/billingNew/client/Client.d.mts +3 -0
  69. package/dist/esm/api/resources/billingNew/client/Client.mjs +5 -0
  70. package/dist/esm/api/resources/billingNew/resources/billingPeriods/client/Client.d.mts +2 -2
  71. package/dist/esm/api/resources/billingNew/resources/billingPeriods/client/Client.mjs +1 -1
  72. package/dist/esm/api/resources/billingNew/resources/chrtGroundProviderRates/client/requests/ChrtGroundProviderRatesClientCreate1.d.mts +0 -3
  73. package/dist/esm/api/resources/billingNew/resources/chrtGroundProviderRates/client/requests/ChrtGroundProviderRatesClientUpdate1.d.mts +0 -6
  74. package/dist/esm/api/resources/billingNew/resources/index.d.mts +2 -0
  75. package/dist/esm/api/resources/billingNew/resources/index.mjs +2 -0
  76. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/Client.d.mts +17 -73
  77. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/Client.mjs +50 -193
  78. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/{resources/export/client → client}/requests/InvoiceLineItemExportListReq.d.mts +1 -0
  79. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/index.d.mts +1 -3
  80. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/index.d.mts +0 -1
  81. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/index.mjs +0 -1
  82. package/dist/esm/api/resources/billingNew/resources/invoices/client/Client.d.mts +57 -32
  83. package/dist/esm/api/resources/billingNew/resources/invoices/client/Client.mjs +169 -89
  84. package/dist/esm/api/resources/billingNew/resources/invoices/client/requests/index.d.mts +0 -1
  85. package/dist/esm/api/resources/billingNew/resources/orders/client/Client.d.mts +28 -3
  86. package/dist/esm/api/resources/billingNew/resources/orders/client/Client.mjs +126 -5
  87. package/dist/esm/api/resources/billingNew/resources/orders/client/requests/index.d.mts +1 -0
  88. package/dist/esm/api/resources/billingNew/resources/orders/index.d.mts +0 -1
  89. package/dist/esm/api/resources/billingNew/resources/orders/index.mjs +0 -1
  90. package/dist/esm/api/resources/billingNew/resources/taxConfigurations/client/Client.d.mts +128 -0
  91. package/dist/esm/api/resources/billingNew/resources/taxConfigurations/client/Client.mjs +448 -0
  92. package/dist/esm/api/resources/billingNew/resources/taxConfigurations/client/requests/TaxConfigurationClientCreate1.d.mts +21 -0
  93. package/dist/esm/api/resources/billingNew/resources/taxConfigurations/client/requests/TaxConfigurationClientUpdate1.d.mts +12 -0
  94. package/dist/esm/api/resources/billingNew/resources/taxConfigurations/client/requests/TaxConfigurationResolveReq.d.mts +14 -0
  95. package/dist/esm/api/resources/billingNew/resources/taxConfigurations/client/requests/TaxConfigurationsListV1Request.d.mts +33 -0
  96. package/dist/esm/api/resources/billingNew/resources/taxConfigurations/client/requests/index.d.mts +4 -0
  97. package/dist/esm/api/resources/flights/client/Client.d.mts +1 -1
  98. package/dist/esm/api/resources/flights/client/Client.mjs +1 -1
  99. package/dist/esm/api/types/BillingCurrencyCodeEnum1.d.mts +1 -2
  100. package/dist/esm/api/types/BillingCurrencyCodeEnum1.mjs +0 -1
  101. package/dist/esm/api/types/BillingPeriodCloseRes.d.mts +8 -0
  102. package/dist/esm/api/types/CalculatedInvoiceTax1.d.mts +12 -0
  103. package/dist/esm/api/types/ChrtGroundProviderRates1.d.mts +0 -3
  104. package/dist/esm/api/types/{CreateInvoiceLineItemsFromAwbCostsInvoiceRes1.d.mts → CreateInvoiceLineItemsFromAwbCostsGroupRes1.d.mts} +2 -2
  105. package/dist/esm/api/types/CreateInvoiceLineItemsFromAwbCostsRes.d.mts +1 -1
  106. package/dist/esm/api/{resources/billingNew/resources/invoices/client/requests → types}/InvoiceClientCreate1.d.mts +1 -9
  107. package/dist/esm/api/types/InvoiceCreateFromOrdersReq.d.mts +22 -0
  108. package/dist/esm/api/types/InvoiceCreateFromOrdersRes.d.mts +14 -0
  109. package/dist/esm/api/types/InvoiceCreateFromOrdersRes.mjs +4 -0
  110. package/dist/esm/api/types/InvoiceCreateReq.d.mts +20 -0
  111. package/dist/esm/api/types/InvoiceCreateReq.mjs +4 -0
  112. package/dist/esm/api/types/InvoiceLineItemExportListItem.d.mts +3 -2
  113. package/dist/esm/api/types/InvoiceLineItemTypeEnum1.d.mts +2 -4
  114. package/dist/esm/api/types/InvoiceLineItemTypeEnum1.mjs +1 -3
  115. package/dist/esm/api/types/InvoicePreviewFromOrdersRes.d.mts +15 -0
  116. package/dist/esm/api/types/InvoicePreviewFromOrdersRes.mjs +4 -0
  117. package/dist/esm/api/types/InvoicePreviewRes.d.mts +10 -0
  118. package/dist/esm/api/types/InvoicePreviewRes.mjs +4 -0
  119. package/dist/esm/api/types/InvoiceTaxCalculation1.d.mts +12 -0
  120. package/dist/esm/api/types/InvoiceTaxCalculation1.mjs +4 -0
  121. package/dist/esm/api/types/TaxConfiguration1.d.mts +24 -0
  122. package/dist/esm/api/types/TaxConfiguration1.mjs +4 -0
  123. package/dist/esm/api/types/TaxConfigurationListRes.d.mts +8 -0
  124. package/dist/esm/api/types/TaxConfigurationListRes.mjs +4 -0
  125. package/dist/esm/api/types/TaxConfigurationSortByEnum.d.mts +8 -0
  126. package/dist/esm/api/types/TaxConfigurationSortByEnum.mjs +7 -0
  127. package/dist/esm/api/types/{TaxRate1.d.mts → TaxRule1.d.mts} +2 -3
  128. package/dist/esm/api/types/TaxRule1.mjs +4 -0
  129. package/dist/esm/api/types/index.d.mts +14 -6
  130. package/dist/esm/api/types/index.mjs +14 -6
  131. package/dist/esm/version.d.mts +1 -1
  132. package/dist/esm/version.mjs +1 -1
  133. package/package.json +1 -1
  134. package/reference.md +520 -219
  135. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/CreateInvoiceLineItemsFromAmountReq.d.ts +0 -32
  136. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/CreateInvoiceLineItemsFromLineItemsReq.d.ts +0 -46
  137. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/RecalculateOrderTaxInvoiceLineItemsReq.d.ts +0 -12
  138. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/Client.d.ts +0 -51
  139. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/Client.js +0 -153
  140. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/requests/index.d.ts +0 -1
  141. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/resources/index.d.ts +0 -2
  142. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/resources/index.js +0 -41
  143. package/dist/cjs/api/resources/billingNew/resources/orders/resources/index.d.ts +0 -2
  144. package/dist/cjs/api/resources/billingNew/resources/orders/resources/index.js +0 -41
  145. package/dist/cjs/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/Client.d.ts +0 -49
  146. package/dist/cjs/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/Client.js +0 -135
  147. package/dist/cjs/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/index.d.ts +0 -2
  148. package/dist/cjs/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/index.js +0 -17
  149. package/dist/cjs/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/requests/index.d.ts +0 -1
  150. package/dist/cjs/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/requests/index.js +0 -2
  151. package/dist/cjs/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/index.d.ts +0 -1
  152. package/dist/cjs/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/index.js +0 -17
  153. package/dist/cjs/api/types/CreateInvoiceLineItemsFromAmountRes.d.ts +0 -7
  154. package/dist/cjs/api/types/CreateInvoiceLineItemsFromLineItemsRes.d.ts +0 -7
  155. package/dist/cjs/api/types/InvoiceLineItemAmountTransformation1.d.ts +0 -8
  156. package/dist/cjs/api/types/InvoiceLineItemAmountTransformationTypeEnum1.d.ts +0 -9
  157. package/dist/cjs/api/types/InvoiceLineItemAmountTransformationTypeEnum1.js +0 -11
  158. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/CreateInvoiceLineItemsFromAmountReq.d.mts +0 -32
  159. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/CreateInvoiceLineItemsFromLineItemsReq.d.mts +0 -46
  160. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/RecalculateOrderTaxInvoiceLineItemsReq.d.mts +0 -12
  161. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/Client.d.mts +0 -51
  162. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/Client.mjs +0 -116
  163. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/requests/index.d.mts +0 -1
  164. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/resources/index.d.mts +0 -2
  165. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/resources/index.mjs +0 -2
  166. package/dist/esm/api/resources/billingNew/resources/orders/resources/index.d.mts +0 -2
  167. package/dist/esm/api/resources/billingNew/resources/orders/resources/index.mjs +0 -2
  168. package/dist/esm/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/Client.d.mts +0 -49
  169. package/dist/esm/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/Client.mjs +0 -98
  170. package/dist/esm/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/index.d.mts +0 -2
  171. package/dist/esm/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/index.mjs +0 -1
  172. package/dist/esm/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/requests/index.d.mts +0 -1
  173. package/dist/esm/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/client/requests/index.mjs +0 -1
  174. package/dist/esm/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/index.d.mts +0 -1
  175. package/dist/esm/api/resources/billingNew/resources/orders/resources/rateSheetLineItems/index.mjs +0 -1
  176. package/dist/esm/api/types/CreateInvoiceLineItemsFromAmountRes.d.mts +0 -7
  177. package/dist/esm/api/types/CreateInvoiceLineItemsFromLineItemsRes.d.mts +0 -7
  178. package/dist/esm/api/types/InvoiceLineItemAmountTransformation1.d.mts +0 -8
  179. package/dist/esm/api/types/InvoiceLineItemAmountTransformationTypeEnum1.d.mts +0 -9
  180. package/dist/esm/api/types/InvoiceLineItemAmountTransformationTypeEnum1.mjs +0 -8
  181. /package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/{resources/export/client → client}/requests/InvoiceLineItemExportListReq.js +0 -0
  182. /package/dist/cjs/api/resources/billingNew/resources/orders/{resources/rateSheetLineItems/client → client}/requests/OrderRateSheetLineItemsGenerateManyReq.d.ts +0 -0
  183. /package/dist/cjs/api/resources/billingNew/resources/orders/{resources/rateSheetLineItems/client → client}/requests/OrderRateSheetLineItemsGenerateManyReq.js +0 -0
  184. /package/dist/cjs/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/client/index.d.ts +0 -0
  185. /package/dist/cjs/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/client/index.js +0 -0
  186. /package/dist/cjs/api/resources/billingNew/resources/{invoiceLineItems/client/requests/CreateInvoiceLineItemsFromAmountReq.js → taxConfigurations/client/requests/TaxConfigurationClientCreate1.js} +0 -0
  187. /package/dist/cjs/api/resources/billingNew/resources/{invoiceLineItems/client/requests/CreateInvoiceLineItemsFromLineItemsReq.js → taxConfigurations/client/requests/TaxConfigurationClientUpdate1.js} +0 -0
  188. /package/dist/cjs/api/resources/billingNew/resources/{invoiceLineItems/client/requests/RecalculateOrderTaxInvoiceLineItemsReq.js → taxConfigurations/client/requests/TaxConfigurationResolveReq.js} +0 -0
  189. /package/dist/cjs/api/resources/billingNew/resources/{invoices/client/requests/InvoiceClientCreate1.js → taxConfigurations/client/requests/TaxConfigurationsListV1Request.js} +0 -0
  190. /package/dist/cjs/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/client/requests/index.js +0 -0
  191. /package/dist/cjs/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/index.d.ts +0 -0
  192. /package/dist/cjs/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/index.js +0 -0
  193. /package/dist/cjs/api/types/{CreateInvoiceLineItemsFromAmountRes.js → BillingPeriodCloseRes.js} +0 -0
  194. /package/dist/cjs/api/types/{CreateInvoiceLineItemsFromAwbCostsInvoiceRes1.js → CalculatedInvoiceTax1.js} +0 -0
  195. /package/dist/cjs/api/types/{CreateInvoiceLineItemsFromLineItemsRes.js → CreateInvoiceLineItemsFromAwbCostsGroupRes1.js} +0 -0
  196. /package/dist/cjs/api/types/{InvoiceLineItemAmountTransformation1.js → InvoiceClientCreate1.js} +0 -0
  197. /package/dist/cjs/api/types/{TaxRate1.js → InvoiceCreateFromOrdersReq.js} +0 -0
  198. /package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/{resources/export/client → client}/requests/InvoiceLineItemExportListReq.mjs +0 -0
  199. /package/dist/esm/api/resources/billingNew/resources/orders/{resources/rateSheetLineItems/client → client}/requests/OrderRateSheetLineItemsGenerateManyReq.d.mts +0 -0
  200. /package/dist/esm/api/resources/billingNew/resources/orders/{resources/rateSheetLineItems/client → client}/requests/OrderRateSheetLineItemsGenerateManyReq.mjs +0 -0
  201. /package/dist/esm/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/client/index.d.mts +0 -0
  202. /package/dist/esm/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/client/index.mjs +0 -0
  203. /package/dist/esm/api/resources/billingNew/resources/{invoiceLineItems/client/requests/CreateInvoiceLineItemsFromAmountReq.mjs → taxConfigurations/client/requests/TaxConfigurationClientCreate1.mjs} +0 -0
  204. /package/dist/esm/api/resources/billingNew/resources/{invoiceLineItems/client/requests/CreateInvoiceLineItemsFromLineItemsReq.mjs → taxConfigurations/client/requests/TaxConfigurationClientUpdate1.mjs} +0 -0
  205. /package/dist/esm/api/resources/billingNew/resources/{invoiceLineItems/client/requests/RecalculateOrderTaxInvoiceLineItemsReq.mjs → taxConfigurations/client/requests/TaxConfigurationResolveReq.mjs} +0 -0
  206. /package/dist/esm/api/resources/billingNew/resources/{invoices/client/requests/InvoiceClientCreate1.mjs → taxConfigurations/client/requests/TaxConfigurationsListV1Request.mjs} +0 -0
  207. /package/dist/esm/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/client/requests/index.mjs +0 -0
  208. /package/dist/esm/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/index.d.mts +0 -0
  209. /package/dist/esm/api/resources/billingNew/resources/{invoiceLineItems/resources/export → taxConfigurations}/index.mjs +0 -0
  210. /package/dist/esm/api/types/{CreateInvoiceLineItemsFromAmountRes.mjs → BillingPeriodCloseRes.mjs} +0 -0
  211. /package/dist/esm/api/types/{CreateInvoiceLineItemsFromAwbCostsInvoiceRes1.mjs → CalculatedInvoiceTax1.mjs} +0 -0
  212. /package/dist/esm/api/types/{CreateInvoiceLineItemsFromLineItemsRes.mjs → CreateInvoiceLineItemsFromAwbCostsGroupRes1.mjs} +0 -0
  213. /package/dist/esm/api/types/{InvoiceLineItemAmountTransformation1.mjs → InvoiceClientCreate1.mjs} +0 -0
  214. /package/dist/esm/api/types/{TaxRate1.mjs → InvoiceCreateFromOrdersReq.mjs} +0 -0
@@ -115,9 +115,9 @@ class Invoices {
115
115
  });
116
116
  }
117
117
  /**
118
- * Returns the matching draft invoice period, or creates one with an optional rolling-month default. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceClientCreate1) -> (PydanticObjectId)
118
+ * Creates a new draft invoice, optionally attaching selected uninvoiced charges atomically. Omitted dates derive from completed deliveries; empty drafts and charges without completed delivery dates require explicit bounds. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceCreateReq) -> (PydanticObjectId)
119
119
  *
120
- * @param {Chrt.billingNew.InvoiceClientCreate1} request
120
+ * @param {Chrt.InvoiceCreateReq} request
121
121
  * @param {Invoices.RequestOptions} requestOptions - Request-specific configuration.
122
122
  *
123
123
  * @throws {@link Chrt.UnprocessableEntityError}
@@ -181,87 +181,36 @@ class Invoices {
181
181
  });
182
182
  }
183
183
  /**
184
- * Hard-deletes a draft invoice and detaches its line items. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (bool)
184
+ * Creates one draft from matching order charges and reports skipped items. Billing period dates do not filter charges. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceCreateFromOrdersReq) -> (InvoiceCreateFromOrdersRes)
185
185
  *
186
- * @param {string} invoiceId
186
+ * @param {Chrt.InvoiceCreateFromOrdersReq} request
187
187
  * @param {Invoices.RequestOptions} requestOptions - Request-specific configuration.
188
188
  *
189
189
  * @throws {@link Chrt.UnprocessableEntityError}
190
190
  *
191
191
  * @example
192
- * await client.billingNew.invoices.deleteV1("invoice_id")
193
- */
194
- deleteV1(invoiceId, requestOptions) {
195
- return core.HttpResponsePromise.fromPromise(this.__deleteV1(invoiceId, requestOptions));
196
- }
197
- __deleteV1(invoiceId, requestOptions) {
198
- return __awaiter(this, void 0, void 0, function* () {
199
- var _a, _b, _c, _d;
200
- let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
201
- const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
202
- url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `billing_new/invoices/delete/v1/${encodeURIComponent(invoiceId)}`),
203
- method: "DELETE",
204
- headers: _headers,
205
- queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
206
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
207
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
208
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
209
- });
210
- if (_response.ok) {
211
- return { data: _response.body, rawResponse: _response.rawResponse };
212
- }
213
- if (_response.error.reason === "status-code") {
214
- switch (_response.error.statusCode) {
215
- case 422:
216
- throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
217
- default:
218
- throw new errors.ChrtError({
219
- statusCode: _response.error.statusCode,
220
- body: _response.error.body,
221
- rawResponse: _response.rawResponse,
222
- });
223
- }
224
- }
225
- switch (_response.error.reason) {
226
- case "non-json":
227
- throw new errors.ChrtError({
228
- statusCode: _response.error.statusCode,
229
- body: _response.error.rawBody,
230
- rawResponse: _response.rawResponse,
231
- });
232
- case "timeout":
233
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling DELETE /billing_new/invoices/delete/v1/{invoice_id}.");
234
- case "unknown":
235
- throw new errors.ChrtError({
236
- message: _response.error.errorMessage,
237
- rawResponse: _response.rawResponse,
238
- });
239
- }
240
- });
241
- }
242
- /**
243
- * Retrieves an owner-scoped invoice with line-item orders, counterparties, and accounts expanded. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (InvoiceExpandedRes)
244
- *
245
- * @param {string} invoiceId
246
- * @param {Invoices.RequestOptions} requestOptions - Request-specific configuration.
247
- *
248
- * @throws {@link Chrt.UnprocessableEntityError}
249
- *
250
- * @example
251
- * await client.billingNew.invoices.getExpandedV1("invoice_id")
192
+ * await client.billingNew.invoices.createFromOrdersV1({
193
+ * currency_code: "USD",
194
+ * invoice_type: "accounts_receivable",
195
+ * order_ids: ["order_ids"],
196
+ * schema_version: 1
197
+ * })
252
198
  */
253
- getExpandedV1(invoiceId, requestOptions) {
254
- return core.HttpResponsePromise.fromPromise(this.__getExpandedV1(invoiceId, requestOptions));
199
+ createFromOrdersV1(request, requestOptions) {
200
+ return core.HttpResponsePromise.fromPromise(this.__createFromOrdersV1(request, requestOptions));
255
201
  }
256
- __getExpandedV1(invoiceId, requestOptions) {
202
+ __createFromOrdersV1(request, requestOptions) {
257
203
  return __awaiter(this, void 0, void 0, function* () {
258
204
  var _a, _b, _c, _d;
259
205
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
260
206
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
261
- url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `billing_new/invoices/expanded/v1/${encodeURIComponent(invoiceId)}`),
262
- method: "GET",
207
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "billing_new/invoices/create_from_orders/v1"),
208
+ method: "POST",
263
209
  headers: _headers,
210
+ contentType: "application/json",
264
211
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
212
+ requestType: "json",
213
+ body: request,
265
214
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
266
215
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
267
216
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -289,7 +238,7 @@ class Invoices {
289
238
  rawResponse: _response.rawResponse,
290
239
  });
291
240
  case "timeout":
292
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /billing_new/invoices/expanded/v1/{invoice_id}.");
241
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /billing_new/invoices/create_from_orders/v1.");
293
242
  case "unknown":
294
243
  throw new errors.ChrtError({
295
244
  message: _response.error.errorMessage,
@@ -299,27 +248,26 @@ class Invoices {
299
248
  });
300
249
  }
301
250
  /**
302
- * Attaches one line item to a draft invoice, moving it from another draft invoice when needed, and synchronizes both invoices. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (Invoice1)
251
+ * Hard-deletes a draft invoice and detaches its line items. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (bool)
303
252
  *
304
253
  * @param {string} invoiceId
305
- * @param {string} invoiceLineItemId
306
254
  * @param {Invoices.RequestOptions} requestOptions - Request-specific configuration.
307
255
  *
308
256
  * @throws {@link Chrt.UnprocessableEntityError}
309
257
  *
310
258
  * @example
311
- * await client.billingNew.invoices.addLineItemV1("invoice_id", "invoice_line_item_id")
259
+ * await client.billingNew.invoices.deleteV1("invoice_id")
312
260
  */
313
- addLineItemV1(invoiceId, invoiceLineItemId, requestOptions) {
314
- return core.HttpResponsePromise.fromPromise(this.__addLineItemV1(invoiceId, invoiceLineItemId, requestOptions));
261
+ deleteV1(invoiceId, requestOptions) {
262
+ return core.HttpResponsePromise.fromPromise(this.__deleteV1(invoiceId, requestOptions));
315
263
  }
316
- __addLineItemV1(invoiceId, invoiceLineItemId, requestOptions) {
264
+ __deleteV1(invoiceId, requestOptions) {
317
265
  return __awaiter(this, void 0, void 0, function* () {
318
266
  var _a, _b, _c, _d;
319
267
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
320
268
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
321
- url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `billing_new/invoices/line_item/add/v1/${encodeURIComponent(invoiceId)}/${encodeURIComponent(invoiceLineItemId)}`),
322
- method: "POST",
269
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `billing_new/invoices/delete/v1/${encodeURIComponent(invoiceId)}`),
270
+ method: "DELETE",
323
271
  headers: _headers,
324
272
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
325
273
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -349,7 +297,7 @@ class Invoices {
349
297
  rawResponse: _response.rawResponse,
350
298
  });
351
299
  case "timeout":
352
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /billing_new/invoices/line_item/add/v1/{invoice_id}/{invoice_line_item_id}.");
300
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling DELETE /billing_new/invoices/delete/v1/{invoice_id}.");
353
301
  case "unknown":
354
302
  throw new errors.ChrtError({
355
303
  message: _response.error.errorMessage,
@@ -359,27 +307,26 @@ class Invoices {
359
307
  });
360
308
  }
361
309
  /**
362
- * Detaches one line item from a draft invoice and synchronizes the invoice total and accounts. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (Invoice1)
310
+ * Retrieves an owner-scoped invoice with line-item orders, counterparties, and accounts expanded. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (InvoiceExpandedRes)
363
311
  *
364
312
  * @param {string} invoiceId
365
- * @param {string} invoiceLineItemId
366
313
  * @param {Invoices.RequestOptions} requestOptions - Request-specific configuration.
367
314
  *
368
315
  * @throws {@link Chrt.UnprocessableEntityError}
369
316
  *
370
317
  * @example
371
- * await client.billingNew.invoices.removeLineItemV1("invoice_id", "invoice_line_item_id")
318
+ * await client.billingNew.invoices.getExpandedV1("invoice_id")
372
319
  */
373
- removeLineItemV1(invoiceId, invoiceLineItemId, requestOptions) {
374
- return core.HttpResponsePromise.fromPromise(this.__removeLineItemV1(invoiceId, invoiceLineItemId, requestOptions));
320
+ getExpandedV1(invoiceId, requestOptions) {
321
+ return core.HttpResponsePromise.fromPromise(this.__getExpandedV1(invoiceId, requestOptions));
375
322
  }
376
- __removeLineItemV1(invoiceId, invoiceLineItemId, requestOptions) {
323
+ __getExpandedV1(invoiceId, requestOptions) {
377
324
  return __awaiter(this, void 0, void 0, function* () {
378
325
  var _a, _b, _c, _d;
379
326
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
380
327
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
381
- url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `billing_new/invoices/line_item/remove/v1/${encodeURIComponent(invoiceId)}/${encodeURIComponent(invoiceLineItemId)}`),
382
- method: "DELETE",
328
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `billing_new/invoices/expanded/v1/${encodeURIComponent(invoiceId)}`),
329
+ method: "GET",
383
330
  headers: _headers,
384
331
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
385
332
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
@@ -409,7 +356,7 @@ class Invoices {
409
356
  rawResponse: _response.rawResponse,
410
357
  });
411
358
  case "timeout":
412
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling DELETE /billing_new/invoices/line_item/remove/v1/{invoice_id}/{invoice_line_item_id}.");
359
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /billing_new/invoices/expanded/v1/{invoice_id}.");
413
360
  case "unknown":
414
361
  throw new errors.ChrtError({
415
362
  message: _response.error.errorMessage,
@@ -419,7 +366,7 @@ class Invoices {
419
366
  });
420
367
  }
421
368
  /**
422
- * Attaches existing line items to a draft invoice, moving them from any other draft invoices, and synchronizes all affected invoice totals and accounts. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemsAddReq) -> (Invoice1)
369
+ * Attaches uninvoiced line items to a draft invoice and refreshes its totals and accounts. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemsAddReq) -> (Invoice1)
423
370
  *
424
371
  * @param {string} invoiceId
425
372
  * @param {Chrt.billingNew.InvoiceLineItemsAddReq} request
@@ -689,6 +636,139 @@ class Invoices {
689
636
  }
690
637
  });
691
638
  }
639
+ /**
640
+ * Previews exact uninvoiced charges, current resolved taxes, and explicit or derived billing dates without saving. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceCreateReq) -> (InvoicePreviewRes)
641
+ *
642
+ * @param {Chrt.InvoiceCreateReq} request
643
+ * @param {Invoices.RequestOptions} requestOptions - Request-specific configuration.
644
+ *
645
+ * @throws {@link Chrt.UnprocessableEntityError}
646
+ *
647
+ * @example
648
+ * await client.billingNew.invoices.previewV1({
649
+ * currency_code: "USD",
650
+ * invoice_type: "accounts_receivable",
651
+ * schema_version: 1
652
+ * })
653
+ */
654
+ previewV1(request, requestOptions) {
655
+ return core.HttpResponsePromise.fromPromise(this.__previewV1(request, requestOptions));
656
+ }
657
+ __previewV1(request, requestOptions) {
658
+ return __awaiter(this, void 0, void 0, function* () {
659
+ var _a, _b, _c, _d;
660
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
661
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
662
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "billing_new/invoices/preview/v1"),
663
+ method: "POST",
664
+ headers: _headers,
665
+ contentType: "application/json",
666
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
667
+ requestType: "json",
668
+ body: request,
669
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
670
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
671
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
672
+ });
673
+ if (_response.ok) {
674
+ return { data: _response.body, rawResponse: _response.rawResponse };
675
+ }
676
+ if (_response.error.reason === "status-code") {
677
+ switch (_response.error.statusCode) {
678
+ case 422:
679
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
680
+ default:
681
+ throw new errors.ChrtError({
682
+ statusCode: _response.error.statusCode,
683
+ body: _response.error.body,
684
+ rawResponse: _response.rawResponse,
685
+ });
686
+ }
687
+ }
688
+ switch (_response.error.reason) {
689
+ case "non-json":
690
+ throw new errors.ChrtError({
691
+ statusCode: _response.error.statusCode,
692
+ body: _response.error.rawBody,
693
+ rawResponse: _response.rawResponse,
694
+ });
695
+ case "timeout":
696
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /billing_new/invoices/preview/v1.");
697
+ case "unknown":
698
+ throw new errors.ChrtError({
699
+ message: _response.error.errorMessage,
700
+ rawResponse: _response.rawResponse,
701
+ });
702
+ }
703
+ });
704
+ }
705
+ /**
706
+ * Selects matching uninvoiced ordinary charges, reports omitted items, and previews current taxes and billing dates without saving. Period dates do not filter charges. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceCreateFromOrdersReq) -> (InvoicePreviewFromOrdersRes)
707
+ *
708
+ * @param {Chrt.InvoiceCreateFromOrdersReq} request
709
+ * @param {Invoices.RequestOptions} requestOptions - Request-specific configuration.
710
+ *
711
+ * @throws {@link Chrt.UnprocessableEntityError}
712
+ *
713
+ * @example
714
+ * await client.billingNew.invoices.previewFromOrdersV1({
715
+ * currency_code: "USD",
716
+ * invoice_type: "accounts_receivable",
717
+ * order_ids: ["order_ids"],
718
+ * schema_version: 1
719
+ * })
720
+ */
721
+ previewFromOrdersV1(request, requestOptions) {
722
+ return core.HttpResponsePromise.fromPromise(this.__previewFromOrdersV1(request, requestOptions));
723
+ }
724
+ __previewFromOrdersV1(request, requestOptions) {
725
+ return __awaiter(this, void 0, void 0, function* () {
726
+ var _a, _b, _c, _d;
727
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
728
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
729
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "billing_new/invoices/preview_from_orders/v1"),
730
+ method: "POST",
731
+ headers: _headers,
732
+ contentType: "application/json",
733
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
734
+ requestType: "json",
735
+ body: request,
736
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
737
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
738
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
739
+ });
740
+ if (_response.ok) {
741
+ return { data: _response.body, rawResponse: _response.rawResponse };
742
+ }
743
+ if (_response.error.reason === "status-code") {
744
+ switch (_response.error.statusCode) {
745
+ case 422:
746
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
747
+ default:
748
+ throw new errors.ChrtError({
749
+ statusCode: _response.error.statusCode,
750
+ body: _response.error.body,
751
+ rawResponse: _response.rawResponse,
752
+ });
753
+ }
754
+ }
755
+ switch (_response.error.reason) {
756
+ case "non-json":
757
+ throw new errors.ChrtError({
758
+ statusCode: _response.error.statusCode,
759
+ body: _response.error.rawBody,
760
+ rawResponse: _response.rawResponse,
761
+ });
762
+ case "timeout":
763
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /billing_new/invoices/preview_from_orders/v1.");
764
+ case "unknown":
765
+ throw new errors.ChrtError({
766
+ message: _response.error.errorMessage,
767
+ rawResponse: _response.rawResponse,
768
+ });
769
+ }
770
+ });
771
+ }
692
772
  /**
693
773
  * Updates the name or description of a draft invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceClientUpdate1) -> (bool)
694
774
  *
@@ -1,4 +1,3 @@
1
- export { type InvoiceClientCreate1 } from "./InvoiceClientCreate1.js";
2
1
  export { type InvoiceLineItemsAddReq } from "./InvoiceLineItemsAddReq.js";
3
2
  export { type InvoiceLineItemsRemoveReq } from "./InvoiceLineItemsRemoveReq.js";
4
3
  export { type InvoicesListV1Request } from "./InvoicesListV1Request.js";
@@ -4,7 +4,6 @@
4
4
  import * as environments from "../../../../../../environments.js";
5
5
  import * as core from "../../../../../../core/index.js";
6
6
  import * as Chrt from "../../../../../index.js";
7
- import { RateSheetLineItems } from "../resources/rateSheetLineItems/client/Client.js";
8
7
  export declare namespace Orders {
9
8
  interface Options {
10
9
  environment?: core.Supplier<environments.ChrtEnvironment | string>;
@@ -30,9 +29,7 @@ export declare namespace Orders {
30
29
  }
31
30
  export declare class Orders {
32
31
  protected readonly _options: Orders.Options;
33
- protected _rateSheetLineItems: RateSheetLineItems | undefined;
34
32
  constructor(_options?: Orders.Options);
35
- get rateSheetLineItems(): RateSheetLineItems;
36
33
  /**
37
34
  * Lists completed, unbilled AWBs with delivery account allocations. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (OrderAwbBillingListRes)
38
35
  *
@@ -88,5 +85,33 @@ export declare class Orders {
88
85
  */
89
86
  listExpandedForCoordinatorOperatorsV1(request?: Chrt.billingNew.OrderBillingExpandedListReq, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<Chrt.OrderBillingExpandedListRes>;
90
87
  private __listExpandedForCoordinatorOperatorsV1;
88
+ /**
89
+ * Regenerates uninvoiced rate-sheet charges per Order, reporting skips and failures. Detach existing charges before regeneration. | authz: allowed_org_types=[provider], min_org_role=operator | authz_personas=[coordinator_org_operators] | (OrderRateSheetLineItemsGenerateManyReq) -> (OrderRateSheetLineItemsGenerateManyRes)
90
+ *
91
+ * @param {Chrt.billingNew.OrderRateSheetLineItemsGenerateManyReq} request
92
+ * @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
93
+ *
94
+ * @throws {@link Chrt.UnprocessableEntityError}
95
+ *
96
+ * @example
97
+ * await client.billingNew.orders.generateRateSheetLineItemsManyV1({
98
+ * order_ids: ["order_ids"]
99
+ * })
100
+ */
101
+ generateRateSheetLineItemsManyV1(request: Chrt.billingNew.OrderRateSheetLineItemsGenerateManyReq, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<Chrt.OrderRateSheetLineItemsGenerateManyRes>;
102
+ private __generateRateSheetLineItemsManyV1;
103
+ /**
104
+ * Estimates current taxes for uninvoiced ordinary charges grouped by counterparty, direction, and currency. Returns an empty list when no charges qualify. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (list[InvoicePreviewRes])
105
+ *
106
+ * @param {string} orderId
107
+ * @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
108
+ *
109
+ * @throws {@link Chrt.UnprocessableEntityError}
110
+ *
111
+ * @example
112
+ * await client.billingNew.orders.taxEstimatesV1("order_id")
113
+ */
114
+ taxEstimatesV1(orderId: string, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<Chrt.InvoicePreviewRes[]>;
115
+ private __taxEstimatesV1;
91
116
  protected _getAuthorizationHeader(): Promise<string | undefined>;
92
117
  }
@@ -62,15 +62,10 @@ const core = __importStar(require("../../../../../../core/index.js"));
62
62
  const Chrt = __importStar(require("../../../../../index.js"));
63
63
  const headers_js_1 = require("../../../../../../core/headers.js");
64
64
  const errors = __importStar(require("../../../../../../errors/index.js"));
65
- const Client_js_1 = require("../resources/rateSheetLineItems/client/Client.js");
66
65
  class Orders {
67
66
  constructor(_options = {}) {
68
67
  this._options = _options;
69
68
  }
70
- get rateSheetLineItems() {
71
- var _a;
72
- return ((_a = this._rateSheetLineItems) !== null && _a !== void 0 ? _a : (this._rateSheetLineItems = new Client_js_1.RateSheetLineItems(this._options)));
73
- }
74
69
  /**
75
70
  * Lists completed, unbilled AWBs with delivery account allocations. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (OrderAwbBillingListRes)
76
71
  *
@@ -321,6 +316,132 @@ class Orders {
321
316
  }
322
317
  });
323
318
  }
319
+ /**
320
+ * Regenerates uninvoiced rate-sheet charges per Order, reporting skips and failures. Detach existing charges before regeneration. | authz: allowed_org_types=[provider], min_org_role=operator | authz_personas=[coordinator_org_operators] | (OrderRateSheetLineItemsGenerateManyReq) -> (OrderRateSheetLineItemsGenerateManyRes)
321
+ *
322
+ * @param {Chrt.billingNew.OrderRateSheetLineItemsGenerateManyReq} request
323
+ * @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
324
+ *
325
+ * @throws {@link Chrt.UnprocessableEntityError}
326
+ *
327
+ * @example
328
+ * await client.billingNew.orders.generateRateSheetLineItemsManyV1({
329
+ * order_ids: ["order_ids"]
330
+ * })
331
+ */
332
+ generateRateSheetLineItemsManyV1(request, requestOptions) {
333
+ return core.HttpResponsePromise.fromPromise(this.__generateRateSheetLineItemsManyV1(request, requestOptions));
334
+ }
335
+ __generateRateSheetLineItemsManyV1(request, requestOptions) {
336
+ return __awaiter(this, void 0, void 0, function* () {
337
+ var _a, _b, _c, _d;
338
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
339
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
340
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "billing_new/orders/rate_sheet_line_items/generate_many/v1"),
341
+ method: "POST",
342
+ headers: _headers,
343
+ contentType: "application/json",
344
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
345
+ requestType: "json",
346
+ body: request,
347
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
348
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
349
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
350
+ });
351
+ if (_response.ok) {
352
+ return {
353
+ data: _response.body,
354
+ rawResponse: _response.rawResponse,
355
+ };
356
+ }
357
+ if (_response.error.reason === "status-code") {
358
+ switch (_response.error.statusCode) {
359
+ case 422:
360
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
361
+ default:
362
+ throw new errors.ChrtError({
363
+ statusCode: _response.error.statusCode,
364
+ body: _response.error.body,
365
+ rawResponse: _response.rawResponse,
366
+ });
367
+ }
368
+ }
369
+ switch (_response.error.reason) {
370
+ case "non-json":
371
+ throw new errors.ChrtError({
372
+ statusCode: _response.error.statusCode,
373
+ body: _response.error.rawBody,
374
+ rawResponse: _response.rawResponse,
375
+ });
376
+ case "timeout":
377
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /billing_new/orders/rate_sheet_line_items/generate_many/v1.");
378
+ case "unknown":
379
+ throw new errors.ChrtError({
380
+ message: _response.error.errorMessage,
381
+ rawResponse: _response.rawResponse,
382
+ });
383
+ }
384
+ });
385
+ }
386
+ /**
387
+ * Estimates current taxes for uninvoiced ordinary charges grouped by counterparty, direction, and currency. Returns an empty list when no charges qualify. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (list[InvoicePreviewRes])
388
+ *
389
+ * @param {string} orderId
390
+ * @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
391
+ *
392
+ * @throws {@link Chrt.UnprocessableEntityError}
393
+ *
394
+ * @example
395
+ * await client.billingNew.orders.taxEstimatesV1("order_id")
396
+ */
397
+ taxEstimatesV1(orderId, requestOptions) {
398
+ return core.HttpResponsePromise.fromPromise(this.__taxEstimatesV1(orderId, requestOptions));
399
+ }
400
+ __taxEstimatesV1(orderId, requestOptions) {
401
+ return __awaiter(this, void 0, void 0, function* () {
402
+ var _a, _b, _c, _d;
403
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
404
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
405
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `billing_new/orders/tax_estimates/v1/${encodeURIComponent(orderId)}`),
406
+ method: "GET",
407
+ headers: _headers,
408
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
409
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
410
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
411
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
412
+ });
413
+ if (_response.ok) {
414
+ return { data: _response.body, rawResponse: _response.rawResponse };
415
+ }
416
+ if (_response.error.reason === "status-code") {
417
+ switch (_response.error.statusCode) {
418
+ case 422:
419
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
420
+ default:
421
+ throw new errors.ChrtError({
422
+ statusCode: _response.error.statusCode,
423
+ body: _response.error.body,
424
+ rawResponse: _response.rawResponse,
425
+ });
426
+ }
427
+ }
428
+ switch (_response.error.reason) {
429
+ case "non-json":
430
+ throw new errors.ChrtError({
431
+ statusCode: _response.error.statusCode,
432
+ body: _response.error.rawBody,
433
+ rawResponse: _response.rawResponse,
434
+ });
435
+ case "timeout":
436
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /billing_new/orders/tax_estimates/v1/{order_id}.");
437
+ case "unknown":
438
+ throw new errors.ChrtError({
439
+ message: _response.error.errorMessage,
440
+ rawResponse: _response.rawResponse,
441
+ });
442
+ }
443
+ });
444
+ }
324
445
  _getAuthorizationHeader() {
325
446
  return __awaiter(this, void 0, void 0, function* () {
326
447
  const bearer = yield core.Supplier.get(this._options.token);
@@ -1,2 +1,3 @@
1
1
  export { type OrdersListAwbBillingForCoordinatorOperatorsV1Request } from "./OrdersListAwbBillingForCoordinatorOperatorsV1Request.js";
2
2
  export { type OrderBillingExpandedListReq } from "./OrderBillingExpandedListReq.js";
3
+ export { type OrderRateSheetLineItemsGenerateManyReq } from "./OrderRateSheetLineItemsGenerateManyReq.js";
@@ -1,2 +1 @@
1
1
  export * from "./client/index.js";
2
- export * from "./resources/index.js";
@@ -15,4 +15,3 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./client/index.js"), exports);
18
- __exportStar(require("./resources/index.js"), exports);