orb-billing 1.0.1 → 1.19.2

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 (1252) hide show
  1. package/README.md +61 -41
  2. package/dist/internal/utils/requestbody.d.ts +1 -1
  3. package/dist/internal/utils/requestbody.js +1 -1
  4. package/dist/internal/utils/retries.d.ts +2 -2
  5. package/dist/internal/utils/security.d.ts +5 -2
  6. package/dist/internal/utils/security.js +28 -28
  7. package/dist/sdk/availability.d.ts +3 -4
  8. package/dist/sdk/availability.js +80 -10
  9. package/dist/sdk/coupon.d.ts +16 -7
  10. package/dist/sdk/coupon.js +396 -35
  11. package/dist/sdk/credit.d.ts +111 -87
  12. package/dist/sdk/credit.js +573 -128
  13. package/dist/sdk/creditnote.d.ts +8 -5
  14. package/dist/sdk/creditnote.js +160 -16
  15. package/dist/sdk/customer.d.ts +358 -93
  16. package/dist/sdk/customer.js +1351 -189
  17. package/dist/sdk/event.d.ts +198 -103
  18. package/dist/sdk/event.js +906 -157
  19. package/dist/sdk/invoice.d.ts +39 -10
  20. package/dist/sdk/invoice.js +727 -47
  21. package/dist/sdk/item.d.ts +27 -0
  22. package/dist/sdk/item.js +328 -0
  23. package/dist/sdk/metric.d.ts +39 -0
  24. package/dist/sdk/metric.js +475 -0
  25. package/dist/sdk/models/errors/index.d.ts +1 -0
  26. package/dist/sdk/models/errors/index.js +20 -0
  27. package/dist/sdk/models/errors/sdkerror.d.ts +7 -0
  28. package/dist/sdk/models/errors/sdkerror.js +40 -0
  29. package/dist/sdk/models/operations/addeditpriceintervals.d.ts +53 -0
  30. package/dist/sdk/models/operations/addeditpriceintervals.js +123 -0
  31. package/dist/sdk/models/operations/amendevent.d.ts +35 -5
  32. package/dist/sdk/models/operations/amendevent.js +28 -4
  33. package/dist/sdk/models/operations/amendusage.d.ts +36 -15
  34. package/dist/sdk/models/operations/amendusage.js +31 -22
  35. package/dist/sdk/models/operations/amendusageexternalcustomerid.d.ts +36 -15
  36. package/dist/sdk/models/operations/amendusageexternalcustomerid.js +31 -22
  37. package/dist/sdk/models/operations/archivecoupon.d.ts +37 -0
  38. package/dist/sdk/models/operations/archivecoupon.js +28 -0
  39. package/dist/sdk/models/operations/cancelsubscription.d.ts +38 -1
  40. package/dist/sdk/models/operations/cancelsubscription.js +30 -2
  41. package/dist/sdk/models/operations/closebackfill.d.ts +37 -0
  42. package/dist/sdk/models/operations/closebackfill.js +28 -0
  43. package/dist/sdk/models/operations/createbackfill.d.ts +37 -0
  44. package/dist/sdk/models/operations/createbackfill.js +28 -0
  45. package/dist/sdk/models/operations/createcoupon.d.ts +38 -1
  46. package/dist/sdk/models/operations/createcoupon.js +28 -0
  47. package/dist/sdk/models/operations/createcustomer.d.ts +37 -0
  48. package/dist/sdk/models/operations/createcustomer.js +28 -0
  49. package/dist/sdk/models/operations/createcustomerbalancetransaction.d.ts +38 -1
  50. package/dist/sdk/models/operations/createcustomerbalancetransaction.js +30 -2
  51. package/dist/sdk/models/operations/createinvoice.d.ts +49 -0
  52. package/dist/sdk/models/operations/createinvoice.js +107 -0
  53. package/dist/sdk/models/operations/createinvoicelineitem.d.ts +37 -0
  54. package/dist/sdk/models/operations/createinvoicelineitem.js +28 -0
  55. package/dist/sdk/models/operations/createledgerentry.d.ts +40 -3
  56. package/dist/sdk/models/operations/createledgerentry.js +31 -3
  57. package/dist/sdk/models/operations/createledgerentryexternalid.d.ts +53 -0
  58. package/dist/sdk/models/operations/createledgerentryexternalid.js +123 -0
  59. package/dist/sdk/models/operations/createmetric.d.ts +49 -0
  60. package/dist/sdk/models/operations/createmetric.js +107 -0
  61. package/dist/sdk/models/operations/createplan.d.ts +49 -0
  62. package/dist/sdk/models/operations/createplan.js +107 -0
  63. package/dist/sdk/models/operations/createprice.d.ts +49 -0
  64. package/dist/sdk/models/operations/{addledgerentryexternalid.js → createprice.js} +37 -25
  65. package/dist/sdk/models/operations/createsubscription.d.ts +38 -1
  66. package/dist/sdk/models/operations/createsubscription.js +28 -0
  67. package/dist/sdk/models/operations/deletecustomer.d.ts +41 -11
  68. package/dist/sdk/models/operations/deletecustomer.js +57 -16
  69. package/dist/sdk/models/operations/deprecateevent.d.ts +35 -5
  70. package/dist/sdk/models/operations/deprecateevent.js +28 -4
  71. package/dist/sdk/models/operations/fetchbackfill.d.ts +52 -0
  72. package/dist/sdk/models/operations/fetchbackfill.js +119 -0
  73. package/dist/sdk/models/operations/fetchcoupon.d.ts +37 -0
  74. package/dist/sdk/models/operations/fetchcoupon.js +28 -0
  75. package/dist/sdk/models/operations/fetchcreditnote.d.ts +37 -3
  76. package/dist/sdk/models/operations/fetchcreditnote.js +28 -0
  77. package/dist/sdk/models/operations/fetchcustomer.d.ts +38 -4
  78. package/dist/sdk/models/operations/fetchcustomer.js +28 -0
  79. package/dist/sdk/models/operations/fetchcustomercosts.d.ts +44 -12
  80. package/dist/sdk/models/operations/fetchcustomercosts.js +37 -1
  81. package/dist/sdk/models/operations/fetchcustomercostsexternalid.d.ts +45 -10
  82. package/dist/sdk/models/operations/fetchcustomercostsexternalid.js +37 -1
  83. package/dist/sdk/models/operations/fetchcustomercredits.d.ts +37 -9
  84. package/dist/sdk/models/operations/fetchcustomercredits.js +31 -3
  85. package/dist/sdk/models/operations/fetchcustomercreditsexternalid.d.ts +39 -8
  86. package/dist/sdk/models/operations/fetchcustomercreditsexternalid.js +31 -3
  87. package/dist/sdk/models/operations/fetchcustomercreditsledger.d.ts +53 -13
  88. package/dist/sdk/models/operations/fetchcustomercreditsledger.js +66 -3
  89. package/dist/sdk/models/operations/fetchcustomercreditsledgerexternalid.d.ts +53 -13
  90. package/dist/sdk/models/operations/fetchcustomercreditsledgerexternalid.js +66 -3
  91. package/dist/sdk/models/operations/fetchcustomerexternalid.d.ts +37 -0
  92. package/dist/sdk/models/operations/fetchcustomerexternalid.js +28 -0
  93. package/dist/sdk/models/operations/fetchinvoice.d.ts +37 -0
  94. package/dist/sdk/models/operations/fetchinvoice.js +28 -0
  95. package/dist/sdk/models/operations/fetchitem.d.ts +52 -0
  96. package/dist/sdk/models/operations/fetchitem.js +119 -0
  97. package/dist/sdk/models/operations/fetchmetric.d.ts +52 -0
  98. package/dist/sdk/models/operations/fetchmetric.js +119 -0
  99. package/dist/sdk/models/operations/fetchplan.d.ts +37 -0
  100. package/dist/sdk/models/operations/fetchplan.js +28 -0
  101. package/dist/sdk/models/operations/fetchplanexternalid.d.ts +37 -0
  102. package/dist/sdk/models/operations/fetchplanexternalid.js +28 -0
  103. package/dist/sdk/models/operations/fetchprice.d.ts +52 -0
  104. package/dist/sdk/models/operations/fetchprice.js +119 -0
  105. package/dist/sdk/models/operations/fetchpriceexternalid.d.ts +52 -0
  106. package/dist/sdk/models/operations/fetchpriceexternalid.js +119 -0
  107. package/dist/sdk/models/operations/fetchsubscription.d.ts +37 -0
  108. package/dist/sdk/models/operations/fetchsubscription.js +28 -0
  109. package/dist/sdk/models/operations/fetchsubscriptioncosts.d.ts +45 -10
  110. package/dist/sdk/models/operations/fetchsubscriptioncosts.js +37 -1
  111. package/dist/sdk/models/operations/fetchsubscriptionschedule.d.ts +43 -8
  112. package/dist/sdk/models/operations/fetchsubscriptionschedule.js +47 -3
  113. package/dist/sdk/models/operations/fetchsubscriptionusage.d.ts +60 -16
  114. package/dist/sdk/models/operations/fetchsubscriptionusage.js +69 -2
  115. package/dist/sdk/models/operations/fetchupcominginvoice.d.ts +38 -1
  116. package/dist/sdk/models/operations/fetchupcominginvoice.js +28 -0
  117. package/dist/sdk/models/operations/index.d.ts +20 -2
  118. package/dist/sdk/models/operations/index.js +20 -2
  119. package/dist/sdk/models/operations/ingest.d.ts +36 -12
  120. package/dist/sdk/models/operations/ingest.js +31 -22
  121. package/dist/sdk/models/operations/issueinvoice.d.ts +35 -2
  122. package/dist/sdk/models/operations/issueinvoice.js +28 -4
  123. package/dist/sdk/models/operations/listbackfills.d.ts +37 -6
  124. package/dist/sdk/models/operations/listbackfills.js +29 -1
  125. package/dist/sdk/models/operations/listbalancetransactions.d.ts +45 -10
  126. package/dist/sdk/models/operations/listbalancetransactions.js +49 -5
  127. package/dist/sdk/models/operations/listcoupons.d.ts +35 -10
  128. package/dist/sdk/models/operations/listcoupons.js +29 -1
  129. package/dist/sdk/models/operations/listcouponsubscriptions.d.ts +39 -0
  130. package/dist/sdk/models/operations/listcouponsubscriptions.js +36 -0
  131. package/dist/sdk/models/operations/listcreditnotes.d.ts +53 -0
  132. package/dist/sdk/models/operations/listcreditnotes.js +123 -0
  133. package/dist/sdk/models/operations/listcustomers.d.ts +41 -6
  134. package/dist/sdk/models/operations/listcustomers.js +45 -1
  135. package/dist/sdk/models/operations/listinvoices.d.ts +66 -14
  136. package/dist/sdk/models/operations/listinvoices.js +109 -3
  137. package/dist/sdk/models/operations/listitems.d.ts +53 -0
  138. package/dist/sdk/models/operations/{listcreditnote.js → listitems.js} +46 -30
  139. package/dist/sdk/models/operations/listmetrics.d.ts +57 -0
  140. package/dist/sdk/models/operations/listmetrics.js +139 -0
  141. package/dist/sdk/models/operations/listplans.d.ts +53 -6
  142. package/dist/sdk/models/operations/listplans.js +59 -2
  143. package/dist/sdk/models/operations/listprices.d.ts +53 -0
  144. package/dist/sdk/models/operations/listprices.js +123 -0
  145. package/dist/sdk/models/operations/listsubscriptions.d.ts +48 -7
  146. package/dist/sdk/models/operations/listsubscriptions.js +56 -2
  147. package/dist/sdk/models/operations/markinvoiceaspaid.d.ts +53 -0
  148. package/dist/sdk/models/operations/markinvoiceaspaid.js +123 -0
  149. package/dist/sdk/models/operations/ping.d.ts +39 -2
  150. package/dist/sdk/models/operations/ping.js +30 -2
  151. package/dist/sdk/models/operations/revertbackfill.d.ts +37 -0
  152. package/dist/sdk/models/operations/revertbackfill.js +28 -0
  153. package/dist/sdk/models/operations/scheduleplanchange.d.ts +37 -0
  154. package/dist/sdk/models/operations/scheduleplanchange.js +28 -0
  155. package/dist/sdk/models/operations/searchevents.d.ts +42 -7
  156. package/dist/sdk/models/operations/searchevents.js +47 -3
  157. package/dist/sdk/models/operations/triggerphase.d.ts +53 -0
  158. package/dist/sdk/models/operations/triggerphase.js +123 -0
  159. package/dist/sdk/models/operations/unschedulecancellation.d.ts +37 -0
  160. package/dist/sdk/models/operations/unschedulecancellation.js +28 -0
  161. package/dist/sdk/models/operations/unschedulefixedfeequantity.d.ts +53 -0
  162. package/dist/sdk/models/operations/unschedulefixedfeequantity.js +123 -0
  163. package/dist/sdk/models/operations/unscheduleplanchange.d.ts +37 -0
  164. package/dist/sdk/models/operations/unscheduleplanchange.js +28 -0
  165. package/dist/sdk/models/operations/updatecustomer.d.ts +38 -4
  166. package/dist/sdk/models/operations/updatecustomer.js +30 -2
  167. package/dist/sdk/models/operations/updatecustomerexternalid.d.ts +38 -1
  168. package/dist/sdk/models/operations/updatecustomerexternalid.js +30 -2
  169. package/dist/sdk/models/operations/updatefixedfeequantity.d.ts +37 -0
  170. package/dist/sdk/models/operations/updatefixedfeequantity.js +28 -0
  171. package/dist/sdk/models/operations/updateplan.d.ts +53 -0
  172. package/dist/sdk/models/operations/updateplan.js +123 -0
  173. package/dist/sdk/models/operations/updateplanexternal.d.ts +53 -0
  174. package/dist/sdk/models/operations/updateplanexternal.js +123 -0
  175. package/dist/sdk/models/operations/voidinvoice.d.ts +36 -3
  176. package/dist/sdk/models/operations/voidinvoice.js +28 -4
  177. package/dist/sdk/models/shared/accountingprovider.d.ts +9 -0
  178. package/dist/sdk/models/shared/accountingprovider.js +55 -0
  179. package/dist/sdk/models/shared/accountingproviderconfig.d.ts +5 -0
  180. package/dist/sdk/models/shared/{creditblock.js → accountingproviderconfig.js} +10 -18
  181. package/dist/sdk/models/shared/accountingsyncconfiguration.d.ts +6 -0
  182. package/dist/sdk/models/shared/accountingsyncconfiguration.js +52 -0
  183. package/dist/sdk/models/shared/adddecrementcreditledgerentryrequestparams.d.ts +24 -0
  184. package/dist/sdk/models/shared/adddecrementcreditledgerentryrequestparams.js +76 -0
  185. package/dist/sdk/models/shared/addeditpriceintervalparams.d.ts +13 -0
  186. package/dist/sdk/models/shared/addeditpriceintervalparams.js +54 -0
  187. package/dist/sdk/models/shared/addexpirationchangecreditledgerentryrequestparams.d.ts +37 -0
  188. package/dist/sdk/models/shared/{newcreditledgerentry.js → addexpirationchangecreditledgerentryrequestparams.js} +25 -34
  189. package/dist/sdk/models/shared/addincrementcreditledgerentryrequestparams.d.ts +42 -0
  190. package/dist/sdk/models/shared/addincrementcreditledgerentryrequestparams.js +107 -0
  191. package/dist/sdk/models/shared/addpriceintervalparams.d.ts +54 -0
  192. package/dist/sdk/models/shared/addpriceintervalparams.js +103 -0
  193. package/dist/sdk/models/shared/address.d.ts +9 -0
  194. package/dist/sdk/models/shared/address.js +70 -0
  195. package/dist/sdk/models/shared/addressinput.d.ts +9 -0
  196. package/dist/sdk/models/shared/addressinput.js +70 -0
  197. package/dist/sdk/models/shared/addvoidcreditledgerentryrequestparams.d.ts +34 -0
  198. package/dist/sdk/models/shared/addvoidcreditledgerentryrequestparams.js +88 -0
  199. package/dist/sdk/models/shared/affectedblock.d.ts +6 -0
  200. package/dist/sdk/models/shared/{credit.js → affectedblock.js} +9 -14
  201. package/dist/sdk/models/shared/{subscriptioncost.d.ts → aggregatedcost.d.ts} +1 -1
  202. package/dist/sdk/models/shared/{customercost.js → aggregatedcost.js} +11 -11
  203. package/dist/sdk/models/shared/amendedusage.d.ts +2 -7
  204. package/dist/sdk/models/shared/amendedusage.js +2 -14
  205. package/dist/sdk/models/shared/amendeventresult.d.ts +1 -4
  206. package/dist/sdk/models/shared/amendeventresult.js +0 -3
  207. package/dist/sdk/models/shared/amendmentledgerentry.d.ts +27 -0
  208. package/dist/sdk/models/shared/amendmentledgerentry.js +120 -0
  209. package/dist/sdk/models/shared/amountdiscount.d.ts +15 -0
  210. package/dist/sdk/models/shared/amountdiscount.js +59 -0
  211. package/dist/sdk/models/shared/amountdiscountcreationparams.d.ts +11 -0
  212. package/dist/sdk/models/shared/amountdiscountcreationparams.js +54 -0
  213. package/dist/sdk/models/shared/amountdiscountinterval.d.ts +27 -0
  214. package/dist/sdk/models/shared/amountdiscountinterval.js +82 -0
  215. package/dist/sdk/models/shared/autocollection.d.ts +3 -6
  216. package/dist/sdk/models/shared/autocollection.js +0 -3
  217. package/dist/sdk/models/shared/backfill.d.ts +2 -2
  218. package/dist/sdk/models/shared/backfills.d.ts +2 -5
  219. package/dist/sdk/models/shared/backfills.js +0 -3
  220. package/dist/sdk/models/shared/billablemetric.d.ts +24 -1
  221. package/dist/sdk/models/shared/billablemetric.js +40 -1
  222. package/dist/sdk/models/shared/billablemetrics.d.ts +7 -0
  223. package/dist/sdk/models/shared/billablemetrics.js +54 -0
  224. package/dist/sdk/models/shared/billablemetricsimple.d.ts +5 -0
  225. package/dist/sdk/models/shared/{billablemetricminified.js → billablemetricsimple.js} +8 -8
  226. package/dist/sdk/models/shared/billablemetrictiny.d.ts +4 -0
  227. package/dist/sdk/models/shared/billablemetrictiny.js +45 -0
  228. package/dist/sdk/models/shared/billingcyclealignment.d.ts +8 -0
  229. package/dist/sdk/models/shared/billingcyclealignment.js +15 -0
  230. package/dist/sdk/models/shared/bpsconfig.d.ts +7 -4
  231. package/dist/sdk/models/shared/bpsconfig.js +1 -4
  232. package/dist/sdk/models/shared/bpsprice.d.ts +242 -0
  233. package/dist/sdk/models/shared/bpsprice.js +363 -0
  234. package/dist/sdk/models/shared/bpstier.d.ts +15 -3
  235. package/dist/sdk/models/shared/bpstier.js +1 -1
  236. package/dist/sdk/models/shared/bulkbpsconfig.d.ts +4 -4
  237. package/dist/sdk/models/shared/bulkbpsconfig.js +0 -3
  238. package/dist/sdk/models/shared/bulkbpsprice.d.ts +242 -0
  239. package/dist/sdk/models/shared/bulkbpsprice.js +363 -0
  240. package/dist/sdk/models/shared/bulkbpstier.d.ts +10 -1
  241. package/dist/sdk/models/shared/bulkbpstier.js +1 -1
  242. package/dist/sdk/models/shared/bulkconfig.d.ts +4 -4
  243. package/dist/sdk/models/shared/bulkconfig.js +0 -3
  244. package/dist/sdk/models/shared/bulkprice.d.ts +242 -0
  245. package/dist/sdk/models/shared/bulkprice.js +363 -0
  246. package/dist/sdk/models/shared/bulktier.d.ts +7 -1
  247. package/dist/sdk/models/shared/bulktier.js +1 -1
  248. package/dist/sdk/models/shared/cancelsubscriptionparams.d.ts +19 -0
  249. package/dist/sdk/models/shared/cancelsubscriptionparams.js +63 -0
  250. package/dist/sdk/models/shared/changeoption.d.ts +0 -3
  251. package/dist/sdk/models/shared/changeoption.js +0 -3
  252. package/dist/sdk/models/shared/coupon.d.ts +14 -10
  253. package/dist/sdk/models/shared/coupon.js +16 -6
  254. package/dist/sdk/models/shared/couponredemption.d.ts +6 -0
  255. package/dist/sdk/models/shared/{usageitem.js → couponredemption.js} +12 -12
  256. package/dist/sdk/models/shared/coupons.d.ts +2 -5
  257. package/dist/sdk/models/shared/coupons.js +0 -3
  258. package/dist/sdk/models/shared/{newinvoicelineitem.d.ts → createinvoicelineitemparams.d.ts} +5 -5
  259. package/dist/sdk/models/shared/{newinvoicelineitem.js → createinvoicelineitemparams.js} +13 -13
  260. package/dist/sdk/models/shared/createoneoffinvoiceparams.d.ts +33 -0
  261. package/dist/sdk/models/shared/createoneoffinvoiceparams.js +86 -0
  262. package/dist/sdk/models/shared/creditblockexpiryledgerentry.d.ts +27 -0
  263. package/dist/sdk/models/shared/creditblockexpiryledgerentry.js +120 -0
  264. package/dist/sdk/models/shared/creditledgerentries.d.ts +1 -5
  265. package/dist/sdk/models/shared/creditledgerentries.js +1 -6
  266. package/dist/sdk/models/shared/creditnote.d.ts +34 -22
  267. package/dist/sdk/models/shared/creditnote.js +44 -7
  268. package/dist/sdk/models/shared/creditnotelineitem.d.ts +12 -10
  269. package/dist/sdk/models/shared/creditnotelineitem.js +24 -10
  270. package/dist/sdk/models/shared/creditnoteminified.d.ts +7 -0
  271. package/dist/sdk/models/shared/creditnoteminified.js +45 -0
  272. package/dist/sdk/models/shared/creditnotes.d.ts +2 -5
  273. package/dist/sdk/models/shared/creditnotes.js +0 -3
  274. package/dist/sdk/models/shared/{sublineitem2.d.ts → creditnotesublineitem.d.ts} +1 -1
  275. package/dist/sdk/models/shared/{sublineitem2.js → creditnotesublineitem.js} +9 -9
  276. package/dist/sdk/models/shared/creditnotesummary.d.ts +9 -6
  277. package/dist/sdk/models/shared/customer.d.ts +30 -181
  278. package/dist/sdk/models/shared/customer.js +41 -223
  279. package/dist/sdk/models/shared/customerbalancetransaction.d.ts +13 -28
  280. package/dist/sdk/models/shared/customerbalancetransaction.js +18 -42
  281. package/dist/sdk/models/shared/{transactions.d.ts → customerbalancetransactions.d.ts} +3 -6
  282. package/dist/sdk/models/shared/{transactions.js → customerbalancetransactions.js} +8 -11
  283. package/dist/sdk/models/shared/customercosts.d.ts +2 -5
  284. package/dist/sdk/models/shared/customercosts.js +3 -6
  285. package/dist/sdk/models/shared/customercreditbalance.d.ts +7 -0
  286. package/dist/sdk/models/shared/customercreditbalance.js +64 -0
  287. package/dist/sdk/models/shared/customercreditbalances.d.ts +7 -0
  288. package/dist/sdk/models/shared/customercreditbalances.js +54 -0
  289. package/dist/sdk/models/shared/customerminified.d.ts +0 -3
  290. package/dist/sdk/models/shared/customerminified.js +0 -3
  291. package/dist/sdk/models/shared/customers.d.ts +0 -3
  292. package/dist/sdk/models/shared/customers.js +0 -3
  293. package/dist/sdk/models/shared/customertaxid.d.ts +6 -0
  294. package/dist/sdk/models/shared/{newtransaction.js → customertaxid.js} +12 -13
  295. package/dist/sdk/models/shared/debug.d.ts +2 -2
  296. package/dist/sdk/models/shared/decrementledgerentry.d.ts +30 -0
  297. package/dist/sdk/models/shared/{creditledgerentry.js → decrementledgerentry.js} +42 -51
  298. package/dist/sdk/models/shared/deletecustomerresponse.d.ts +3 -0
  299. package/dist/sdk/models/shared/deletecustomerresponse.js +30 -0
  300. package/dist/sdk/models/shared/deprecatedeventresult.d.ts +1 -4
  301. package/dist/sdk/models/shared/deprecatedeventresult.js +0 -3
  302. package/dist/sdk/models/shared/discount.d.ts +13 -5
  303. package/dist/sdk/models/shared/discount.js +13 -4
  304. package/dist/sdk/models/shared/duplicateconstraintviolationerror.d.ts +16 -0
  305. package/dist/sdk/models/shared/duplicateconstraintviolationerror.js +82 -0
  306. package/dist/sdk/models/shared/duplicateresourcecreationerror.d.ts +16 -0
  307. package/dist/sdk/models/shared/duplicateresourcecreationerror.js +82 -0
  308. package/dist/sdk/models/shared/editcustomer.d.ts +72 -0
  309. package/dist/sdk/models/shared/editcustomer.js +151 -0
  310. package/dist/sdk/models/shared/editplan.d.ts +10 -0
  311. package/dist/sdk/models/shared/editplan.js +59 -0
  312. package/dist/sdk/models/shared/editpriceintervalparams.d.ts +34 -0
  313. package/dist/sdk/models/shared/editpriceintervalparams.js +78 -0
  314. package/dist/sdk/models/shared/event.d.ts +11 -4
  315. package/dist/sdk/models/shared/event.js +14 -3
  316. package/dist/sdk/models/shared/{credits.d.ts → events.d.ts} +3 -6
  317. package/dist/sdk/models/shared/{eventsearchresults.js → events.js} +8 -11
  318. package/dist/sdk/models/shared/expirationchangeledgerentry.d.ts +28 -0
  319. package/dist/sdk/models/shared/expirationchangeledgerentry.js +129 -0
  320. package/dist/sdk/models/shared/featurenotavailableerror.d.ts +16 -0
  321. package/dist/sdk/models/shared/featurenotavailableerror.js +82 -0
  322. package/dist/sdk/models/shared/fivehundrederror.d.ts +13 -0
  323. package/dist/sdk/models/shared/fivehundrederror.js +78 -0
  324. package/dist/sdk/models/shared/fivetranexampleprice.d.ts +241 -0
  325. package/dist/sdk/models/shared/fivetranexampleprice.js +361 -0
  326. package/dist/sdk/models/shared/fixedfeequantitychange.d.ts +12 -5
  327. package/dist/sdk/models/shared/fixedfeequantitychange.js +11 -3
  328. package/dist/sdk/models/shared/fixedfeequantityscheduleentry.d.ts +7 -0
  329. package/dist/sdk/models/shared/{fixedfeequantityschedule.js → fixedfeequantityscheduleentry.js} +10 -10
  330. package/dist/sdk/models/shared/fixedfeequantitytransition.d.ts +6 -0
  331. package/dist/sdk/models/shared/fixedfeequantitytransition.js +59 -0
  332. package/dist/sdk/models/shared/fourhundredandoneerror.d.ts +16 -0
  333. package/dist/sdk/models/shared/fourhundredandoneerror.js +82 -0
  334. package/dist/sdk/models/shared/fourhundredandtwentynineerror.d.ts +16 -0
  335. package/dist/sdk/models/shared/fourhundredandtwentynineerror.js +82 -0
  336. package/dist/sdk/models/shared/groupedsubscriptionusage.d.ts +7 -0
  337. package/dist/sdk/models/shared/groupedsubscriptionusage.js +54 -0
  338. package/dist/sdk/models/shared/groupedsubscriptionusagerecord.d.ts +14 -0
  339. package/dist/sdk/models/shared/groupedsubscriptionusagerecord.js +71 -0
  340. package/dist/sdk/models/shared/idempotencyconflict.d.ts +16 -0
  341. package/dist/sdk/models/shared/idempotencyconflict.js +82 -0
  342. package/dist/sdk/models/shared/idempotencykeyvalidationerror.d.ts +17 -0
  343. package/dist/sdk/models/shared/idempotencykeyvalidationerror.js +87 -0
  344. package/dist/sdk/models/shared/idempotencyrequestmismatch.d.ts +16 -0
  345. package/dist/sdk/models/shared/idempotencyrequestmismatch.js +82 -0
  346. package/dist/sdk/models/shared/{invoicesettings.d.ts → incrementcreditledgerentryinvoicesettings.d.ts} +2 -2
  347. package/dist/sdk/models/shared/{invoicesettings.js → incrementcreditledgerentryinvoicesettings.js} +10 -10
  348. package/dist/sdk/models/shared/incrementledgerentry.d.ts +27 -0
  349. package/dist/sdk/models/shared/incrementledgerentry.js +120 -0
  350. package/dist/sdk/models/shared/index.d.ts +143 -54
  351. package/dist/sdk/models/shared/index.js +143 -54
  352. package/dist/sdk/models/shared/ingestevent.d.ts +32 -0
  353. package/dist/sdk/models/shared/ingestevent.js +86 -0
  354. package/dist/sdk/models/shared/ingestionresponse.d.ts +5 -5
  355. package/dist/sdk/models/shared/ingestionresponse.js +3 -6
  356. package/dist/sdk/models/shared/ingestrequestbody.d.ts +5 -0
  357. package/dist/sdk/models/shared/{tieredbpsconfig1.js → ingestrequestbody.js} +11 -11
  358. package/dist/sdk/models/shared/invoice.d.ts +46 -182
  359. package/dist/sdk/models/shared/invoice.js +70 -201
  360. package/dist/sdk/models/shared/invoicelineitem.d.ts +10 -168
  361. package/dist/sdk/models/shared/invoicelineitem.js +21 -303
  362. package/dist/sdk/models/shared/invoicelineitemparams.d.ts +27 -0
  363. package/dist/sdk/models/shared/invoicelineitemparams.js +90 -0
  364. package/dist/sdk/models/shared/invoiceminified.d.ts +7 -0
  365. package/dist/sdk/models/shared/invoiceminified.js +45 -0
  366. package/dist/sdk/models/shared/invoices.d.ts +2 -5
  367. package/dist/sdk/models/shared/invoices.js +0 -3
  368. package/dist/sdk/models/shared/item.d.ts +14 -0
  369. package/dist/sdk/models/shared/item.js +72 -0
  370. package/dist/sdk/models/shared/itemexternalconnection.d.ts +16 -0
  371. package/dist/sdk/models/shared/itemexternalconnection.js +63 -0
  372. package/dist/sdk/models/shared/items.d.ts +7 -0
  373. package/dist/sdk/models/shared/{credits.js → items.js} +11 -14
  374. package/dist/sdk/models/shared/itemslim.d.ts +5 -0
  375. package/dist/sdk/models/shared/itemslim.js +50 -0
  376. package/dist/sdk/models/shared/markaspaidrequestparams.d.ts +16 -0
  377. package/dist/sdk/models/shared/markaspaidrequestparams.js +60 -0
  378. package/dist/sdk/models/shared/matrixconfig.d.ts +12 -5
  379. package/dist/sdk/models/shared/matrixconfig.js +5 -3
  380. package/dist/sdk/models/shared/matrixprice.d.ts +242 -0
  381. package/dist/sdk/models/shared/matrixprice.js +363 -0
  382. package/dist/sdk/models/shared/matrixsublineitem.d.ts +17 -0
  383. package/dist/sdk/models/shared/matrixsublineitem.js +78 -0
  384. package/dist/sdk/models/shared/matrixvalue.d.ts +8 -1
  385. package/dist/sdk/models/shared/matrixvalue.js +5 -0
  386. package/dist/sdk/models/shared/maximum.d.ts +11 -0
  387. package/dist/sdk/models/shared/{subscriptionusage.js → maximum.js} +14 -14
  388. package/dist/sdk/models/shared/maximuminterval.d.ts +23 -0
  389. package/dist/sdk/models/shared/{subscriptioncost.js → maximuminterval.js} +21 -23
  390. package/dist/sdk/models/shared/metricgroup.d.ts +5 -0
  391. package/dist/sdk/models/shared/metricgroup.js +50 -0
  392. package/dist/sdk/models/shared/minimum.d.ts +11 -0
  393. package/dist/sdk/models/shared/minimum.js +50 -0
  394. package/dist/sdk/models/shared/minimuminterval.d.ts +23 -0
  395. package/dist/sdk/models/shared/minimuminterval.js +73 -0
  396. package/dist/sdk/models/shared/newaccountingsyncconfiguration.d.ts +6 -0
  397. package/dist/sdk/models/shared/newaccountingsyncconfiguration.js +52 -0
  398. package/dist/sdk/models/shared/newbackfill.d.ts +1 -1
  399. package/dist/sdk/models/shared/newbillablemetric.d.ts +28 -0
  400. package/dist/sdk/models/shared/newbillablemetric.js +77 -0
  401. package/dist/sdk/models/shared/newbpsprice.d.ts +53 -0
  402. package/dist/sdk/models/shared/newbpsprice.js +110 -0
  403. package/dist/sdk/models/shared/newbulkbpsprice.d.ts +53 -0
  404. package/dist/sdk/models/shared/newbulkbpsprice.js +110 -0
  405. package/dist/sdk/models/shared/newbulkprice.d.ts +53 -0
  406. package/dist/sdk/models/shared/newbulkprice.js +110 -0
  407. package/dist/sdk/models/shared/newcoupon.d.ts +4 -10
  408. package/dist/sdk/models/shared/newcoupon.js +11 -11
  409. package/dist/sdk/models/shared/newcustomer.d.ts +20 -154
  410. package/dist/sdk/models/shared/newcustomer.js +34 -206
  411. package/dist/sdk/models/shared/newcustomerbalancetransaction.d.ts +13 -0
  412. package/dist/sdk/models/shared/newcustomerbalancetransaction.js +60 -0
  413. package/dist/sdk/models/shared/newmatrixprice.d.ts +53 -0
  414. package/dist/sdk/models/shared/{sublineitem.js → newmatrixprice.js} +51 -43
  415. package/dist/sdk/models/shared/newpackageprice.d.ts +53 -0
  416. package/dist/sdk/models/shared/newpackageprice.js +110 -0
  417. package/dist/sdk/models/shared/newpackagewithallocationprice.d.ts +52 -0
  418. package/dist/sdk/models/shared/newpackagewithallocationprice.js +108 -0
  419. package/dist/sdk/models/shared/newplan.d.ts +26 -0
  420. package/dist/sdk/models/shared/newplan.js +93 -0
  421. package/dist/sdk/models/shared/newreportingconfiguration.d.ts +4 -0
  422. package/dist/sdk/models/shared/newreportingconfiguration.js +45 -0
  423. package/dist/sdk/models/shared/newsubscription.d.ts +18 -43
  424. package/dist/sdk/models/shared/newsubscription.js +50 -8
  425. package/dist/sdk/models/shared/newthresholdtotalamountprice.d.ts +52 -0
  426. package/dist/sdk/models/shared/newthresholdtotalamountprice.js +108 -0
  427. package/dist/sdk/models/shared/newtieredbpsprice.d.ts +53 -0
  428. package/dist/sdk/models/shared/newtieredbpsprice.js +110 -0
  429. package/dist/sdk/models/shared/newtieredpackageprice.d.ts +52 -0
  430. package/dist/sdk/models/shared/newtieredpackageprice.js +108 -0
  431. package/dist/sdk/models/shared/newtieredprice.d.ts +53 -0
  432. package/dist/sdk/models/shared/newtieredprice.js +110 -0
  433. package/dist/sdk/models/shared/newtieredwithminimumprice.d.ts +52 -0
  434. package/dist/sdk/models/shared/newtieredwithminimumprice.js +108 -0
  435. package/dist/sdk/models/shared/newunitprice.d.ts +53 -0
  436. package/dist/sdk/models/shared/newunitprice.js +110 -0
  437. package/dist/sdk/models/shared/othersublineitem.d.ts +15 -0
  438. package/dist/sdk/models/shared/othersublineitem.js +71 -0
  439. package/dist/sdk/models/shared/overridebpsprice.d.ts +27 -0
  440. package/dist/sdk/models/shared/{bpspriceoverride.js → overridebpsprice.js} +27 -18
  441. package/dist/sdk/models/shared/overridebulkbpsprice.d.ts +27 -0
  442. package/dist/sdk/models/shared/{bulkbpspriceoverride.js → overridebulkbpsprice.js} +27 -18
  443. package/dist/sdk/models/shared/overridebulkprice.d.ts +27 -0
  444. package/dist/sdk/models/shared/{bulkpriceoverride.js → overridebulkprice.js} +27 -18
  445. package/dist/sdk/models/shared/overridefivetranexampleprice.d.ts +26 -0
  446. package/dist/sdk/models/shared/overridefivetranexampleprice.js +81 -0
  447. package/dist/sdk/models/shared/overridematrixprice.d.ts +27 -0
  448. package/dist/sdk/models/shared/overridematrixprice.js +83 -0
  449. package/dist/sdk/models/shared/overridepackageprice.d.ts +27 -0
  450. package/dist/sdk/models/shared/{packagepriceoverride.js → overridepackageprice.js} +27 -18
  451. package/dist/sdk/models/shared/overridepackagewithallocationprice.d.ts +26 -0
  452. package/dist/sdk/models/shared/overridepackagewithallocationprice.js +81 -0
  453. package/dist/sdk/models/shared/overridetestratingfunctionprice.d.ts +26 -0
  454. package/dist/sdk/models/shared/overridetestratingfunctionprice.js +81 -0
  455. package/dist/sdk/models/shared/overridethresholdtotalamountprice.d.ts +26 -0
  456. package/dist/sdk/models/shared/overridethresholdtotalamountprice.js +81 -0
  457. package/dist/sdk/models/shared/overridetieredbpsprice.d.ts +27 -0
  458. package/dist/sdk/models/shared/{tieredbpspriceoverride.js → overridetieredbpsprice.js} +30 -21
  459. package/dist/sdk/models/shared/overridetieredpackageprice.d.ts +26 -0
  460. package/dist/sdk/models/shared/overridetieredpackageprice.js +81 -0
  461. package/dist/sdk/models/shared/overridetieredprice.d.ts +27 -0
  462. package/dist/sdk/models/shared/{tieredpriceoverride.js → overridetieredprice.js} +27 -18
  463. package/dist/sdk/models/shared/overridetieredwithminimumprice.d.ts +26 -0
  464. package/dist/sdk/models/shared/overridetieredwithminimumprice.js +81 -0
  465. package/dist/sdk/models/shared/overrideunitprice.d.ts +27 -0
  466. package/dist/sdk/models/shared/{unitpriceoverride.js → overrideunitprice.js} +27 -18
  467. package/dist/sdk/models/shared/packageconfig.d.ts +7 -4
  468. package/dist/sdk/models/shared/packageconfig.js +0 -3
  469. package/dist/sdk/models/shared/packageprice.d.ts +242 -0
  470. package/dist/sdk/models/shared/packageprice.js +363 -0
  471. package/dist/sdk/models/shared/packagewithallocationprice.d.ts +241 -0
  472. package/dist/sdk/models/shared/packagewithallocationprice.js +361 -0
  473. package/dist/sdk/models/shared/percentagediscount.d.ts +15 -0
  474. package/dist/sdk/models/shared/percentagediscount.js +59 -0
  475. package/dist/sdk/models/shared/percentagediscountcreationparams.d.ts +11 -0
  476. package/dist/sdk/models/shared/percentagediscountcreationparams.js +54 -0
  477. package/dist/sdk/models/shared/percentagediscountinterval.d.ts +27 -0
  478. package/dist/sdk/models/shared/percentagediscountinterval.js +82 -0
  479. package/dist/sdk/models/shared/perpricecost.d.ts +206 -6
  480. package/dist/sdk/models/shared/perpricecost.js +6 -6
  481. package/dist/sdk/models/shared/phaseoverride.d.ts +7 -30
  482. package/dist/sdk/models/shared/phaseoverride.js +4 -42
  483. package/dist/sdk/models/shared/{availability.d.ts → pingresponse.d.ts} +1 -4
  484. package/dist/sdk/models/shared/{availability.js → pingresponse.js} +7 -10
  485. package/dist/sdk/models/shared/plan.d.ts +29 -62
  486. package/dist/sdk/models/shared/plan.js +55 -108
  487. package/dist/sdk/models/shared/planminified.d.ts +6 -2
  488. package/dist/sdk/models/shared/planminified.js +5 -0
  489. package/dist/sdk/models/shared/planphase.d.ts +18 -58
  490. package/dist/sdk/models/shared/planphase.js +30 -86
  491. package/dist/sdk/models/shared/plans.d.ts +2 -5
  492. package/dist/sdk/models/shared/plans.js +0 -3
  493. package/dist/sdk/models/shared/pricegroup.d.ts +2 -2
  494. package/dist/sdk/models/shared/priceinterval.d.ts +239 -0
  495. package/dist/sdk/models/shared/priceinterval.js +104 -0
  496. package/dist/sdk/models/shared/priceintervalfixedfeequantitytransitionparams.d.ts +11 -0
  497. package/dist/sdk/models/shared/priceintervalfixedfeequantitytransitionparams.js +54 -0
  498. package/dist/sdk/models/shared/prices.d.ts +6 -0
  499. package/dist/sdk/models/shared/prices.js +52 -0
  500. package/dist/sdk/models/shared/reportingconfiguration.d.ts +4 -0
  501. package/dist/sdk/models/shared/reportingconfiguration.js +45 -0
  502. package/dist/sdk/models/shared/requesttoolargeerror.d.ts +16 -0
  503. package/dist/sdk/models/shared/requesttoolargeerror.js +82 -0
  504. package/dist/sdk/models/shared/requestvalidationerror.d.ts +14 -17
  505. package/dist/sdk/models/shared/requestvalidationerror.js +29 -7
  506. package/dist/sdk/models/shared/resourcenotfounderror.d.ts +16 -0
  507. package/dist/sdk/models/shared/resourcenotfounderror.js +82 -0
  508. package/dist/sdk/models/shared/resourcetoolargeerror.d.ts +16 -0
  509. package/dist/sdk/models/shared/resourcetoolargeerror.js +82 -0
  510. package/dist/sdk/models/shared/sublineitemgrouping.d.ts +8 -0
  511. package/dist/sdk/models/shared/{grouping.js → sublineitemgrouping.js} +8 -11
  512. package/dist/sdk/models/shared/sublineitemmatrixconfig.d.ts +7 -0
  513. package/dist/sdk/models/shared/{matrixconfig1.js → sublineitemmatrixconfig.js} +7 -10
  514. package/dist/sdk/models/shared/subscription.d.ts +64 -31
  515. package/dist/sdk/models/shared/subscription.js +61 -42
  516. package/dist/sdk/models/shared/subscriptioncosts.d.ts +2 -5
  517. package/dist/sdk/models/shared/subscriptioncosts.js +3 -6
  518. package/dist/sdk/models/shared/subscriptionminified.d.ts +0 -3
  519. package/dist/sdk/models/shared/subscriptionminified.js +0 -3
  520. package/dist/sdk/models/shared/subscriptionplanchange.d.ts +20 -15
  521. package/dist/sdk/models/shared/subscriptionplanchange.js +37 -15
  522. package/dist/sdk/models/shared/subscriptions.d.ts +2 -5
  523. package/dist/sdk/models/shared/subscriptions.js +0 -3
  524. package/dist/sdk/models/shared/subscriptionscheduleitem.d.ts +3 -3
  525. package/dist/sdk/models/shared/{subscriptionschedule.d.ts → subscriptionscheduleitems.d.ts} +3 -6
  526. package/dist/sdk/models/shared/{subscriptionschedule.js → subscriptionscheduleitems.js} +8 -11
  527. package/dist/sdk/models/shared/subscriptiontrialinfo.d.ts +4 -0
  528. package/dist/sdk/models/shared/{subscriptioncancellation.js → subscriptiontrialinfo.js} +8 -14
  529. package/dist/sdk/models/shared/testratingfunctionprice.d.ts +241 -0
  530. package/dist/sdk/models/shared/testratingfunctionprice.js +361 -0
  531. package/dist/sdk/models/shared/thresholdtotalamountprice.d.ts +241 -0
  532. package/dist/sdk/models/shared/thresholdtotalamountprice.js +361 -0
  533. package/dist/sdk/models/shared/tier.d.ts +11 -2
  534. package/dist/sdk/models/shared/tier.js +2 -2
  535. package/dist/sdk/models/shared/tierconfig.d.ts +2 -5
  536. package/dist/sdk/models/shared/tierconfig.js +2 -5
  537. package/dist/sdk/models/shared/tieredbpsconfig.d.ts +4 -4
  538. package/dist/sdk/models/shared/tieredbpsconfig.js +0 -3
  539. package/dist/sdk/models/shared/tieredbpsprice.d.ts +242 -0
  540. package/dist/sdk/models/shared/tieredbpsprice.js +363 -0
  541. package/dist/sdk/models/shared/tieredconfig.d.ts +4 -4
  542. package/dist/sdk/models/shared/tieredconfig.js +0 -3
  543. package/dist/sdk/models/shared/tieredpackageprice.d.ts +241 -0
  544. package/dist/sdk/models/shared/tieredpackageprice.js +361 -0
  545. package/dist/sdk/models/shared/tieredprice.d.ts +242 -0
  546. package/dist/sdk/models/shared/tieredprice.js +363 -0
  547. package/dist/sdk/models/shared/tieredwithminimumprice.d.ts +241 -0
  548. package/dist/sdk/models/shared/tieredwithminimumprice.js +361 -0
  549. package/dist/sdk/models/shared/tiersublineitem.d.ts +17 -0
  550. package/dist/sdk/models/shared/{sublineitem1.js → tiersublineitem.js} +21 -18
  551. package/dist/sdk/models/shared/trialconfig.d.ts +1 -1
  552. package/dist/sdk/models/shared/trialdiscount.d.ts +19 -0
  553. package/dist/sdk/models/shared/trialdiscount.js +64 -0
  554. package/dist/sdk/models/shared/triggersubscriptionphaseparams.d.ts +8 -0
  555. package/dist/sdk/models/shared/triggersubscriptionphaseparams.js +50 -0
  556. package/dist/sdk/models/shared/ungroupedsubscriptionusage.d.ts +5 -0
  557. package/dist/sdk/models/shared/ungroupedsubscriptionusage.js +47 -0
  558. package/dist/sdk/models/shared/ungroupedsubscriptionusagerecord.d.ts +12 -0
  559. package/dist/sdk/models/shared/ungroupedsubscriptionusagerecord.js +64 -0
  560. package/dist/sdk/models/shared/unitconfig.d.ts +8 -4
  561. package/dist/sdk/models/shared/unitconfig.js +5 -3
  562. package/dist/sdk/models/shared/unitprice.d.ts +242 -0
  563. package/dist/sdk/models/shared/unitprice.js +363 -0
  564. package/dist/sdk/models/shared/unschedulefixedfeequantitychangeparams.d.ts +7 -0
  565. package/dist/sdk/models/shared/unschedulefixedfeequantitychangeparams.js +45 -0
  566. package/dist/sdk/models/shared/upcominginvoice.d.ts +89 -54
  567. package/dist/sdk/models/shared/upcominginvoice.js +216 -88
  568. package/dist/sdk/models/shared/updateevent.d.ts +1 -1
  569. package/dist/sdk/models/shared/updateevent.js +5 -1
  570. package/dist/sdk/models/shared/urlnotfound.d.ts +16 -0
  571. package/dist/sdk/models/shared/urlnotfound.js +82 -0
  572. package/dist/sdk/models/shared/usage.d.ts +3 -10
  573. package/dist/sdk/models/shared/usage.js +18 -24
  574. package/dist/sdk/models/shared/usagediscount.d.ts +15 -0
  575. package/dist/sdk/models/shared/{tier7.js → usagediscount.js} +18 -19
  576. package/dist/sdk/models/shared/usagediscountcreationparams.d.ts +11 -0
  577. package/dist/sdk/models/shared/usagediscountcreationparams.js +54 -0
  578. package/dist/sdk/models/shared/usagediscountinterval.d.ts +27 -0
  579. package/dist/sdk/models/shared/usagediscountinterval.js +82 -0
  580. package/dist/sdk/models/shared/validationerror.d.ts +11 -0
  581. package/dist/sdk/models/shared/validationerror.js +50 -0
  582. package/dist/sdk/models/shared/voidinitiatedledgerentry.d.ts +30 -0
  583. package/dist/sdk/models/shared/voidinitiatedledgerentry.js +139 -0
  584. package/dist/sdk/models/shared/voidledgerentry.d.ts +29 -0
  585. package/dist/sdk/models/shared/voidledgerentry.js +130 -0
  586. package/dist/sdk/plan.d.ts +54 -186
  587. package/dist/sdk/plan.js +656 -202
  588. package/dist/sdk/price.d.ts +246 -0
  589. package/dist/sdk/price.js +790 -0
  590. package/dist/sdk/priceinterval.d.ts +65 -0
  591. package/dist/sdk/priceinterval.js +281 -0
  592. package/dist/sdk/sdk.d.ts +149 -58
  593. package/dist/sdk/sdk.js +23 -40
  594. package/dist/sdk/subscription.d.ts +435 -280
  595. package/dist/sdk/subscription.js +1516 -350
  596. package/docs/models/operations/addeditpriceintervalsrequest.md +9 -0
  597. package/docs/models/operations/addeditpriceintervalsresponse.md +18 -0
  598. package/docs/models/operations/amendeventrequest.md +9 -0
  599. package/docs/models/operations/amendeventresponse.md +18 -0
  600. package/docs/models/operations/amendusageexternalcustomeridrequest.md +11 -0
  601. package/docs/models/operations/amendusageexternalcustomeridresponse.md +18 -0
  602. package/docs/models/operations/amendusagerequest.md +11 -0
  603. package/docs/models/operations/amendusageresponse.md +18 -0
  604. package/docs/models/operations/archivecouponrequest.md +8 -0
  605. package/docs/models/operations/archivecouponresponse.md +18 -0
  606. package/docs/models/operations/cancelsubscriptionrequest.md +9 -0
  607. package/docs/models/operations/cancelsubscriptionresponse.md +18 -0
  608. package/docs/models/operations/closebackfillrequest.md +8 -0
  609. package/docs/models/operations/closebackfillresponse.md +18 -0
  610. package/docs/models/operations/createbackfillresponse.md +18 -0
  611. package/docs/models/operations/createcouponresponse.md +18 -0
  612. package/docs/models/operations/createcustomerbalancetransactionrequest.md +9 -0
  613. package/docs/models/operations/createcustomerbalancetransactionresponse.md +18 -0
  614. package/docs/models/operations/createcustomerresponse.md +18 -0
  615. package/docs/models/operations/createinvoicelineitemresponse.md +18 -0
  616. package/docs/models/operations/createinvoiceresponse.md +18 -0
  617. package/docs/models/operations/createledgerentryexternalidrequest.md +9 -0
  618. package/docs/models/operations/createledgerentryexternalidresponse.md +18 -0
  619. package/docs/models/operations/createledgerentryrequest.md +9 -0
  620. package/docs/models/operations/createledgerentryresponse.md +18 -0
  621. package/docs/models/operations/createmetricresponse.md +18 -0
  622. package/docs/models/operations/createplanresponse.md +18 -0
  623. package/docs/models/operations/createpriceresponse.md +18 -0
  624. package/docs/models/operations/createsubscriptionresponse.md +18 -0
  625. package/docs/models/operations/deletecustomerrequest.md +8 -0
  626. package/docs/models/operations/deletecustomerresponse.md +18 -0
  627. package/docs/models/operations/deprecateeventrequest.md +8 -0
  628. package/docs/models/operations/deprecateeventresponse.md +18 -0
  629. package/docs/models/operations/fetchbackfillrequest.md +8 -0
  630. package/docs/models/operations/fetchbackfillresponse.md +18 -0
  631. package/docs/models/operations/fetchcouponrequest.md +8 -0
  632. package/docs/models/operations/fetchcouponresponse.md +18 -0
  633. package/docs/models/operations/fetchcreditnoterequest.md +8 -0
  634. package/docs/models/operations/fetchcreditnoteresponse.md +18 -0
  635. package/docs/models/operations/fetchcustomercostsexternalidrequest.md +12 -0
  636. package/docs/models/operations/fetchcustomercostsexternalidresponse.md +18 -0
  637. package/docs/models/operations/fetchcustomercostsexternalidviewmodeviewmode.md +11 -0
  638. package/docs/models/operations/fetchcustomercostsrequest.md +12 -0
  639. package/docs/models/operations/fetchcustomercostsresponse.md +18 -0
  640. package/docs/models/operations/fetchcustomercostsviewmodeviewmode.md +11 -0
  641. package/docs/models/operations/fetchcustomercreditsexternalidrequest.md +10 -0
  642. package/docs/models/operations/fetchcustomercreditsexternalidresponse.md +18 -0
  643. package/docs/models/operations/fetchcustomercreditsledgerentrystatusentrystatus.md +9 -0
  644. package/docs/models/operations/fetchcustomercreditsledgerentrytypeentrytype.md +14 -0
  645. package/docs/models/operations/fetchcustomercreditsledgerexternalidentrystatusentrystatus.md +9 -0
  646. package/docs/models/operations/fetchcustomercreditsledgerexternalidentrytypeentrytype.md +14 -0
  647. package/docs/models/operations/fetchcustomercreditsledgerexternalidrequest.md +18 -0
  648. package/docs/models/operations/fetchcustomercreditsledgerexternalidresponse.md +18 -0
  649. package/docs/models/operations/fetchcustomercreditsledgerrequest.md +18 -0
  650. package/docs/models/operations/fetchcustomercreditsledgerresponse.md +18 -0
  651. package/docs/models/operations/fetchcustomercreditsrequest.md +10 -0
  652. package/docs/models/operations/fetchcustomercreditsresponse.md +18 -0
  653. package/docs/models/operations/fetchcustomerexternalidrequest.md +8 -0
  654. package/docs/models/operations/fetchcustomerexternalidresponse.md +18 -0
  655. package/docs/models/operations/fetchcustomerrequest.md +8 -0
  656. package/docs/models/operations/fetchcustomerresponse.md +18 -0
  657. package/docs/models/operations/fetchinvoicerequest.md +8 -0
  658. package/docs/models/operations/fetchinvoiceresponse.md +18 -0
  659. package/docs/models/operations/fetchitemrequest.md +8 -0
  660. package/docs/models/operations/fetchitemresponse.md +18 -0
  661. package/docs/models/operations/fetchmetricrequest.md +8 -0
  662. package/docs/models/operations/fetchmetricresponse.md +18 -0
  663. package/docs/models/operations/fetchplanexternalidrequest.md +8 -0
  664. package/docs/models/operations/fetchplanexternalidresponse.md +18 -0
  665. package/docs/models/operations/fetchplanrequest.md +8 -0
  666. package/docs/models/operations/fetchplanresponse.md +18 -0
  667. package/docs/models/operations/fetchpriceexternalidrequest.md +8 -0
  668. package/docs/models/operations/fetchpriceexternalidresponse.md +18 -0
  669. package/docs/models/operations/fetchpricerequest.md +8 -0
  670. package/docs/models/operations/fetchpriceresponse.md +18 -0
  671. package/docs/models/operations/fetchsubscriptioncostsrequest.md +12 -0
  672. package/docs/models/operations/fetchsubscriptioncostsresponse.md +18 -0
  673. package/docs/models/operations/fetchsubscriptioncostsviewmodeviewmode.md +11 -0
  674. package/docs/models/operations/fetchsubscriptionrequest.md +8 -0
  675. package/docs/models/operations/fetchsubscriptionresponse.md +18 -0
  676. package/docs/models/operations/fetchsubscriptionschedulerequest.md +14 -0
  677. package/docs/models/operations/fetchsubscriptionscheduleresponse.md +18 -0
  678. package/docs/models/operations/fetchsubscriptionusagegranularitygranularity.md +10 -0
  679. package/docs/models/operations/fetchsubscriptionusagerequest.md +20 -0
  680. package/docs/models/operations/fetchsubscriptionusageresponse.md +18 -0
  681. package/docs/models/operations/fetchsubscriptionusageviewmodeviewmode.md +11 -0
  682. package/docs/models/operations/fetchupcominginvoicerequest.md +8 -0
  683. package/docs/models/operations/fetchupcominginvoiceresponse.md +18 -0
  684. package/docs/models/operations/ingestrequest.md +10 -0
  685. package/docs/models/operations/ingestresponse.md +18 -0
  686. package/docs/models/operations/issueinvoicerequest.md +8 -0
  687. package/docs/models/operations/issueinvoiceresponse.md +18 -0
  688. package/docs/models/operations/listbackfillsrequest.md +9 -0
  689. package/docs/models/operations/listbackfillsresponse.md +18 -0
  690. package/docs/models/operations/listbalancetransactionsrequest.md +14 -0
  691. package/docs/models/operations/listbalancetransactionsresponse.md +18 -0
  692. package/docs/models/operations/listcouponsrequest.md +11 -0
  693. package/docs/models/operations/listcouponsresponse.md +18 -0
  694. package/docs/models/operations/listcouponsubscriptionsrequest.md +10 -0
  695. package/docs/models/operations/listcouponsubscriptionsresponse.md +18 -0
  696. package/docs/models/operations/listcreditnotesrequest.md +9 -0
  697. package/docs/models/operations/listcreditnotesresponse.md +18 -0
  698. package/docs/models/operations/listcustomersrequest.md +13 -0
  699. package/docs/models/operations/listcustomersresponse.md +18 -0
  700. package/docs/models/operations/listinvoicesdatetypedatetype.md +9 -0
  701. package/docs/models/operations/listinvoicesrequest.md +27 -0
  702. package/docs/models/operations/listinvoicesresponse.md +18 -0
  703. package/docs/models/operations/listinvoicesstatus.md +12 -0
  704. package/docs/models/operations/listinvoicesstatusstatus.md +12 -0
  705. package/docs/models/operations/listitemsrequest.md +9 -0
  706. package/docs/models/operations/listitemsresponse.md +18 -0
  707. package/docs/models/operations/listmetricsrequest.md +13 -0
  708. package/docs/models/operations/listmetricsresponse.md +18 -0
  709. package/docs/models/operations/listplansrequest.md +14 -0
  710. package/docs/models/operations/listplansresponse.md +18 -0
  711. package/docs/models/operations/listplansstatusstatus.md +12 -0
  712. package/docs/models/operations/listpricesrequest.md +9 -0
  713. package/docs/models/operations/listpricesresponse.md +18 -0
  714. package/docs/models/operations/listsubscriptionsrequest.md +16 -0
  715. package/docs/models/operations/listsubscriptionsresponse.md +18 -0
  716. package/docs/models/operations/listsubscriptionsstatusstatus.md +10 -0
  717. package/docs/models/operations/markinvoiceaspaidrequest.md +9 -0
  718. package/docs/models/operations/markinvoiceaspaidresponse.md +18 -0
  719. package/docs/models/operations/pingresponse.md +18 -0
  720. package/docs/models/operations/revertbackfillrequest.md +8 -0
  721. package/docs/models/operations/revertbackfillresponse.md +18 -0
  722. package/docs/models/operations/scheduleplanchangerequest.md +9 -0
  723. package/docs/models/operations/scheduleplanchangeresponse.md +18 -0
  724. package/docs/models/operations/searcheventsrequest.md +14 -0
  725. package/docs/models/operations/searcheventsresponse.md +18 -0
  726. package/docs/models/operations/triggerphaserequest.md +9 -0
  727. package/docs/models/operations/triggerphaseresponse.md +18 -0
  728. package/docs/models/operations/unschedulecancellationrequest.md +8 -0
  729. package/docs/models/operations/unschedulecancellationresponse.md +18 -0
  730. package/docs/models/operations/unschedulefixedfeequantityrequest.md +9 -0
  731. package/docs/models/operations/unschedulefixedfeequantityresponse.md +18 -0
  732. package/docs/models/operations/unscheduleplanchangerequest.md +8 -0
  733. package/docs/models/operations/unscheduleplanchangeresponse.md +18 -0
  734. package/docs/models/operations/updatecustomerexternalidrequest.md +9 -0
  735. package/docs/models/operations/updatecustomerexternalidresponse.md +18 -0
  736. package/docs/models/operations/updatecustomerrequest.md +9 -0
  737. package/docs/models/operations/updatecustomerresponse.md +18 -0
  738. package/docs/models/operations/updatefixedfeequantityrequest.md +9 -0
  739. package/docs/models/operations/updatefixedfeequantityresponse.md +18 -0
  740. package/docs/models/operations/updateplanexternalrequest.md +9 -0
  741. package/docs/models/operations/updateplanexternalresponse.md +18 -0
  742. package/docs/models/operations/updateplanrequest.md +9 -0
  743. package/docs/models/operations/updateplanresponse.md +18 -0
  744. package/docs/models/operations/voidinvoicerequest.md +8 -0
  745. package/docs/models/operations/voidinvoiceresponse.md +18 -0
  746. package/docs/models/shared/accountingprovider.md +9 -0
  747. package/docs/models/shared/accountingproviderconfig.md +9 -0
  748. package/docs/models/shared/accountingproviderprovidertype.md +9 -0
  749. package/docs/models/shared/accountingsyncconfiguration.md +9 -0
  750. package/docs/models/shared/adddecrementcreditledgerentryrequestparams.md +11 -0
  751. package/docs/models/shared/adddecrementcreditledgerentryrequestparamsentrytype.md +8 -0
  752. package/docs/models/shared/adddecrementcreditledgerentryrequestparamsmetadata.md +9 -0
  753. package/docs/models/shared/addeditpriceintervalparams.md +9 -0
  754. package/docs/models/shared/addexpirationchangecreditledgerentryrequestparams.md +14 -0
  755. package/docs/models/shared/addexpirationchangecreditledgerentryrequestparamsentrytype.md +8 -0
  756. package/docs/models/shared/addexpirationchangecreditledgerentryrequestparamsmetadata.md +9 -0
  757. package/docs/models/shared/addincrementcreditledgerentryrequestparams.md +15 -0
  758. package/docs/models/shared/addincrementcreditledgerentryrequestparamsentrytype.md +8 -0
  759. package/docs/models/shared/addincrementcreditledgerentryrequestparamsmetadata.md +9 -0
  760. package/docs/models/shared/addpriceintervalparams.md +16 -0
  761. package/docs/models/shared/addpriceintervalparamsenddateenddate.md +11 -0
  762. package/docs/models/shared/addpriceintervalparamsstartdatestartdate.md +11 -0
  763. package/docs/models/shared/address.md +13 -0
  764. package/docs/models/shared/addressinput.md +13 -0
  765. package/docs/models/shared/addvoidcreditledgerentryrequestparams.md +12 -0
  766. package/docs/models/shared/addvoidcreditledgerentryrequestparamsentrytype.md +8 -0
  767. package/docs/models/shared/addvoidcreditledgerentryrequestparamsmetadata.md +9 -0
  768. package/docs/models/shared/addvoidcreditledgerentryrequestparamsvoidreason.md +10 -0
  769. package/docs/models/shared/affectedblock.md +10 -0
  770. package/docs/models/shared/aggregatedcost.md +12 -0
  771. package/docs/models/shared/amendedevent.md +12 -0
  772. package/docs/models/shared/amendedeventproperties.md +9 -0
  773. package/docs/models/shared/amendedusage.md +9 -0
  774. package/docs/models/shared/amendeventresult.md +8 -0
  775. package/docs/models/shared/amendmentledgerentry.md +21 -0
  776. package/docs/models/shared/amendmentledgerentryentrystatus.md +9 -0
  777. package/docs/models/shared/amendmentledgerentryentrytype.md +8 -0
  778. package/docs/models/shared/amountdiscount.md +10 -0
  779. package/docs/models/shared/amountdiscountcreationparams.md +9 -0
  780. package/docs/models/shared/amountdiscountcreationparamsdiscounttype.md +8 -0
  781. package/docs/models/shared/amountdiscountdiscounttype.md +8 -0
  782. package/docs/models/shared/amountdiscountinterval.md +13 -0
  783. package/docs/models/shared/amountdiscountintervaldiscounttype.md +8 -0
  784. package/docs/models/shared/autocollection.md +10 -0
  785. package/docs/models/shared/backfill.md +17 -0
  786. package/docs/models/shared/backfills.md +9 -0
  787. package/docs/models/shared/backfillstatus.md +13 -0
  788. package/docs/models/shared/billablemetric.md +16 -0
  789. package/docs/models/shared/billablemetrics.md +9 -0
  790. package/docs/models/shared/billablemetricsimple.md +9 -0
  791. package/docs/models/shared/billablemetricstatus.md +10 -0
  792. package/docs/models/shared/billablemetrictiny.md +8 -0
  793. package/docs/models/shared/billingcyclealignment.md +12 -0
  794. package/docs/models/shared/bpsconfig.md +9 -0
  795. package/docs/models/shared/bpsprice.md +225 -0
  796. package/docs/models/shared/bpspricecadence.md +11 -0
  797. package/docs/models/shared/bpspricemodeltype.md +8 -0
  798. package/docs/models/shared/bpspricepricetype.md +9 -0
  799. package/docs/models/shared/bpstier.md +11 -0
  800. package/docs/models/shared/bulkbpsconfig.md +8 -0
  801. package/docs/models/shared/bulkbpsprice.md +225 -0
  802. package/docs/models/shared/bulkbpspricecadence.md +11 -0
  803. package/docs/models/shared/bulkbpspricemodeltype.md +8 -0
  804. package/docs/models/shared/bulkbpspricepricetype.md +9 -0
  805. package/docs/models/shared/bulkbpstier.md +10 -0
  806. package/docs/models/shared/bulkconfig.md +8 -0
  807. package/docs/models/shared/bulkprice.md +225 -0
  808. package/docs/models/shared/bulkpricecadence.md +11 -0
  809. package/docs/models/shared/bulkpricemodeltype.md +8 -0
  810. package/docs/models/shared/bulkpricepricetype.md +9 -0
  811. package/docs/models/shared/bulktier.md +9 -0
  812. package/docs/models/shared/cancelsubscriptionparams.md +9 -0
  813. package/docs/models/shared/cancelsubscriptionparamscanceloption.md +12 -0
  814. package/docs/models/shared/changeoption.md +10 -0
  815. package/docs/models/shared/coupon.md +21 -0
  816. package/docs/models/shared/coupondiscount.md +7 -0
  817. package/docs/models/shared/couponredemption.md +10 -0
  818. package/docs/models/shared/coupons.md +9 -0
  819. package/docs/models/shared/createinvoicelineitemparams.md +13 -0
  820. package/docs/models/shared/createoneoffinvoiceparams.md +15 -0
  821. package/docs/models/shared/creditblockexpiryledgerentry.md +21 -0
  822. package/docs/models/shared/creditblockexpiryledgerentryentrystatus.md +9 -0
  823. package/docs/models/shared/creditblockexpiryledgerentryentrytype.md +8 -0
  824. package/docs/models/shared/creditledgerentries.md +9 -0
  825. package/docs/models/shared/creditnote.md +26 -0
  826. package/docs/models/shared/creditnotediscounts.md +7 -0
  827. package/docs/models/shared/creditnotelineitem.md +15 -0
  828. package/docs/models/shared/creditnotelineitemdiscounts.md +7 -0
  829. package/docs/models/shared/creditnotelineitemtaxamounts.md +7 -0
  830. package/docs/models/shared/creditnotemaximumamountadjustment.md +9 -0
  831. package/docs/models/shared/creditnoteminified.md +8 -0
  832. package/docs/models/shared/creditnotereason.md +11 -0
  833. package/docs/models/shared/creditnotes.md +9 -0
  834. package/docs/models/shared/creditnotesublineitem.md +10 -0
  835. package/docs/models/shared/creditnotesummary.md +13 -0
  836. package/docs/models/shared/creditnotetype.md +9 -0
  837. package/docs/models/shared/customer.md +42 -0
  838. package/docs/models/shared/customerbalancetransaction.md +17 -0
  839. package/docs/models/shared/customerbalancetransactionaction.md +10 -0
  840. package/docs/models/shared/customerbalancetransactions.md +9 -0
  841. package/docs/models/shared/customerbalancetransactiontype.md +9 -0
  842. package/docs/models/shared/customercosts.md +8 -0
  843. package/docs/models/shared/customercreditbalance.md +11 -0
  844. package/docs/models/shared/customercreditbalances.md +9 -0
  845. package/docs/models/shared/customerminified.md +9 -0
  846. package/docs/models/shared/customerpaymentprovider.md +14 -0
  847. package/docs/models/shared/customers.md +9 -0
  848. package/docs/models/shared/customertaxid.md +10 -0
  849. package/docs/models/shared/debug.md +11 -0
  850. package/docs/models/shared/decrementledgerentry.md +24 -0
  851. package/docs/models/shared/decrementledgerentryentrystatus.md +9 -0
  852. package/docs/models/shared/decrementledgerentryentrytype.md +8 -0
  853. package/docs/models/shared/deletecustomerresponse.md +7 -0
  854. package/docs/models/shared/deprecatedeventresult.md +8 -0
  855. package/docs/models/shared/discount.md +15 -0
  856. package/docs/models/shared/discountdiscounttype.md +11 -0
  857. package/docs/models/shared/duplicateconstraintviolationerror.md +12 -0
  858. package/docs/models/shared/duplicateconstraintviolationerrorheaders.md +7 -0
  859. package/docs/models/shared/duplicateconstraintviolationerrorstatus.md +8 -0
  860. package/docs/models/shared/duplicateconstraintviolationerrortype.md +8 -0
  861. package/docs/models/shared/duplicateresourcecreationerror.md +12 -0
  862. package/docs/models/shared/duplicateresourcecreationerrorheaders.md +7 -0
  863. package/docs/models/shared/duplicateresourcecreationerrorstatus.md +8 -0
  864. package/docs/models/shared/duplicateresourcecreationerrortype.md +8 -0
  865. package/docs/models/shared/editcustomer.md +22 -0
  866. package/docs/models/shared/editcustomermetadata.md +9 -0
  867. package/docs/models/shared/editcustomerpaymentprovider.md +16 -0
  868. package/docs/models/shared/editplan.md +9 -0
  869. package/docs/models/shared/editplanmetadata.md +7 -0
  870. package/docs/models/shared/editpriceintervalparams.md +11 -0
  871. package/docs/models/shared/editpriceintervalparamsenddateenddate.md +11 -0
  872. package/docs/models/shared/editpriceintervalparamsstartdatestartdate.md +11 -0
  873. package/docs/models/shared/event.md +17 -0
  874. package/docs/models/shared/eventproperties.md +9 -0
  875. package/docs/models/shared/events.md +9 -0
  876. package/docs/models/shared/eventsearchcriteria.md +9 -0
  877. package/docs/models/shared/expirationchangeledgerentry.md +22 -0
  878. package/docs/models/shared/expirationchangeledgerentryentrystatus.md +9 -0
  879. package/docs/models/shared/expirationchangeledgerentryentrytype.md +8 -0
  880. package/docs/models/shared/featurenotavailableerror.md +12 -0
  881. package/docs/models/shared/featurenotavailableerrorheaders.md +7 -0
  882. package/docs/models/shared/featurenotavailableerrorstatus.md +8 -0
  883. package/docs/models/shared/featurenotavailableerrortype.md +8 -0
  884. package/docs/models/shared/fivehundrederror.md +12 -0
  885. package/docs/models/shared/fivehundrederrorheaders.md +7 -0
  886. package/docs/models/shared/fivehundrederrortype.md +8 -0
  887. package/docs/models/shared/fivetranexampleprice.md +225 -0
  888. package/docs/models/shared/fivetranexamplepricecadence.md +11 -0
  889. package/docs/models/shared/fivetranexamplepricemodeltype.md +8 -0
  890. package/docs/models/shared/fivetranexamplepricepricetype.md +9 -0
  891. package/docs/models/shared/fixedfeequantitychange.md +11 -0
  892. package/docs/models/shared/fixedfeequantitychangechangeoption.md +12 -0
  893. package/docs/models/shared/fixedfeequantityscheduleentry.md +11 -0
  894. package/docs/models/shared/fixedfeequantitytransition.md +10 -0
  895. package/docs/models/shared/fourhundredandoneerror.md +12 -0
  896. package/docs/models/shared/fourhundredandoneerrorheaders.md +7 -0
  897. package/docs/models/shared/fourhundredandoneerrorstatus.md +8 -0
  898. package/docs/models/shared/fourhundredandoneerrortype.md +8 -0
  899. package/docs/models/shared/fourhundredandtwentynineerror.md +12 -0
  900. package/docs/models/shared/fourhundredandtwentynineerrorheaders.md +7 -0
  901. package/docs/models/shared/fourhundredandtwentynineerrorstatus.md +8 -0
  902. package/docs/models/shared/fourhundredandtwentynineerrortype.md +8 -0
  903. package/docs/models/shared/groupedsubscriptionusage.md +9 -0
  904. package/docs/models/shared/groupedsubscriptionusagerecord.md +11 -0
  905. package/docs/models/shared/groupedsubscriptionusagerecordviewmode.md +9 -0
  906. package/docs/models/shared/idempotencyconflict.md +12 -0
  907. package/docs/models/shared/idempotencyconflictheaders.md +7 -0
  908. package/docs/models/shared/idempotencyconflictstatus.md +8 -0
  909. package/docs/models/shared/idempotencyconflicttype.md +8 -0
  910. package/docs/models/shared/idempotencykeyvalidationerror.md +13 -0
  911. package/docs/models/shared/idempotencykeyvalidationerrorheaders.md +7 -0
  912. package/docs/models/shared/idempotencykeyvalidationerrorstatus.md +8 -0
  913. package/docs/models/shared/idempotencykeyvalidationerrortype.md +8 -0
  914. package/docs/models/shared/idempotencyrequestmismatch.md +12 -0
  915. package/docs/models/shared/idempotencyrequestmismatchheaders.md +7 -0
  916. package/docs/models/shared/idempotencyrequestmismatchstatus.md +8 -0
  917. package/docs/models/shared/idempotencyrequestmismatchtype.md +8 -0
  918. package/docs/models/shared/incrementcreditledgerentryinvoicesettings.md +12 -0
  919. package/docs/models/shared/incrementledgerentry.md +21 -0
  920. package/docs/models/shared/incrementledgerentryentrystatus.md +9 -0
  921. package/docs/models/shared/incrementledgerentryentrytype.md +8 -0
  922. package/docs/models/shared/ingestevent.md +13 -0
  923. package/docs/models/shared/ingesteventproperties.md +9 -0
  924. package/docs/models/shared/ingestionresponse.md +9 -0
  925. package/docs/models/shared/ingestrequestbody.md +8 -0
  926. package/docs/models/shared/invoice.md +51 -0
  927. package/docs/models/shared/invoicelineitem.md +23 -0
  928. package/docs/models/shared/invoicelineitemparams.md +14 -0
  929. package/docs/models/shared/invoicelineitemparamsmodeltype.md +8 -0
  930. package/docs/models/shared/invoicemetadata.md +7 -0
  931. package/docs/models/shared/invoiceminified.md +8 -0
  932. package/docs/models/shared/invoices.md +9 -0
  933. package/docs/models/shared/invoicestatus.md +12 -0
  934. package/docs/models/shared/item.md +14 -0
  935. package/docs/models/shared/itemexternalconnection.md +9 -0
  936. package/docs/models/shared/itemexternalconnectionexternalconnectionnameexternalconnectionname.md +11 -0
  937. package/docs/models/shared/itemexternalconnectionexternalconnectionnameexternalconnectionname1.md +10 -0
  938. package/docs/models/shared/items.md +9 -0
  939. package/docs/models/shared/itemslim.md +9 -0
  940. package/docs/models/shared/markaspaidrequestparams.md +10 -0
  941. package/docs/models/shared/matrixconfig.md +11 -0
  942. package/docs/models/shared/matrixprice.md +225 -0
  943. package/docs/models/shared/matrixpricecadence.md +11 -0
  944. package/docs/models/shared/matrixpricemodeltype.md +8 -0
  945. package/docs/models/shared/matrixpricepricetype.md +9 -0
  946. package/docs/models/shared/matrixsublineitem.md +13 -0
  947. package/docs/models/shared/matrixsublineitemtype.md +8 -0
  948. package/docs/models/shared/matrixvalue.md +10 -0
  949. package/docs/models/shared/maximum.md +9 -0
  950. package/docs/models/shared/maximuminterval.md +12 -0
  951. package/docs/models/shared/metricgroup.md +9 -0
  952. package/docs/models/shared/minimum.md +9 -0
  953. package/docs/models/shared/minimuminterval.md +12 -0
  954. package/docs/models/shared/newaccountingsyncconfiguration.md +9 -0
  955. package/docs/models/shared/newbackfill.md +13 -0
  956. package/docs/models/shared/newbillablemetric.md +12 -0
  957. package/docs/models/shared/newbillablemetricmetadata.md +9 -0
  958. package/docs/models/shared/newbpsprice.md +18 -0
  959. package/docs/models/shared/newbpspricecadence.md +12 -0
  960. package/docs/models/shared/newbpspricemodeltype.md +8 -0
  961. package/docs/models/shared/newbulkbpsprice.md +18 -0
  962. package/docs/models/shared/newbulkbpspricecadence.md +12 -0
  963. package/docs/models/shared/newbulkbpspricemodeltype.md +8 -0
  964. package/docs/models/shared/newbulkprice.md +18 -0
  965. package/docs/models/shared/newbulkpricecadence.md +12 -0
  966. package/docs/models/shared/newbulkpricemodeltype.md +8 -0
  967. package/docs/models/shared/newcoupon.md +11 -0
  968. package/docs/models/shared/newcoupondiscount.md +7 -0
  969. package/docs/models/shared/newcustomer.md +23 -0
  970. package/docs/models/shared/newcustomerbalancetransaction.md +10 -0
  971. package/docs/models/shared/newcustomerbalancetransactiontype.md +9 -0
  972. package/docs/models/shared/newcustomermetadata.md +9 -0
  973. package/docs/models/shared/newcustomerpaymentprovider.md +14 -0
  974. package/docs/models/shared/newmatrixprice.md +18 -0
  975. package/docs/models/shared/newmatrixpricecadence.md +12 -0
  976. package/docs/models/shared/newmatrixpricemodeltype.md +8 -0
  977. package/docs/models/shared/newpackageprice.md +18 -0
  978. package/docs/models/shared/newpackagepricecadence.md +12 -0
  979. package/docs/models/shared/newpackagepricemodeltype.md +8 -0
  980. package/docs/models/shared/newpackagewithallocationprice.md +18 -0
  981. package/docs/models/shared/newpackagewithallocationpricecadence.md +12 -0
  982. package/docs/models/shared/newpackagewithallocationpricemodeltype.md +8 -0
  983. package/docs/models/shared/newplan.md +14 -0
  984. package/docs/models/shared/newplanmetadata.md +7 -0
  985. package/docs/models/shared/newplanprices.md +7 -0
  986. package/docs/models/shared/newreportingconfiguration.md +8 -0
  987. package/docs/models/shared/newsubscription.md +31 -0
  988. package/docs/models/shared/newsubscriptionexternalmarketplace.md +10 -0
  989. package/docs/models/shared/newsubscriptionmetadata.md +7 -0
  990. package/docs/models/shared/newthresholdtotalamountprice.md +18 -0
  991. package/docs/models/shared/newthresholdtotalamountpricecadence.md +12 -0
  992. package/docs/models/shared/newthresholdtotalamountpricemodeltype.md +8 -0
  993. package/docs/models/shared/newtieredbpsprice.md +18 -0
  994. package/docs/models/shared/newtieredbpspricecadence.md +12 -0
  995. package/docs/models/shared/newtieredbpspricemodeltype.md +8 -0
  996. package/docs/models/shared/newtieredpackageprice.md +18 -0
  997. package/docs/models/shared/newtieredpackagepricecadence.md +12 -0
  998. package/docs/models/shared/newtieredpackagepricemodeltype.md +8 -0
  999. package/docs/models/shared/newtieredprice.md +18 -0
  1000. package/docs/models/shared/newtieredpricecadence.md +12 -0
  1001. package/docs/models/shared/newtieredpricemodeltype.md +8 -0
  1002. package/docs/models/shared/newtieredwithminimumprice.md +18 -0
  1003. package/docs/models/shared/newtieredwithminimumpricecadence.md +12 -0
  1004. package/docs/models/shared/newtieredwithminimumpricemodeltype.md +8 -0
  1005. package/docs/models/shared/newunitprice.md +18 -0
  1006. package/docs/models/shared/newunitpricecadence.md +12 -0
  1007. package/docs/models/shared/newunitpricemodeltype.md +8 -0
  1008. package/docs/models/shared/othersublineitem.md +12 -0
  1009. package/docs/models/shared/othersublineitemtype.md +8 -0
  1010. package/docs/models/shared/overridebpsprice.md +14 -0
  1011. package/docs/models/shared/overridebpspricemodeltype.md +8 -0
  1012. package/docs/models/shared/overridebulkbpsprice.md +14 -0
  1013. package/docs/models/shared/overridebulkbpspricemodeltype.md +8 -0
  1014. package/docs/models/shared/overridebulkprice.md +14 -0
  1015. package/docs/models/shared/overridebulkpricemodeltype.md +8 -0
  1016. package/docs/models/shared/overridefivetranexampleprice.md +14 -0
  1017. package/docs/models/shared/overridefivetranexamplepricemodeltype.md +8 -0
  1018. package/docs/models/shared/overridematrixprice.md +14 -0
  1019. package/docs/models/shared/overridematrixpricemodeltype.md +8 -0
  1020. package/docs/models/shared/overridepackageprice.md +14 -0
  1021. package/docs/models/shared/overridepackagepricemodeltype.md +8 -0
  1022. package/docs/models/shared/overridepackagewithallocationprice.md +14 -0
  1023. package/docs/models/shared/overridepackagewithallocationpricemodeltype.md +8 -0
  1024. package/docs/models/shared/overridetestratingfunctionprice.md +14 -0
  1025. package/docs/models/shared/overridetestratingfunctionpricemodeltype.md +8 -0
  1026. package/docs/models/shared/overridethresholdtotalamountprice.md +14 -0
  1027. package/docs/models/shared/overridethresholdtotalamountpricemodeltype.md +8 -0
  1028. package/docs/models/shared/overridetieredbpsprice.md +14 -0
  1029. package/docs/models/shared/overridetieredbpspricemodeltype.md +8 -0
  1030. package/docs/models/shared/overridetieredpackageprice.md +14 -0
  1031. package/docs/models/shared/overridetieredpackagepricemodeltype.md +8 -0
  1032. package/docs/models/shared/overridetieredprice.md +14 -0
  1033. package/docs/models/shared/overridetieredpricemodeltype.md +8 -0
  1034. package/docs/models/shared/overridetieredwithminimumprice.md +14 -0
  1035. package/docs/models/shared/overridetieredwithminimumpricemodeltype.md +8 -0
  1036. package/docs/models/shared/overrideunitprice.md +14 -0
  1037. package/docs/models/shared/overrideunitpricemodeltype.md +8 -0
  1038. package/docs/models/shared/packageconfig.md +9 -0
  1039. package/docs/models/shared/packageprice.md +225 -0
  1040. package/docs/models/shared/packagepricecadence.md +11 -0
  1041. package/docs/models/shared/packagepricemodeltype.md +8 -0
  1042. package/docs/models/shared/packagepricepricetype.md +9 -0
  1043. package/docs/models/shared/packagewithallocationprice.md +225 -0
  1044. package/docs/models/shared/packagewithallocationpricecadence.md +11 -0
  1045. package/docs/models/shared/packagewithallocationpricemodeltype.md +8 -0
  1046. package/docs/models/shared/packagewithallocationpricepricetype.md +9 -0
  1047. package/docs/models/shared/paginationmetadata.md +9 -0
  1048. package/docs/models/shared/percentagediscount.md +10 -0
  1049. package/docs/models/shared/percentagediscountcreationparams.md +9 -0
  1050. package/docs/models/shared/percentagediscountcreationparamsdiscounttype.md +8 -0
  1051. package/docs/models/shared/percentagediscountdiscounttype.md +8 -0
  1052. package/docs/models/shared/percentagediscountinterval.md +13 -0
  1053. package/docs/models/shared/percentagediscountintervaldiscounttype.md +8 -0
  1054. package/docs/models/shared/perpricecost.md +12 -0
  1055. package/docs/models/shared/phaseoverride.md +11 -0
  1056. package/docs/models/shared/pingresponse.md +8 -0
  1057. package/docs/models/shared/plan.md +33 -0
  1058. package/docs/models/shared/planmetadata.md +7 -0
  1059. package/docs/models/shared/planminified.md +10 -0
  1060. package/docs/models/shared/planphase.md +18 -0
  1061. package/docs/models/shared/planphasedurationunit.md +11 -0
  1062. package/docs/models/shared/planprices.md +7 -0
  1063. package/docs/models/shared/plans.md +9 -0
  1064. package/docs/models/shared/planstatus.md +10 -0
  1065. package/docs/models/shared/pricegroup.md +12 -0
  1066. package/docs/models/shared/priceinterval.md +18 -0
  1067. package/docs/models/shared/priceintervalfixedfeequantitytransitionparams.md +9 -0
  1068. package/docs/models/shared/prices.md +9 -0
  1069. package/docs/models/shared/product.md +10 -0
  1070. package/docs/models/shared/reportingconfiguration.md +8 -0
  1071. package/docs/models/shared/requesttoolargeerror.md +12 -0
  1072. package/docs/models/shared/requesttoolargeerrorheaders.md +7 -0
  1073. package/docs/models/shared/requesttoolargeerrorstatus.md +8 -0
  1074. package/docs/models/shared/requesttoolargeerrortype.md +8 -0
  1075. package/docs/models/shared/requestvalidationerror.md +13 -0
  1076. package/docs/models/shared/requestvalidationerrorheaders.md +7 -0
  1077. package/docs/models/shared/requestvalidationerrorstatus.md +8 -0
  1078. package/docs/models/shared/requestvalidationerrortype.md +8 -0
  1079. package/docs/models/shared/resourcenotfounderror.md +12 -0
  1080. package/docs/models/shared/resourcenotfounderrorheaders.md +7 -0
  1081. package/docs/models/shared/resourcenotfounderrorstatus.md +8 -0
  1082. package/docs/models/shared/resourcenotfounderrortype.md +8 -0
  1083. package/docs/models/shared/resourcetoolargeerror.md +12 -0
  1084. package/docs/models/shared/resourcetoolargeerrorheaders.md +7 -0
  1085. package/docs/models/shared/resourcetoolargeerrorstatus.md +8 -0
  1086. package/docs/models/shared/resourcetoolargeerrortype.md +8 -0
  1087. package/docs/models/shared/security.md +8 -0
  1088. package/docs/models/shared/sublineitemgrouping.md +9 -0
  1089. package/docs/models/shared/sublineitemmatrixconfig.md +8 -0
  1090. package/docs/models/shared/subscription.md +44 -0
  1091. package/docs/models/shared/subscriptioncosts.md +8 -0
  1092. package/docs/models/shared/subscriptionmetadata.md +9 -0
  1093. package/docs/models/shared/subscriptionminified.md +8 -0
  1094. package/docs/models/shared/subscriptionplanchange.md +23 -0
  1095. package/docs/models/shared/subscriptions.md +9 -0
  1096. package/docs/models/shared/subscriptionscheduleitem.md +10 -0
  1097. package/docs/models/shared/subscriptionscheduleitems.md +9 -0
  1098. package/docs/models/shared/subscriptionstatus.md +10 -0
  1099. package/docs/models/shared/subscriptiontrialinfo.md +8 -0
  1100. package/docs/models/shared/taxamount.md +10 -0
  1101. package/docs/models/shared/testratingfunctionprice.md +225 -0
  1102. package/docs/models/shared/testratingfunctionpricecadence.md +11 -0
  1103. package/docs/models/shared/testratingfunctionpricemodeltype.md +8 -0
  1104. package/docs/models/shared/testratingfunctionpricepricetype.md +9 -0
  1105. package/docs/models/shared/thresholdtotalamountprice.md +225 -0
  1106. package/docs/models/shared/thresholdtotalamountpricecadence.md +11 -0
  1107. package/docs/models/shared/thresholdtotalamountpricemodeltype.md +8 -0
  1108. package/docs/models/shared/thresholdtotalamountpricepricetype.md +9 -0
  1109. package/docs/models/shared/tier.md +10 -0
  1110. package/docs/models/shared/tierconfig.md +10 -0
  1111. package/docs/models/shared/tieredbpsconfig.md +8 -0
  1112. package/docs/models/shared/tieredbpsprice.md +225 -0
  1113. package/docs/models/shared/tieredbpspricecadence.md +11 -0
  1114. package/docs/models/shared/tieredbpspricemodeltype.md +8 -0
  1115. package/docs/models/shared/tieredbpspricepricetype.md +9 -0
  1116. package/docs/models/shared/tieredconfig.md +8 -0
  1117. package/docs/models/shared/tieredpackageprice.md +225 -0
  1118. package/docs/models/shared/tieredpackagepricecadence.md +11 -0
  1119. package/docs/models/shared/tieredpackagepricemodeltype.md +8 -0
  1120. package/docs/models/shared/tieredpackagepricepricetype.md +9 -0
  1121. package/docs/models/shared/tieredprice.md +225 -0
  1122. package/docs/models/shared/tieredpricecadence.md +11 -0
  1123. package/docs/models/shared/tieredpricemodeltype.md +8 -0
  1124. package/docs/models/shared/tieredpricepricetype.md +9 -0
  1125. package/docs/models/shared/tieredwithminimumprice.md +225 -0
  1126. package/docs/models/shared/tieredwithminimumpricecadence.md +11 -0
  1127. package/docs/models/shared/tieredwithminimumpricemodeltype.md +8 -0
  1128. package/docs/models/shared/tieredwithminimumpricepricetype.md +9 -0
  1129. package/docs/models/shared/tiersublineitem.md +13 -0
  1130. package/docs/models/shared/tiersublineitemtype.md +8 -0
  1131. package/docs/models/shared/trialconfig.md +9 -0
  1132. package/docs/models/shared/trialconfigtrialperiodunit.md +8 -0
  1133. package/docs/models/shared/trialdiscount.md +11 -0
  1134. package/docs/models/shared/trialdiscountdiscounttype.md +8 -0
  1135. package/docs/models/shared/triggersubscriptionphaseparams.md +8 -0
  1136. package/docs/models/shared/ungroupedsubscriptionusage.md +8 -0
  1137. package/docs/models/shared/ungroupedsubscriptionusagerecord.md +10 -0
  1138. package/docs/models/shared/ungroupedsubscriptionusagerecordviewmode.md +9 -0
  1139. package/docs/models/shared/unitconfig.md +9 -0
  1140. package/docs/models/shared/unitprice.md +225 -0
  1141. package/docs/models/shared/unitpricecadence.md +11 -0
  1142. package/docs/models/shared/unitpricemodeltype.md +8 -0
  1143. package/docs/models/shared/unitpricepricetype.md +9 -0
  1144. package/docs/models/shared/unschedulefixedfeequantitychangeparams.md +8 -0
  1145. package/docs/models/shared/upcominginvoice.md +46 -0
  1146. package/docs/models/shared/upcominginvoicemetadata.md +7 -0
  1147. package/docs/models/shared/upcominginvoicestatus.md +12 -0
  1148. package/docs/models/shared/updateevent.md +12 -0
  1149. package/docs/models/shared/updateeventproperties.md +9 -0
  1150. package/docs/models/shared/urlnotfound.md +12 -0
  1151. package/docs/models/shared/urlnotfoundheaders.md +7 -0
  1152. package/docs/models/shared/urlnotfoundstatus.md +8 -0
  1153. package/docs/models/shared/urlnotfoundtype.md +8 -0
  1154. package/docs/models/shared/usage.md +10 -0
  1155. package/docs/models/shared/usagediscount.md +10 -0
  1156. package/docs/models/shared/usagediscountcreationparams.md +9 -0
  1157. package/docs/models/shared/usagediscountcreationparamsdiscounttype.md +8 -0
  1158. package/docs/models/shared/usagediscountdiscounttype.md +8 -0
  1159. package/docs/models/shared/usagediscountinterval.md +13 -0
  1160. package/docs/models/shared/usagediscountintervaldiscounttype.md +8 -0
  1161. package/docs/models/shared/validationerror.md +9 -0
  1162. package/docs/models/shared/voidinitiatedledgerentry.md +24 -0
  1163. package/docs/models/shared/voidinitiatedledgerentryentrystatus.md +9 -0
  1164. package/docs/models/shared/voidinitiatedledgerentryentrytype.md +8 -0
  1165. package/docs/models/shared/voidledgerentry.md +23 -0
  1166. package/docs/models/shared/voidledgerentryentrystatus.md +9 -0
  1167. package/docs/models/shared/voidledgerentryentrytype.md +8 -0
  1168. package/docs/sdks/availability/README.md +45 -0
  1169. package/docs/sdks/coupon/README.md +226 -0
  1170. package/docs/sdks/credit/README.md +424 -0
  1171. package/docs/sdks/creditnote/README.md +91 -0
  1172. package/docs/sdks/customer/README.md +1129 -0
  1173. package/docs/sdks/event/README.md +674 -0
  1174. package/docs/sdks/invoice/README.md +402 -0
  1175. package/docs/sdks/item/README.md +89 -0
  1176. package/docs/sdks/metric/README.md +140 -0
  1177. package/docs/sdks/orb/README.md +21 -0
  1178. package/docs/sdks/plan/README.md +300 -0
  1179. package/docs/sdks/price/README.md +411 -0
  1180. package/docs/sdks/priceinterval/README.md +180 -0
  1181. package/docs/sdks/subscription/README.md +1412 -0
  1182. package/docs/types/rfcdate.md +11 -0
  1183. package/package.json +2 -1
  1184. package/dist/sdk/models/operations/addledgerentryexternalid.d.ts +0 -16
  1185. package/dist/sdk/models/operations/listcreditnote.d.ts +0 -34
  1186. package/dist/sdk/models/shared/action.d.ts +0 -8
  1187. package/dist/sdk/models/shared/action.js +0 -15
  1188. package/dist/sdk/models/shared/billablemetricminified.d.ts +0 -5
  1189. package/dist/sdk/models/shared/bpspriceoverride.d.ts +0 -24
  1190. package/dist/sdk/models/shared/bulkbpspriceoverride.d.ts +0 -24
  1191. package/dist/sdk/models/shared/bulkpriceoverride.d.ts +0 -24
  1192. package/dist/sdk/models/shared/cadence.d.ts +0 -5
  1193. package/dist/sdk/models/shared/cadence.js +0 -12
  1194. package/dist/sdk/models/shared/canceloption.d.ts +0 -8
  1195. package/dist/sdk/models/shared/canceloption.js +0 -15
  1196. package/dist/sdk/models/shared/changeoption1.d.ts +0 -8
  1197. package/dist/sdk/models/shared/changeoption1.js +0 -15
  1198. package/dist/sdk/models/shared/credit.d.ts +0 -16
  1199. package/dist/sdk/models/shared/creditblock.d.ts +0 -15
  1200. package/dist/sdk/models/shared/creditledgerentry.d.ts +0 -58
  1201. package/dist/sdk/models/shared/creditnotetype.d.ts +0 -7
  1202. package/dist/sdk/models/shared/creditnotetype.js +0 -14
  1203. package/dist/sdk/models/shared/customercost.d.ts +0 -15
  1204. package/dist/sdk/models/shared/discounttype.d.ts +0 -6
  1205. package/dist/sdk/models/shared/discounttype.js +0 -13
  1206. package/dist/sdk/models/shared/durationunit.d.ts +0 -8
  1207. package/dist/sdk/models/shared/durationunit.js +0 -15
  1208. package/dist/sdk/models/shared/entrystatus.d.ts +0 -7
  1209. package/dist/sdk/models/shared/entrystatus.js +0 -14
  1210. package/dist/sdk/models/shared/entrytype.d.ts +0 -9
  1211. package/dist/sdk/models/shared/entrytype.js +0 -16
  1212. package/dist/sdk/models/shared/eventsearchresults.d.ts +0 -10
  1213. package/dist/sdk/models/shared/externalmarketplace.d.ts +0 -8
  1214. package/dist/sdk/models/shared/externalmarketplace.js +0 -15
  1215. package/dist/sdk/models/shared/fixedfeequantityschedule.d.ts +0 -7
  1216. package/dist/sdk/models/shared/granularity.d.ts +0 -6
  1217. package/dist/sdk/models/shared/granularity.js +0 -13
  1218. package/dist/sdk/models/shared/grouping.d.ts +0 -8
  1219. package/dist/sdk/models/shared/invoicestatus.d.ts +0 -10
  1220. package/dist/sdk/models/shared/invoicestatus.js +0 -17
  1221. package/dist/sdk/models/shared/lineitem.d.ts +0 -58
  1222. package/dist/sdk/models/shared/lineitem.js +0 -147
  1223. package/dist/sdk/models/shared/matrixconfig1.d.ts +0 -10
  1224. package/dist/sdk/models/shared/modeltype.d.ts +0 -10
  1225. package/dist/sdk/models/shared/modeltype.js +0 -17
  1226. package/dist/sdk/models/shared/newcreditledgerentry.d.ts +0 -44
  1227. package/dist/sdk/models/shared/newtransaction.d.ts +0 -10
  1228. package/dist/sdk/models/shared/packagepriceoverride.d.ts +0 -24
  1229. package/dist/sdk/models/shared/price.d.ts +0 -114
  1230. package/dist/sdk/models/shared/price.js +0 -245
  1231. package/dist/sdk/models/shared/reason.d.ts +0 -9
  1232. package/dist/sdk/models/shared/reason.js +0 -16
  1233. package/dist/sdk/models/shared/sublineitem.d.ts +0 -32
  1234. package/dist/sdk/models/shared/sublineitem1.d.ts +0 -24
  1235. package/dist/sdk/models/shared/subscriptioncancellation.d.ts +0 -12
  1236. package/dist/sdk/models/shared/subscriptionstatus.d.ts +0 -5
  1237. package/dist/sdk/models/shared/subscriptionstatus.js +0 -12
  1238. package/dist/sdk/models/shared/subscriptionusage.d.ts +0 -8
  1239. package/dist/sdk/models/shared/tier7.d.ts +0 -7
  1240. package/dist/sdk/models/shared/tieredbpsconfig1.d.ts +0 -5
  1241. package/dist/sdk/models/shared/tieredbpspriceoverride.d.ts +0 -21
  1242. package/dist/sdk/models/shared/tieredpriceoverride.d.ts +0 -27
  1243. package/dist/sdk/models/shared/transactiontype.d.ts +0 -4
  1244. package/dist/sdk/models/shared/transactiontype.js +0 -11
  1245. package/dist/sdk/models/shared/type.d.ts +0 -7
  1246. package/dist/sdk/models/shared/type.js +0 -14
  1247. package/dist/sdk/models/shared/unitpriceoverride.d.ts +0 -24
  1248. package/dist/sdk/models/shared/usageitem.d.ts +0 -6
  1249. package/dist/sdk/models/shared/validationerrors.d.ts +0 -13
  1250. package/dist/sdk/models/shared/validationerrors.js +0 -59
  1251. package/dist/sdk/models/shared/viewmode.d.ts +0 -7
  1252. package/dist/sdk/models/shared/viewmode.js +0 -14
@@ -91,35 +91,41 @@ var __read = (this && this.__read) || function (o, n) {
91
91
  Object.defineProperty(exports, "__esModule", { value: true });
92
92
  exports.Invoice = void 0;
93
93
  var utils = __importStar(require("../internal/utils"));
94
+ var errors = __importStar(require("./models/errors"));
94
95
  var operations = __importStar(require("./models/operations"));
95
96
  var shared = __importStar(require("./models/shared"));
96
97
  /**
97
- * An [`Invoice`](../guides/concepts#invoice) is a fundamental billing entity, representing the request for payment for a single subscription. This includes a set of line items, which correspond to prices in the subscription's plan and can represent fixed recurring fees or usage-based fees. They are generated at the end of a billing period, or as the result of an action, such as a cancellation.
98
+ * An [`Invoice`](../guides/concepts#invoice) is a fundamental billing entity, representing the request for payment for
99
+ *
100
+ * @remarks
101
+ * a single subscription. This includes a set of line items, which correspond to prices in the subscription's plan and
102
+ * can represent fixed recurring fees or usage-based fees. They are generated at the end of a billing period, or as
103
+ * the result of an action, such as a cancellation.
98
104
  */
99
105
  var Invoice = /** @class */ (function () {
100
106
  function Invoice(sdkConfig) {
101
107
  this.sdkConfiguration = sdkConfig;
102
108
  }
103
109
  /**
104
- * Create invoice line item
110
+ * Create a one-off invoice
105
111
  *
106
112
  * @remarks
107
- * This creates a one-off fixed fee invoice line item on an [Invoice](../guides/concepts#invoice). This can only be done for invoices that are in a `draft` status.
113
+ * This endpoint is used to create a one-off invoice for a customer.
108
114
  */
109
115
  Invoice.prototype.create = function (req, config) {
110
116
  var _a, _b;
111
117
  return __awaiter(this, void 0, void 0, function () {
112
- var baseURL, url, _c, reqBodyHeaders, reqBody, client, headers, httpRes, contentType, res, decodedRes;
118
+ var baseURL, url, _c, reqBodyHeaders, reqBody, client, globalSecurity, properties, headers, httpRes, contentType, res, decodedRes;
113
119
  var _d;
114
120
  return __generator(this, function (_e) {
115
121
  switch (_e.label) {
116
122
  case 0:
117
123
  if (!(req instanceof utils.SpeakeasyBase)) {
118
- req = new shared.NewInvoiceLineItem(req);
124
+ req = new shared.CreateOneOffInvoiceParams(req);
119
125
  }
120
126
  baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
121
- url = baseURL.replace(/\/$/, "") + "/invoice_line_items";
122
- _c = __read([{}, {}], 2), reqBodyHeaders = _c[0], reqBody = _c[1];
127
+ url = baseURL.replace(/\/$/, "") + "/invoices";
128
+ _c = __read([{}, null], 2), reqBodyHeaders = _c[0], reqBody = _c[1];
123
129
  try {
124
130
  _d = __read(utils.serializeRequestBody(req, "request", "json"), 2), reqBodyHeaders = _d[0], reqBody = _d[1];
125
131
  }
@@ -128,12 +134,151 @@ var Invoice = /** @class */ (function () {
128
134
  throw new Error("Error serializing request body, cause: ".concat(e.message));
129
135
  }
130
136
  }
131
- client = this.sdkConfiguration.securityClient || this.sdkConfiguration.defaultClient;
132
- headers = __assign(__assign({}, reqBodyHeaders), config === null || config === void 0 ? void 0 : config.headers);
137
+ client = this.sdkConfiguration.defaultClient;
138
+ globalSecurity = this.sdkConfiguration.security;
139
+ if (!(typeof globalSecurity === "function")) return [3 /*break*/, 2];
140
+ return [4 /*yield*/, globalSecurity()];
141
+ case 1:
142
+ globalSecurity = _e.sent();
143
+ _e.label = 2;
144
+ case 2:
145
+ if (!(globalSecurity instanceof utils.SpeakeasyBase)) {
146
+ globalSecurity = new shared.Security(globalSecurity);
147
+ }
148
+ properties = utils.parseSecurityProperties(globalSecurity);
149
+ headers = __assign(__assign(__assign({}, reqBodyHeaders), config === null || config === void 0 ? void 0 : config.headers), properties.headers);
133
150
  headers["Accept"] = "application/json";
134
- headers["user-agent"] = "speakeasy-sdk/".concat(this.sdkConfiguration.language, " ").concat(this.sdkConfiguration.sdkVersion, " ").concat(this.sdkConfiguration.genVersion, " ").concat(this.sdkConfiguration.openapiDocVersion);
151
+ headers["user-agent"] = this.sdkConfiguration.userAgent;
135
152
  return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url, method: "post", headers: headers, responseType: "arraybuffer", data: reqBody }, config))];
153
+ case 3:
154
+ httpRes = _e.sent();
155
+ contentType = (_b = (_a = httpRes === null || httpRes === void 0 ? void 0 : httpRes.headers) === null || _a === void 0 ? void 0 : _a["content-type"]) !== null && _b !== void 0 ? _b : "";
156
+ if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
157
+ throw new Error("status code not found in response: ".concat(httpRes));
158
+ }
159
+ res = new operations.CreateInvoiceResponse({
160
+ statusCode: httpRes.status,
161
+ contentType: contentType,
162
+ rawResponse: httpRes,
163
+ });
164
+ decodedRes = new TextDecoder().decode(httpRes === null || httpRes === void 0 ? void 0 : httpRes.data);
165
+ switch (true) {
166
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 201:
167
+ if (utils.matchContentType(contentType, "application/json")) {
168
+ res.invoice = utils.objectToClass(JSON.parse(decodedRes), shared.Invoice);
169
+ }
170
+ else {
171
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
172
+ }
173
+ break;
174
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 400:
175
+ if (utils.matchContentType(contentType, "application/json")) {
176
+ res.fourHundredError = JSON.parse(decodedRes);
177
+ }
178
+ else {
179
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
180
+ }
181
+ break;
182
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 401:
183
+ if (utils.matchContentType(contentType, "application/json")) {
184
+ res.fourHundredAndOneError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndOneError);
185
+ }
186
+ else {
187
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
188
+ }
189
+ break;
190
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 404:
191
+ if (utils.matchContentType(contentType, "application/json")) {
192
+ res.fourHundredAndFourError = JSON.parse(decodedRes);
193
+ }
194
+ else {
195
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
196
+ }
197
+ break;
198
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 409:
199
+ if (utils.matchContentType(contentType, "application/json")) {
200
+ res.fourHundredAndNineError = JSON.parse(decodedRes);
201
+ }
202
+ else {
203
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
204
+ }
205
+ break;
206
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 413:
207
+ if (utils.matchContentType(contentType, "application/json")) {
208
+ res.fourHundredAndThirteenError = JSON.parse(decodedRes);
209
+ }
210
+ else {
211
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
212
+ }
213
+ break;
214
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 429:
215
+ if (utils.matchContentType(contentType, "application/json")) {
216
+ res.fourHundredAndTwentyNineError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndTwentyNineError);
217
+ }
218
+ else {
219
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
220
+ }
221
+ break;
222
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 500:
223
+ if (utils.matchContentType(contentType, "application/json")) {
224
+ res.fiveHundredError = utils.objectToClass(JSON.parse(decodedRes), shared.FiveHundredError);
225
+ }
226
+ else {
227
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
228
+ }
229
+ break;
230
+ }
231
+ return [2 /*return*/, res];
232
+ }
233
+ });
234
+ });
235
+ };
236
+ /**
237
+ * Create invoice line item
238
+ *
239
+ * @remarks
240
+ * This creates a one-off fixed fee invoice line item on an Invoice.
241
+ * This can only be done for invoices that are in a `draft` status.
242
+ */
243
+ Invoice.prototype.createLineItem = function (req, config) {
244
+ var _a, _b;
245
+ return __awaiter(this, void 0, void 0, function () {
246
+ var baseURL, url, _c, reqBodyHeaders, reqBody, client, globalSecurity, properties, headers, httpRes, contentType, res, decodedRes;
247
+ var _d;
248
+ return __generator(this, function (_e) {
249
+ switch (_e.label) {
250
+ case 0:
251
+ if (!(req instanceof utils.SpeakeasyBase)) {
252
+ req = new shared.CreateInvoiceLineItemParams(req);
253
+ }
254
+ baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
255
+ url = baseURL.replace(/\/$/, "") + "/invoice_line_items";
256
+ _c = __read([{}, null], 2), reqBodyHeaders = _c[0], reqBody = _c[1];
257
+ try {
258
+ _d = __read(utils.serializeRequestBody(req, "request", "json"), 2), reqBodyHeaders = _d[0], reqBody = _d[1];
259
+ }
260
+ catch (e) {
261
+ if (e instanceof Error) {
262
+ throw new Error("Error serializing request body, cause: ".concat(e.message));
263
+ }
264
+ }
265
+ client = this.sdkConfiguration.defaultClient;
266
+ globalSecurity = this.sdkConfiguration.security;
267
+ if (!(typeof globalSecurity === "function")) return [3 /*break*/, 2];
268
+ return [4 /*yield*/, globalSecurity()];
136
269
  case 1:
270
+ globalSecurity = _e.sent();
271
+ _e.label = 2;
272
+ case 2:
273
+ if (!(globalSecurity instanceof utils.SpeakeasyBase)) {
274
+ globalSecurity = new shared.Security(globalSecurity);
275
+ }
276
+ properties = utils.parseSecurityProperties(globalSecurity);
277
+ headers = __assign(__assign(__assign({}, reqBodyHeaders), config === null || config === void 0 ? void 0 : config.headers), properties.headers);
278
+ headers["Accept"] = "application/json";
279
+ headers["user-agent"] = this.sdkConfiguration.userAgent;
280
+ return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url, method: "post", headers: headers, responseType: "arraybuffer", data: reqBody }, config))];
281
+ case 3:
137
282
  httpRes = _e.sent();
138
283
  contentType = (_b = (_a = httpRes === null || httpRes === void 0 ? void 0 : httpRes.headers) === null || _a === void 0 ? void 0 : _a["content-type"]) !== null && _b !== void 0 ? _b : "";
139
284
  if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
@@ -150,6 +295,65 @@ var Invoice = /** @class */ (function () {
150
295
  if (utils.matchContentType(contentType, "application/json")) {
151
296
  res.invoiceLineItem = utils.objectToClass(JSON.parse(decodedRes), shared.InvoiceLineItem);
152
297
  }
298
+ else {
299
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
300
+ }
301
+ break;
302
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 400:
303
+ if (utils.matchContentType(contentType, "application/json")) {
304
+ res.fourHundredError = JSON.parse(decodedRes);
305
+ }
306
+ else {
307
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
308
+ }
309
+ break;
310
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 401:
311
+ if (utils.matchContentType(contentType, "application/json")) {
312
+ res.fourHundredAndOneError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndOneError);
313
+ }
314
+ else {
315
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
316
+ }
317
+ break;
318
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 404:
319
+ if (utils.matchContentType(contentType, "application/json")) {
320
+ res.fourHundredAndFourError = JSON.parse(decodedRes);
321
+ }
322
+ else {
323
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
324
+ }
325
+ break;
326
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 409:
327
+ if (utils.matchContentType(contentType, "application/json")) {
328
+ res.fourHundredAndNineError = JSON.parse(decodedRes);
329
+ }
330
+ else {
331
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
332
+ }
333
+ break;
334
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 413:
335
+ if (utils.matchContentType(contentType, "application/json")) {
336
+ res.fourHundredAndThirteenError = JSON.parse(decodedRes);
337
+ }
338
+ else {
339
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
340
+ }
341
+ break;
342
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 429:
343
+ if (utils.matchContentType(contentType, "application/json")) {
344
+ res.fourHundredAndTwentyNineError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndTwentyNineError);
345
+ }
346
+ else {
347
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
348
+ }
349
+ break;
350
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 500:
351
+ if (utils.matchContentType(contentType, "application/json")) {
352
+ res.fiveHundredError = utils.objectToClass(JSON.parse(decodedRes), shared.FiveHundredError);
353
+ }
354
+ else {
355
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
356
+ }
153
357
  break;
154
358
  }
155
359
  return [2 /*return*/, res];
@@ -166,7 +370,7 @@ var Invoice = /** @class */ (function () {
166
370
  Invoice.prototype.fetch = function (req, config) {
167
371
  var _a, _b;
168
372
  return __awaiter(this, void 0, void 0, function () {
169
- var baseURL, url, client, headers, httpRes, contentType, res, decodedRes;
373
+ var baseURL, url, client, globalSecurity, properties, headers, httpRes, contentType, res, decodedRes;
170
374
  return __generator(this, function (_c) {
171
375
  switch (_c.label) {
172
376
  case 0:
@@ -175,12 +379,23 @@ var Invoice = /** @class */ (function () {
175
379
  }
176
380
  baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
177
381
  url = utils.generateURL(baseURL, "/invoices/{invoice_id}", req);
178
- client = this.sdkConfiguration.securityClient || this.sdkConfiguration.defaultClient;
179
- headers = __assign({}, config === null || config === void 0 ? void 0 : config.headers);
382
+ client = this.sdkConfiguration.defaultClient;
383
+ globalSecurity = this.sdkConfiguration.security;
384
+ if (!(typeof globalSecurity === "function")) return [3 /*break*/, 2];
385
+ return [4 /*yield*/, globalSecurity()];
386
+ case 1:
387
+ globalSecurity = _c.sent();
388
+ _c.label = 2;
389
+ case 2:
390
+ if (!(globalSecurity instanceof utils.SpeakeasyBase)) {
391
+ globalSecurity = new shared.Security(globalSecurity);
392
+ }
393
+ properties = utils.parseSecurityProperties(globalSecurity);
394
+ headers = __assign(__assign({}, config === null || config === void 0 ? void 0 : config.headers), properties.headers);
180
395
  headers["Accept"] = "application/json";
181
- headers["user-agent"] = "speakeasy-sdk/".concat(this.sdkConfiguration.language, " ").concat(this.sdkConfiguration.sdkVersion, " ").concat(this.sdkConfiguration.genVersion, " ").concat(this.sdkConfiguration.openapiDocVersion);
396
+ headers["user-agent"] = this.sdkConfiguration.userAgent;
182
397
  return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url, method: "get", headers: headers, responseType: "arraybuffer" }, config))];
183
- case 1:
398
+ case 3:
184
399
  httpRes = _c.sent();
185
400
  contentType = (_b = (_a = httpRes === null || httpRes === void 0 ? void 0 : httpRes.headers) === null || _a === void 0 ? void 0 : _a["content-type"]) !== null && _b !== void 0 ? _b : "";
186
401
  if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
@@ -197,6 +412,65 @@ var Invoice = /** @class */ (function () {
197
412
  if (utils.matchContentType(contentType, "application/json")) {
198
413
  res.invoice = utils.objectToClass(JSON.parse(decodedRes), shared.Invoice);
199
414
  }
415
+ else {
416
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
417
+ }
418
+ break;
419
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 400:
420
+ if (utils.matchContentType(contentType, "application/json")) {
421
+ res.fourHundredError = JSON.parse(decodedRes);
422
+ }
423
+ else {
424
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
425
+ }
426
+ break;
427
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 401:
428
+ if (utils.matchContentType(contentType, "application/json")) {
429
+ res.fourHundredAndOneError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndOneError);
430
+ }
431
+ else {
432
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
433
+ }
434
+ break;
435
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 404:
436
+ if (utils.matchContentType(contentType, "application/json")) {
437
+ res.fourHundredAndFourError = JSON.parse(decodedRes);
438
+ }
439
+ else {
440
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
441
+ }
442
+ break;
443
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 409:
444
+ if (utils.matchContentType(contentType, "application/json")) {
445
+ res.fourHundredAndNineError = JSON.parse(decodedRes);
446
+ }
447
+ else {
448
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
449
+ }
450
+ break;
451
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 413:
452
+ if (utils.matchContentType(contentType, "application/json")) {
453
+ res.fourHundredAndThirteenError = JSON.parse(decodedRes);
454
+ }
455
+ else {
456
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
457
+ }
458
+ break;
459
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 429:
460
+ if (utils.matchContentType(contentType, "application/json")) {
461
+ res.fourHundredAndTwentyNineError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndTwentyNineError);
462
+ }
463
+ else {
464
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
465
+ }
466
+ break;
467
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 500:
468
+ if (utils.matchContentType(contentType, "application/json")) {
469
+ res.fiveHundredError = utils.objectToClass(JSON.parse(decodedRes), shared.FiveHundredError);
470
+ }
471
+ else {
472
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
473
+ }
200
474
  break;
201
475
  }
202
476
  return [2 /*return*/, res];
@@ -208,12 +482,13 @@ var Invoice = /** @class */ (function () {
208
482
  * Fetch upcoming invoice
209
483
  *
210
484
  * @remarks
211
- * This endpoint can be used to fetch the upcoming [invoice](../guides/concepts#invoice) for the current billing period given a subscription.
485
+ * This endpoint can be used to fetch the upcoming [invoice](../guides/concepts#invoice) for the current billing
486
+ * period given a subscription.
212
487
  */
213
488
  Invoice.prototype.fetchUpcoming = function (req, config) {
214
489
  var _a, _b;
215
490
  return __awaiter(this, void 0, void 0, function () {
216
- var baseURL, url, client, headers, queryParams, httpRes, contentType, res, decodedRes;
491
+ var baseURL, url, client, globalSecurity, properties, headers, queryParams, httpRes, contentType, res, decodedRes;
217
492
  return __generator(this, function (_c) {
218
493
  switch (_c.label) {
219
494
  case 0:
@@ -222,13 +497,24 @@ var Invoice = /** @class */ (function () {
222
497
  }
223
498
  baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
224
499
  url = baseURL.replace(/\/$/, "") + "/invoices/upcoming";
225
- client = this.sdkConfiguration.securityClient || this.sdkConfiguration.defaultClient;
226
- headers = __assign({}, config === null || config === void 0 ? void 0 : config.headers);
500
+ client = this.sdkConfiguration.defaultClient;
501
+ globalSecurity = this.sdkConfiguration.security;
502
+ if (!(typeof globalSecurity === "function")) return [3 /*break*/, 2];
503
+ return [4 /*yield*/, globalSecurity()];
504
+ case 1:
505
+ globalSecurity = _c.sent();
506
+ _c.label = 2;
507
+ case 2:
508
+ if (!(globalSecurity instanceof utils.SpeakeasyBase)) {
509
+ globalSecurity = new shared.Security(globalSecurity);
510
+ }
511
+ properties = utils.parseSecurityProperties(globalSecurity);
512
+ headers = __assign(__assign({}, config === null || config === void 0 ? void 0 : config.headers), properties.headers);
227
513
  queryParams = utils.serializeQueryParams(req);
228
514
  headers["Accept"] = "application/json";
229
- headers["user-agent"] = "speakeasy-sdk/".concat(this.sdkConfiguration.language, " ").concat(this.sdkConfiguration.sdkVersion, " ").concat(this.sdkConfiguration.genVersion, " ").concat(this.sdkConfiguration.openapiDocVersion);
515
+ headers["user-agent"] = this.sdkConfiguration.userAgent;
230
516
  return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url + queryParams, method: "get", headers: headers, responseType: "arraybuffer" }, config))];
231
- case 1:
517
+ case 3:
232
518
  httpRes = _c.sent();
233
519
  contentType = (_b = (_a = httpRes === null || httpRes === void 0 ? void 0 : httpRes.headers) === null || _a === void 0 ? void 0 : _a["content-type"]) !== null && _b !== void 0 ? _b : "";
234
520
  if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
@@ -245,6 +531,65 @@ var Invoice = /** @class */ (function () {
245
531
  if (utils.matchContentType(contentType, "application/json")) {
246
532
  res.upcomingInvoice = utils.objectToClass(JSON.parse(decodedRes), shared.UpcomingInvoice);
247
533
  }
534
+ else {
535
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
536
+ }
537
+ break;
538
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 400:
539
+ if (utils.matchContentType(contentType, "application/json")) {
540
+ res.fourHundredError = JSON.parse(decodedRes);
541
+ }
542
+ else {
543
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
544
+ }
545
+ break;
546
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 401:
547
+ if (utils.matchContentType(contentType, "application/json")) {
548
+ res.fourHundredAndOneError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndOneError);
549
+ }
550
+ else {
551
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
552
+ }
553
+ break;
554
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 404:
555
+ if (utils.matchContentType(contentType, "application/json")) {
556
+ res.fourHundredAndFourError = JSON.parse(decodedRes);
557
+ }
558
+ else {
559
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
560
+ }
561
+ break;
562
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 409:
563
+ if (utils.matchContentType(contentType, "application/json")) {
564
+ res.fourHundredAndNineError = JSON.parse(decodedRes);
565
+ }
566
+ else {
567
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
568
+ }
569
+ break;
570
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 413:
571
+ if (utils.matchContentType(contentType, "application/json")) {
572
+ res.fourHundredAndThirteenError = JSON.parse(decodedRes);
573
+ }
574
+ else {
575
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
576
+ }
577
+ break;
578
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 429:
579
+ if (utils.matchContentType(contentType, "application/json")) {
580
+ res.fourHundredAndTwentyNineError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndTwentyNineError);
581
+ }
582
+ else {
583
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
584
+ }
585
+ break;
586
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 500:
587
+ if (utils.matchContentType(contentType, "application/json")) {
588
+ res.fiveHundredError = utils.objectToClass(JSON.parse(decodedRes), shared.FiveHundredError);
589
+ }
590
+ else {
591
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
592
+ }
248
593
  break;
249
594
  }
250
595
  return [2 /*return*/, res];
@@ -253,16 +598,18 @@ var Invoice = /** @class */ (function () {
253
598
  });
254
599
  };
255
600
  /**
256
- * Issue an invoice
601
+ * Issue invoice
257
602
  *
258
603
  * @remarks
259
- * This endpoint allows an eligible invoice to be issued manually. This is only possible with invoices where `status` is `draft`, `will_auto_issue` is true, and an `eligible_to_issue_at` is a time in the past.
260
- * Issuing an invoice could possibly trigger side effects, some of which could be customer-visible (e.g. sending emails, auto-collecting payment, syncing the invoice to external providers, etc).
604
+ * This endpoint allows an eligible invoice to be issued manually. This is only possible with invoices where status is `draft`,
605
+ * `will_auto_issue` is true, and an `eligible_to_issue_at` is a time in the past. Issuing an invoice could possibly trigger
606
+ * side effects, some of which could be customer-visible (e.g. sending emails, auto-collecting payment,
607
+ * syncing the invoice to external providers, etc).
261
608
  */
262
609
  Invoice.prototype.issue = function (req, config) {
263
610
  var _a, _b;
264
611
  return __awaiter(this, void 0, void 0, function () {
265
- var baseURL, url, client, headers, httpRes, contentType, res, decodedRes;
612
+ var baseURL, url, client, globalSecurity, properties, headers, httpRes, contentType, res, decodedRes;
266
613
  return __generator(this, function (_c) {
267
614
  switch (_c.label) {
268
615
  case 0:
@@ -271,12 +618,23 @@ var Invoice = /** @class */ (function () {
271
618
  }
272
619
  baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
273
620
  url = utils.generateURL(baseURL, "/invoices/{invoice_id}/issue", req);
274
- client = this.sdkConfiguration.securityClient || this.sdkConfiguration.defaultClient;
275
- headers = __assign({}, config === null || config === void 0 ? void 0 : config.headers);
276
- headers["Accept"] = "application/json;q=1, application/json;q=0";
277
- headers["user-agent"] = "speakeasy-sdk/".concat(this.sdkConfiguration.language, " ").concat(this.sdkConfiguration.sdkVersion, " ").concat(this.sdkConfiguration.genVersion, " ").concat(this.sdkConfiguration.openapiDocVersion);
278
- return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url, method: "post", headers: headers, responseType: "arraybuffer" }, config))];
621
+ client = this.sdkConfiguration.defaultClient;
622
+ globalSecurity = this.sdkConfiguration.security;
623
+ if (!(typeof globalSecurity === "function")) return [3 /*break*/, 2];
624
+ return [4 /*yield*/, globalSecurity()];
279
625
  case 1:
626
+ globalSecurity = _c.sent();
627
+ _c.label = 2;
628
+ case 2:
629
+ if (!(globalSecurity instanceof utils.SpeakeasyBase)) {
630
+ globalSecurity = new shared.Security(globalSecurity);
631
+ }
632
+ properties = utils.parseSecurityProperties(globalSecurity);
633
+ headers = __assign(__assign({}, config === null || config === void 0 ? void 0 : config.headers), properties.headers);
634
+ headers["Accept"] = "application/json";
635
+ headers["user-agent"] = this.sdkConfiguration.userAgent;
636
+ return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url, method: "post", headers: headers, responseType: "arraybuffer" }, config))];
637
+ case 3:
280
638
  httpRes = _c.sent();
281
639
  contentType = (_b = (_a = httpRes === null || httpRes === void 0 ? void 0 : httpRes.headers) === null || _a === void 0 ? void 0 : _a["content-type"]) !== null && _b !== void 0 ? _b : "";
282
640
  if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
@@ -293,10 +651,64 @@ var Invoice = /** @class */ (function () {
293
651
  if (utils.matchContentType(contentType, "application/json")) {
294
652
  res.invoice = utils.objectToClass(JSON.parse(decodedRes), shared.Invoice);
295
653
  }
654
+ else {
655
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
656
+ }
296
657
  break;
297
658
  case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 400:
298
659
  if (utils.matchContentType(contentType, "application/json")) {
299
- res.requestValidationError = utils.objectToClass(JSON.parse(decodedRes), shared.RequestValidationError);
660
+ res.fourHundredError = JSON.parse(decodedRes);
661
+ }
662
+ else {
663
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
664
+ }
665
+ break;
666
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 401:
667
+ if (utils.matchContentType(contentType, "application/json")) {
668
+ res.fourHundredAndOneError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndOneError);
669
+ }
670
+ else {
671
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
672
+ }
673
+ break;
674
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 404:
675
+ if (utils.matchContentType(contentType, "application/json")) {
676
+ res.fourHundredAndFourError = JSON.parse(decodedRes);
677
+ }
678
+ else {
679
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
680
+ }
681
+ break;
682
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 409:
683
+ if (utils.matchContentType(contentType, "application/json")) {
684
+ res.fourHundredAndNineError = JSON.parse(decodedRes);
685
+ }
686
+ else {
687
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
688
+ }
689
+ break;
690
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 413:
691
+ if (utils.matchContentType(contentType, "application/json")) {
692
+ res.fourHundredAndThirteenError = JSON.parse(decodedRes);
693
+ }
694
+ else {
695
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
696
+ }
697
+ break;
698
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 429:
699
+ if (utils.matchContentType(contentType, "application/json")) {
700
+ res.fourHundredAndTwentyNineError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndTwentyNineError);
701
+ }
702
+ else {
703
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
704
+ }
705
+ break;
706
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 500:
707
+ if (utils.matchContentType(contentType, "application/json")) {
708
+ res.fiveHundredError = utils.objectToClass(JSON.parse(decodedRes), shared.FiveHundredError);
709
+ }
710
+ else {
711
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
300
712
  }
301
713
  break;
302
714
  }
@@ -311,14 +723,16 @@ var Invoice = /** @class */ (function () {
311
723
  * @remarks
312
724
  * This endpoint returns a list of all [`Invoice`](../guides/concepts#invoice)s for an account in a list format.
313
725
  *
314
- * The list of invoices is ordered starting from the most recently issued invoice date. The response also includes [`pagination_metadata`](../reference/pagination), which lets the caller retrieve the next page of results if they exist.
726
+ * The list of invoices is ordered starting from the most recently issued invoice date. The response also includes
727
+ * [`pagination_metadata`](../reference/pagination), which lets the caller retrieve the next page of results if they
728
+ * exist.
315
729
  *
316
730
  * By default, this only returns invoices that are `issued`, `paid`, or `synced`.
317
731
  */
318
732
  Invoice.prototype.list = function (req, config) {
319
733
  var _a, _b;
320
734
  return __awaiter(this, void 0, void 0, function () {
321
- var baseURL, url, client, headers, queryParams, httpRes, contentType, res, decodedRes;
735
+ var baseURL, url, client, globalSecurity, properties, headers, queryParams, httpRes, contentType, res, decodedRes;
322
736
  return __generator(this, function (_c) {
323
737
  switch (_c.label) {
324
738
  case 0:
@@ -327,13 +741,24 @@ var Invoice = /** @class */ (function () {
327
741
  }
328
742
  baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
329
743
  url = baseURL.replace(/\/$/, "") + "/invoices";
330
- client = this.sdkConfiguration.securityClient || this.sdkConfiguration.defaultClient;
331
- headers = __assign({}, config === null || config === void 0 ? void 0 : config.headers);
744
+ client = this.sdkConfiguration.defaultClient;
745
+ globalSecurity = this.sdkConfiguration.security;
746
+ if (!(typeof globalSecurity === "function")) return [3 /*break*/, 2];
747
+ return [4 /*yield*/, globalSecurity()];
748
+ case 1:
749
+ globalSecurity = _c.sent();
750
+ _c.label = 2;
751
+ case 2:
752
+ if (!(globalSecurity instanceof utils.SpeakeasyBase)) {
753
+ globalSecurity = new shared.Security(globalSecurity);
754
+ }
755
+ properties = utils.parseSecurityProperties(globalSecurity);
756
+ headers = __assign(__assign({}, config === null || config === void 0 ? void 0 : config.headers), properties.headers);
332
757
  queryParams = utils.serializeQueryParams(req);
333
758
  headers["Accept"] = "application/json";
334
- headers["user-agent"] = "speakeasy-sdk/".concat(this.sdkConfiguration.language, " ").concat(this.sdkConfiguration.sdkVersion, " ").concat(this.sdkConfiguration.genVersion, " ").concat(this.sdkConfiguration.openapiDocVersion);
759
+ headers["user-agent"] = this.sdkConfiguration.userAgent;
335
760
  return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url + queryParams, method: "get", headers: headers, responseType: "arraybuffer" }, config))];
336
- case 1:
761
+ case 3:
337
762
  httpRes = _c.sent();
338
763
  contentType = (_b = (_a = httpRes === null || httpRes === void 0 ? void 0 : httpRes.headers) === null || _a === void 0 ? void 0 : _a["content-type"]) !== null && _b !== void 0 ? _b : "";
339
764
  if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
@@ -350,6 +775,193 @@ var Invoice = /** @class */ (function () {
350
775
  if (utils.matchContentType(contentType, "application/json")) {
351
776
  res.invoices = utils.objectToClass(JSON.parse(decodedRes), shared.Invoices);
352
777
  }
778
+ else {
779
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
780
+ }
781
+ break;
782
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 400:
783
+ if (utils.matchContentType(contentType, "application/json")) {
784
+ res.fourHundredError = JSON.parse(decodedRes);
785
+ }
786
+ else {
787
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
788
+ }
789
+ break;
790
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 401:
791
+ if (utils.matchContentType(contentType, "application/json")) {
792
+ res.fourHundredAndOneError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndOneError);
793
+ }
794
+ else {
795
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
796
+ }
797
+ break;
798
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 404:
799
+ if (utils.matchContentType(contentType, "application/json")) {
800
+ res.fourHundredAndFourError = JSON.parse(decodedRes);
801
+ }
802
+ else {
803
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
804
+ }
805
+ break;
806
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 409:
807
+ if (utils.matchContentType(contentType, "application/json")) {
808
+ res.fourHundredAndNineError = JSON.parse(decodedRes);
809
+ }
810
+ else {
811
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
812
+ }
813
+ break;
814
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 413:
815
+ if (utils.matchContentType(contentType, "application/json")) {
816
+ res.fourHundredAndThirteenError = JSON.parse(decodedRes);
817
+ }
818
+ else {
819
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
820
+ }
821
+ break;
822
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 429:
823
+ if (utils.matchContentType(contentType, "application/json")) {
824
+ res.fourHundredAndTwentyNineError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndTwentyNineError);
825
+ }
826
+ else {
827
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
828
+ }
829
+ break;
830
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 500:
831
+ if (utils.matchContentType(contentType, "application/json")) {
832
+ res.fiveHundredError = utils.objectToClass(JSON.parse(decodedRes), shared.FiveHundredError);
833
+ }
834
+ else {
835
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
836
+ }
837
+ break;
838
+ }
839
+ return [2 /*return*/, res];
840
+ }
841
+ });
842
+ });
843
+ };
844
+ /**
845
+ * Mark invoice as paid
846
+ *
847
+ * @remarks
848
+ * This endpoint allows an invoice's status to be set the `paid` status. This can only be done to invoices that are in
849
+ * the `issued` status.
850
+ */
851
+ Invoice.prototype.markInvoiceAsPaid = function (req, config) {
852
+ var _a, _b;
853
+ return __awaiter(this, void 0, void 0, function () {
854
+ var baseURL, url, _c, reqBodyHeaders, reqBody, client, globalSecurity, properties, headers, httpRes, contentType, res, decodedRes;
855
+ var _d;
856
+ return __generator(this, function (_e) {
857
+ switch (_e.label) {
858
+ case 0:
859
+ if (!(req instanceof utils.SpeakeasyBase)) {
860
+ req = new operations.MarkInvoiceAsPaidRequest(req);
861
+ }
862
+ baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
863
+ url = utils.generateURL(baseURL, "/invoices/{invoice_id}/mark_paid", req);
864
+ _c = __read([{}, null], 2), reqBodyHeaders = _c[0], reqBody = _c[1];
865
+ try {
866
+ _d = __read(utils.serializeRequestBody(req, "markAsPaidRequestParams", "json"), 2), reqBodyHeaders = _d[0], reqBody = _d[1];
867
+ }
868
+ catch (e) {
869
+ if (e instanceof Error) {
870
+ throw new Error("Error serializing request body, cause: ".concat(e.message));
871
+ }
872
+ }
873
+ client = this.sdkConfiguration.defaultClient;
874
+ globalSecurity = this.sdkConfiguration.security;
875
+ if (!(typeof globalSecurity === "function")) return [3 /*break*/, 2];
876
+ return [4 /*yield*/, globalSecurity()];
877
+ case 1:
878
+ globalSecurity = _e.sent();
879
+ _e.label = 2;
880
+ case 2:
881
+ if (!(globalSecurity instanceof utils.SpeakeasyBase)) {
882
+ globalSecurity = new shared.Security(globalSecurity);
883
+ }
884
+ properties = utils.parseSecurityProperties(globalSecurity);
885
+ headers = __assign(__assign(__assign({}, reqBodyHeaders), config === null || config === void 0 ? void 0 : config.headers), properties.headers);
886
+ headers["Accept"] = "application/json";
887
+ headers["user-agent"] = this.sdkConfiguration.userAgent;
888
+ return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url, method: "post", headers: headers, responseType: "arraybuffer", data: reqBody }, config))];
889
+ case 3:
890
+ httpRes = _e.sent();
891
+ contentType = (_b = (_a = httpRes === null || httpRes === void 0 ? void 0 : httpRes.headers) === null || _a === void 0 ? void 0 : _a["content-type"]) !== null && _b !== void 0 ? _b : "";
892
+ if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
893
+ throw new Error("status code not found in response: ".concat(httpRes));
894
+ }
895
+ res = new operations.MarkInvoiceAsPaidResponse({
896
+ statusCode: httpRes.status,
897
+ contentType: contentType,
898
+ rawResponse: httpRes,
899
+ });
900
+ decodedRes = new TextDecoder().decode(httpRes === null || httpRes === void 0 ? void 0 : httpRes.data);
901
+ switch (true) {
902
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
903
+ if (utils.matchContentType(contentType, "application/json")) {
904
+ res.invoice = utils.objectToClass(JSON.parse(decodedRes), shared.Invoice);
905
+ }
906
+ else {
907
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
908
+ }
909
+ break;
910
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 400:
911
+ if (utils.matchContentType(contentType, "application/json")) {
912
+ res.fourHundredError = JSON.parse(decodedRes);
913
+ }
914
+ else {
915
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
916
+ }
917
+ break;
918
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 401:
919
+ if (utils.matchContentType(contentType, "application/json")) {
920
+ res.fourHundredAndOneError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndOneError);
921
+ }
922
+ else {
923
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
924
+ }
925
+ break;
926
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 404:
927
+ if (utils.matchContentType(contentType, "application/json")) {
928
+ res.fourHundredAndFourError = JSON.parse(decodedRes);
929
+ }
930
+ else {
931
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
932
+ }
933
+ break;
934
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 409:
935
+ if (utils.matchContentType(contentType, "application/json")) {
936
+ res.fourHundredAndNineError = JSON.parse(decodedRes);
937
+ }
938
+ else {
939
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
940
+ }
941
+ break;
942
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 413:
943
+ if (utils.matchContentType(contentType, "application/json")) {
944
+ res.fourHundredAndThirteenError = JSON.parse(decodedRes);
945
+ }
946
+ else {
947
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
948
+ }
949
+ break;
950
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 429:
951
+ if (utils.matchContentType(contentType, "application/json")) {
952
+ res.fourHundredAndTwentyNineError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndTwentyNineError);
953
+ }
954
+ else {
955
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
956
+ }
957
+ break;
958
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 500:
959
+ if (utils.matchContentType(contentType, "application/json")) {
960
+ res.fiveHundredError = utils.objectToClass(JSON.parse(decodedRes), shared.FiveHundredError);
961
+ }
962
+ else {
963
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
964
+ }
353
965
  break;
354
966
  }
355
967
  return [2 /*return*/, res];
@@ -361,14 +973,17 @@ var Invoice = /** @class */ (function () {
361
973
  * Void invoice
362
974
  *
363
975
  * @remarks
364
- * This endpoint allows an invoice's status to be set the `void` status. This can only be done to invoices that are in the `issued` status.
976
+ * This endpoint allows an invoice's status to be set the `void` status. This can only be done to invoices that are in
977
+ * the `issued` status.
365
978
  *
366
- * If the associated invoice has used the customer balance to change the amount due, the customer balance operation will be reverted. For example, if the invoice used $10 of customer balance, that amount will be added back to the customer balance upon voiding.
979
+ * If the associated invoice has used the customer balance to change the amount due, the customer balance operation
980
+ * will be reverted. For example, if the invoice used $10 of customer balance, that amount will be added back to the
981
+ * customer balance upon voiding.
367
982
  */
368
983
  Invoice.prototype.void = function (req, config) {
369
984
  var _a, _b;
370
985
  return __awaiter(this, void 0, void 0, function () {
371
- var baseURL, url, client, headers, httpRes, contentType, res, decodedRes;
986
+ var baseURL, url, client, globalSecurity, properties, headers, httpRes, contentType, res, decodedRes;
372
987
  return __generator(this, function (_c) {
373
988
  switch (_c.label) {
374
989
  case 0:
@@ -377,12 +992,23 @@ var Invoice = /** @class */ (function () {
377
992
  }
378
993
  baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
379
994
  url = utils.generateURL(baseURL, "/invoices/{invoice_id}/void", req);
380
- client = this.sdkConfiguration.securityClient || this.sdkConfiguration.defaultClient;
381
- headers = __assign({}, config === null || config === void 0 ? void 0 : config.headers);
382
- headers["Accept"] = "application/json;q=1, application/json;q=0";
383
- headers["user-agent"] = "speakeasy-sdk/".concat(this.sdkConfiguration.language, " ").concat(this.sdkConfiguration.sdkVersion, " ").concat(this.sdkConfiguration.genVersion, " ").concat(this.sdkConfiguration.openapiDocVersion);
384
- return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url, method: "post", headers: headers, responseType: "arraybuffer" }, config))];
995
+ client = this.sdkConfiguration.defaultClient;
996
+ globalSecurity = this.sdkConfiguration.security;
997
+ if (!(typeof globalSecurity === "function")) return [3 /*break*/, 2];
998
+ return [4 /*yield*/, globalSecurity()];
385
999
  case 1:
1000
+ globalSecurity = _c.sent();
1001
+ _c.label = 2;
1002
+ case 2:
1003
+ if (!(globalSecurity instanceof utils.SpeakeasyBase)) {
1004
+ globalSecurity = new shared.Security(globalSecurity);
1005
+ }
1006
+ properties = utils.parseSecurityProperties(globalSecurity);
1007
+ headers = __assign(__assign({}, config === null || config === void 0 ? void 0 : config.headers), properties.headers);
1008
+ headers["Accept"] = "application/json";
1009
+ headers["user-agent"] = this.sdkConfiguration.userAgent;
1010
+ return [4 /*yield*/, client.request(__assign({ validateStatus: function () { return true; }, url: url, method: "post", headers: headers, responseType: "arraybuffer" }, config))];
1011
+ case 3:
386
1012
  httpRes = _c.sent();
387
1013
  contentType = (_b = (_a = httpRes === null || httpRes === void 0 ? void 0 : httpRes.headers) === null || _a === void 0 ? void 0 : _a["content-type"]) !== null && _b !== void 0 ? _b : "";
388
1014
  if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
@@ -395,14 +1021,68 @@ var Invoice = /** @class */ (function () {
395
1021
  });
396
1022
  decodedRes = new TextDecoder().decode(httpRes === null || httpRes === void 0 ? void 0 : httpRes.data);
397
1023
  switch (true) {
398
- case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 201:
1024
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
399
1025
  if (utils.matchContentType(contentType, "application/json")) {
400
1026
  res.invoice = utils.objectToClass(JSON.parse(decodedRes), shared.Invoice);
401
1027
  }
1028
+ else {
1029
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
1030
+ }
402
1031
  break;
403
1032
  case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 400:
404
1033
  if (utils.matchContentType(contentType, "application/json")) {
405
- res.requestValidationError = utils.objectToClass(JSON.parse(decodedRes), shared.RequestValidationError);
1034
+ res.fourHundredError = JSON.parse(decodedRes);
1035
+ }
1036
+ else {
1037
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
1038
+ }
1039
+ break;
1040
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 401:
1041
+ if (utils.matchContentType(contentType, "application/json")) {
1042
+ res.fourHundredAndOneError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndOneError);
1043
+ }
1044
+ else {
1045
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
1046
+ }
1047
+ break;
1048
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 404:
1049
+ if (utils.matchContentType(contentType, "application/json")) {
1050
+ res.fourHundredAndFourError = JSON.parse(decodedRes);
1051
+ }
1052
+ else {
1053
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
1054
+ }
1055
+ break;
1056
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 409:
1057
+ if (utils.matchContentType(contentType, "application/json")) {
1058
+ res.fourHundredAndNineError = JSON.parse(decodedRes);
1059
+ }
1060
+ else {
1061
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
1062
+ }
1063
+ break;
1064
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 413:
1065
+ if (utils.matchContentType(contentType, "application/json")) {
1066
+ res.fourHundredAndThirteenError = JSON.parse(decodedRes);
1067
+ }
1068
+ else {
1069
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
1070
+ }
1071
+ break;
1072
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 429:
1073
+ if (utils.matchContentType(contentType, "application/json")) {
1074
+ res.fourHundredAndTwentyNineError = utils.objectToClass(JSON.parse(decodedRes), shared.FourHundredAndTwentyNineError);
1075
+ }
1076
+ else {
1077
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
1078
+ }
1079
+ break;
1080
+ case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 500:
1081
+ if (utils.matchContentType(contentType, "application/json")) {
1082
+ res.fiveHundredError = utils.objectToClass(JSON.parse(decodedRes), shared.FiveHundredError);
1083
+ }
1084
+ else {
1085
+ throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
406
1086
  }
407
1087
  break;
408
1088
  }