orb-billing 1.21.0 → 1.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1115) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/LICENSE +201 -0
  3. package/README.md +196 -192
  4. package/_shims/MultipartBody.d.ts +9 -0
  5. package/_shims/MultipartBody.d.ts.map +1 -0
  6. package/_shims/MultipartBody.js +16 -0
  7. package/_shims/MultipartBody.js.map +1 -0
  8. package/_shims/MultipartBody.mjs +12 -0
  9. package/_shims/MultipartBody.mjs.map +1 -0
  10. package/_shims/README.md +46 -0
  11. package/_shims/auto/runtime-bun.d.ts +5 -0
  12. package/_shims/auto/runtime-bun.d.ts.map +1 -0
  13. package/_shims/auto/runtime-bun.js +21 -0
  14. package/_shims/auto/runtime-bun.js.map +1 -0
  15. package/_shims/auto/runtime-bun.mjs +2 -0
  16. package/_shims/auto/runtime-bun.mjs.map +1 -0
  17. package/_shims/auto/runtime-node.d.ts +5 -0
  18. package/_shims/auto/runtime-node.d.ts.map +1 -0
  19. package/_shims/auto/runtime-node.js +21 -0
  20. package/_shims/auto/runtime-node.js.map +1 -0
  21. package/_shims/auto/runtime-node.mjs +2 -0
  22. package/_shims/auto/runtime-node.mjs.map +1 -0
  23. package/_shims/auto/runtime.d.ts +5 -0
  24. package/_shims/auto/runtime.d.ts.map +1 -0
  25. package/_shims/auto/runtime.js +21 -0
  26. package/_shims/auto/runtime.js.map +1 -0
  27. package/_shims/auto/runtime.mjs +2 -0
  28. package/_shims/auto/runtime.mjs.map +1 -0
  29. package/_shims/auto/types-node.d.ts +5 -0
  30. package/_shims/auto/types-node.d.ts.map +1 -0
  31. package/_shims/auto/types-node.js +21 -0
  32. package/_shims/auto/types-node.js.map +1 -0
  33. package/_shims/auto/types-node.mjs +2 -0
  34. package/_shims/auto/types-node.mjs.map +1 -0
  35. package/_shims/auto/types.d.ts +101 -0
  36. package/_shims/auto/types.js +3 -0
  37. package/_shims/auto/types.mjs +3 -0
  38. package/_shims/bun-runtime.d.ts +6 -0
  39. package/_shims/bun-runtime.d.ts.map +1 -0
  40. package/_shims/bun-runtime.js +14 -0
  41. package/_shims/bun-runtime.js.map +1 -0
  42. package/_shims/bun-runtime.mjs +10 -0
  43. package/_shims/bun-runtime.mjs.map +1 -0
  44. package/_shims/index.d.ts +81 -0
  45. package/_shims/index.js +13 -0
  46. package/_shims/index.mjs +7 -0
  47. package/_shims/manual-types.d.ts +12 -0
  48. package/_shims/manual-types.js +3 -0
  49. package/_shims/manual-types.mjs +3 -0
  50. package/_shims/node-runtime.d.ts +3 -0
  51. package/_shims/node-runtime.d.ts.map +1 -0
  52. package/_shims/node-runtime.js +90 -0
  53. package/_shims/node-runtime.js.map +1 -0
  54. package/_shims/node-runtime.mjs +56 -0
  55. package/_shims/node-runtime.mjs.map +1 -0
  56. package/_shims/node-types.d.ts +42 -0
  57. package/_shims/node-types.js +3 -0
  58. package/_shims/node-types.mjs +3 -0
  59. package/_shims/registry.d.ts +37 -0
  60. package/_shims/registry.d.ts.map +1 -0
  61. package/_shims/registry.js +41 -0
  62. package/_shims/registry.js.map +1 -0
  63. package/_shims/registry.mjs +37 -0
  64. package/_shims/registry.mjs.map +1 -0
  65. package/_shims/web-runtime.d.ts +5 -0
  66. package/_shims/web-runtime.d.ts.map +1 -0
  67. package/_shims/web-runtime.js +78 -0
  68. package/_shims/web-runtime.js.map +1 -0
  69. package/_shims/web-runtime.mjs +71 -0
  70. package/_shims/web-runtime.mjs.map +1 -0
  71. package/_shims/web-types.d.ts +83 -0
  72. package/_shims/web-types.js +3 -0
  73. package/_shims/web-types.mjs +3 -0
  74. package/core.d.ts +239 -0
  75. package/core.d.ts.map +1 -0
  76. package/core.js +830 -0
  77. package/core.js.map +1 -0
  78. package/core.mjs +799 -0
  79. package/core.mjs.map +1 -0
  80. package/error.d.ts +131 -0
  81. package/error.d.ts.map +1 -0
  82. package/error.js +298 -0
  83. package/error.js.map +1 -0
  84. package/error.mjs +271 -0
  85. package/error.mjs.map +1 -0
  86. package/index.d.mts +210 -0
  87. package/index.d.ts +210 -0
  88. package/index.d.ts.map +1 -0
  89. package/index.js +153 -0
  90. package/index.js.map +1 -0
  91. package/index.mjs +125 -0
  92. package/index.mjs.map +1 -0
  93. package/package.json +90 -27
  94. package/pagination.d.ts +31 -0
  95. package/pagination.d.ts.map +1 -0
  96. package/pagination.js +34 -0
  97. package/pagination.js.map +1 -0
  98. package/pagination.mjs +30 -0
  99. package/pagination.mjs.map +1 -0
  100. package/resource.d.ts +12 -0
  101. package/resource.d.ts.map +1 -0
  102. package/resource.js +17 -0
  103. package/resource.js.map +1 -0
  104. package/resource.mjs +13 -0
  105. package/resource.mjs.map +1 -0
  106. package/resources/coupons/coupons.d.ts +114 -0
  107. package/resources/coupons/coupons.d.ts.map +1 -0
  108. package/resources/coupons/coupons.js +76 -0
  109. package/resources/coupons/coupons.js.map +1 -0
  110. package/resources/coupons/coupons.mjs +48 -0
  111. package/resources/coupons/coupons.mjs.map +1 -0
  112. package/resources/coupons/index.d.ts +3 -0
  113. package/resources/coupons/index.d.ts.map +1 -0
  114. package/resources/coupons/index.js +10 -0
  115. package/resources/coupons/index.js.map +1 -0
  116. package/resources/coupons/index.mjs +4 -0
  117. package/resources/coupons/index.mjs.map +1 -0
  118. package/resources/coupons/subscriptions.d.ts +23 -0
  119. package/resources/coupons/subscriptions.d.ts.map +1 -0
  120. package/resources/coupons/subscriptions.js +20 -0
  121. package/resources/coupons/subscriptions.js.map +1 -0
  122. package/resources/coupons/subscriptions.mjs +16 -0
  123. package/resources/coupons/subscriptions.mjs.map +1 -0
  124. package/resources/credit-notes.d.ts +136 -0
  125. package/resources/credit-notes.d.ts.map +1 -0
  126. package/resources/credit-notes.js +54 -0
  127. package/resources/credit-notes.js.map +1 -0
  128. package/resources/credit-notes.mjs +26 -0
  129. package/resources/credit-notes.mjs.map +1 -0
  130. package/resources/customers/balance-transactions.d.ts +159 -0
  131. package/resources/customers/balance-transactions.d.ts.map +1 -0
  132. package/resources/customers/balance-transactions.js +54 -0
  133. package/resources/customers/balance-transactions.js.map +1 -0
  134. package/resources/customers/balance-transactions.mjs +26 -0
  135. package/resources/customers/balance-transactions.mjs.map +1 -0
  136. package/resources/customers/costs.d.ts +915 -0
  137. package/resources/customers/costs.d.ts.map +1 -0
  138. package/resources/customers/costs.js +24 -0
  139. package/resources/customers/costs.js.map +1 -0
  140. package/resources/customers/costs.mjs +20 -0
  141. package/resources/customers/costs.mjs.map +1 -0
  142. package/resources/customers/credits/credits.d.ts +58 -0
  143. package/resources/customers/credits/credits.d.ts.map +1 -0
  144. package/resources/customers/credits/credits.js +68 -0
  145. package/resources/customers/credits/credits.js.map +1 -0
  146. package/resources/customers/credits/credits.mjs +39 -0
  147. package/resources/customers/credits/credits.mjs.map +1 -0
  148. package/resources/customers/credits/index.d.ts +3 -0
  149. package/resources/customers/credits/index.d.ts.map +1 -0
  150. package/resources/customers/credits/index.js +13 -0
  151. package/resources/customers/credits/index.js.map +1 -0
  152. package/resources/customers/credits/index.mjs +4 -0
  153. package/resources/customers/credits/index.mjs.map +1 -0
  154. package/resources/customers/credits/ledger.d.ts +1537 -0
  155. package/resources/customers/credits/ledger.d.ts.map +1 -0
  156. package/resources/customers/credits/ledger.js +291 -0
  157. package/resources/customers/credits/ledger.js.map +1 -0
  158. package/resources/customers/credits/ledger.mjs +262 -0
  159. package/resources/customers/credits/ledger.mjs.map +1 -0
  160. package/resources/customers/customers.d.ts +524 -0
  161. package/resources/customers/customers.d.ts.map +1 -0
  162. package/resources/customers/customers.js +135 -0
  163. package/resources/customers/customers.js.map +1 -0
  164. package/resources/customers/customers.mjs +107 -0
  165. package/resources/customers/customers.mjs.map +1 -0
  166. package/resources/customers/index.d.ts +6 -0
  167. package/resources/customers/index.d.ts.map +1 -0
  168. package/resources/customers/index.js +19 -0
  169. package/resources/customers/index.js.map +1 -0
  170. package/resources/customers/index.mjs +7 -0
  171. package/resources/customers/index.mjs.map +1 -0
  172. package/resources/customers/usage.d.ts +306 -0
  173. package/resources/customers/usage.d.ts.map +1 -0
  174. package/resources/customers/usage.js +223 -0
  175. package/resources/customers/usage.js.map +1 -0
  176. package/resources/customers/usage.mjs +219 -0
  177. package/resources/customers/usage.mjs.map +1 -0
  178. package/resources/events/backfills.d.ts +250 -0
  179. package/resources/events/backfills.d.ts.map +1 -0
  180. package/resources/events/backfills.js +104 -0
  181. package/resources/events/backfills.js.map +1 -0
  182. package/resources/events/backfills.mjs +76 -0
  183. package/resources/events/backfills.mjs.map +1 -0
  184. package/resources/events/events.d.ts +547 -0
  185. package/resources/events/events.d.ts.map +1 -0
  186. package/resources/events/events.js +354 -0
  187. package/resources/events/events.js.map +1 -0
  188. package/resources/events/events.mjs +327 -0
  189. package/resources/events/events.mjs.map +1 -0
  190. package/resources/events/index.d.ts +3 -0
  191. package/resources/events/index.d.ts.map +1 -0
  192. package/resources/events/index.js +10 -0
  193. package/resources/events/index.js.map +1 -0
  194. package/resources/events/index.mjs +4 -0
  195. package/resources/events/index.mjs.map +1 -0
  196. package/resources/index.d.ts +13 -0
  197. package/resources/index.d.ts.map +1 -0
  198. package/resources/index.js +39 -0
  199. package/resources/index.js.map +1 -0
  200. package/resources/index.mjs +14 -0
  201. package/resources/index.mjs.map +1 -0
  202. package/resources/invoice-line-items.d.ts +434 -0
  203. package/resources/invoice-line-items.d.ts.map +1 -0
  204. package/resources/invoice-line-items.js +18 -0
  205. package/resources/invoice-line-items.js.map +1 -0
  206. package/resources/invoice-line-items.mjs +14 -0
  207. package/resources/invoice-line-items.mjs.map +1 -0
  208. package/resources/invoices.d.ts +1541 -0
  209. package/resources/invoices.d.ts.map +1 -0
  210. package/resources/invoices.js +96 -0
  211. package/resources/invoices.js.map +1 -0
  212. package/resources/invoices.mjs +68 -0
  213. package/resources/invoices.mjs.map +1 -0
  214. package/resources/items.d.ts +61 -0
  215. package/resources/items.d.ts.map +1 -0
  216. package/resources/items.js +53 -0
  217. package/resources/items.js.map +1 -0
  218. package/resources/items.mjs +25 -0
  219. package/resources/items.mjs.map +1 -0
  220. package/resources/metrics.d.ts +176 -0
  221. package/resources/metrics.d.ts.map +1 -0
  222. package/resources/metrics.js +63 -0
  223. package/resources/metrics.js.map +1 -0
  224. package/resources/metrics.mjs +35 -0
  225. package/resources/metrics.mjs.map +1 -0
  226. package/resources/plans/external-plan-id.d.ts +50 -0
  227. package/resources/plans/external-plan-id.d.ts.map +1 -0
  228. package/resources/plans/external-plan-id.js +35 -0
  229. package/resources/plans/external-plan-id.js.map +1 -0
  230. package/resources/plans/external-plan-id.mjs +31 -0
  231. package/resources/plans/external-plan-id.mjs.map +1 -0
  232. package/resources/plans/index.d.ts +3 -0
  233. package/resources/plans/index.d.ts.map +1 -0
  234. package/resources/plans/index.js +10 -0
  235. package/resources/plans/index.js.map +1 -0
  236. package/resources/plans/index.mjs +4 -0
  237. package/resources/plans/index.mjs.map +1 -0
  238. package/resources/plans/plans.d.ts +256 -0
  239. package/resources/plans/plans.d.ts.map +1 -0
  240. package/resources/plans/plans.js +87 -0
  241. package/resources/plans/plans.js.map +1 -0
  242. package/resources/plans/plans.mjs +59 -0
  243. package/resources/plans/plans.mjs.map +1 -0
  244. package/resources/prices/external-price-id.d.ts +12 -0
  245. package/resources/prices/external-price-id.d.ts.map +1 -0
  246. package/resources/prices/external-price-id.js +17 -0
  247. package/resources/prices/external-price-id.js.map +1 -0
  248. package/resources/prices/external-price-id.mjs +13 -0
  249. package/resources/prices/external-price-id.mjs.map +1 -0
  250. package/resources/prices/index.d.ts +3 -0
  251. package/resources/prices/index.d.ts.map +1 -0
  252. package/resources/prices/index.js +10 -0
  253. package/resources/prices/index.js.map +1 -0
  254. package/resources/prices/index.mjs +4 -0
  255. package/resources/prices/index.mjs.map +1 -0
  256. package/resources/prices/prices.d.ts +1872 -0
  257. package/resources/prices/prices.d.ts.map +1 -0
  258. package/resources/prices/prices.js +74 -0
  259. package/resources/prices/prices.js.map +1 -0
  260. package/resources/prices/prices.mjs +46 -0
  261. package/resources/prices/prices.mjs.map +1 -0
  262. package/resources/subscriptions.d.ts +3752 -0
  263. package/resources/subscriptions.d.ts.map +1 -0
  264. package/resources/subscriptions.js +254 -0
  265. package/resources/subscriptions.js.map +1 -0
  266. package/resources/subscriptions.mjs +225 -0
  267. package/resources/subscriptions.mjs.map +1 -0
  268. package/resources/top-level.d.ts +21 -0
  269. package/resources/top-level.d.ts.map +1 -0
  270. package/resources/top-level.js +22 -0
  271. package/resources/top-level.js.map +1 -0
  272. package/resources/top-level.mjs +18 -0
  273. package/resources/top-level.mjs.map +1 -0
  274. package/shims/node.d.ts +29 -0
  275. package/shims/node.d.ts.map +1 -0
  276. package/shims/node.js +31 -0
  277. package/shims/node.js.map +1 -0
  278. package/shims/node.mjs +5 -0
  279. package/shims/node.mjs.map +1 -0
  280. package/shims/web.d.ts +26 -0
  281. package/shims/web.d.ts.map +1 -0
  282. package/shims/web.js +31 -0
  283. package/shims/web.js.map +1 -0
  284. package/shims/web.mjs +5 -0
  285. package/shims/web.mjs.map +1 -0
  286. package/src/_shims/MultipartBody.ts +9 -0
  287. package/src/_shims/README.md +46 -0
  288. package/src/_shims/auto/runtime-bun.ts +4 -0
  289. package/src/_shims/auto/runtime-node.ts +4 -0
  290. package/src/_shims/auto/runtime.ts +4 -0
  291. package/src/_shims/auto/types-node.ts +4 -0
  292. package/src/_shims/auto/types.d.ts +101 -0
  293. package/src/_shims/auto/types.js +3 -0
  294. package/src/_shims/auto/types.mjs +3 -0
  295. package/src/_shims/bun-runtime.ts +14 -0
  296. package/src/_shims/index.d.ts +81 -0
  297. package/src/_shims/index.js +13 -0
  298. package/src/_shims/index.mjs +7 -0
  299. package/src/_shims/manual-types.d.ts +12 -0
  300. package/src/_shims/manual-types.js +3 -0
  301. package/src/_shims/manual-types.mjs +3 -0
  302. package/src/_shims/node-runtime.ts +83 -0
  303. package/src/_shims/node-types.d.ts +42 -0
  304. package/src/_shims/node-types.js +3 -0
  305. package/src/_shims/node-types.mjs +3 -0
  306. package/src/_shims/registry.ts +67 -0
  307. package/src/_shims/web-runtime.ts +103 -0
  308. package/src/_shims/web-types.d.ts +83 -0
  309. package/src/_shims/web-types.js +3 -0
  310. package/src/_shims/web-types.mjs +3 -0
  311. package/src/core.ts +1099 -0
  312. package/src/error.ts +469 -0
  313. package/src/index.ts +305 -0
  314. package/src/pagination.ts +63 -0
  315. package/src/resource.ts +24 -0
  316. package/src/resources/coupons/coupons.ts +150 -0
  317. package/src/resources/coupons/index.ts +4 -0
  318. package/src/resources/coupons/subscriptions.ts +45 -0
  319. package/src/resources/credit-notes.ts +184 -0
  320. package/src/resources/customers/balance-transactions.ts +222 -0
  321. package/src/resources/customers/costs.ts +991 -0
  322. package/src/resources/customers/credits/credits.ts +113 -0
  323. package/src/resources/customers/credits/index.ts +24 -0
  324. package/src/resources/customers/credits/ledger.ts +2254 -0
  325. package/src/resources/customers/customers.ts +734 -0
  326. package/src/resources/customers/index.ts +42 -0
  327. package/src/resources/customers/usage.ts +350 -0
  328. package/src/resources/events/backfills.ts +324 -0
  329. package/src/resources/events/events.ts +635 -0
  330. package/src/resources/events/index.ts +23 -0
  331. package/src/resources/index.ts +72 -0
  332. package/src/resources/invoice-line-items.ts +502 -0
  333. package/src/resources/invoices.ts +1906 -0
  334. package/src/resources/items.ts +106 -0
  335. package/src/resources/metrics.ts +264 -0
  336. package/src/resources/plans/external-plan-id.ts +73 -0
  337. package/src/resources/plans/index.ts +4 -0
  338. package/src/resources/plans/plans.ts +350 -0
  339. package/src/resources/prices/external-price-id.ts +16 -0
  340. package/src/resources/prices/index.ts +4 -0
  341. package/src/resources/prices/prices.ts +2466 -0
  342. package/src/resources/subscriptions.ts +4590 -0
  343. package/src/resources/top-level.ts +27 -0
  344. package/src/shims/node.ts +50 -0
  345. package/src/shims/web.ts +50 -0
  346. package/src/tsconfig.json +11 -0
  347. package/src/uploads.ts +246 -0
  348. package/src/version.ts +1 -0
  349. package/uploads.d.ts +75 -0
  350. package/uploads.d.ts.map +1 -0
  351. package/uploads.js +162 -0
  352. package/uploads.js.map +1 -0
  353. package/uploads.mjs +149 -0
  354. package/uploads.mjs.map +1 -0
  355. package/version.d.ts +2 -0
  356. package/version.d.ts.map +1 -0
  357. package/version.js +5 -0
  358. package/version.js.map +1 -0
  359. package/version.mjs +2 -0
  360. package/version.mjs.map +1 -0
  361. package/LICENSE.md +0 -21
  362. package/dist/index.d.ts +0 -1
  363. package/dist/index.js +0 -20
  364. package/dist/internal/utils/contenttype.d.ts +0 -1
  365. package/dist/internal/utils/contenttype.js +0 -33
  366. package/dist/internal/utils/headers.d.ts +0 -4
  367. package/dist/internal/utils/headers.js +0 -92
  368. package/dist/internal/utils/index.d.ts +0 -8
  369. package/dist/internal/utils/index.js +0 -27
  370. package/dist/internal/utils/pathparams.d.ts +0 -2
  371. package/dist/internal/utils/pathparams.js +0 -53
  372. package/dist/internal/utils/queryparams.d.ts +0 -2
  373. package/dist/internal/utils/queryparams.js +0 -178
  374. package/dist/internal/utils/requestbody.d.ts +0 -2
  375. package/dist/internal/utils/requestbody.js +0 -318
  376. package/dist/internal/utils/retries.d.ts +0 -20
  377. package/dist/internal/utils/retries.js +0 -250
  378. package/dist/internal/utils/security.d.ts +0 -5
  379. package/dist/internal/utils/security.js +0 -188
  380. package/dist/internal/utils/utils.d.ts +0 -37
  381. package/dist/internal/utils/utils.js +0 -370
  382. package/dist/sdk/availability.d.ts +0 -18
  383. package/dist/sdk/availability.js +0 -186
  384. package/dist/sdk/coupon.d.ts +0 -62
  385. package/dist/sdk/coupon.js +0 -629
  386. package/dist/sdk/credit.d.ts +0 -348
  387. package/dist/sdk/credit.js +0 -1020
  388. package/dist/sdk/creditnote.d.ts +0 -29
  389. package/dist/sdk/creditnote.js +0 -293
  390. package/dist/sdk/customer.d.ts +0 -529
  391. package/dist/sdk/customer.js +0 -1882
  392. package/dist/sdk/event.d.ts +0 -353
  393. package/dist/sdk/event.js +0 -1314
  394. package/dist/sdk/index.d.ts +0 -1
  395. package/dist/sdk/index.js +0 -20
  396. package/dist/sdk/invoice.d.ts +0 -89
  397. package/dist/sdk/invoice.js +0 -945
  398. package/dist/sdk/item.d.ts +0 -27
  399. package/dist/sdk/item.js +0 -291
  400. package/dist/sdk/metric.d.ts +0 -39
  401. package/dist/sdk/metric.js +0 -418
  402. package/dist/sdk/models/errors/fivehundrederror.d.ts +0 -11
  403. package/dist/sdk/models/errors/fivehundrederror.js +0 -88
  404. package/dist/sdk/models/errors/fourhundredandoneerror.d.ts +0 -11
  405. package/dist/sdk/models/errors/fourhundredandoneerror.js +0 -88
  406. package/dist/sdk/models/errors/fourhundredandtwentynineerror.d.ts +0 -11
  407. package/dist/sdk/models/errors/fourhundredandtwentynineerror.js +0 -88
  408. package/dist/sdk/models/errors/index.d.ts +0 -4
  409. package/dist/sdk/models/errors/index.js +0 -23
  410. package/dist/sdk/models/errors/sdkerror.d.ts +0 -7
  411. package/dist/sdk/models/errors/sdkerror.js +0 -40
  412. package/dist/sdk/models/operations/addeditpriceintervals.d.ts +0 -25
  413. package/dist/sdk/models/operations/addeditpriceintervals.js +0 -95
  414. package/dist/sdk/models/operations/amendevent.d.ts +0 -25
  415. package/dist/sdk/models/operations/amendevent.js +0 -95
  416. package/dist/sdk/models/operations/amendusage.d.ts +0 -27
  417. package/dist/sdk/models/operations/amendusage.js +0 -103
  418. package/dist/sdk/models/operations/amendusageexternalcustomerid.d.ts +0 -27
  419. package/dist/sdk/models/operations/amendusageexternalcustomerid.js +0 -103
  420. package/dist/sdk/models/operations/archivecoupon.d.ts +0 -24
  421. package/dist/sdk/models/operations/archivecoupon.js +0 -91
  422. package/dist/sdk/models/operations/cancelsubscription.d.ts +0 -25
  423. package/dist/sdk/models/operations/cancelsubscription.js +0 -95
  424. package/dist/sdk/models/operations/closebackfill.d.ts +0 -24
  425. package/dist/sdk/models/operations/closebackfill.js +0 -91
  426. package/dist/sdk/models/operations/createbackfill.d.ts +0 -21
  427. package/dist/sdk/models/operations/createbackfill.js +0 -79
  428. package/dist/sdk/models/operations/createcoupon.d.ts +0 -21
  429. package/dist/sdk/models/operations/createcoupon.js +0 -79
  430. package/dist/sdk/models/operations/createcustomer.d.ts +0 -21
  431. package/dist/sdk/models/operations/createcustomer.js +0 -79
  432. package/dist/sdk/models/operations/createcustomerbalancetransaction.d.ts +0 -25
  433. package/dist/sdk/models/operations/createcustomerbalancetransaction.js +0 -95
  434. package/dist/sdk/models/operations/createinvoice.d.ts +0 -21
  435. package/dist/sdk/models/operations/createinvoice.js +0 -79
  436. package/dist/sdk/models/operations/createinvoicelineitem.d.ts +0 -21
  437. package/dist/sdk/models/operations/createinvoicelineitem.js +0 -79
  438. package/dist/sdk/models/operations/createledgerentry.d.ts +0 -24
  439. package/dist/sdk/models/operations/createledgerentry.js +0 -71
  440. package/dist/sdk/models/operations/createledgerentryexternalid.d.ts +0 -24
  441. package/dist/sdk/models/operations/createledgerentryexternalid.js +0 -71
  442. package/dist/sdk/models/operations/createmetric.d.ts +0 -21
  443. package/dist/sdk/models/operations/createmetric.js +0 -79
  444. package/dist/sdk/models/operations/createplan.d.ts +0 -21
  445. package/dist/sdk/models/operations/createplan.js +0 -79
  446. package/dist/sdk/models/operations/createprice.d.ts +0 -20
  447. package/dist/sdk/models/operations/createprice.js +0 -55
  448. package/dist/sdk/models/operations/createsubscription.d.ts +0 -21
  449. package/dist/sdk/models/operations/createsubscription.js +0 -79
  450. package/dist/sdk/models/operations/deletecustomer.d.ts +0 -24
  451. package/dist/sdk/models/operations/deletecustomer.js +0 -91
  452. package/dist/sdk/models/operations/deprecateevent.d.ts +0 -24
  453. package/dist/sdk/models/operations/deprecateevent.js +0 -91
  454. package/dist/sdk/models/operations/fetchbackfill.d.ts +0 -24
  455. package/dist/sdk/models/operations/fetchbackfill.js +0 -91
  456. package/dist/sdk/models/operations/fetchcoupon.d.ts +0 -24
  457. package/dist/sdk/models/operations/fetchcoupon.js +0 -91
  458. package/dist/sdk/models/operations/fetchcreditnote.d.ts +0 -24
  459. package/dist/sdk/models/operations/fetchcreditnote.js +0 -91
  460. package/dist/sdk/models/operations/fetchcustomer.d.ts +0 -24
  461. package/dist/sdk/models/operations/fetchcustomer.js +0 -91
  462. package/dist/sdk/models/operations/fetchcustomercosts.d.ts +0 -38
  463. package/dist/sdk/models/operations/fetchcustomercosts.js +0 -115
  464. package/dist/sdk/models/operations/fetchcustomercostsexternalid.d.ts +0 -38
  465. package/dist/sdk/models/operations/fetchcustomercostsexternalid.js +0 -115
  466. package/dist/sdk/models/operations/fetchcustomercredits.d.ts +0 -26
  467. package/dist/sdk/models/operations/fetchcustomercredits.js +0 -99
  468. package/dist/sdk/models/operations/fetchcustomercreditsexternalid.d.ts +0 -26
  469. package/dist/sdk/models/operations/fetchcustomercreditsexternalid.js +0 -99
  470. package/dist/sdk/models/operations/fetchcustomercreditsledger.d.ts +0 -47
  471. package/dist/sdk/models/operations/fetchcustomercreditsledger.js +0 -146
  472. package/dist/sdk/models/operations/fetchcustomercreditsledgerexternalid.d.ts +0 -47
  473. package/dist/sdk/models/operations/fetchcustomercreditsledgerexternalid.js +0 -146
  474. package/dist/sdk/models/operations/fetchcustomerexternalid.d.ts +0 -24
  475. package/dist/sdk/models/operations/fetchcustomerexternalid.js +0 -91
  476. package/dist/sdk/models/operations/fetchinvoice.d.ts +0 -24
  477. package/dist/sdk/models/operations/fetchinvoice.js +0 -91
  478. package/dist/sdk/models/operations/fetchitem.d.ts +0 -24
  479. package/dist/sdk/models/operations/fetchitem.js +0 -91
  480. package/dist/sdk/models/operations/fetchmetric.d.ts +0 -24
  481. package/dist/sdk/models/operations/fetchmetric.js +0 -91
  482. package/dist/sdk/models/operations/fetchplan.d.ts +0 -24
  483. package/dist/sdk/models/operations/fetchplan.js +0 -91
  484. package/dist/sdk/models/operations/fetchplanexternalid.d.ts +0 -24
  485. package/dist/sdk/models/operations/fetchplanexternalid.js +0 -91
  486. package/dist/sdk/models/operations/fetchprice.d.ts +0 -23
  487. package/dist/sdk/models/operations/fetchprice.js +0 -67
  488. package/dist/sdk/models/operations/fetchpriceexternalid.d.ts +0 -23
  489. package/dist/sdk/models/operations/fetchpriceexternalid.js +0 -67
  490. package/dist/sdk/models/operations/fetchsubscription.d.ts +0 -24
  491. package/dist/sdk/models/operations/fetchsubscription.js +0 -91
  492. package/dist/sdk/models/operations/fetchsubscriptioncosts.d.ts +0 -38
  493. package/dist/sdk/models/operations/fetchsubscriptioncosts.js +0 -115
  494. package/dist/sdk/models/operations/fetchsubscriptionschedule.d.ts +0 -30
  495. package/dist/sdk/models/operations/fetchsubscriptionschedule.js +0 -115
  496. package/dist/sdk/models/operations/fetchsubscriptionusage.d.ts +0 -54
  497. package/dist/sdk/models/operations/fetchsubscriptionusage.js +0 -130
  498. package/dist/sdk/models/operations/fetchupcominginvoice.d.ts +0 -24
  499. package/dist/sdk/models/operations/fetchupcominginvoice.js +0 -91
  500. package/dist/sdk/models/operations/index.d.ts +0 -73
  501. package/dist/sdk/models/operations/index.js +0 -92
  502. package/dist/sdk/models/operations/ingest.d.ts +0 -26
  503. package/dist/sdk/models/operations/ingest.js +0 -99
  504. package/dist/sdk/models/operations/issueinvoice.d.ts +0 -24
  505. package/dist/sdk/models/operations/issueinvoice.js +0 -91
  506. package/dist/sdk/models/operations/listbackfills.d.ts +0 -25
  507. package/dist/sdk/models/operations/listbackfills.js +0 -95
  508. package/dist/sdk/models/operations/listbalancetransactions.d.ts +0 -30
  509. package/dist/sdk/models/operations/listbalancetransactions.js +0 -115
  510. package/dist/sdk/models/operations/listcoupons.d.ts +0 -27
  511. package/dist/sdk/models/operations/listcoupons.js +0 -103
  512. package/dist/sdk/models/operations/listcouponsubscriptions.d.ts +0 -26
  513. package/dist/sdk/models/operations/listcouponsubscriptions.js +0 -99
  514. package/dist/sdk/models/operations/listcreditnotes.d.ts +0 -25
  515. package/dist/sdk/models/operations/listcreditnotes.js +0 -95
  516. package/dist/sdk/models/operations/listcustomers.d.ts +0 -29
  517. package/dist/sdk/models/operations/listcustomers.js +0 -111
  518. package/dist/sdk/models/operations/listinvoices.d.ts +0 -62
  519. package/dist/sdk/models/operations/listinvoices.js +0 -189
  520. package/dist/sdk/models/operations/listitems.d.ts +0 -25
  521. package/dist/sdk/models/operations/listitems.js +0 -95
  522. package/dist/sdk/models/operations/listmetrics.d.ts +0 -29
  523. package/dist/sdk/models/operations/listmetrics.js +0 -111
  524. package/dist/sdk/models/operations/listplans.d.ts +0 -41
  525. package/dist/sdk/models/operations/listplans.js +0 -124
  526. package/dist/sdk/models/operations/listprices.d.ts +0 -25
  527. package/dist/sdk/models/operations/listprices.js +0 -95
  528. package/dist/sdk/models/operations/listsubscriptions.d.ts +0 -37
  529. package/dist/sdk/models/operations/listsubscriptions.js +0 -129
  530. package/dist/sdk/models/operations/markinvoiceaspaid.d.ts +0 -25
  531. package/dist/sdk/models/operations/markinvoiceaspaid.js +0 -95
  532. package/dist/sdk/models/operations/ping.d.ts +0 -21
  533. package/dist/sdk/models/operations/ping.js +0 -79
  534. package/dist/sdk/models/operations/revertbackfill.d.ts +0 -24
  535. package/dist/sdk/models/operations/revertbackfill.js +0 -91
  536. package/dist/sdk/models/operations/scheduleplanchange.d.ts +0 -25
  537. package/dist/sdk/models/operations/scheduleplanchange.js +0 -95
  538. package/dist/sdk/models/operations/searchevents.d.ts +0 -30
  539. package/dist/sdk/models/operations/searchevents.js +0 -115
  540. package/dist/sdk/models/operations/triggerphase.d.ts +0 -25
  541. package/dist/sdk/models/operations/triggerphase.js +0 -95
  542. package/dist/sdk/models/operations/unschedulecancellation.d.ts +0 -24
  543. package/dist/sdk/models/operations/unschedulecancellation.js +0 -91
  544. package/dist/sdk/models/operations/unschedulefixedfeequantity.d.ts +0 -25
  545. package/dist/sdk/models/operations/unschedulefixedfeequantity.js +0 -95
  546. package/dist/sdk/models/operations/unscheduleplanchange.d.ts +0 -24
  547. package/dist/sdk/models/operations/unscheduleplanchange.js +0 -91
  548. package/dist/sdk/models/operations/updatecustomer.d.ts +0 -25
  549. package/dist/sdk/models/operations/updatecustomer.js +0 -95
  550. package/dist/sdk/models/operations/updatecustomerexternalid.d.ts +0 -25
  551. package/dist/sdk/models/operations/updatecustomerexternalid.js +0 -95
  552. package/dist/sdk/models/operations/updatefixedfeequantity.d.ts +0 -25
  553. package/dist/sdk/models/operations/updatefixedfeequantity.js +0 -95
  554. package/dist/sdk/models/operations/updateplan.d.ts +0 -25
  555. package/dist/sdk/models/operations/updateplan.js +0 -95
  556. package/dist/sdk/models/operations/updateplanexternal.d.ts +0 -25
  557. package/dist/sdk/models/operations/updateplanexternal.js +0 -95
  558. package/dist/sdk/models/operations/voidinvoice.d.ts +0 -24
  559. package/dist/sdk/models/operations/voidinvoice.js +0 -91
  560. package/dist/sdk/models/shared/accountingprovider.d.ts +0 -9
  561. package/dist/sdk/models/shared/accountingprovider.js +0 -55
  562. package/dist/sdk/models/shared/accountingproviderconfig.d.ts +0 -5
  563. package/dist/sdk/models/shared/accountingproviderconfig.js +0 -50
  564. package/dist/sdk/models/shared/accountingsyncconfiguration.d.ts +0 -6
  565. package/dist/sdk/models/shared/accountingsyncconfiguration.js +0 -52
  566. package/dist/sdk/models/shared/addeditpriceintervalparams.d.ts +0 -13
  567. package/dist/sdk/models/shared/addeditpriceintervalparams.js +0 -54
  568. package/dist/sdk/models/shared/addpriceintervalparams.d.ts +0 -40
  569. package/dist/sdk/models/shared/addpriceintervalparams.js +0 -87
  570. package/dist/sdk/models/shared/address.d.ts +0 -9
  571. package/dist/sdk/models/shared/address.js +0 -70
  572. package/dist/sdk/models/shared/addressinput.d.ts +0 -9
  573. package/dist/sdk/models/shared/addressinput.js +0 -70
  574. package/dist/sdk/models/shared/aggregatedcost.d.ts +0 -15
  575. package/dist/sdk/models/shared/aggregatedcost.js +0 -75
  576. package/dist/sdk/models/shared/amendedevent.d.ts +0 -28
  577. package/dist/sdk/models/shared/amendedevent.js +0 -81
  578. package/dist/sdk/models/shared/amendedusage.d.ts +0 -11
  579. package/dist/sdk/models/shared/amendedusage.js +0 -50
  580. package/dist/sdk/models/shared/amendeventresult.d.ts +0 -7
  581. package/dist/sdk/models/shared/amendeventresult.js +0 -45
  582. package/dist/sdk/models/shared/autocollection.d.ts +0 -15
  583. package/dist/sdk/models/shared/autocollection.js +0 -63
  584. package/dist/sdk/models/shared/backfill.d.ts +0 -27
  585. package/dist/sdk/models/shared/backfill.js +0 -104
  586. package/dist/sdk/models/shared/backfills.d.ts +0 -7
  587. package/dist/sdk/models/shared/backfills.js +0 -54
  588. package/dist/sdk/models/shared/backfillstatus.d.ts +0 -9
  589. package/dist/sdk/models/shared/backfillstatus.js +0 -16
  590. package/dist/sdk/models/shared/billablemetric.d.ts +0 -27
  591. package/dist/sdk/models/shared/billablemetric.js +0 -84
  592. package/dist/sdk/models/shared/billablemetrics.d.ts +0 -7
  593. package/dist/sdk/models/shared/billablemetrics.js +0 -54
  594. package/dist/sdk/models/shared/billingcyclealignment.d.ts +0 -8
  595. package/dist/sdk/models/shared/billingcyclealignment.js +0 -15
  596. package/dist/sdk/models/shared/cancelsubscriptionparams.d.ts +0 -19
  597. package/dist/sdk/models/shared/cancelsubscriptionparams.js +0 -63
  598. package/dist/sdk/models/shared/changeoption.d.ts +0 -5
  599. package/dist/sdk/models/shared/changeoption.js +0 -12
  600. package/dist/sdk/models/shared/coupon.d.ts +0 -40
  601. package/dist/sdk/models/shared/coupon.js +0 -98
  602. package/dist/sdk/models/shared/couponredemption.d.ts +0 -6
  603. package/dist/sdk/models/shared/couponredemption.js +0 -63
  604. package/dist/sdk/models/shared/coupons.d.ts +0 -7
  605. package/dist/sdk/models/shared/coupons.js +0 -54
  606. package/dist/sdk/models/shared/createinvoicelineitemparams.d.ts +0 -28
  607. package/dist/sdk/models/shared/createinvoicelineitemparams.js +0 -81
  608. package/dist/sdk/models/shared/createoneoffinvoiceparams.d.ts +0 -33
  609. package/dist/sdk/models/shared/createoneoffinvoiceparams.js +0 -86
  610. package/dist/sdk/models/shared/creditledgerentries.d.ts +0 -6
  611. package/dist/sdk/models/shared/creditledgerentries.js +0 -52
  612. package/dist/sdk/models/shared/creditnote.d.ts +0 -83
  613. package/dist/sdk/models/shared/creditnote.js +0 -171
  614. package/dist/sdk/models/shared/creditnotelineitem.d.ts +0 -40
  615. package/dist/sdk/models/shared/creditnotelineitem.js +0 -100
  616. package/dist/sdk/models/shared/creditnoteminified.d.ts +0 -7
  617. package/dist/sdk/models/shared/creditnoteminified.js +0 -45
  618. package/dist/sdk/models/shared/creditnotes.d.ts +0 -7
  619. package/dist/sdk/models/shared/creditnotes.js +0 -54
  620. package/dist/sdk/models/shared/creditnotesublineitem.d.ts +0 -6
  621. package/dist/sdk/models/shared/creditnotesublineitem.js +0 -55
  622. package/dist/sdk/models/shared/creditnotesummary.d.ts +0 -12
  623. package/dist/sdk/models/shared/creditnotesummary.js +0 -74
  624. package/dist/sdk/models/shared/customer.d.ts +0 -76
  625. package/dist/sdk/models/shared/customer.js +0 -182
  626. package/dist/sdk/models/shared/customerbalancetransaction.d.ts +0 -42
  627. package/dist/sdk/models/shared/customerbalancetransaction.js +0 -109
  628. package/dist/sdk/models/shared/customerbalancetransactions.d.ts +0 -7
  629. package/dist/sdk/models/shared/customerbalancetransactions.js +0 -54
  630. package/dist/sdk/models/shared/customercosts.d.ts +0 -5
  631. package/dist/sdk/models/shared/customercosts.js +0 -47
  632. package/dist/sdk/models/shared/customercreditbalance.d.ts +0 -7
  633. package/dist/sdk/models/shared/customercreditbalance.js +0 -64
  634. package/dist/sdk/models/shared/customercreditbalances.d.ts +0 -7
  635. package/dist/sdk/models/shared/customercreditbalances.js +0 -54
  636. package/dist/sdk/models/shared/customerminified.d.ts +0 -5
  637. package/dist/sdk/models/shared/customerminified.js +0 -50
  638. package/dist/sdk/models/shared/customers.d.ts +0 -7
  639. package/dist/sdk/models/shared/customers.js +0 -54
  640. package/dist/sdk/models/shared/customertaxid.d.ts +0 -6
  641. package/dist/sdk/models/shared/customertaxid.js +0 -55
  642. package/dist/sdk/models/shared/debug.d.ts +0 -8
  643. package/dist/sdk/models/shared/debug.js +0 -53
  644. package/dist/sdk/models/shared/deletecustomerresponse.d.ts +0 -3
  645. package/dist/sdk/models/shared/deletecustomerresponse.js +0 -30
  646. package/dist/sdk/models/shared/deprecatedeventresult.d.ts +0 -7
  647. package/dist/sdk/models/shared/deprecatedeventresult.js +0 -45
  648. package/dist/sdk/models/shared/discount.d.ts +0 -33
  649. package/dist/sdk/models/shared/discount.js +0 -80
  650. package/dist/sdk/models/shared/editcustomer.d.ts +0 -72
  651. package/dist/sdk/models/shared/editcustomer.js +0 -151
  652. package/dist/sdk/models/shared/editplan.d.ts +0 -10
  653. package/dist/sdk/models/shared/editplan.js +0 -59
  654. package/dist/sdk/models/shared/editpriceintervalparams.d.ts +0 -20
  655. package/dist/sdk/models/shared/editpriceintervalparams.js +0 -62
  656. package/dist/sdk/models/shared/event.d.ts +0 -39
  657. package/dist/sdk/models/shared/event.js +0 -93
  658. package/dist/sdk/models/shared/events.d.ts +0 -7
  659. package/dist/sdk/models/shared/events.js +0 -54
  660. package/dist/sdk/models/shared/eventsearchcriteria.d.ts +0 -11
  661. package/dist/sdk/models/shared/eventsearchcriteria.js +0 -50
  662. package/dist/sdk/models/shared/fixedfeequantitychange.d.ts +0 -25
  663. package/dist/sdk/models/shared/fixedfeequantitychange.js +0 -75
  664. package/dist/sdk/models/shared/fixedfeequantityscheduleentry.d.ts +0 -7
  665. package/dist/sdk/models/shared/fixedfeequantityscheduleentry.js +0 -68
  666. package/dist/sdk/models/shared/fixedfeequantitytransition.d.ts +0 -6
  667. package/dist/sdk/models/shared/fixedfeequantitytransition.js +0 -59
  668. package/dist/sdk/models/shared/index.d.ts +0 -109
  669. package/dist/sdk/models/shared/index.js +0 -128
  670. package/dist/sdk/models/shared/ingestevent.d.ts +0 -32
  671. package/dist/sdk/models/shared/ingestevent.js +0 -86
  672. package/dist/sdk/models/shared/ingestionresponse.d.ts +0 -13
  673. package/dist/sdk/models/shared/ingestionresponse.js +0 -54
  674. package/dist/sdk/models/shared/ingestrequestbody.d.ts +0 -5
  675. package/dist/sdk/models/shared/ingestrequestbody.js +0 -47
  676. package/dist/sdk/models/shared/invoice.d.ts +0 -138
  677. package/dist/sdk/models/shared/invoice.js +0 -329
  678. package/dist/sdk/models/shared/invoicelineitem.d.ts +0 -49
  679. package/dist/sdk/models/shared/invoicelineitem.js +0 -134
  680. package/dist/sdk/models/shared/invoicelineitemparams.d.ts +0 -26
  681. package/dist/sdk/models/shared/invoicelineitemparams.js +0 -90
  682. package/dist/sdk/models/shared/invoiceminified.d.ts +0 -7
  683. package/dist/sdk/models/shared/invoiceminified.js +0 -45
  684. package/dist/sdk/models/shared/invoices.d.ts +0 -7
  685. package/dist/sdk/models/shared/invoices.js +0 -54
  686. package/dist/sdk/models/shared/item.d.ts +0 -14
  687. package/dist/sdk/models/shared/item.js +0 -72
  688. package/dist/sdk/models/shared/itemexternalconnection.d.ts +0 -5
  689. package/dist/sdk/models/shared/itemexternalconnection.js +0 -50
  690. package/dist/sdk/models/shared/items.d.ts +0 -7
  691. package/dist/sdk/models/shared/items.js +0 -54
  692. package/dist/sdk/models/shared/markaspaidrequestparams.d.ts +0 -16
  693. package/dist/sdk/models/shared/markaspaidrequestparams.js +0 -61
  694. package/dist/sdk/models/shared/maximum.d.ts +0 -11
  695. package/dist/sdk/models/shared/maximum.js +0 -50
  696. package/dist/sdk/models/shared/maximuminterval.d.ts +0 -23
  697. package/dist/sdk/models/shared/maximuminterval.js +0 -73
  698. package/dist/sdk/models/shared/minimum.d.ts +0 -11
  699. package/dist/sdk/models/shared/minimum.js +0 -50
  700. package/dist/sdk/models/shared/minimuminterval.d.ts +0 -23
  701. package/dist/sdk/models/shared/minimuminterval.js +0 -73
  702. package/dist/sdk/models/shared/newaccountingsyncconfiguration.d.ts +0 -6
  703. package/dist/sdk/models/shared/newaccountingsyncconfiguration.js +0 -52
  704. package/dist/sdk/models/shared/newbackfill.d.ts +0 -27
  705. package/dist/sdk/models/shared/newbackfill.js +0 -82
  706. package/dist/sdk/models/shared/newbillablemetric.d.ts +0 -28
  707. package/dist/sdk/models/shared/newbillablemetric.js +0 -77
  708. package/dist/sdk/models/shared/newcoupon.d.ts +0 -18
  709. package/dist/sdk/models/shared/newcoupon.js +0 -69
  710. package/dist/sdk/models/shared/newcustomer.d.ts +0 -68
  711. package/dist/sdk/models/shared/newcustomer.js +0 -152
  712. package/dist/sdk/models/shared/newcustomerbalancetransaction.d.ts +0 -13
  713. package/dist/sdk/models/shared/newcustomerbalancetransaction.js +0 -60
  714. package/dist/sdk/models/shared/newplan.d.ts +0 -26
  715. package/dist/sdk/models/shared/newplan.js +0 -93
  716. package/dist/sdk/models/shared/newreportingconfiguration.d.ts +0 -4
  717. package/dist/sdk/models/shared/newreportingconfiguration.js +0 -45
  718. package/dist/sdk/models/shared/newsubscription.d.ts +0 -54
  719. package/dist/sdk/models/shared/newsubscription.js +0 -187
  720. package/dist/sdk/models/shared/paginationmetadata.d.ts +0 -5
  721. package/dist/sdk/models/shared/paginationmetadata.js +0 -50
  722. package/dist/sdk/models/shared/perpricecost.d.ts +0 -224
  723. package/dist/sdk/models/shared/perpricecost.js +0 -67
  724. package/dist/sdk/models/shared/phaseoverride.d.ts +0 -17
  725. package/dist/sdk/models/shared/phaseoverride.js +0 -62
  726. package/dist/sdk/models/shared/pingresponse.d.ts +0 -4
  727. package/dist/sdk/models/shared/pingresponse.js +0 -45
  728. package/dist/sdk/models/shared/plan.d.ts +0 -66
  729. package/dist/sdk/models/shared/plan.js +0 -188
  730. package/dist/sdk/models/shared/planminified.d.ts +0 -9
  731. package/dist/sdk/models/shared/planminified.js +0 -55
  732. package/dist/sdk/models/shared/planphase.d.ts +0 -28
  733. package/dist/sdk/models/shared/planphase.js +0 -106
  734. package/dist/sdk/models/shared/plans.d.ts +0 -7
  735. package/dist/sdk/models/shared/plans.js +0 -54
  736. package/dist/sdk/models/shared/pricegroup.d.ts +0 -17
  737. package/dist/sdk/models/shared/pricegroup.js +0 -65
  738. package/dist/sdk/models/shared/priceinterval.d.ts +0 -239
  739. package/dist/sdk/models/shared/priceinterval.js +0 -104
  740. package/dist/sdk/models/shared/priceintervalfixedfeequantitytransitionparams.d.ts +0 -11
  741. package/dist/sdk/models/shared/priceintervalfixedfeequantitytransitionparams.js +0 -54
  742. package/dist/sdk/models/shared/prices.d.ts +0 -6
  743. package/dist/sdk/models/shared/prices.js +0 -52
  744. package/dist/sdk/models/shared/product.d.ts +0 -6
  745. package/dist/sdk/models/shared/product.js +0 -59
  746. package/dist/sdk/models/shared/reportingconfiguration.d.ts +0 -4
  747. package/dist/sdk/models/shared/reportingconfiguration.js +0 -45
  748. package/dist/sdk/models/shared/security.d.ts +0 -4
  749. package/dist/sdk/models/shared/security.js +0 -45
  750. package/dist/sdk/models/shared/subscription.d.ts +0 -128
  751. package/dist/sdk/models/shared/subscription.js +0 -226
  752. package/dist/sdk/models/shared/subscriptioncosts.d.ts +0 -5
  753. package/dist/sdk/models/shared/subscriptioncosts.js +0 -47
  754. package/dist/sdk/models/shared/subscriptionminified.d.ts +0 -4
  755. package/dist/sdk/models/shared/subscriptionminified.js +0 -45
  756. package/dist/sdk/models/shared/subscriptionplanchange.d.ts +0 -59
  757. package/dist/sdk/models/shared/subscriptionplanchange.js +0 -126
  758. package/dist/sdk/models/shared/subscriptions.d.ts +0 -7
  759. package/dist/sdk/models/shared/subscriptions.js +0 -54
  760. package/dist/sdk/models/shared/subscriptionscheduleitem.d.ts +0 -7
  761. package/dist/sdk/models/shared/subscriptionscheduleitem.js +0 -65
  762. package/dist/sdk/models/shared/subscriptionscheduleitems.d.ts +0 -7
  763. package/dist/sdk/models/shared/subscriptionscheduleitems.js +0 -54
  764. package/dist/sdk/models/shared/subscriptiontrialinfo.d.ts +0 -4
  765. package/dist/sdk/models/shared/subscriptiontrialinfo.js +0 -49
  766. package/dist/sdk/models/shared/taxamount.d.ts +0 -15
  767. package/dist/sdk/models/shared/taxamount.js +0 -55
  768. package/dist/sdk/models/shared/trialconfig.d.ts +0 -8
  769. package/dist/sdk/models/shared/trialconfig.js +0 -54
  770. package/dist/sdk/models/shared/triggersubscriptionphaseparams.d.ts +0 -8
  771. package/dist/sdk/models/shared/triggersubscriptionphaseparams.js +0 -51
  772. package/dist/sdk/models/shared/unschedulefixedfeequantitychangeparams.d.ts +0 -7
  773. package/dist/sdk/models/shared/unschedulefixedfeequantitychangeparams.js +0 -45
  774. package/dist/sdk/models/shared/upcominginvoice.d.ts +0 -130
  775. package/dist/sdk/models/shared/upcominginvoice.js +0 -321
  776. package/dist/sdk/models/shared/updateevent.d.ts +0 -28
  777. package/dist/sdk/models/shared/updateevent.js +0 -81
  778. package/dist/sdk/models/shared/validationerror.d.ts +0 -11
  779. package/dist/sdk/models/shared/validationerror.js +0 -50
  780. package/dist/sdk/plan.d.ts +0 -90
  781. package/dist/sdk/plan.js +0 -764
  782. package/dist/sdk/price.d.ts +0 -246
  783. package/dist/sdk/price.js +0 -715
  784. package/dist/sdk/priceinterval.d.ts +0 -66
  785. package/dist/sdk/priceinterval.js +0 -263
  786. package/dist/sdk/sdk.d.ts +0 -389
  787. package/dist/sdk/sdk.js +0 -93
  788. package/dist/sdk/subscription.d.ts +0 -769
  789. package/dist/sdk/subscription.js +0 -2116
  790. package/dist/sdk/types/index.d.ts +0 -1
  791. package/dist/sdk/types/index.js +0 -20
  792. package/dist/sdk/types/rfcdate.d.ts +0 -9
  793. package/dist/sdk/types/rfcdate.js +0 -59
  794. package/docs/models/errors/fivehundrederror.md +0 -12
  795. package/docs/models/errors/fivehundrederrorheaders.md +0 -7
  796. package/docs/models/errors/fourhundredandoneerror.md +0 -12
  797. package/docs/models/errors/fourhundredandoneerrorheaders.md +0 -7
  798. package/docs/models/errors/fourhundredandtwentynineerror.md +0 -12
  799. package/docs/models/errors/fourhundredandtwentynineerrorheaders.md +0 -7
  800. package/docs/models/operations/addeditpriceintervalsrequest.md +0 -9
  801. package/docs/models/operations/addeditpriceintervalsresponse.md +0 -11
  802. package/docs/models/operations/amendeventrequest.md +0 -9
  803. package/docs/models/operations/amendeventresponse.md +0 -11
  804. package/docs/models/operations/amendusageexternalcustomeridrequest.md +0 -11
  805. package/docs/models/operations/amendusageexternalcustomeridresponse.md +0 -11
  806. package/docs/models/operations/amendusagerequest.md +0 -11
  807. package/docs/models/operations/amendusageresponse.md +0 -11
  808. package/docs/models/operations/archivecouponrequest.md +0 -8
  809. package/docs/models/operations/archivecouponresponse.md +0 -11
  810. package/docs/models/operations/cancelsubscriptionrequest.md +0 -9
  811. package/docs/models/operations/cancelsubscriptionresponse.md +0 -11
  812. package/docs/models/operations/closebackfillrequest.md +0 -8
  813. package/docs/models/operations/closebackfillresponse.md +0 -11
  814. package/docs/models/operations/createbackfillresponse.md +0 -11
  815. package/docs/models/operations/createcouponresponse.md +0 -11
  816. package/docs/models/operations/createcustomerbalancetransactionrequest.md +0 -9
  817. package/docs/models/operations/createcustomerbalancetransactionresponse.md +0 -11
  818. package/docs/models/operations/createcustomerresponse.md +0 -11
  819. package/docs/models/operations/createinvoicelineitemresponse.md +0 -11
  820. package/docs/models/operations/createinvoiceresponse.md +0 -11
  821. package/docs/models/operations/createledgerentryexternalidrequest.md +0 -9
  822. package/docs/models/operations/createledgerentryexternalidresponse.md +0 -11
  823. package/docs/models/operations/createledgerentryrequest.md +0 -9
  824. package/docs/models/operations/createledgerentryresponse.md +0 -11
  825. package/docs/models/operations/createmetricresponse.md +0 -11
  826. package/docs/models/operations/createplanresponse.md +0 -11
  827. package/docs/models/operations/createpriceresponse.md +0 -11
  828. package/docs/models/operations/createsubscriptionresponse.md +0 -11
  829. package/docs/models/operations/deletecustomerrequest.md +0 -8
  830. package/docs/models/operations/deletecustomerresponse.md +0 -11
  831. package/docs/models/operations/deprecateeventrequest.md +0 -8
  832. package/docs/models/operations/deprecateeventresponse.md +0 -11
  833. package/docs/models/operations/fetchbackfillrequest.md +0 -8
  834. package/docs/models/operations/fetchbackfillresponse.md +0 -11
  835. package/docs/models/operations/fetchcouponrequest.md +0 -8
  836. package/docs/models/operations/fetchcouponresponse.md +0 -11
  837. package/docs/models/operations/fetchcreditnoterequest.md +0 -8
  838. package/docs/models/operations/fetchcreditnoteresponse.md +0 -11
  839. package/docs/models/operations/fetchcustomercostsexternalidrequest.md +0 -12
  840. package/docs/models/operations/fetchcustomercostsexternalidresponse.md +0 -11
  841. package/docs/models/operations/fetchcustomercostsexternalidviewmodeviewmode.md +0 -11
  842. package/docs/models/operations/fetchcustomercostsrequest.md +0 -12
  843. package/docs/models/operations/fetchcustomercostsresponse.md +0 -11
  844. package/docs/models/operations/fetchcustomercostsviewmodeviewmode.md +0 -11
  845. package/docs/models/operations/fetchcustomercreditsexternalidrequest.md +0 -10
  846. package/docs/models/operations/fetchcustomercreditsexternalidresponse.md +0 -11
  847. package/docs/models/operations/fetchcustomercreditsledgerentrystatusentrystatus.md +0 -9
  848. package/docs/models/operations/fetchcustomercreditsledgerentrytypeentrytype.md +0 -14
  849. package/docs/models/operations/fetchcustomercreditsledgerexternalidentrystatusentrystatus.md +0 -9
  850. package/docs/models/operations/fetchcustomercreditsledgerexternalidentrytypeentrytype.md +0 -14
  851. package/docs/models/operations/fetchcustomercreditsledgerexternalidrequest.md +0 -18
  852. package/docs/models/operations/fetchcustomercreditsledgerexternalidresponse.md +0 -11
  853. package/docs/models/operations/fetchcustomercreditsledgerrequest.md +0 -18
  854. package/docs/models/operations/fetchcustomercreditsledgerresponse.md +0 -11
  855. package/docs/models/operations/fetchcustomercreditsrequest.md +0 -10
  856. package/docs/models/operations/fetchcustomercreditsresponse.md +0 -11
  857. package/docs/models/operations/fetchcustomerexternalidrequest.md +0 -8
  858. package/docs/models/operations/fetchcustomerexternalidresponse.md +0 -11
  859. package/docs/models/operations/fetchcustomerrequest.md +0 -8
  860. package/docs/models/operations/fetchcustomerresponse.md +0 -11
  861. package/docs/models/operations/fetchinvoicerequest.md +0 -8
  862. package/docs/models/operations/fetchinvoiceresponse.md +0 -11
  863. package/docs/models/operations/fetchitemrequest.md +0 -8
  864. package/docs/models/operations/fetchitemresponse.md +0 -11
  865. package/docs/models/operations/fetchmetricrequest.md +0 -8
  866. package/docs/models/operations/fetchmetricresponse.md +0 -11
  867. package/docs/models/operations/fetchplanexternalidrequest.md +0 -8
  868. package/docs/models/operations/fetchplanexternalidresponse.md +0 -11
  869. package/docs/models/operations/fetchplanrequest.md +0 -8
  870. package/docs/models/operations/fetchplanresponse.md +0 -11
  871. package/docs/models/operations/fetchpriceexternalidrequest.md +0 -8
  872. package/docs/models/operations/fetchpriceexternalidresponse.md +0 -11
  873. package/docs/models/operations/fetchpricerequest.md +0 -8
  874. package/docs/models/operations/fetchpriceresponse.md +0 -11
  875. package/docs/models/operations/fetchsubscriptioncostsrequest.md +0 -12
  876. package/docs/models/operations/fetchsubscriptioncostsresponse.md +0 -11
  877. package/docs/models/operations/fetchsubscriptioncostsviewmodeviewmode.md +0 -11
  878. package/docs/models/operations/fetchsubscriptionrequest.md +0 -8
  879. package/docs/models/operations/fetchsubscriptionresponse.md +0 -11
  880. package/docs/models/operations/fetchsubscriptionschedulerequest.md +0 -14
  881. package/docs/models/operations/fetchsubscriptionscheduleresponse.md +0 -11
  882. package/docs/models/operations/fetchsubscriptionusagegranularitygranularity.md +0 -10
  883. package/docs/models/operations/fetchsubscriptionusagerequest.md +0 -20
  884. package/docs/models/operations/fetchsubscriptionusageresponse.md +0 -11
  885. package/docs/models/operations/fetchsubscriptionusageviewmodeviewmode.md +0 -11
  886. package/docs/models/operations/fetchupcominginvoicerequest.md +0 -8
  887. package/docs/models/operations/fetchupcominginvoiceresponse.md +0 -11
  888. package/docs/models/operations/ingestrequest.md +0 -10
  889. package/docs/models/operations/ingestresponse.md +0 -11
  890. package/docs/models/operations/issueinvoicerequest.md +0 -8
  891. package/docs/models/operations/issueinvoiceresponse.md +0 -11
  892. package/docs/models/operations/listbackfillsrequest.md +0 -9
  893. package/docs/models/operations/listbackfillsresponse.md +0 -11
  894. package/docs/models/operations/listbalancetransactionsrequest.md +0 -14
  895. package/docs/models/operations/listbalancetransactionsresponse.md +0 -11
  896. package/docs/models/operations/listcouponsrequest.md +0 -11
  897. package/docs/models/operations/listcouponsresponse.md +0 -11
  898. package/docs/models/operations/listcouponsubscriptionsrequest.md +0 -10
  899. package/docs/models/operations/listcouponsubscriptionsresponse.md +0 -11
  900. package/docs/models/operations/listcreditnotesrequest.md +0 -9
  901. package/docs/models/operations/listcreditnotesresponse.md +0 -11
  902. package/docs/models/operations/listcustomersrequest.md +0 -13
  903. package/docs/models/operations/listcustomersresponse.md +0 -11
  904. package/docs/models/operations/listinvoicesdatetypedatetype.md +0 -9
  905. package/docs/models/operations/listinvoicesrequest.md +0 -27
  906. package/docs/models/operations/listinvoicesresponse.md +0 -11
  907. package/docs/models/operations/listinvoicesstatus.md +0 -12
  908. package/docs/models/operations/listinvoicesstatusstatus.md +0 -12
  909. package/docs/models/operations/listitemsrequest.md +0 -9
  910. package/docs/models/operations/listitemsresponse.md +0 -11
  911. package/docs/models/operations/listmetricsrequest.md +0 -13
  912. package/docs/models/operations/listmetricsresponse.md +0 -11
  913. package/docs/models/operations/listplansrequest.md +0 -14
  914. package/docs/models/operations/listplansresponse.md +0 -11
  915. package/docs/models/operations/listplansstatusstatus.md +0 -12
  916. package/docs/models/operations/listpricesrequest.md +0 -9
  917. package/docs/models/operations/listpricesresponse.md +0 -11
  918. package/docs/models/operations/listsubscriptionsrequest.md +0 -16
  919. package/docs/models/operations/listsubscriptionsresponse.md +0 -11
  920. package/docs/models/operations/listsubscriptionsstatusstatus.md +0 -10
  921. package/docs/models/operations/markinvoiceaspaidrequest.md +0 -9
  922. package/docs/models/operations/markinvoiceaspaidresponse.md +0 -11
  923. package/docs/models/operations/pingresponse.md +0 -11
  924. package/docs/models/operations/revertbackfillrequest.md +0 -8
  925. package/docs/models/operations/revertbackfillresponse.md +0 -11
  926. package/docs/models/operations/scheduleplanchangerequest.md +0 -9
  927. package/docs/models/operations/scheduleplanchangeresponse.md +0 -11
  928. package/docs/models/operations/searcheventsrequest.md +0 -14
  929. package/docs/models/operations/searcheventsresponse.md +0 -11
  930. package/docs/models/operations/triggerphaserequest.md +0 -9
  931. package/docs/models/operations/triggerphaseresponse.md +0 -11
  932. package/docs/models/operations/unschedulecancellationrequest.md +0 -8
  933. package/docs/models/operations/unschedulecancellationresponse.md +0 -11
  934. package/docs/models/operations/unschedulefixedfeequantityrequest.md +0 -9
  935. package/docs/models/operations/unschedulefixedfeequantityresponse.md +0 -11
  936. package/docs/models/operations/unscheduleplanchangerequest.md +0 -8
  937. package/docs/models/operations/unscheduleplanchangeresponse.md +0 -11
  938. package/docs/models/operations/updatecustomerexternalidrequest.md +0 -9
  939. package/docs/models/operations/updatecustomerexternalidresponse.md +0 -11
  940. package/docs/models/operations/updatecustomerrequest.md +0 -9
  941. package/docs/models/operations/updatecustomerresponse.md +0 -11
  942. package/docs/models/operations/updatefixedfeequantityrequest.md +0 -9
  943. package/docs/models/operations/updatefixedfeequantityresponse.md +0 -11
  944. package/docs/models/operations/updateplanexternalrequest.md +0 -9
  945. package/docs/models/operations/updateplanexternalresponse.md +0 -11
  946. package/docs/models/operations/updateplanrequest.md +0 -9
  947. package/docs/models/operations/updateplanresponse.md +0 -11
  948. package/docs/models/operations/voidinvoicerequest.md +0 -8
  949. package/docs/models/operations/voidinvoiceresponse.md +0 -11
  950. package/docs/models/shared/accountingprovider.md +0 -9
  951. package/docs/models/shared/accountingproviderconfig.md +0 -9
  952. package/docs/models/shared/accountingproviderprovidertype.md +0 -9
  953. package/docs/models/shared/accountingsyncconfiguration.md +0 -9
  954. package/docs/models/shared/addeditpriceintervalparams.md +0 -9
  955. package/docs/models/shared/addpriceintervalparams.md +0 -16
  956. package/docs/models/shared/address.md +0 -13
  957. package/docs/models/shared/addressinput.md +0 -13
  958. package/docs/models/shared/aggregatedcost.md +0 -12
  959. package/docs/models/shared/amendedevent.md +0 -12
  960. package/docs/models/shared/amendedeventproperties.md +0 -9
  961. package/docs/models/shared/amendedusage.md +0 -9
  962. package/docs/models/shared/amendeventresult.md +0 -8
  963. package/docs/models/shared/autocollection.md +0 -10
  964. package/docs/models/shared/backfill.md +0 -17
  965. package/docs/models/shared/backfills.md +0 -9
  966. package/docs/models/shared/backfillstatus.md +0 -13
  967. package/docs/models/shared/billablemetric.md +0 -16
  968. package/docs/models/shared/billablemetrics.md +0 -9
  969. package/docs/models/shared/billablemetricstatus.md +0 -10
  970. package/docs/models/shared/billingcyclealignment.md +0 -12
  971. package/docs/models/shared/cancelsubscriptionparams.md +0 -9
  972. package/docs/models/shared/cancelsubscriptionparamscanceloption.md +0 -12
  973. package/docs/models/shared/changeoption.md +0 -10
  974. package/docs/models/shared/coupon.md +0 -21
  975. package/docs/models/shared/coupondiscount.md +0 -7
  976. package/docs/models/shared/couponredemption.md +0 -10
  977. package/docs/models/shared/coupons.md +0 -9
  978. package/docs/models/shared/createinvoicelineitemparams.md +0 -13
  979. package/docs/models/shared/createoneoffinvoiceparams.md +0 -15
  980. package/docs/models/shared/creditledgerentries.md +0 -9
  981. package/docs/models/shared/creditnote.md +0 -26
  982. package/docs/models/shared/creditnotediscounts.md +0 -7
  983. package/docs/models/shared/creditnotelineitem.md +0 -15
  984. package/docs/models/shared/creditnotelineitemdiscounts.md +0 -7
  985. package/docs/models/shared/creditnotelineitemtaxamounts.md +0 -7
  986. package/docs/models/shared/creditnotemaximumamountadjustment.md +0 -9
  987. package/docs/models/shared/creditnoteminified.md +0 -8
  988. package/docs/models/shared/creditnotereason.md +0 -11
  989. package/docs/models/shared/creditnotes.md +0 -9
  990. package/docs/models/shared/creditnotesublineitem.md +0 -10
  991. package/docs/models/shared/creditnotesummary.md +0 -13
  992. package/docs/models/shared/creditnotetype.md +0 -9
  993. package/docs/models/shared/customer.md +0 -42
  994. package/docs/models/shared/customerbalancetransaction.md +0 -17
  995. package/docs/models/shared/customerbalancetransactionaction.md +0 -10
  996. package/docs/models/shared/customerbalancetransactions.md +0 -9
  997. package/docs/models/shared/customerbalancetransactiontype.md +0 -9
  998. package/docs/models/shared/customercosts.md +0 -8
  999. package/docs/models/shared/customercreditbalance.md +0 -11
  1000. package/docs/models/shared/customercreditbalances.md +0 -9
  1001. package/docs/models/shared/customerminified.md +0 -9
  1002. package/docs/models/shared/customerpaymentprovider.md +0 -14
  1003. package/docs/models/shared/customers.md +0 -9
  1004. package/docs/models/shared/customertaxid.md +0 -10
  1005. package/docs/models/shared/debug.md +0 -11
  1006. package/docs/models/shared/deletecustomerresponse.md +0 -7
  1007. package/docs/models/shared/deprecatedeventresult.md +0 -8
  1008. package/docs/models/shared/discount.md +0 -15
  1009. package/docs/models/shared/discountdiscounttype.md +0 -11
  1010. package/docs/models/shared/editcustomer.md +0 -22
  1011. package/docs/models/shared/editcustomermetadata.md +0 -9
  1012. package/docs/models/shared/editcustomerpaymentprovider.md +0 -16
  1013. package/docs/models/shared/editplan.md +0 -9
  1014. package/docs/models/shared/editplanmetadata.md +0 -7
  1015. package/docs/models/shared/editpriceintervalparams.md +0 -11
  1016. package/docs/models/shared/event.md +0 -17
  1017. package/docs/models/shared/eventproperties.md +0 -9
  1018. package/docs/models/shared/events.md +0 -9
  1019. package/docs/models/shared/eventsearchcriteria.md +0 -9
  1020. package/docs/models/shared/fixedfeequantitychange.md +0 -11
  1021. package/docs/models/shared/fixedfeequantitychangechangeoption.md +0 -12
  1022. package/docs/models/shared/fixedfeequantityscheduleentry.md +0 -11
  1023. package/docs/models/shared/fixedfeequantitytransition.md +0 -10
  1024. package/docs/models/shared/ingestevent.md +0 -13
  1025. package/docs/models/shared/ingesteventproperties.md +0 -9
  1026. package/docs/models/shared/ingestionresponse.md +0 -9
  1027. package/docs/models/shared/ingestrequestbody.md +0 -8
  1028. package/docs/models/shared/invoice.md +0 -51
  1029. package/docs/models/shared/invoicelineitem.md +0 -23
  1030. package/docs/models/shared/invoicelineitemparams.md +0 -14
  1031. package/docs/models/shared/invoicelineitemparamsmodeltype.md +0 -8
  1032. package/docs/models/shared/invoicemetadata.md +0 -7
  1033. package/docs/models/shared/invoiceminified.md +0 -8
  1034. package/docs/models/shared/invoices.md +0 -9
  1035. package/docs/models/shared/invoicestatus.md +0 -12
  1036. package/docs/models/shared/item.md +0 -14
  1037. package/docs/models/shared/itemexternalconnection.md +0 -9
  1038. package/docs/models/shared/items.md +0 -9
  1039. package/docs/models/shared/markaspaidrequestparams.md +0 -10
  1040. package/docs/models/shared/maximum.md +0 -9
  1041. package/docs/models/shared/maximuminterval.md +0 -12
  1042. package/docs/models/shared/minimum.md +0 -9
  1043. package/docs/models/shared/minimuminterval.md +0 -12
  1044. package/docs/models/shared/newaccountingsyncconfiguration.md +0 -9
  1045. package/docs/models/shared/newbackfill.md +0 -13
  1046. package/docs/models/shared/newbillablemetric.md +0 -12
  1047. package/docs/models/shared/newbillablemetricmetadata.md +0 -9
  1048. package/docs/models/shared/newcoupon.md +0 -11
  1049. package/docs/models/shared/newcoupondiscount.md +0 -7
  1050. package/docs/models/shared/newcustomer.md +0 -23
  1051. package/docs/models/shared/newcustomerbalancetransaction.md +0 -10
  1052. package/docs/models/shared/newcustomerbalancetransactiontype.md +0 -9
  1053. package/docs/models/shared/newcustomermetadata.md +0 -9
  1054. package/docs/models/shared/newcustomerpaymentprovider.md +0 -14
  1055. package/docs/models/shared/newplan.md +0 -14
  1056. package/docs/models/shared/newplanmetadata.md +0 -7
  1057. package/docs/models/shared/newplanprices.md +0 -7
  1058. package/docs/models/shared/newreportingconfiguration.md +0 -8
  1059. package/docs/models/shared/newsubscription.md +0 -31
  1060. package/docs/models/shared/newsubscriptionexternalmarketplace.md +0 -10
  1061. package/docs/models/shared/newsubscriptionmetadata.md +0 -7
  1062. package/docs/models/shared/paginationmetadata.md +0 -9
  1063. package/docs/models/shared/perpricecost.md +0 -12
  1064. package/docs/models/shared/phaseoverride.md +0 -11
  1065. package/docs/models/shared/pingresponse.md +0 -8
  1066. package/docs/models/shared/plan.md +0 -33
  1067. package/docs/models/shared/planmetadata.md +0 -7
  1068. package/docs/models/shared/planminified.md +0 -10
  1069. package/docs/models/shared/planphase.md +0 -18
  1070. package/docs/models/shared/planphasedurationunit.md +0 -11
  1071. package/docs/models/shared/plans.md +0 -9
  1072. package/docs/models/shared/planstatus.md +0 -10
  1073. package/docs/models/shared/pricegroup.md +0 -12
  1074. package/docs/models/shared/priceinterval.md +0 -18
  1075. package/docs/models/shared/priceintervalfixedfeequantitytransitionparams.md +0 -9
  1076. package/docs/models/shared/prices.md +0 -9
  1077. package/docs/models/shared/product.md +0 -10
  1078. package/docs/models/shared/reportingconfiguration.md +0 -8
  1079. package/docs/models/shared/security.md +0 -8
  1080. package/docs/models/shared/subscription.md +0 -44
  1081. package/docs/models/shared/subscriptioncosts.md +0 -8
  1082. package/docs/models/shared/subscriptionmetadata.md +0 -9
  1083. package/docs/models/shared/subscriptionminified.md +0 -8
  1084. package/docs/models/shared/subscriptionplanchange.md +0 -23
  1085. package/docs/models/shared/subscriptions.md +0 -9
  1086. package/docs/models/shared/subscriptionscheduleitem.md +0 -10
  1087. package/docs/models/shared/subscriptionscheduleitems.md +0 -9
  1088. package/docs/models/shared/subscriptionstatus.md +0 -10
  1089. package/docs/models/shared/subscriptiontrialinfo.md +0 -8
  1090. package/docs/models/shared/taxamount.md +0 -10
  1091. package/docs/models/shared/trialconfig.md +0 -9
  1092. package/docs/models/shared/trialconfigtrialperiodunit.md +0 -8
  1093. package/docs/models/shared/triggersubscriptionphaseparams.md +0 -8
  1094. package/docs/models/shared/unschedulefixedfeequantitychangeparams.md +0 -8
  1095. package/docs/models/shared/upcominginvoice.md +0 -46
  1096. package/docs/models/shared/upcominginvoicemetadata.md +0 -7
  1097. package/docs/models/shared/upcominginvoicestatus.md +0 -12
  1098. package/docs/models/shared/updateevent.md +0 -12
  1099. package/docs/models/shared/updateeventproperties.md +0 -9
  1100. package/docs/models/shared/validationerror.md +0 -9
  1101. package/docs/sdks/availability/README.md +0 -46
  1102. package/docs/sdks/coupon/README.md +0 -235
  1103. package/docs/sdks/credit/README.md +0 -565
  1104. package/docs/sdks/creditnote/README.md +0 -94
  1105. package/docs/sdks/customer/README.md +0 -1080
  1106. package/docs/sdks/event/README.md +0 -674
  1107. package/docs/sdks/invoice/README.md +0 -388
  1108. package/docs/sdks/item/README.md +0 -92
  1109. package/docs/sdks/metric/README.md +0 -136
  1110. package/docs/sdks/orb/README.md +0 -21
  1111. package/docs/sdks/plan/README.md +0 -298
  1112. package/docs/sdks/price/README.md +0 -375
  1113. package/docs/sdks/priceinterval/README.md +0 -137
  1114. package/docs/sdks/subscription/README.md +0 -1306
  1115. package/docs/types/rfcdate.md +0 -11
@@ -0,0 +1,2254 @@
1
+ // File generated from our OpenAPI spec by Stainless.
2
+
3
+ import * as Core from "../../../core";
4
+ import { APIResource } from "../../../resource";
5
+ import { isRequestOptions } from "../../../core";
6
+ import * as LedgerAPI from "./ledger";
7
+ import { Page, type PageParams } from "../../../pagination";
8
+
9
+ export class Ledger extends APIResource {
10
+ /**
11
+ * The credits ledger provides _auditing_ functionality over Orb's credits system
12
+ * with a list of actions that have taken place to modify a customer's credit
13
+ * balance. This [paginated endpoint](../reference/pagination) lists these entries,
14
+ * starting from the most recent ledger entry.
15
+ *
16
+ * More details on using Orb's real-time credit feature are
17
+ * [here](../guides/product-catalog/prepurchase.md).
18
+ *
19
+ * There are four major types of modifications to credit balance, detailed below.
20
+ *
21
+ * ## Increment
22
+ *
23
+ * Credits (which optionally expire on a future date) can be added via the API
24
+ * ([Add Ledger Entry](create-ledger-entry)). The ledger entry for such an action
25
+ * will always contain the total eligible starting and ending balance for the
26
+ * customer at the time the entry was added to the ledger.
27
+ *
28
+ * ## Decrement
29
+ *
30
+ * Deductions can occur as a result of an API call to create a ledger entry (see
31
+ * [Add Ledger Entry](create-ledger-entry)), or automatically as a result of
32
+ * incurring usage. Both ledger entries present the `decrement` entry type.
33
+ *
34
+ * As usage for a customer is reported into Orb, credits may be deducted according
35
+ * to the customer's plan configuration. An automated deduction of this type will
36
+ * result in a ledger entry, also with a starting and ending balance. In order to
37
+ * provide better tracing capabilities for automatic deductions, Orb always
38
+ * associates each automatic deduction with the `event_id` at the time of
39
+ * ingestion, used to pinpoint _why_ credit deduction took place and to ensure that
40
+ * credits are never deducted without an associated usage event.
41
+ *
42
+ * By default, Orb uses an algorithm that automatically deducts from the _soonest
43
+ * expiring credit block_ first in order to ensure that all credits are utilized
44
+ * appropriately. As an example, if trial credits with an expiration date of 2
45
+ * weeks from now are present for a customer, they will be used before any
46
+ * deductions take place from a non-expiring credit block.
47
+ *
48
+ * If there are multiple blocks with the same expiration date, Orb will deduct from
49
+ * the block with the _lower cost basis_ first (ex. trial credits with a $0 cost
50
+ * basis before paid credits with a $5.00 cost basis).
51
+ *
52
+ * It's also possible for a single usage event's deduction to _span_ credit blocks.
53
+ * In this case, Orb will deduct from the next block, ending at the credit block
54
+ * which consists of unexpiring credits. Each of these deductions will lead to a
55
+ * _separate_ ledger entry, one per credit block that is deducted from. By default,
56
+ * the customer's total credit balance in Orb can be negative as a result of a
57
+ * decrement.
58
+ *
59
+ * ## Expiration change
60
+ *
61
+ * The expiry of credits can be changed as a result of the API (See
62
+ * [Add Ledger Entry](create-ledger-entry)). This will create a ledger entry that
63
+ * specifies the balance as well as the initial and target expiry dates.
64
+ *
65
+ * Note that for this entry type, `starting_balance` will equal `ending_balance`,
66
+ * and the `amount` represents the balance transferred. The credit block linked to
67
+ * the ledger entry is the source credit block from which there was an expiration
68
+ * change
69
+ *
70
+ * ## Credits expiry
71
+ *
72
+ * When a set of credits expire on pre-set expiration date, the customer's balance
73
+ * automatically reflects this change and adds an entry to the ledger indicating
74
+ * this event. Note that credit expiry should always happen close to a date
75
+ * boundary in the customer's timezone.
76
+ *
77
+ * ## Void initiated
78
+ *
79
+ * Credit blocks can be voided via the API. The `amount` on this entry corresponds
80
+ * to the number of credits that were remaining in the block at time of void.
81
+ * `void_reason` will be populated if the void is created with a reason.
82
+ *
83
+ * ## Void
84
+ *
85
+ * When a set of credits is voided, the customer's balance automatically reflects
86
+ * this change and adds an entry to the ledger indicating this event.
87
+ *
88
+ * ## Amendment
89
+ *
90
+ * When credits are added to a customer's balance as a result of a correction, this
91
+ * entry will be added to the ledger to indicate the adjustment of credits.
92
+ */
93
+ list(
94
+ customerId: string | null,
95
+ query?: LedgerListParams,
96
+ options?: Core.RequestOptions,
97
+ ): Core.PagePromise<LedgerListResponsesPage, LedgerListResponse>;
98
+ list(
99
+ customerId: string | null,
100
+ options?: Core.RequestOptions,
101
+ ): Core.PagePromise<LedgerListResponsesPage, LedgerListResponse>;
102
+ list(
103
+ customerId: string | null,
104
+ query: LedgerListParams | Core.RequestOptions = {},
105
+ options?: Core.RequestOptions,
106
+ ): Core.PagePromise<LedgerListResponsesPage, LedgerListResponse> {
107
+ if (isRequestOptions(query)) {
108
+ return this.list(customerId, {}, query);
109
+ }
110
+ return this.getAPIList(`/customers/${customerId}/credits/ledger`, LedgerListResponsesPage, {
111
+ query,
112
+ ...options,
113
+ });
114
+ }
115
+
116
+ /**
117
+ * This endpoint allows you to create a new ledger entry for a specified customer's
118
+ * balance. This can be used to increment balance, deduct credits, and change the
119
+ * expiry date of existing credits.
120
+ *
121
+ * ## Effects of adding a ledger entry
122
+ *
123
+ * 1. After calling this endpoint, [Fetch Credit Balance](fetch-customer-credits)
124
+ * will return a credit block that represents the changes (i.e. balance changes
125
+ * or transfers).
126
+ * 2. A ledger entry will be added to the credits ledger for this customer, and
127
+ * therefore returned in the [View Credits Ledger](fetch-customer-credits)
128
+ * response as well as serialized in the response to this request. In the case
129
+ * of deductions without a specified block, multiple ledger entries may be
130
+ * created if the deduction spans credit blocks.
131
+ * 3. If `invoice_settings` is specified, an invoice will be created that reflects
132
+ * the cost of the credits (based on `amount` and `per_unit_cost_basis`).
133
+ *
134
+ * ## Adding credits
135
+ *
136
+ * Adding credits is done by creating an entry of type `increment`. This requires
137
+ * the caller to specify a number of credits as well as an optional expiry date in
138
+ * `YYYY-MM-DD` format. Orb also recommends specifying a description to assist with
139
+ * auditing. When adding credits, the caller can also specify a cost basis
140
+ * per-credit, to indicate how much in USD a customer paid for a single credit in a
141
+ * block. This can later be used for revenue recognition.
142
+ *
143
+ * The following snippet illustrates a sample request body to increment credits
144
+ * which will expire in January of 2022.
145
+ *
146
+ * ```json
147
+ * {
148
+ * "entry_type": "increment",
149
+ * "amount": 100,
150
+ * "expiry_date": "2022-12-28",
151
+ * "per_unit_cost_basis": "0.20",
152
+ * "description": "Purchased 100 credits"
153
+ * }
154
+ * ```
155
+ *
156
+ * Note that by default, Orb will always first increment any _negative_ balance in
157
+ * existing blocks before adding the remaining amount to the desired credit block.
158
+ *
159
+ * ### Invoicing for credits
160
+ *
161
+ * By default, Orb manipulates the credit ledger but does not charge for credits.
162
+ * However, if you pass `invoice_settings` in the body of this request, Orb will
163
+ * also generate a one-off invoice for the customer for the credits pre-purchase.
164
+ * Note that you _must_ provide the `per_unit_cost_basis`, since the total charges
165
+ * on the invoice are calculated by multiplying the cost basis with the number of
166
+ * credit units added.
167
+ *
168
+ * ## Deducting Credits
169
+ *
170
+ * Orb allows you to deduct credits from a customer by creating an entry of type
171
+ * `decrement`. Orb matches the algorithm for automatic deductions for determining
172
+ * which credit blocks to decrement from. In the case that the deduction leads to
173
+ * multiple ledger entries, the response from this endpoint will be the final
174
+ * deduction. Orb also optionally allows specifying a description to assist with
175
+ * auditing.
176
+ *
177
+ * The following snippet illustrates a sample request body to decrement credits.
178
+ *
179
+ * ```json
180
+ * {
181
+ * "entry_type": "decrement",
182
+ * "amount": 20,
183
+ * "description": "Removing excess credits"
184
+ * }
185
+ * ```
186
+ *
187
+ * ## Changing credits expiry
188
+ *
189
+ * If you'd like to change when existing credits expire, you should create a ledger
190
+ * entry of type `expiration_change`. For this entry, the required parameter
191
+ * `expiry_date` identifies the _originating_ block, and the required parameter
192
+ * `target_expiry_date` identifies when the transferred credits should now expire.
193
+ * A new credit block will be created with expiry date `target_expiry_date`, with
194
+ * the same cost basis data as the original credit block, if present.
195
+ *
196
+ * Note that the balance of the block with the given `expiry_date` must be at least
197
+ * equal to the desired transfer amount determined by the `amount` parameter.
198
+ *
199
+ * The following snippet illustrates a sample request body to extend the expiration
200
+ * date of credits by one year:
201
+ *
202
+ * ```json
203
+ * {
204
+ * "entry_type": "expiration_change",
205
+ * "amount": 10,
206
+ * "expiry_date": "2022-12-28",
207
+ * "block_id": "UiUhFWeLHPrBY4Ad",
208
+ * "target_expiry_date": "2023-12-28",
209
+ * "description": "Extending credit validity"
210
+ * }
211
+ * ```
212
+ *
213
+ * ## Voiding credits
214
+ *
215
+ * If you'd like to void a credit block, create a ledger entry of type `void`. For
216
+ * this entry, `block_id` is required to identify the block, and `amount` indicates
217
+ * how many credits to void, up to the block's initial balance. Pass in a
218
+ * `void_reason` of `refund` if the void is due to a refund.
219
+ *
220
+ * ## Amendment
221
+ *
222
+ * If you'd like to undo a decrement on a credit block, create a ledger entry of
223
+ * type `amendment`. For this entry, `block_id` is required to identify the block
224
+ * that was originally decremented from, and `amount` indicates how many credits to
225
+ * return to the customer, up to the block's initial balance.
226
+ */
227
+ createEntry(
228
+ customerId: string | null,
229
+ body: LedgerCreateEntryParams,
230
+ options?: Core.RequestOptions,
231
+ ): Core.APIPromise<LedgerCreateEntryResponse> {
232
+ return this.post(`/customers/${customerId}/credits/ledger_entry`, { body, ...options });
233
+ }
234
+
235
+ /**
236
+ * This endpoint allows you to create a new ledger entry for a specified customer's
237
+ * balance. This can be used to increment balance, deduct credits, and change the
238
+ * expiry date of existing credits.
239
+ *
240
+ * ## Effects of adding a ledger entry
241
+ *
242
+ * 1. After calling this endpoint, [Fetch Credit Balance](fetch-customer-credits)
243
+ * will return a credit block that represents the changes (i.e. balance changes
244
+ * or transfers).
245
+ * 2. A ledger entry will be added to the credits ledger for this customer, and
246
+ * therefore returned in the [View Credits Ledger](fetch-customer-credits)
247
+ * response as well as serialized in the response to this request. In the case
248
+ * of deductions without a specified block, multiple ledger entries may be
249
+ * created if the deduction spans credit blocks.
250
+ * 3. If `invoice_settings` is specified, an invoice will be created that reflects
251
+ * the cost of the credits (based on `amount` and `per_unit_cost_basis`).
252
+ *
253
+ * ## Adding credits
254
+ *
255
+ * Adding credits is done by creating an entry of type `increment`. This requires
256
+ * the caller to specify a number of credits as well as an optional expiry date in
257
+ * `YYYY-MM-DD` format. Orb also recommends specifying a description to assist with
258
+ * auditing. When adding credits, the caller can also specify a cost basis
259
+ * per-credit, to indicate how much in USD a customer paid for a single credit in a
260
+ * block. This can later be used for revenue recognition.
261
+ *
262
+ * The following snippet illustrates a sample request body to increment credits
263
+ * which will expire in January of 2022.
264
+ *
265
+ * ```json
266
+ * {
267
+ * "entry_type": "increment",
268
+ * "amount": 100,
269
+ * "expiry_date": "2022-12-28",
270
+ * "per_unit_cost_basis": "0.20",
271
+ * "description": "Purchased 100 credits"
272
+ * }
273
+ * ```
274
+ *
275
+ * Note that by default, Orb will always first increment any _negative_ balance in
276
+ * existing blocks before adding the remaining amount to the desired credit block.
277
+ *
278
+ * ### Invoicing for credits
279
+ *
280
+ * By default, Orb manipulates the credit ledger but does not charge for credits.
281
+ * However, if you pass `invoice_settings` in the body of this request, Orb will
282
+ * also generate a one-off invoice for the customer for the credits pre-purchase.
283
+ * Note that you _must_ provide the `per_unit_cost_basis`, since the total charges
284
+ * on the invoice are calculated by multiplying the cost basis with the number of
285
+ * credit units added.
286
+ *
287
+ * ## Deducting Credits
288
+ *
289
+ * Orb allows you to deduct credits from a customer by creating an entry of type
290
+ * `decrement`. Orb matches the algorithm for automatic deductions for determining
291
+ * which credit blocks to decrement from. In the case that the deduction leads to
292
+ * multiple ledger entries, the response from this endpoint will be the final
293
+ * deduction. Orb also optionally allows specifying a description to assist with
294
+ * auditing.
295
+ *
296
+ * The following snippet illustrates a sample request body to decrement credits.
297
+ *
298
+ * ```json
299
+ * {
300
+ * "entry_type": "decrement",
301
+ * "amount": 20,
302
+ * "description": "Removing excess credits"
303
+ * }
304
+ * ```
305
+ *
306
+ * ## Changing credits expiry
307
+ *
308
+ * If you'd like to change when existing credits expire, you should create a ledger
309
+ * entry of type `expiration_change`. For this entry, the required parameter
310
+ * `expiry_date` identifies the _originating_ block, and the required parameter
311
+ * `target_expiry_date` identifies when the transferred credits should now expire.
312
+ * A new credit block will be created with expiry date `target_expiry_date`, with
313
+ * the same cost basis data as the original credit block, if present.
314
+ *
315
+ * Note that the balance of the block with the given `expiry_date` must be at least
316
+ * equal to the desired transfer amount determined by the `amount` parameter.
317
+ *
318
+ * The following snippet illustrates a sample request body to extend the expiration
319
+ * date of credits by one year:
320
+ *
321
+ * ```json
322
+ * {
323
+ * "entry_type": "expiration_change",
324
+ * "amount": 10,
325
+ * "expiry_date": "2022-12-28",
326
+ * "block_id": "UiUhFWeLHPrBY4Ad",
327
+ * "target_expiry_date": "2023-12-28",
328
+ * "description": "Extending credit validity"
329
+ * }
330
+ * ```
331
+ *
332
+ * ## Voiding credits
333
+ *
334
+ * If you'd like to void a credit block, create a ledger entry of type `void`. For
335
+ * this entry, `block_id` is required to identify the block, and `amount` indicates
336
+ * how many credits to void, up to the block's initial balance. Pass in a
337
+ * `void_reason` of `refund` if the void is due to a refund.
338
+ *
339
+ * ## Amendment
340
+ *
341
+ * If you'd like to undo a decrement on a credit block, create a ledger entry of
342
+ * type `amendment`. For this entry, `block_id` is required to identify the block
343
+ * that was originally decremented from, and `amount` indicates how many credits to
344
+ * return to the customer, up to the block's initial balance.
345
+ */
346
+ createEntryByExteralId(
347
+ externalCustomerId: string | null,
348
+ body: LedgerCreateEntryByExteralIDParams,
349
+ options?: Core.RequestOptions,
350
+ ): Core.APIPromise<LedgerCreateEntryByExteralIDResponse> {
351
+ return this.post(`/customers/external_customer_id/${externalCustomerId}/credits/ledger_entry`, {
352
+ body,
353
+ ...options,
354
+ });
355
+ }
356
+
357
+ /**
358
+ * The credits ledger provides _auditing_ functionality over Orb's credits system
359
+ * with a list of actions that have taken place to modify a customer's credit
360
+ * balance. This [paginated endpoint](../reference/pagination) lists these entries,
361
+ * starting from the most recent ledger entry.
362
+ *
363
+ * More details on using Orb's real-time credit feature are
364
+ * [here](../guides/product-catalog/prepurchase.md).
365
+ *
366
+ * There are four major types of modifications to credit balance, detailed below.
367
+ *
368
+ * ## Increment
369
+ *
370
+ * Credits (which optionally expire on a future date) can be added via the API
371
+ * ([Add Ledger Entry](create-ledger-entry)). The ledger entry for such an action
372
+ * will always contain the total eligible starting and ending balance for the
373
+ * customer at the time the entry was added to the ledger.
374
+ *
375
+ * ## Decrement
376
+ *
377
+ * Deductions can occur as a result of an API call to create a ledger entry (see
378
+ * [Add Ledger Entry](create-ledger-entry)), or automatically as a result of
379
+ * incurring usage. Both ledger entries present the `decrement` entry type.
380
+ *
381
+ * As usage for a customer is reported into Orb, credits may be deducted according
382
+ * to the customer's plan configuration. An automated deduction of this type will
383
+ * result in a ledger entry, also with a starting and ending balance. In order to
384
+ * provide better tracing capabilities for automatic deductions, Orb always
385
+ * associates each automatic deduction with the `event_id` at the time of
386
+ * ingestion, used to pinpoint _why_ credit deduction took place and to ensure that
387
+ * credits are never deducted without an associated usage event.
388
+ *
389
+ * By default, Orb uses an algorithm that automatically deducts from the _soonest
390
+ * expiring credit block_ first in order to ensure that all credits are utilized
391
+ * appropriately. As an example, if trial credits with an expiration date of 2
392
+ * weeks from now are present for a customer, they will be used before any
393
+ * deductions take place from a non-expiring credit block.
394
+ *
395
+ * If there are multiple blocks with the same expiration date, Orb will deduct from
396
+ * the block with the _lower cost basis_ first (ex. trial credits with a $0 cost
397
+ * basis before paid credits with a $5.00 cost basis).
398
+ *
399
+ * It's also possible for a single usage event's deduction to _span_ credit blocks.
400
+ * In this case, Orb will deduct from the next block, ending at the credit block
401
+ * which consists of unexpiring credits. Each of these deductions will lead to a
402
+ * _separate_ ledger entry, one per credit block that is deducted from. By default,
403
+ * the customer's total credit balance in Orb can be negative as a result of a
404
+ * decrement.
405
+ *
406
+ * ## Expiration change
407
+ *
408
+ * The expiry of credits can be changed as a result of the API (See
409
+ * [Add Ledger Entry](create-ledger-entry)). This will create a ledger entry that
410
+ * specifies the balance as well as the initial and target expiry dates.
411
+ *
412
+ * Note that for this entry type, `starting_balance` will equal `ending_balance`,
413
+ * and the `amount` represents the balance transferred. The credit block linked to
414
+ * the ledger entry is the source credit block from which there was an expiration
415
+ * change
416
+ *
417
+ * ## Credits expiry
418
+ *
419
+ * When a set of credits expire on pre-set expiration date, the customer's balance
420
+ * automatically reflects this change and adds an entry to the ledger indicating
421
+ * this event. Note that credit expiry should always happen close to a date
422
+ * boundary in the customer's timezone.
423
+ *
424
+ * ## Void initiated
425
+ *
426
+ * Credit blocks can be voided via the API. The `amount` on this entry corresponds
427
+ * to the number of credits that were remaining in the block at time of void.
428
+ * `void_reason` will be populated if the void is created with a reason.
429
+ *
430
+ * ## Void
431
+ *
432
+ * When a set of credits is voided, the customer's balance automatically reflects
433
+ * this change and adds an entry to the ledger indicating this event.
434
+ *
435
+ * ## Amendment
436
+ *
437
+ * When credits are added to a customer's balance as a result of a correction, this
438
+ * entry will be added to the ledger to indicate the adjustment of credits.
439
+ */
440
+ listByExternalId(
441
+ externalCustomerId: string | null,
442
+ query?: LedgerListByExternalIDParams,
443
+ options?: Core.RequestOptions,
444
+ ): Core.PagePromise<LedgerListByExternalIDResponsesPage, LedgerListByExternalIDResponse>;
445
+ listByExternalId(
446
+ externalCustomerId: string | null,
447
+ options?: Core.RequestOptions,
448
+ ): Core.PagePromise<LedgerListByExternalIDResponsesPage, LedgerListByExternalIDResponse>;
449
+ listByExternalId(
450
+ externalCustomerId: string | null,
451
+ query: LedgerListByExternalIDParams | Core.RequestOptions = {},
452
+ options?: Core.RequestOptions,
453
+ ): Core.PagePromise<LedgerListByExternalIDResponsesPage, LedgerListByExternalIDResponse> {
454
+ if (isRequestOptions(query)) {
455
+ return this.listByExternalId(externalCustomerId, {}, query);
456
+ }
457
+ return this.getAPIList(
458
+ `/customers/external_customer_id/${externalCustomerId}/credits/ledger`,
459
+ LedgerListByExternalIDResponsesPage,
460
+ { query, ...options },
461
+ );
462
+ }
463
+ }
464
+
465
+ export class LedgerListResponsesPage extends Page<LedgerListResponse> {}
466
+
467
+ export class LedgerListByExternalIDResponsesPage extends Page<LedgerListByExternalIDResponse> {}
468
+
469
+ /**
470
+ * The [Credit Ledger Entry resource](/guides/product-catalog/prepurchase) models
471
+ * prepaid credits within Orb.
472
+ */
473
+ export type LedgerListResponse =
474
+ | LedgerListResponse.IncrementLedgerEntry
475
+ | LedgerListResponse.DecrementLedgerEntry
476
+ | LedgerListResponse.ExpirationChangeLedgerEntry
477
+ | LedgerListResponse.CreditBlockExpiryLedgerEntry
478
+ | LedgerListResponse.VoidLedgerEntry
479
+ | LedgerListResponse.VoidInitiatedLedgerEntry
480
+ | LedgerListResponse.AmendmentLedgerEntry;
481
+
482
+ export namespace LedgerListResponse {
483
+ export interface IncrementLedgerEntry {
484
+ id: string;
485
+
486
+ amount: number;
487
+
488
+ created_at: string;
489
+
490
+ credit_block: IncrementLedgerEntry.CreditBlock;
491
+
492
+ customer: IncrementLedgerEntry.Customer;
493
+
494
+ description: string | null;
495
+
496
+ ending_balance: number;
497
+
498
+ entry_status: 'committed' | 'pending';
499
+
500
+ entry_type: 'increment';
501
+
502
+ ledger_sequence_number: number;
503
+
504
+ metadata: Record<string, string>;
505
+
506
+ starting_balance: number;
507
+ }
508
+
509
+ export namespace IncrementLedgerEntry {
510
+ export interface CreditBlock {
511
+ id: string;
512
+
513
+ expiry_date: string | null;
514
+
515
+ per_unit_cost_basis: string | null;
516
+ }
517
+
518
+ export interface Customer {
519
+ id: string;
520
+
521
+ external_customer_id: string | null;
522
+ }
523
+ }
524
+
525
+ export interface DecrementLedgerEntry {
526
+ id: string;
527
+
528
+ amount: number;
529
+
530
+ created_at: string;
531
+
532
+ credit_block: DecrementLedgerEntry.CreditBlock;
533
+
534
+ customer: DecrementLedgerEntry.Customer;
535
+
536
+ description: string | null;
537
+
538
+ ending_balance: number;
539
+
540
+ entry_status: 'committed' | 'pending';
541
+
542
+ entry_type: 'decrement';
543
+
544
+ ledger_sequence_number: number;
545
+
546
+ metadata: Record<string, string>;
547
+
548
+ starting_balance: number;
549
+
550
+ event_id?: string | null;
551
+
552
+ invoice_id?: string | null;
553
+
554
+ price_id?: string | null;
555
+ }
556
+
557
+ export namespace DecrementLedgerEntry {
558
+ export interface CreditBlock {
559
+ id: string;
560
+
561
+ expiry_date: string | null;
562
+
563
+ per_unit_cost_basis: string | null;
564
+ }
565
+
566
+ export interface Customer {
567
+ id: string;
568
+
569
+ external_customer_id: string | null;
570
+ }
571
+ }
572
+
573
+ export interface ExpirationChangeLedgerEntry {
574
+ id: string;
575
+
576
+ amount: number;
577
+
578
+ created_at: string;
579
+
580
+ credit_block: ExpirationChangeLedgerEntry.CreditBlock;
581
+
582
+ customer: ExpirationChangeLedgerEntry.Customer;
583
+
584
+ description: string | null;
585
+
586
+ ending_balance: number;
587
+
588
+ entry_status: 'committed' | 'pending';
589
+
590
+ entry_type: 'expiration_change';
591
+
592
+ ledger_sequence_number: number;
593
+
594
+ metadata: Record<string, string>;
595
+
596
+ new_block_expiry_date: string;
597
+
598
+ starting_balance: number;
599
+ }
600
+
601
+ export namespace ExpirationChangeLedgerEntry {
602
+ export interface CreditBlock {
603
+ id: string;
604
+
605
+ expiry_date: string | null;
606
+
607
+ per_unit_cost_basis: string | null;
608
+ }
609
+
610
+ export interface Customer {
611
+ id: string;
612
+
613
+ external_customer_id: string | null;
614
+ }
615
+ }
616
+
617
+ export interface CreditBlockExpiryLedgerEntry {
618
+ id: string;
619
+
620
+ amount: number;
621
+
622
+ created_at: string;
623
+
624
+ credit_block: CreditBlockExpiryLedgerEntry.CreditBlock;
625
+
626
+ customer: CreditBlockExpiryLedgerEntry.Customer;
627
+
628
+ description: string | null;
629
+
630
+ ending_balance: number;
631
+
632
+ entry_status: 'committed' | 'pending';
633
+
634
+ entry_type: 'credit_block_expiry';
635
+
636
+ ledger_sequence_number: number;
637
+
638
+ metadata: Record<string, string>;
639
+
640
+ starting_balance: number;
641
+ }
642
+
643
+ export namespace CreditBlockExpiryLedgerEntry {
644
+ export interface CreditBlock {
645
+ id: string;
646
+
647
+ expiry_date: string | null;
648
+
649
+ per_unit_cost_basis: string | null;
650
+ }
651
+
652
+ export interface Customer {
653
+ id: string;
654
+
655
+ external_customer_id: string | null;
656
+ }
657
+ }
658
+
659
+ export interface VoidLedgerEntry {
660
+ id: string;
661
+
662
+ amount: number;
663
+
664
+ created_at: string;
665
+
666
+ credit_block: VoidLedgerEntry.CreditBlock;
667
+
668
+ customer: VoidLedgerEntry.Customer;
669
+
670
+ description: string | null;
671
+
672
+ ending_balance: number;
673
+
674
+ entry_status: 'committed' | 'pending';
675
+
676
+ entry_type: 'void';
677
+
678
+ ledger_sequence_number: number;
679
+
680
+ metadata: Record<string, string>;
681
+
682
+ starting_balance: number;
683
+
684
+ void_amount: number;
685
+
686
+ void_reason: string | null;
687
+ }
688
+
689
+ export namespace VoidLedgerEntry {
690
+ export interface CreditBlock {
691
+ id: string;
692
+
693
+ expiry_date: string | null;
694
+
695
+ per_unit_cost_basis: string | null;
696
+ }
697
+
698
+ export interface Customer {
699
+ id: string;
700
+
701
+ external_customer_id: string | null;
702
+ }
703
+ }
704
+
705
+ export interface VoidInitiatedLedgerEntry {
706
+ id: string;
707
+
708
+ amount: number;
709
+
710
+ created_at: string;
711
+
712
+ credit_block: VoidInitiatedLedgerEntry.CreditBlock;
713
+
714
+ customer: VoidInitiatedLedgerEntry.Customer;
715
+
716
+ description: string | null;
717
+
718
+ ending_balance: number;
719
+
720
+ entry_status: 'committed' | 'pending';
721
+
722
+ entry_type: 'void_initiated';
723
+
724
+ ledger_sequence_number: number;
725
+
726
+ metadata: Record<string, string>;
727
+
728
+ new_block_expiry_date: string;
729
+
730
+ starting_balance: number;
731
+
732
+ void_amount: number;
733
+
734
+ void_reason: string | null;
735
+ }
736
+
737
+ export namespace VoidInitiatedLedgerEntry {
738
+ export interface CreditBlock {
739
+ id: string;
740
+
741
+ expiry_date: string | null;
742
+
743
+ per_unit_cost_basis: string | null;
744
+ }
745
+
746
+ export interface Customer {
747
+ id: string;
748
+
749
+ external_customer_id: string | null;
750
+ }
751
+ }
752
+
753
+ export interface AmendmentLedgerEntry {
754
+ id: string;
755
+
756
+ amount: number;
757
+
758
+ created_at: string;
759
+
760
+ credit_block: AmendmentLedgerEntry.CreditBlock;
761
+
762
+ customer: AmendmentLedgerEntry.Customer;
763
+
764
+ description: string | null;
765
+
766
+ ending_balance: number;
767
+
768
+ entry_status: 'committed' | 'pending';
769
+
770
+ entry_type: 'amendment';
771
+
772
+ ledger_sequence_number: number;
773
+
774
+ metadata: Record<string, string>;
775
+
776
+ starting_balance: number;
777
+ }
778
+
779
+ export namespace AmendmentLedgerEntry {
780
+ export interface CreditBlock {
781
+ id: string;
782
+
783
+ expiry_date: string | null;
784
+
785
+ per_unit_cost_basis: string | null;
786
+ }
787
+
788
+ export interface Customer {
789
+ id: string;
790
+
791
+ external_customer_id: string | null;
792
+ }
793
+ }
794
+ }
795
+
796
+ /**
797
+ * The [Credit Ledger Entry resource](/guides/product-catalog/prepurchase) models
798
+ * prepaid credits within Orb.
799
+ */
800
+ export type LedgerCreateEntryResponse =
801
+ | LedgerCreateEntryResponse.IncrementLedgerEntry
802
+ | LedgerCreateEntryResponse.DecrementLedgerEntry
803
+ | LedgerCreateEntryResponse.ExpirationChangeLedgerEntry
804
+ | LedgerCreateEntryResponse.CreditBlockExpiryLedgerEntry
805
+ | LedgerCreateEntryResponse.VoidLedgerEntry
806
+ | LedgerCreateEntryResponse.VoidInitiatedLedgerEntry
807
+ | LedgerCreateEntryResponse.AmendmentLedgerEntry;
808
+
809
+ export namespace LedgerCreateEntryResponse {
810
+ export interface IncrementLedgerEntry {
811
+ id: string;
812
+
813
+ amount: number;
814
+
815
+ created_at: string;
816
+
817
+ credit_block: IncrementLedgerEntry.CreditBlock;
818
+
819
+ customer: IncrementLedgerEntry.Customer;
820
+
821
+ description: string | null;
822
+
823
+ ending_balance: number;
824
+
825
+ entry_status: 'committed' | 'pending';
826
+
827
+ entry_type: 'increment';
828
+
829
+ ledger_sequence_number: number;
830
+
831
+ metadata: Record<string, string>;
832
+
833
+ starting_balance: number;
834
+ }
835
+
836
+ export namespace IncrementLedgerEntry {
837
+ export interface CreditBlock {
838
+ id: string;
839
+
840
+ expiry_date: string | null;
841
+
842
+ per_unit_cost_basis: string | null;
843
+ }
844
+
845
+ export interface Customer {
846
+ id: string;
847
+
848
+ external_customer_id: string | null;
849
+ }
850
+ }
851
+
852
+ export interface DecrementLedgerEntry {
853
+ id: string;
854
+
855
+ amount: number;
856
+
857
+ created_at: string;
858
+
859
+ credit_block: DecrementLedgerEntry.CreditBlock;
860
+
861
+ customer: DecrementLedgerEntry.Customer;
862
+
863
+ description: string | null;
864
+
865
+ ending_balance: number;
866
+
867
+ entry_status: 'committed' | 'pending';
868
+
869
+ entry_type: 'decrement';
870
+
871
+ ledger_sequence_number: number;
872
+
873
+ metadata: Record<string, string>;
874
+
875
+ starting_balance: number;
876
+
877
+ event_id?: string | null;
878
+
879
+ invoice_id?: string | null;
880
+
881
+ price_id?: string | null;
882
+ }
883
+
884
+ export namespace DecrementLedgerEntry {
885
+ export interface CreditBlock {
886
+ id: string;
887
+
888
+ expiry_date: string | null;
889
+
890
+ per_unit_cost_basis: string | null;
891
+ }
892
+
893
+ export interface Customer {
894
+ id: string;
895
+
896
+ external_customer_id: string | null;
897
+ }
898
+ }
899
+
900
+ export interface ExpirationChangeLedgerEntry {
901
+ id: string;
902
+
903
+ amount: number;
904
+
905
+ created_at: string;
906
+
907
+ credit_block: ExpirationChangeLedgerEntry.CreditBlock;
908
+
909
+ customer: ExpirationChangeLedgerEntry.Customer;
910
+
911
+ description: string | null;
912
+
913
+ ending_balance: number;
914
+
915
+ entry_status: 'committed' | 'pending';
916
+
917
+ entry_type: 'expiration_change';
918
+
919
+ ledger_sequence_number: number;
920
+
921
+ metadata: Record<string, string>;
922
+
923
+ new_block_expiry_date: string;
924
+
925
+ starting_balance: number;
926
+ }
927
+
928
+ export namespace ExpirationChangeLedgerEntry {
929
+ export interface CreditBlock {
930
+ id: string;
931
+
932
+ expiry_date: string | null;
933
+
934
+ per_unit_cost_basis: string | null;
935
+ }
936
+
937
+ export interface Customer {
938
+ id: string;
939
+
940
+ external_customer_id: string | null;
941
+ }
942
+ }
943
+
944
+ export interface CreditBlockExpiryLedgerEntry {
945
+ id: string;
946
+
947
+ amount: number;
948
+
949
+ created_at: string;
950
+
951
+ credit_block: CreditBlockExpiryLedgerEntry.CreditBlock;
952
+
953
+ customer: CreditBlockExpiryLedgerEntry.Customer;
954
+
955
+ description: string | null;
956
+
957
+ ending_balance: number;
958
+
959
+ entry_status: 'committed' | 'pending';
960
+
961
+ entry_type: 'credit_block_expiry';
962
+
963
+ ledger_sequence_number: number;
964
+
965
+ metadata: Record<string, string>;
966
+
967
+ starting_balance: number;
968
+ }
969
+
970
+ export namespace CreditBlockExpiryLedgerEntry {
971
+ export interface CreditBlock {
972
+ id: string;
973
+
974
+ expiry_date: string | null;
975
+
976
+ per_unit_cost_basis: string | null;
977
+ }
978
+
979
+ export interface Customer {
980
+ id: string;
981
+
982
+ external_customer_id: string | null;
983
+ }
984
+ }
985
+
986
+ export interface VoidLedgerEntry {
987
+ id: string;
988
+
989
+ amount: number;
990
+
991
+ created_at: string;
992
+
993
+ credit_block: VoidLedgerEntry.CreditBlock;
994
+
995
+ customer: VoidLedgerEntry.Customer;
996
+
997
+ description: string | null;
998
+
999
+ ending_balance: number;
1000
+
1001
+ entry_status: 'committed' | 'pending';
1002
+
1003
+ entry_type: 'void';
1004
+
1005
+ ledger_sequence_number: number;
1006
+
1007
+ metadata: Record<string, string>;
1008
+
1009
+ starting_balance: number;
1010
+
1011
+ void_amount: number;
1012
+
1013
+ void_reason: string | null;
1014
+ }
1015
+
1016
+ export namespace VoidLedgerEntry {
1017
+ export interface CreditBlock {
1018
+ id: string;
1019
+
1020
+ expiry_date: string | null;
1021
+
1022
+ per_unit_cost_basis: string | null;
1023
+ }
1024
+
1025
+ export interface Customer {
1026
+ id: string;
1027
+
1028
+ external_customer_id: string | null;
1029
+ }
1030
+ }
1031
+
1032
+ export interface VoidInitiatedLedgerEntry {
1033
+ id: string;
1034
+
1035
+ amount: number;
1036
+
1037
+ created_at: string;
1038
+
1039
+ credit_block: VoidInitiatedLedgerEntry.CreditBlock;
1040
+
1041
+ customer: VoidInitiatedLedgerEntry.Customer;
1042
+
1043
+ description: string | null;
1044
+
1045
+ ending_balance: number;
1046
+
1047
+ entry_status: 'committed' | 'pending';
1048
+
1049
+ entry_type: 'void_initiated';
1050
+
1051
+ ledger_sequence_number: number;
1052
+
1053
+ metadata: Record<string, string>;
1054
+
1055
+ new_block_expiry_date: string;
1056
+
1057
+ starting_balance: number;
1058
+
1059
+ void_amount: number;
1060
+
1061
+ void_reason: string | null;
1062
+ }
1063
+
1064
+ export namespace VoidInitiatedLedgerEntry {
1065
+ export interface CreditBlock {
1066
+ id: string;
1067
+
1068
+ expiry_date: string | null;
1069
+
1070
+ per_unit_cost_basis: string | null;
1071
+ }
1072
+
1073
+ export interface Customer {
1074
+ id: string;
1075
+
1076
+ external_customer_id: string | null;
1077
+ }
1078
+ }
1079
+
1080
+ export interface AmendmentLedgerEntry {
1081
+ id: string;
1082
+
1083
+ amount: number;
1084
+
1085
+ created_at: string;
1086
+
1087
+ credit_block: AmendmentLedgerEntry.CreditBlock;
1088
+
1089
+ customer: AmendmentLedgerEntry.Customer;
1090
+
1091
+ description: string | null;
1092
+
1093
+ ending_balance: number;
1094
+
1095
+ entry_status: 'committed' | 'pending';
1096
+
1097
+ entry_type: 'amendment';
1098
+
1099
+ ledger_sequence_number: number;
1100
+
1101
+ metadata: Record<string, string>;
1102
+
1103
+ starting_balance: number;
1104
+ }
1105
+
1106
+ export namespace AmendmentLedgerEntry {
1107
+ export interface CreditBlock {
1108
+ id: string;
1109
+
1110
+ expiry_date: string | null;
1111
+
1112
+ per_unit_cost_basis: string | null;
1113
+ }
1114
+
1115
+ export interface Customer {
1116
+ id: string;
1117
+
1118
+ external_customer_id: string | null;
1119
+ }
1120
+ }
1121
+ }
1122
+
1123
+ /**
1124
+ * The [Credit Ledger Entry resource](/guides/product-catalog/prepurchase) models
1125
+ * prepaid credits within Orb.
1126
+ */
1127
+ export type LedgerCreateEntryByExteralIDResponse =
1128
+ | LedgerCreateEntryByExteralIDResponse.IncrementLedgerEntry
1129
+ | LedgerCreateEntryByExteralIDResponse.DecrementLedgerEntry
1130
+ | LedgerCreateEntryByExteralIDResponse.ExpirationChangeLedgerEntry
1131
+ | LedgerCreateEntryByExteralIDResponse.CreditBlockExpiryLedgerEntry
1132
+ | LedgerCreateEntryByExteralIDResponse.VoidLedgerEntry
1133
+ | LedgerCreateEntryByExteralIDResponse.VoidInitiatedLedgerEntry
1134
+ | LedgerCreateEntryByExteralIDResponse.AmendmentLedgerEntry;
1135
+
1136
+ export namespace LedgerCreateEntryByExteralIDResponse {
1137
+ export interface IncrementLedgerEntry {
1138
+ id: string;
1139
+
1140
+ amount: number;
1141
+
1142
+ created_at: string;
1143
+
1144
+ credit_block: IncrementLedgerEntry.CreditBlock;
1145
+
1146
+ customer: IncrementLedgerEntry.Customer;
1147
+
1148
+ description: string | null;
1149
+
1150
+ ending_balance: number;
1151
+
1152
+ entry_status: 'committed' | 'pending';
1153
+
1154
+ entry_type: 'increment';
1155
+
1156
+ ledger_sequence_number: number;
1157
+
1158
+ metadata: Record<string, string>;
1159
+
1160
+ starting_balance: number;
1161
+ }
1162
+
1163
+ export namespace IncrementLedgerEntry {
1164
+ export interface CreditBlock {
1165
+ id: string;
1166
+
1167
+ expiry_date: string | null;
1168
+
1169
+ per_unit_cost_basis: string | null;
1170
+ }
1171
+
1172
+ export interface Customer {
1173
+ id: string;
1174
+
1175
+ external_customer_id: string | null;
1176
+ }
1177
+ }
1178
+
1179
+ export interface DecrementLedgerEntry {
1180
+ id: string;
1181
+
1182
+ amount: number;
1183
+
1184
+ created_at: string;
1185
+
1186
+ credit_block: DecrementLedgerEntry.CreditBlock;
1187
+
1188
+ customer: DecrementLedgerEntry.Customer;
1189
+
1190
+ description: string | null;
1191
+
1192
+ ending_balance: number;
1193
+
1194
+ entry_status: 'committed' | 'pending';
1195
+
1196
+ entry_type: 'decrement';
1197
+
1198
+ ledger_sequence_number: number;
1199
+
1200
+ metadata: Record<string, string>;
1201
+
1202
+ starting_balance: number;
1203
+
1204
+ event_id?: string | null;
1205
+
1206
+ invoice_id?: string | null;
1207
+
1208
+ price_id?: string | null;
1209
+ }
1210
+
1211
+ export namespace DecrementLedgerEntry {
1212
+ export interface CreditBlock {
1213
+ id: string;
1214
+
1215
+ expiry_date: string | null;
1216
+
1217
+ per_unit_cost_basis: string | null;
1218
+ }
1219
+
1220
+ export interface Customer {
1221
+ id: string;
1222
+
1223
+ external_customer_id: string | null;
1224
+ }
1225
+ }
1226
+
1227
+ export interface ExpirationChangeLedgerEntry {
1228
+ id: string;
1229
+
1230
+ amount: number;
1231
+
1232
+ created_at: string;
1233
+
1234
+ credit_block: ExpirationChangeLedgerEntry.CreditBlock;
1235
+
1236
+ customer: ExpirationChangeLedgerEntry.Customer;
1237
+
1238
+ description: string | null;
1239
+
1240
+ ending_balance: number;
1241
+
1242
+ entry_status: 'committed' | 'pending';
1243
+
1244
+ entry_type: 'expiration_change';
1245
+
1246
+ ledger_sequence_number: number;
1247
+
1248
+ metadata: Record<string, string>;
1249
+
1250
+ new_block_expiry_date: string;
1251
+
1252
+ starting_balance: number;
1253
+ }
1254
+
1255
+ export namespace ExpirationChangeLedgerEntry {
1256
+ export interface CreditBlock {
1257
+ id: string;
1258
+
1259
+ expiry_date: string | null;
1260
+
1261
+ per_unit_cost_basis: string | null;
1262
+ }
1263
+
1264
+ export interface Customer {
1265
+ id: string;
1266
+
1267
+ external_customer_id: string | null;
1268
+ }
1269
+ }
1270
+
1271
+ export interface CreditBlockExpiryLedgerEntry {
1272
+ id: string;
1273
+
1274
+ amount: number;
1275
+
1276
+ created_at: string;
1277
+
1278
+ credit_block: CreditBlockExpiryLedgerEntry.CreditBlock;
1279
+
1280
+ customer: CreditBlockExpiryLedgerEntry.Customer;
1281
+
1282
+ description: string | null;
1283
+
1284
+ ending_balance: number;
1285
+
1286
+ entry_status: 'committed' | 'pending';
1287
+
1288
+ entry_type: 'credit_block_expiry';
1289
+
1290
+ ledger_sequence_number: number;
1291
+
1292
+ metadata: Record<string, string>;
1293
+
1294
+ starting_balance: number;
1295
+ }
1296
+
1297
+ export namespace CreditBlockExpiryLedgerEntry {
1298
+ export interface CreditBlock {
1299
+ id: string;
1300
+
1301
+ expiry_date: string | null;
1302
+
1303
+ per_unit_cost_basis: string | null;
1304
+ }
1305
+
1306
+ export interface Customer {
1307
+ id: string;
1308
+
1309
+ external_customer_id: string | null;
1310
+ }
1311
+ }
1312
+
1313
+ export interface VoidLedgerEntry {
1314
+ id: string;
1315
+
1316
+ amount: number;
1317
+
1318
+ created_at: string;
1319
+
1320
+ credit_block: VoidLedgerEntry.CreditBlock;
1321
+
1322
+ customer: VoidLedgerEntry.Customer;
1323
+
1324
+ description: string | null;
1325
+
1326
+ ending_balance: number;
1327
+
1328
+ entry_status: 'committed' | 'pending';
1329
+
1330
+ entry_type: 'void';
1331
+
1332
+ ledger_sequence_number: number;
1333
+
1334
+ metadata: Record<string, string>;
1335
+
1336
+ starting_balance: number;
1337
+
1338
+ void_amount: number;
1339
+
1340
+ void_reason: string | null;
1341
+ }
1342
+
1343
+ export namespace VoidLedgerEntry {
1344
+ export interface CreditBlock {
1345
+ id: string;
1346
+
1347
+ expiry_date: string | null;
1348
+
1349
+ per_unit_cost_basis: string | null;
1350
+ }
1351
+
1352
+ export interface Customer {
1353
+ id: string;
1354
+
1355
+ external_customer_id: string | null;
1356
+ }
1357
+ }
1358
+
1359
+ export interface VoidInitiatedLedgerEntry {
1360
+ id: string;
1361
+
1362
+ amount: number;
1363
+
1364
+ created_at: string;
1365
+
1366
+ credit_block: VoidInitiatedLedgerEntry.CreditBlock;
1367
+
1368
+ customer: VoidInitiatedLedgerEntry.Customer;
1369
+
1370
+ description: string | null;
1371
+
1372
+ ending_balance: number;
1373
+
1374
+ entry_status: 'committed' | 'pending';
1375
+
1376
+ entry_type: 'void_initiated';
1377
+
1378
+ ledger_sequence_number: number;
1379
+
1380
+ metadata: Record<string, string>;
1381
+
1382
+ new_block_expiry_date: string;
1383
+
1384
+ starting_balance: number;
1385
+
1386
+ void_amount: number;
1387
+
1388
+ void_reason: string | null;
1389
+ }
1390
+
1391
+ export namespace VoidInitiatedLedgerEntry {
1392
+ export interface CreditBlock {
1393
+ id: string;
1394
+
1395
+ expiry_date: string | null;
1396
+
1397
+ per_unit_cost_basis: string | null;
1398
+ }
1399
+
1400
+ export interface Customer {
1401
+ id: string;
1402
+
1403
+ external_customer_id: string | null;
1404
+ }
1405
+ }
1406
+
1407
+ export interface AmendmentLedgerEntry {
1408
+ id: string;
1409
+
1410
+ amount: number;
1411
+
1412
+ created_at: string;
1413
+
1414
+ credit_block: AmendmentLedgerEntry.CreditBlock;
1415
+
1416
+ customer: AmendmentLedgerEntry.Customer;
1417
+
1418
+ description: string | null;
1419
+
1420
+ ending_balance: number;
1421
+
1422
+ entry_status: 'committed' | 'pending';
1423
+
1424
+ entry_type: 'amendment';
1425
+
1426
+ ledger_sequence_number: number;
1427
+
1428
+ metadata: Record<string, string>;
1429
+
1430
+ starting_balance: number;
1431
+ }
1432
+
1433
+ export namespace AmendmentLedgerEntry {
1434
+ export interface CreditBlock {
1435
+ id: string;
1436
+
1437
+ expiry_date: string | null;
1438
+
1439
+ per_unit_cost_basis: string | null;
1440
+ }
1441
+
1442
+ export interface Customer {
1443
+ id: string;
1444
+
1445
+ external_customer_id: string | null;
1446
+ }
1447
+ }
1448
+ }
1449
+
1450
+ /**
1451
+ * The [Credit Ledger Entry resource](/guides/product-catalog/prepurchase) models
1452
+ * prepaid credits within Orb.
1453
+ */
1454
+ export type LedgerListByExternalIDResponse =
1455
+ | LedgerListByExternalIDResponse.IncrementLedgerEntry
1456
+ | LedgerListByExternalIDResponse.DecrementLedgerEntry
1457
+ | LedgerListByExternalIDResponse.ExpirationChangeLedgerEntry
1458
+ | LedgerListByExternalIDResponse.CreditBlockExpiryLedgerEntry
1459
+ | LedgerListByExternalIDResponse.VoidLedgerEntry
1460
+ | LedgerListByExternalIDResponse.VoidInitiatedLedgerEntry
1461
+ | LedgerListByExternalIDResponse.AmendmentLedgerEntry;
1462
+
1463
+ export namespace LedgerListByExternalIDResponse {
1464
+ export interface IncrementLedgerEntry {
1465
+ id: string;
1466
+
1467
+ amount: number;
1468
+
1469
+ created_at: string;
1470
+
1471
+ credit_block: IncrementLedgerEntry.CreditBlock;
1472
+
1473
+ customer: IncrementLedgerEntry.Customer;
1474
+
1475
+ description: string | null;
1476
+
1477
+ ending_balance: number;
1478
+
1479
+ entry_status: 'committed' | 'pending';
1480
+
1481
+ entry_type: 'increment';
1482
+
1483
+ ledger_sequence_number: number;
1484
+
1485
+ metadata: Record<string, string>;
1486
+
1487
+ starting_balance: number;
1488
+ }
1489
+
1490
+ export namespace IncrementLedgerEntry {
1491
+ export interface CreditBlock {
1492
+ id: string;
1493
+
1494
+ expiry_date: string | null;
1495
+
1496
+ per_unit_cost_basis: string | null;
1497
+ }
1498
+
1499
+ export interface Customer {
1500
+ id: string;
1501
+
1502
+ external_customer_id: string | null;
1503
+ }
1504
+ }
1505
+
1506
+ export interface DecrementLedgerEntry {
1507
+ id: string;
1508
+
1509
+ amount: number;
1510
+
1511
+ created_at: string;
1512
+
1513
+ credit_block: DecrementLedgerEntry.CreditBlock;
1514
+
1515
+ customer: DecrementLedgerEntry.Customer;
1516
+
1517
+ description: string | null;
1518
+
1519
+ ending_balance: number;
1520
+
1521
+ entry_status: 'committed' | 'pending';
1522
+
1523
+ entry_type: 'decrement';
1524
+
1525
+ ledger_sequence_number: number;
1526
+
1527
+ metadata: Record<string, string>;
1528
+
1529
+ starting_balance: number;
1530
+
1531
+ event_id?: string | null;
1532
+
1533
+ invoice_id?: string | null;
1534
+
1535
+ price_id?: string | null;
1536
+ }
1537
+
1538
+ export namespace DecrementLedgerEntry {
1539
+ export interface CreditBlock {
1540
+ id: string;
1541
+
1542
+ expiry_date: string | null;
1543
+
1544
+ per_unit_cost_basis: string | null;
1545
+ }
1546
+
1547
+ export interface Customer {
1548
+ id: string;
1549
+
1550
+ external_customer_id: string | null;
1551
+ }
1552
+ }
1553
+
1554
+ export interface ExpirationChangeLedgerEntry {
1555
+ id: string;
1556
+
1557
+ amount: number;
1558
+
1559
+ created_at: string;
1560
+
1561
+ credit_block: ExpirationChangeLedgerEntry.CreditBlock;
1562
+
1563
+ customer: ExpirationChangeLedgerEntry.Customer;
1564
+
1565
+ description: string | null;
1566
+
1567
+ ending_balance: number;
1568
+
1569
+ entry_status: 'committed' | 'pending';
1570
+
1571
+ entry_type: 'expiration_change';
1572
+
1573
+ ledger_sequence_number: number;
1574
+
1575
+ metadata: Record<string, string>;
1576
+
1577
+ new_block_expiry_date: string;
1578
+
1579
+ starting_balance: number;
1580
+ }
1581
+
1582
+ export namespace ExpirationChangeLedgerEntry {
1583
+ export interface CreditBlock {
1584
+ id: string;
1585
+
1586
+ expiry_date: string | null;
1587
+
1588
+ per_unit_cost_basis: string | null;
1589
+ }
1590
+
1591
+ export interface Customer {
1592
+ id: string;
1593
+
1594
+ external_customer_id: string | null;
1595
+ }
1596
+ }
1597
+
1598
+ export interface CreditBlockExpiryLedgerEntry {
1599
+ id: string;
1600
+
1601
+ amount: number;
1602
+
1603
+ created_at: string;
1604
+
1605
+ credit_block: CreditBlockExpiryLedgerEntry.CreditBlock;
1606
+
1607
+ customer: CreditBlockExpiryLedgerEntry.Customer;
1608
+
1609
+ description: string | null;
1610
+
1611
+ ending_balance: number;
1612
+
1613
+ entry_status: 'committed' | 'pending';
1614
+
1615
+ entry_type: 'credit_block_expiry';
1616
+
1617
+ ledger_sequence_number: number;
1618
+
1619
+ metadata: Record<string, string>;
1620
+
1621
+ starting_balance: number;
1622
+ }
1623
+
1624
+ export namespace CreditBlockExpiryLedgerEntry {
1625
+ export interface CreditBlock {
1626
+ id: string;
1627
+
1628
+ expiry_date: string | null;
1629
+
1630
+ per_unit_cost_basis: string | null;
1631
+ }
1632
+
1633
+ export interface Customer {
1634
+ id: string;
1635
+
1636
+ external_customer_id: string | null;
1637
+ }
1638
+ }
1639
+
1640
+ export interface VoidLedgerEntry {
1641
+ id: string;
1642
+
1643
+ amount: number;
1644
+
1645
+ created_at: string;
1646
+
1647
+ credit_block: VoidLedgerEntry.CreditBlock;
1648
+
1649
+ customer: VoidLedgerEntry.Customer;
1650
+
1651
+ description: string | null;
1652
+
1653
+ ending_balance: number;
1654
+
1655
+ entry_status: 'committed' | 'pending';
1656
+
1657
+ entry_type: 'void';
1658
+
1659
+ ledger_sequence_number: number;
1660
+
1661
+ metadata: Record<string, string>;
1662
+
1663
+ starting_balance: number;
1664
+
1665
+ void_amount: number;
1666
+
1667
+ void_reason: string | null;
1668
+ }
1669
+
1670
+ export namespace VoidLedgerEntry {
1671
+ export interface CreditBlock {
1672
+ id: string;
1673
+
1674
+ expiry_date: string | null;
1675
+
1676
+ per_unit_cost_basis: string | null;
1677
+ }
1678
+
1679
+ export interface Customer {
1680
+ id: string;
1681
+
1682
+ external_customer_id: string | null;
1683
+ }
1684
+ }
1685
+
1686
+ export interface VoidInitiatedLedgerEntry {
1687
+ id: string;
1688
+
1689
+ amount: number;
1690
+
1691
+ created_at: string;
1692
+
1693
+ credit_block: VoidInitiatedLedgerEntry.CreditBlock;
1694
+
1695
+ customer: VoidInitiatedLedgerEntry.Customer;
1696
+
1697
+ description: string | null;
1698
+
1699
+ ending_balance: number;
1700
+
1701
+ entry_status: 'committed' | 'pending';
1702
+
1703
+ entry_type: 'void_initiated';
1704
+
1705
+ ledger_sequence_number: number;
1706
+
1707
+ metadata: Record<string, string>;
1708
+
1709
+ new_block_expiry_date: string;
1710
+
1711
+ starting_balance: number;
1712
+
1713
+ void_amount: number;
1714
+
1715
+ void_reason: string | null;
1716
+ }
1717
+
1718
+ export namespace VoidInitiatedLedgerEntry {
1719
+ export interface CreditBlock {
1720
+ id: string;
1721
+
1722
+ expiry_date: string | null;
1723
+
1724
+ per_unit_cost_basis: string | null;
1725
+ }
1726
+
1727
+ export interface Customer {
1728
+ id: string;
1729
+
1730
+ external_customer_id: string | null;
1731
+ }
1732
+ }
1733
+
1734
+ export interface AmendmentLedgerEntry {
1735
+ id: string;
1736
+
1737
+ amount: number;
1738
+
1739
+ created_at: string;
1740
+
1741
+ credit_block: AmendmentLedgerEntry.CreditBlock;
1742
+
1743
+ customer: AmendmentLedgerEntry.Customer;
1744
+
1745
+ description: string | null;
1746
+
1747
+ ending_balance: number;
1748
+
1749
+ entry_status: 'committed' | 'pending';
1750
+
1751
+ entry_type: 'amendment';
1752
+
1753
+ ledger_sequence_number: number;
1754
+
1755
+ metadata: Record<string, string>;
1756
+
1757
+ starting_balance: number;
1758
+ }
1759
+
1760
+ export namespace AmendmentLedgerEntry {
1761
+ export interface CreditBlock {
1762
+ id: string;
1763
+
1764
+ expiry_date: string | null;
1765
+
1766
+ per_unit_cost_basis: string | null;
1767
+ }
1768
+
1769
+ export interface Customer {
1770
+ id: string;
1771
+
1772
+ external_customer_id: string | null;
1773
+ }
1774
+ }
1775
+ }
1776
+
1777
+ export interface LedgerListParams extends PageParams {
1778
+ 'created_at[gt]'?: string | null;
1779
+
1780
+ 'created_at[gte]'?: string | null;
1781
+
1782
+ 'created_at[lt]'?: string | null;
1783
+
1784
+ 'created_at[lte]'?: string | null;
1785
+
1786
+ currency?: string | null;
1787
+
1788
+ entry_status?: 'committed' | 'pending' | null;
1789
+
1790
+ entry_type?:
1791
+ | 'increment'
1792
+ | 'decrement'
1793
+ | 'expiration_change'
1794
+ | 'credit_block_expiry'
1795
+ | 'void'
1796
+ | 'void_initiated'
1797
+ | 'amendment'
1798
+ | null;
1799
+
1800
+ minimum_amount?: string | null;
1801
+ }
1802
+
1803
+ export type LedgerCreateEntryParams =
1804
+ | LedgerCreateEntryParams.AddIncrementCreditLedgerEntryRequestParams
1805
+ | LedgerCreateEntryParams.AddDecrementCreditLedgerEntryRequestParams
1806
+ | LedgerCreateEntryParams.AddExpirationChangeCreditLedgerEntryRequestParams
1807
+ | LedgerCreateEntryParams.AddVoidCreditLedgerEntryRequestParams
1808
+ | LedgerCreateEntryParams.AddAmendmentCreditLedgerEntryRequestParams;
1809
+
1810
+ export namespace LedgerCreateEntryParams {
1811
+ export interface AddIncrementCreditLedgerEntryRequestParams {
1812
+ /**
1813
+ * The number of credits to effect. Note that this is required for increment,
1814
+ * decrement, void, or undo operations.
1815
+ */
1816
+ amount: number;
1817
+
1818
+ entry_type: 'increment';
1819
+
1820
+ /**
1821
+ * Optional metadata that can be specified when adding ledger results via the API.
1822
+ * For example, this can be used to note an increment refers to trial credits, or
1823
+ * for noting corrections as a result of an incident, etc.
1824
+ */
1825
+ description?: string | null;
1826
+
1827
+ /**
1828
+ * A future date (specified in YYYY-MM-DD format) that denotes when this credit
1829
+ * balance should become available for use.
1830
+ */
1831
+ effective_date?: string | null;
1832
+
1833
+ /**
1834
+ * A future date (specified in YYYY-MM-DD format) that denotes when this credit
1835
+ * balance should expire.
1836
+ */
1837
+ expiry_date?: string | null;
1838
+
1839
+ /**
1840
+ * Passing `invoice_settings` automatically generates an invoice for the newly
1841
+ * added credits. If `invoice_settings` is passed, you must specify
1842
+ * per_unit_cost_basis, as the calculation of the invoice total is done on that
1843
+ * basis.
1844
+ */
1845
+ invoice_settings?: LedgerCreateEntryParams.AddIncrementCreditLedgerEntryRequestParams.InvoiceSettings | null;
1846
+
1847
+ /**
1848
+ * User-specified key/value pairs for the ledger entry resource.
1849
+ */
1850
+ metadata?: unknown;
1851
+
1852
+ /**
1853
+ * Can only be specified when entry_type=increment. How much, in USD, a customer
1854
+ * paid for a single credit in this block
1855
+ */
1856
+ per_unit_cost_basis?: string | null;
1857
+ }
1858
+
1859
+ export namespace AddIncrementCreditLedgerEntryRequestParams {
1860
+ /**
1861
+ * Passing `invoice_settings` automatically generates an invoice for the newly
1862
+ * added credits. If `invoice_settings` is passed, you must specify
1863
+ * per_unit_cost_basis, as the calculation of the invoice total is done on that
1864
+ * basis.
1865
+ */
1866
+ export interface InvoiceSettings {
1867
+ /**
1868
+ * Whether the credits purchase invoice should auto collect with the customer's
1869
+ * saved payment method.
1870
+ */
1871
+ auto_collection: boolean;
1872
+
1873
+ /**
1874
+ * The net terms determines the difference between the invoice date and the issue
1875
+ * date for the invoice. If you intend the invoice to be due on issue, set this
1876
+ * to 0.
1877
+ */
1878
+ net_terms: number;
1879
+
1880
+ /**
1881
+ * An optional memo to display on the invoice.
1882
+ */
1883
+ memo?: string | null;
1884
+ }
1885
+ }
1886
+
1887
+ export interface AddDecrementCreditLedgerEntryRequestParams {
1888
+ /**
1889
+ * The number of credits to effect. Note that this is required for increment,
1890
+ * decrement, void, or undo operations.
1891
+ */
1892
+ amount: number;
1893
+
1894
+ entry_type: 'decrement';
1895
+
1896
+ /**
1897
+ * Optional metadata that can be specified when adding ledger results via the API.
1898
+ * For example, this can be used to note an increment refers to trial credits, or
1899
+ * for noting corrections as a result of an incident, etc.
1900
+ */
1901
+ description?: string | null;
1902
+
1903
+ /**
1904
+ * User-specified key/value pairs for the ledger entry resource.
1905
+ */
1906
+ metadata?: unknown;
1907
+ }
1908
+
1909
+ export interface AddExpirationChangeCreditLedgerEntryRequestParams {
1910
+ entry_type: 'expiration_change';
1911
+
1912
+ /**
1913
+ * A future date (specified in YYYY-MM-DD format) that identifies the origination
1914
+ * credit block to expire
1915
+ */
1916
+ expiry_date: string | null;
1917
+
1918
+ /**
1919
+ * A future date (specified in YYYY-MM-DD format) used for expiration change,
1920
+ * denoting when credits transferred (as part of a partial block expiration) should
1921
+ * expire.
1922
+ */
1923
+ target_expiry_date: string;
1924
+
1925
+ /**
1926
+ * The number of credits to effect. Note that this is required for increment,
1927
+ * decrement, void, or undo operations.
1928
+ */
1929
+ amount?: number | null;
1930
+
1931
+ /**
1932
+ * The ID of the block affected by an expiration_change, used to differentiate
1933
+ * between multiple blocks with the same `expiry_date`.
1934
+ */
1935
+ block_id?: string | null;
1936
+
1937
+ /**
1938
+ * Optional metadata that can be specified when adding ledger results via the API.
1939
+ * For example, this can be used to note an increment refers to trial credits, or
1940
+ * for noting corrections as a result of an incident, etc.
1941
+ */
1942
+ description?: string | null;
1943
+
1944
+ /**
1945
+ * User-specified key/value pairs for the ledger entry resource.
1946
+ */
1947
+ metadata?: unknown;
1948
+ }
1949
+
1950
+ export interface AddVoidCreditLedgerEntryRequestParams {
1951
+ /**
1952
+ * The number of credits to effect. Note that this is required for increment,
1953
+ * decrement, void, or undo operations.
1954
+ */
1955
+ amount: number;
1956
+
1957
+ /**
1958
+ * The ID of the block to void.
1959
+ */
1960
+ block_id: string;
1961
+
1962
+ entry_type: 'void';
1963
+
1964
+ /**
1965
+ * Optional metadata that can be specified when adding ledger results via the API.
1966
+ * For example, this can be used to note an increment refers to trial credits, or
1967
+ * for noting corrections as a result of an incident, etc.
1968
+ */
1969
+ description?: string | null;
1970
+
1971
+ /**
1972
+ * User-specified key/value pairs for the ledger entry resource.
1973
+ */
1974
+ metadata?: unknown;
1975
+
1976
+ /**
1977
+ * Can only be specified when `entry_type=void`. The reason for the void.
1978
+ */
1979
+ void_reason?: 'refund' | null;
1980
+ }
1981
+
1982
+ export interface AddAmendmentCreditLedgerEntryRequestParams {
1983
+ /**
1984
+ * The number of credits to effect. Note that this is required for increment,
1985
+ * decrement or void operations.
1986
+ */
1987
+ amount: number;
1988
+
1989
+ /**
1990
+ * The ID of the block to reverse a decrement from.
1991
+ */
1992
+ block_id: string;
1993
+
1994
+ entry_type: 'amendment';
1995
+
1996
+ /**
1997
+ * Optional metadata that can be specified when adding ledger results via the API.
1998
+ * For example, this can be used to note an increment refers to trial credits, or
1999
+ * for noting corrections as a result of an incident, etc.
2000
+ */
2001
+ description?: string | null;
2002
+
2003
+ /**
2004
+ * User-specified key/value pairs for the ledger entry resource.
2005
+ */
2006
+ metadata?: unknown;
2007
+ }
2008
+ }
2009
+
2010
+ export type LedgerCreateEntryByExteralIDParams =
2011
+ | LedgerCreateEntryByExteralIDParams.AddIncrementCreditLedgerEntryRequestParams
2012
+ | LedgerCreateEntryByExteralIDParams.AddDecrementCreditLedgerEntryRequestParams
2013
+ | LedgerCreateEntryByExteralIDParams.AddExpirationChangeCreditLedgerEntryRequestParams
2014
+ | LedgerCreateEntryByExteralIDParams.AddVoidCreditLedgerEntryRequestParams
2015
+ | LedgerCreateEntryByExteralIDParams.AddAmendmentCreditLedgerEntryRequestParams;
2016
+
2017
+ export namespace LedgerCreateEntryByExteralIDParams {
2018
+ export interface AddIncrementCreditLedgerEntryRequestParams {
2019
+ /**
2020
+ * The number of credits to effect. Note that this is required for increment,
2021
+ * decrement, void, or undo operations.
2022
+ */
2023
+ amount: number;
2024
+
2025
+ entry_type: 'increment';
2026
+
2027
+ /**
2028
+ * Optional metadata that can be specified when adding ledger results via the API.
2029
+ * For example, this can be used to note an increment refers to trial credits, or
2030
+ * for noting corrections as a result of an incident, etc.
2031
+ */
2032
+ description?: string | null;
2033
+
2034
+ /**
2035
+ * A future date (specified in YYYY-MM-DD format) that denotes when this credit
2036
+ * balance should become available for use.
2037
+ */
2038
+ effective_date?: string | null;
2039
+
2040
+ /**
2041
+ * A future date (specified in YYYY-MM-DD format) that denotes when this credit
2042
+ * balance should expire.
2043
+ */
2044
+ expiry_date?: string | null;
2045
+
2046
+ /**
2047
+ * Passing `invoice_settings` automatically generates an invoice for the newly
2048
+ * added credits. If `invoice_settings` is passed, you must specify
2049
+ * per_unit_cost_basis, as the calculation of the invoice total is done on that
2050
+ * basis.
2051
+ */
2052
+ invoice_settings?: LedgerCreateEntryByExteralIDParams.AddIncrementCreditLedgerEntryRequestParams.InvoiceSettings | null;
2053
+
2054
+ /**
2055
+ * User-specified key/value pairs for the ledger entry resource.
2056
+ */
2057
+ metadata?: unknown;
2058
+
2059
+ /**
2060
+ * Can only be specified when entry_type=increment. How much, in USD, a customer
2061
+ * paid for a single credit in this block
2062
+ */
2063
+ per_unit_cost_basis?: string | null;
2064
+ }
2065
+
2066
+ export namespace AddIncrementCreditLedgerEntryRequestParams {
2067
+ /**
2068
+ * Passing `invoice_settings` automatically generates an invoice for the newly
2069
+ * added credits. If `invoice_settings` is passed, you must specify
2070
+ * per_unit_cost_basis, as the calculation of the invoice total is done on that
2071
+ * basis.
2072
+ */
2073
+ export interface InvoiceSettings {
2074
+ /**
2075
+ * Whether the credits purchase invoice should auto collect with the customer's
2076
+ * saved payment method.
2077
+ */
2078
+ auto_collection: boolean;
2079
+
2080
+ /**
2081
+ * The net terms determines the difference between the invoice date and the issue
2082
+ * date for the invoice. If you intend the invoice to be due on issue, set this
2083
+ * to 0.
2084
+ */
2085
+ net_terms: number;
2086
+
2087
+ /**
2088
+ * An optional memo to display on the invoice.
2089
+ */
2090
+ memo?: string | null;
2091
+ }
2092
+ }
2093
+
2094
+ export interface AddDecrementCreditLedgerEntryRequestParams {
2095
+ /**
2096
+ * The number of credits to effect. Note that this is required for increment,
2097
+ * decrement, void, or undo operations.
2098
+ */
2099
+ amount: number;
2100
+
2101
+ entry_type: 'decrement';
2102
+
2103
+ /**
2104
+ * Optional metadata that can be specified when adding ledger results via the API.
2105
+ * For example, this can be used to note an increment refers to trial credits, or
2106
+ * for noting corrections as a result of an incident, etc.
2107
+ */
2108
+ description?: string | null;
2109
+
2110
+ /**
2111
+ * User-specified key/value pairs for the ledger entry resource.
2112
+ */
2113
+ metadata?: unknown;
2114
+ }
2115
+
2116
+ export interface AddExpirationChangeCreditLedgerEntryRequestParams {
2117
+ entry_type: 'expiration_change';
2118
+
2119
+ /**
2120
+ * A future date (specified in YYYY-MM-DD format) that identifies the origination
2121
+ * credit block to expire
2122
+ */
2123
+ expiry_date: string | null;
2124
+
2125
+ /**
2126
+ * A future date (specified in YYYY-MM-DD format) used for expiration change,
2127
+ * denoting when credits transferred (as part of a partial block expiration) should
2128
+ * expire.
2129
+ */
2130
+ target_expiry_date: string;
2131
+
2132
+ /**
2133
+ * The number of credits to effect. Note that this is required for increment,
2134
+ * decrement, void, or undo operations.
2135
+ */
2136
+ amount?: number | null;
2137
+
2138
+ /**
2139
+ * The ID of the block affected by an expiration_change, used to differentiate
2140
+ * between multiple blocks with the same `expiry_date`.
2141
+ */
2142
+ block_id?: string | null;
2143
+
2144
+ /**
2145
+ * Optional metadata that can be specified when adding ledger results via the API.
2146
+ * For example, this can be used to note an increment refers to trial credits, or
2147
+ * for noting corrections as a result of an incident, etc.
2148
+ */
2149
+ description?: string | null;
2150
+
2151
+ /**
2152
+ * User-specified key/value pairs for the ledger entry resource.
2153
+ */
2154
+ metadata?: unknown;
2155
+ }
2156
+
2157
+ export interface AddVoidCreditLedgerEntryRequestParams {
2158
+ /**
2159
+ * The number of credits to effect. Note that this is required for increment,
2160
+ * decrement, void, or undo operations.
2161
+ */
2162
+ amount: number;
2163
+
2164
+ /**
2165
+ * The ID of the block to void.
2166
+ */
2167
+ block_id: string;
2168
+
2169
+ entry_type: 'void';
2170
+
2171
+ /**
2172
+ * Optional metadata that can be specified when adding ledger results via the API.
2173
+ * For example, this can be used to note an increment refers to trial credits, or
2174
+ * for noting corrections as a result of an incident, etc.
2175
+ */
2176
+ description?: string | null;
2177
+
2178
+ /**
2179
+ * User-specified key/value pairs for the ledger entry resource.
2180
+ */
2181
+ metadata?: unknown;
2182
+
2183
+ /**
2184
+ * Can only be specified when `entry_type=void`. The reason for the void.
2185
+ */
2186
+ void_reason?: 'refund' | null;
2187
+ }
2188
+
2189
+ export interface AddAmendmentCreditLedgerEntryRequestParams {
2190
+ /**
2191
+ * The number of credits to effect. Note that this is required for increment,
2192
+ * decrement or void operations.
2193
+ */
2194
+ amount: number;
2195
+
2196
+ /**
2197
+ * The ID of the block to reverse a decrement from.
2198
+ */
2199
+ block_id: string;
2200
+
2201
+ entry_type: 'amendment';
2202
+
2203
+ /**
2204
+ * Optional metadata that can be specified when adding ledger results via the API.
2205
+ * For example, this can be used to note an increment refers to trial credits, or
2206
+ * for noting corrections as a result of an incident, etc.
2207
+ */
2208
+ description?: string | null;
2209
+
2210
+ /**
2211
+ * User-specified key/value pairs for the ledger entry resource.
2212
+ */
2213
+ metadata?: unknown;
2214
+ }
2215
+ }
2216
+
2217
+ export interface LedgerListByExternalIDParams extends PageParams {
2218
+ 'created_at[gt]'?: string | null;
2219
+
2220
+ 'created_at[gte]'?: string | null;
2221
+
2222
+ 'created_at[lt]'?: string | null;
2223
+
2224
+ 'created_at[lte]'?: string | null;
2225
+
2226
+ currency?: string | null;
2227
+
2228
+ entry_status?: 'committed' | 'pending' | null;
2229
+
2230
+ entry_type?:
2231
+ | 'increment'
2232
+ | 'decrement'
2233
+ | 'expiration_change'
2234
+ | 'credit_block_expiry'
2235
+ | 'void'
2236
+ | 'void_initiated'
2237
+ | 'amendment'
2238
+ | null;
2239
+
2240
+ minimum_amount?: string | null;
2241
+ }
2242
+
2243
+ export namespace Ledger {
2244
+ export import LedgerListResponse = LedgerAPI.LedgerListResponse;
2245
+ export import LedgerCreateEntryResponse = LedgerAPI.LedgerCreateEntryResponse;
2246
+ export import LedgerCreateEntryByExteralIDResponse = LedgerAPI.LedgerCreateEntryByExteralIDResponse;
2247
+ export import LedgerListByExternalIDResponse = LedgerAPI.LedgerListByExternalIDResponse;
2248
+ export import LedgerListResponsesPage = LedgerAPI.LedgerListResponsesPage;
2249
+ export import LedgerListByExternalIDResponsesPage = LedgerAPI.LedgerListByExternalIDResponsesPage;
2250
+ export import LedgerListParams = LedgerAPI.LedgerListParams;
2251
+ export import LedgerCreateEntryParams = LedgerAPI.LedgerCreateEntryParams;
2252
+ export import LedgerCreateEntryByExteralIDParams = LedgerAPI.LedgerCreateEntryByExteralIDParams;
2253
+ export import LedgerListByExternalIDParams = LedgerAPI.LedgerListByExternalIDParams;
2254
+ }