@stigg/typescript 0.1.0-beta.20 → 0.1.0-beta.22

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 (433) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/client.d.mts +3 -0
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +3 -0
  5. package/client.d.ts.map +1 -1
  6. package/client.js +3 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +3 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/index.d.mts +1 -0
  12. package/resources/index.d.mts.map +1 -1
  13. package/resources/index.d.ts +1 -0
  14. package/resources/index.d.ts.map +1 -1
  15. package/resources/index.js +3 -1
  16. package/resources/index.js.map +1 -1
  17. package/resources/index.mjs +1 -0
  18. package/resources/index.mjs.map +1 -1
  19. package/resources/v1/addons/addons.d.mts +145 -94
  20. package/resources/v1/addons/addons.d.mts.map +1 -1
  21. package/resources/v1/addons/addons.d.ts +145 -94
  22. package/resources/v1/addons/addons.d.ts.map +1 -1
  23. package/resources/v1/addons/addons.js +110 -76
  24. package/resources/v1/addons/addons.js.map +1 -1
  25. package/resources/v1/addons/addons.mjs +110 -76
  26. package/resources/v1/addons/addons.mjs.map +1 -1
  27. package/resources/v1/addons/entitlements.d.mts +62 -36
  28. package/resources/v1/addons/entitlements.d.mts.map +1 -1
  29. package/resources/v1/addons/entitlements.d.ts +62 -36
  30. package/resources/v1/addons/entitlements.d.ts.map +1 -1
  31. package/resources/v1/addons/entitlements.js +49 -39
  32. package/resources/v1/addons/entitlements.js.map +1 -1
  33. package/resources/v1/addons/entitlements.mjs +49 -39
  34. package/resources/v1/addons/entitlements.mjs.map +1 -1
  35. package/resources/v1/addons/index.d.mts +2 -2
  36. package/resources/v1/addons/index.d.mts.map +1 -1
  37. package/resources/v1/addons/index.d.ts +2 -2
  38. package/resources/v1/addons/index.d.ts.map +1 -1
  39. package/resources/v1/addons/index.js.map +1 -1
  40. package/resources/v1/addons/index.mjs.map +1 -1
  41. package/resources/v1/coupons.d.mts +81 -57
  42. package/resources/v1/coupons.d.mts.map +1 -1
  43. package/resources/v1/coupons.d.ts +81 -57
  44. package/resources/v1/coupons.d.ts.map +1 -1
  45. package/resources/v1/coupons.js +60 -45
  46. package/resources/v1/coupons.js.map +1 -1
  47. package/resources/v1/coupons.mjs +60 -45
  48. package/resources/v1/coupons.mjs.map +1 -1
  49. package/resources/v1/credits/credits.d.mts +60 -52
  50. package/resources/v1/credits/credits.d.mts.map +1 -1
  51. package/resources/v1/credits/credits.d.ts +60 -52
  52. package/resources/v1/credits/credits.d.ts.map +1 -1
  53. package/resources/v1/credits/credits.js +36 -30
  54. package/resources/v1/credits/credits.js.map +1 -1
  55. package/resources/v1/credits/credits.mjs +36 -30
  56. package/resources/v1/credits/credits.mjs.map +1 -1
  57. package/resources/v1/credits/custom-currencies.d.mts +98 -74
  58. package/resources/v1/credits/custom-currencies.d.mts.map +1 -1
  59. package/resources/v1/credits/custom-currencies.d.ts +98 -74
  60. package/resources/v1/credits/custom-currencies.d.ts.map +1 -1
  61. package/resources/v1/credits/custom-currencies.js +76 -61
  62. package/resources/v1/credits/custom-currencies.js.map +1 -1
  63. package/resources/v1/credits/custom-currencies.mjs +76 -61
  64. package/resources/v1/credits/custom-currencies.mjs.map +1 -1
  65. package/resources/v1/credits/grants.d.mts +63 -54
  66. package/resources/v1/credits/grants.d.mts.map +1 -1
  67. package/resources/v1/credits/grants.d.ts +63 -54
  68. package/resources/v1/credits/grants.d.ts.map +1 -1
  69. package/resources/v1/credits/grants.js +35 -33
  70. package/resources/v1/credits/grants.js.map +1 -1
  71. package/resources/v1/credits/grants.mjs +35 -33
  72. package/resources/v1/credits/grants.mjs.map +1 -1
  73. package/resources/v1/credits/index.d.mts +2 -2
  74. package/resources/v1/credits/index.d.mts.map +1 -1
  75. package/resources/v1/credits/index.d.ts +2 -2
  76. package/resources/v1/credits/index.d.ts.map +1 -1
  77. package/resources/v1/credits/index.js.map +1 -1
  78. package/resources/v1/credits/index.mjs.map +1 -1
  79. package/resources/v1/customers/customers.d.mts +167 -127
  80. package/resources/v1/customers/customers.d.mts.map +1 -1
  81. package/resources/v1/customers/customers.d.ts +167 -127
  82. package/resources/v1/customers/customers.d.ts.map +1 -1
  83. package/resources/v1/customers/customers.js +124 -96
  84. package/resources/v1/customers/customers.js.map +1 -1
  85. package/resources/v1/customers/customers.mjs +124 -96
  86. package/resources/v1/customers/customers.mjs.map +1 -1
  87. package/resources/v1/customers/index.d.mts +2 -2
  88. package/resources/v1/customers/index.d.mts.map +1 -1
  89. package/resources/v1/customers/index.d.ts +2 -2
  90. package/resources/v1/customers/index.d.ts.map +1 -1
  91. package/resources/v1/customers/index.js.map +1 -1
  92. package/resources/v1/customers/index.mjs +1 -1
  93. package/resources/v1/customers/index.mjs.map +1 -1
  94. package/resources/v1/customers/integrations.d.mts +66 -58
  95. package/resources/v1/customers/integrations.d.mts.map +1 -1
  96. package/resources/v1/customers/integrations.d.ts +66 -58
  97. package/resources/v1/customers/integrations.d.ts.map +1 -1
  98. package/resources/v1/customers/integrations.js +57 -56
  99. package/resources/v1/customers/integrations.js.map +1 -1
  100. package/resources/v1/customers/integrations.mjs +57 -56
  101. package/resources/v1/customers/integrations.mjs.map +1 -1
  102. package/resources/v1/customers/payment-method.d.mts +33 -25
  103. package/resources/v1/customers/payment-method.d.mts.map +1 -1
  104. package/resources/v1/customers/payment-method.d.ts +33 -25
  105. package/resources/v1/customers/payment-method.d.ts.map +1 -1
  106. package/resources/v1/customers/payment-method.js +26 -20
  107. package/resources/v1/customers/payment-method.js.map +1 -1
  108. package/resources/v1/customers/payment-method.mjs +26 -20
  109. package/resources/v1/customers/payment-method.mjs.map +1 -1
  110. package/resources/v1/customers/promotional-entitlements.d.mts +42 -60
  111. package/resources/v1/customers/promotional-entitlements.d.mts.map +1 -1
  112. package/resources/v1/customers/promotional-entitlements.d.ts +42 -60
  113. package/resources/v1/customers/promotional-entitlements.d.ts.map +1 -1
  114. package/resources/v1/customers/promotional-entitlements.js +38 -57
  115. package/resources/v1/customers/promotional-entitlements.js.map +1 -1
  116. package/resources/v1/customers/promotional-entitlements.mjs +38 -57
  117. package/resources/v1/customers/promotional-entitlements.mjs.map +1 -1
  118. package/resources/v1/events/data-export/data-export.d.mts +29 -21
  119. package/resources/v1/events/data-export/data-export.d.mts.map +1 -1
  120. package/resources/v1/events/data-export/data-export.d.ts +29 -21
  121. package/resources/v1/events/data-export/data-export.d.ts.map +1 -1
  122. package/resources/v1/events/data-export/data-export.js +27 -18
  123. package/resources/v1/events/data-export/data-export.js.map +1 -1
  124. package/resources/v1/events/data-export/data-export.mjs +27 -18
  125. package/resources/v1/events/data-export/data-export.mjs.map +1 -1
  126. package/resources/v1/events/data-export/destinations.d.mts +29 -22
  127. package/resources/v1/events/data-export/destinations.d.mts.map +1 -1
  128. package/resources/v1/events/data-export/destinations.d.ts +29 -22
  129. package/resources/v1/events/data-export/destinations.d.ts.map +1 -1
  130. package/resources/v1/events/data-export/destinations.js +26 -21
  131. package/resources/v1/events/data-export/destinations.js.map +1 -1
  132. package/resources/v1/events/data-export/destinations.mjs +26 -21
  133. package/resources/v1/events/data-export/destinations.mjs.map +1 -1
  134. package/resources/v1/events/data-export/index.d.mts +1 -1
  135. package/resources/v1/events/data-export/index.d.mts.map +1 -1
  136. package/resources/v1/events/data-export/index.d.ts +1 -1
  137. package/resources/v1/events/data-export/index.d.ts.map +1 -1
  138. package/resources/v1/events/data-export/index.js.map +1 -1
  139. package/resources/v1/events/data-export/index.mjs.map +1 -1
  140. package/resources/v1/events/events.d.mts +13 -19
  141. package/resources/v1/events/events.d.mts.map +1 -1
  142. package/resources/v1/events/events.d.ts +13 -19
  143. package/resources/v1/events/events.d.ts.map +1 -1
  144. package/resources/v1/events/events.js +14 -19
  145. package/resources/v1/events/events.js.map +1 -1
  146. package/resources/v1/events/events.mjs +14 -19
  147. package/resources/v1/events/events.mjs.map +1 -1
  148. package/resources/v1/events/index.d.mts +0 -1
  149. package/resources/v1/events/index.d.mts.map +1 -1
  150. package/resources/v1/events/index.d.ts +0 -1
  151. package/resources/v1/events/index.d.ts.map +1 -1
  152. package/resources/v1/events/index.js +3 -5
  153. package/resources/v1/events/index.js.map +1 -1
  154. package/resources/v1/events/index.mjs +0 -1
  155. package/resources/v1/events/index.mjs.map +1 -1
  156. package/resources/v1/features.d.mts +109 -74
  157. package/resources/v1/features.d.mts.map +1 -1
  158. package/resources/v1/features.d.ts +109 -74
  159. package/resources/v1/features.d.ts.map +1 -1
  160. package/resources/v1/features.js +72 -54
  161. package/resources/v1/features.js.map +1 -1
  162. package/resources/v1/features.mjs +72 -54
  163. package/resources/v1/features.mjs.map +1 -1
  164. package/resources/v1/index.d.mts +7 -7
  165. package/resources/v1/index.d.mts.map +1 -1
  166. package/resources/v1/index.d.ts +7 -7
  167. package/resources/v1/index.d.ts.map +1 -1
  168. package/resources/v1/index.js.map +1 -1
  169. package/resources/v1/index.mjs.map +1 -1
  170. package/resources/v1/plans/entitlements.d.mts +62 -36
  171. package/resources/v1/plans/entitlements.d.mts.map +1 -1
  172. package/resources/v1/plans/entitlements.d.ts +62 -36
  173. package/resources/v1/plans/entitlements.d.ts.map +1 -1
  174. package/resources/v1/plans/entitlements.js +49 -39
  175. package/resources/v1/plans/entitlements.js.map +1 -1
  176. package/resources/v1/plans/entitlements.mjs +49 -39
  177. package/resources/v1/plans/entitlements.mjs.map +1 -1
  178. package/resources/v1/plans/index.d.mts +2 -2
  179. package/resources/v1/plans/index.d.mts.map +1 -1
  180. package/resources/v1/plans/index.d.ts +2 -2
  181. package/resources/v1/plans/index.d.ts.map +1 -1
  182. package/resources/v1/plans/index.js.map +1 -1
  183. package/resources/v1/plans/index.mjs.map +1 -1
  184. package/resources/v1/plans/plans.d.mts +159 -106
  185. package/resources/v1/plans/plans.d.mts.map +1 -1
  186. package/resources/v1/plans/plans.d.ts +159 -106
  187. package/resources/v1/plans/plans.d.ts.map +1 -1
  188. package/resources/v1/plans/plans.js +127 -89
  189. package/resources/v1/plans/plans.js.map +1 -1
  190. package/resources/v1/plans/plans.mjs +127 -89
  191. package/resources/v1/plans/plans.mjs.map +1 -1
  192. package/resources/v1/products.d.mts +97 -66
  193. package/resources/v1/products.d.mts.map +1 -1
  194. package/resources/v1/products.d.ts +97 -66
  195. package/resources/v1/products.d.ts.map +1 -1
  196. package/resources/v1/products.js +73 -54
  197. package/resources/v1/products.js.map +1 -1
  198. package/resources/v1/products.mjs +73 -54
  199. package/resources/v1/products.mjs.map +1 -1
  200. package/resources/v1/subscriptions/future-update.d.mts +29 -19
  201. package/resources/v1/subscriptions/future-update.d.mts.map +1 -1
  202. package/resources/v1/subscriptions/future-update.d.ts +29 -19
  203. package/resources/v1/subscriptions/future-update.d.ts.map +1 -1
  204. package/resources/v1/subscriptions/future-update.js +25 -20
  205. package/resources/v1/subscriptions/future-update.js.map +1 -1
  206. package/resources/v1/subscriptions/future-update.mjs +25 -20
  207. package/resources/v1/subscriptions/future-update.mjs.map +1 -1
  208. package/resources/v1/subscriptions/index.d.mts +4 -4
  209. package/resources/v1/subscriptions/index.d.mts.map +1 -1
  210. package/resources/v1/subscriptions/index.d.ts +4 -4
  211. package/resources/v1/subscriptions/index.d.ts.map +1 -1
  212. package/resources/v1/subscriptions/index.js.map +1 -1
  213. package/resources/v1/subscriptions/index.mjs +1 -1
  214. package/resources/v1/subscriptions/index.mjs.map +1 -1
  215. package/resources/v1/subscriptions/invoice.d.mts +15 -8
  216. package/resources/v1/subscriptions/invoice.d.mts.map +1 -1
  217. package/resources/v1/subscriptions/invoice.d.ts +15 -8
  218. package/resources/v1/subscriptions/invoice.d.ts.map +1 -1
  219. package/resources/v1/subscriptions/invoice.js +13 -8
  220. package/resources/v1/subscriptions/invoice.js.map +1 -1
  221. package/resources/v1/subscriptions/invoice.mjs +13 -8
  222. package/resources/v1/subscriptions/invoice.mjs.map +1 -1
  223. package/resources/v1/subscriptions/subscriptions.d.mts +244 -161
  224. package/resources/v1/subscriptions/subscriptions.d.mts.map +1 -1
  225. package/resources/v1/subscriptions/subscriptions.d.ts +244 -161
  226. package/resources/v1/subscriptions/subscriptions.d.ts.map +1 -1
  227. package/resources/v1/subscriptions/subscriptions.js +126 -100
  228. package/resources/v1/subscriptions/subscriptions.js.map +1 -1
  229. package/resources/v1/subscriptions/subscriptions.mjs +128 -102
  230. package/resources/v1/subscriptions/subscriptions.mjs.map +1 -1
  231. package/resources/v1/subscriptions/usage.d.mts +29 -17
  232. package/resources/v1/subscriptions/usage.d.mts.map +1 -1
  233. package/resources/v1/subscriptions/usage.d.ts +29 -17
  234. package/resources/v1/subscriptions/usage.d.ts.map +1 -1
  235. package/resources/v1/subscriptions/usage.js +26 -17
  236. package/resources/v1/subscriptions/usage.js.map +1 -1
  237. package/resources/v1/subscriptions/usage.mjs +26 -17
  238. package/resources/v1/subscriptions/usage.mjs.map +1 -1
  239. package/resources/v1/usage.d.mts +24 -26
  240. package/resources/v1/usage.d.mts.map +1 -1
  241. package/resources/v1/usage.d.ts +24 -26
  242. package/resources/v1/usage.d.ts.map +1 -1
  243. package/resources/v1/usage.js +26 -28
  244. package/resources/v1/usage.js.map +1 -1
  245. package/resources/v1/usage.mjs +26 -28
  246. package/resources/v1/usage.mjs.map +1 -1
  247. package/resources/v1/v1.d.mts +14 -14
  248. package/resources/v1/v1.d.mts.map +1 -1
  249. package/resources/v1/v1.d.ts +14 -14
  250. package/resources/v1/v1.d.ts.map +1 -1
  251. package/resources/v1/v1.js.map +1 -1
  252. package/resources/v1/v1.mjs.map +1 -1
  253. package/resources/v1-beta/customers/assignments.d.mts +242 -0
  254. package/resources/v1-beta/customers/assignments.d.mts.map +1 -0
  255. package/resources/v1-beta/customers/assignments.d.ts +242 -0
  256. package/resources/v1-beta/customers/assignments.d.ts.map +1 -0
  257. package/resources/v1-beta/customers/assignments.js +84 -0
  258. package/resources/v1-beta/customers/assignments.js.map +1 -0
  259. package/resources/v1-beta/customers/assignments.mjs +80 -0
  260. package/resources/v1-beta/customers/assignments.mjs.map +1 -0
  261. package/resources/{v1/events/beta → v1-beta}/customers/customers.d.mts +1 -1
  262. package/resources/v1-beta/customers/customers.d.mts.map +1 -0
  263. package/resources/{v1/events/beta → v1-beta}/customers/customers.d.ts +1 -1
  264. package/resources/v1-beta/customers/customers.d.ts.map +1 -0
  265. package/resources/{v1/events/beta → v1-beta}/customers/customers.js +2 -2
  266. package/resources/v1-beta/customers/customers.js.map +1 -0
  267. package/resources/{v1/events/beta → v1-beta}/customers/customers.mjs +1 -1
  268. package/resources/v1-beta/customers/customers.mjs.map +1 -0
  269. package/resources/{v1/events/beta → v1-beta}/customers/entities.d.mts +94 -47
  270. package/resources/v1-beta/customers/entities.d.mts.map +1 -0
  271. package/resources/{v1/events/beta → v1-beta}/customers/entities.d.ts +94 -47
  272. package/resources/v1-beta/customers/entities.d.ts.map +1 -0
  273. package/resources/v1-beta/customers/entities.js +150 -0
  274. package/resources/v1-beta/customers/entities.js.map +1 -0
  275. package/resources/v1-beta/customers/entities.mjs +146 -0
  276. package/resources/v1-beta/customers/entities.mjs.map +1 -0
  277. package/resources/{v1/events/beta → v1-beta}/customers/entitlements.d.mts +27 -16
  278. package/resources/v1-beta/customers/entitlements.d.mts.map +1 -0
  279. package/resources/{v1/events/beta → v1-beta}/customers/entitlements.d.ts +27 -16
  280. package/resources/v1-beta/customers/entitlements.d.ts.map +1 -0
  281. package/resources/v1-beta/customers/entitlements.js +36 -0
  282. package/resources/v1-beta/customers/entitlements.js.map +1 -0
  283. package/resources/v1-beta/customers/entitlements.mjs +32 -0
  284. package/resources/v1-beta/customers/entitlements.mjs.map +1 -0
  285. package/resources/v1-beta/customers/index.d.mts.map +1 -0
  286. package/resources/v1-beta/customers/index.d.ts.map +1 -0
  287. package/resources/v1-beta/customers/index.js.map +1 -0
  288. package/resources/v1-beta/customers/index.mjs.map +1 -0
  289. package/resources/v1-beta/customers.d.mts.map +1 -0
  290. package/resources/v1-beta/customers.d.ts.map +1 -0
  291. package/resources/{v1/events/beta → v1-beta}/customers.js +1 -1
  292. package/resources/v1-beta/customers.js.map +1 -0
  293. package/resources/v1-beta/customers.mjs.map +1 -0
  294. package/resources/{v1/events/beta → v1-beta}/entity-types.d.mts +44 -23
  295. package/resources/v1-beta/entity-types.d.mts.map +1 -0
  296. package/resources/{v1/events/beta → v1-beta}/entity-types.d.ts +44 -23
  297. package/resources/v1-beta/entity-types.d.ts.map +1 -0
  298. package/resources/v1-beta/entity-types.js +75 -0
  299. package/resources/v1-beta/entity-types.js.map +1 -0
  300. package/resources/v1-beta/entity-types.mjs +71 -0
  301. package/resources/v1-beta/entity-types.mjs.map +1 -0
  302. package/resources/{v1/events/beta → v1-beta}/index.d.mts +1 -1
  303. package/resources/v1-beta/index.d.mts.map +1 -0
  304. package/resources/{v1/events/beta → v1-beta}/index.d.ts +1 -1
  305. package/resources/v1-beta/index.d.ts.map +1 -0
  306. package/resources/{v1/events/beta → v1-beta}/index.js +3 -3
  307. package/resources/v1-beta/index.js.map +1 -0
  308. package/resources/{v1/events/beta → v1-beta}/index.mjs +1 -1
  309. package/resources/v1-beta/index.mjs.map +1 -0
  310. package/resources/{v1/events/beta/beta.d.mts → v1-beta/v1-beta.d.mts} +4 -4
  311. package/resources/v1-beta/v1-beta.d.mts.map +1 -0
  312. package/resources/{v1/events/beta/beta.d.ts → v1-beta/v1-beta.d.ts} +4 -4
  313. package/resources/v1-beta/v1-beta.d.ts.map +1 -0
  314. package/resources/{v1/events/beta/beta.js → v1-beta/v1-beta.js} +8 -8
  315. package/resources/v1-beta/v1-beta.js.map +1 -0
  316. package/resources/{v1/events/beta/beta.mjs → v1-beta/v1-beta.mjs} +5 -5
  317. package/resources/v1-beta/v1-beta.mjs.map +1 -0
  318. package/resources/v1-beta.d.mts +2 -0
  319. package/resources/v1-beta.d.mts.map +1 -0
  320. package/resources/v1-beta.d.ts +2 -0
  321. package/resources/v1-beta.d.ts.map +1 -0
  322. package/resources/{v1/events/beta.js → v1-beta.js} +3 -3
  323. package/resources/v1-beta.js.map +1 -0
  324. package/resources/{v1/events/beta.mjs → v1-beta.mjs} +2 -2
  325. package/resources/v1-beta.mjs.map +1 -0
  326. package/src/client.ts +5 -0
  327. package/src/resources/index.ts +1 -0
  328. package/src/resources/v1/addons/addons.ts +293 -105
  329. package/src/resources/v1/addons/entitlements.ts +123 -41
  330. package/src/resources/v1/addons/index.ts +5 -0
  331. package/src/resources/v1/coupons.ts +158 -63
  332. package/src/resources/v1/credits/credits.ts +103 -50
  333. package/src/resources/v1/credits/custom-currencies.ts +191 -82
  334. package/src/resources/v1/credits/grants.ts +104 -54
  335. package/src/resources/v1/credits/index.ts +4 -0
  336. package/src/resources/v1/customers/customers.ts +324 -140
  337. package/src/resources/v1/customers/index.ts +8 -1
  338. package/src/resources/v1/customers/integrations.ts +129 -63
  339. package/src/resources/v1/customers/payment-method.ts +66 -25
  340. package/src/resources/v1/customers/promotional-entitlements.ts +82 -62
  341. package/src/resources/v1/events/data-export/data-export.ts +58 -21
  342. package/src/resources/v1/events/data-export/destinations.ts +61 -23
  343. package/src/resources/v1/events/data-export/index.ts +1 -0
  344. package/src/resources/v1/events/events.ts +28 -22
  345. package/src/resources/v1/events/index.ts +0 -1
  346. package/src/resources/v1/features.ts +209 -82
  347. package/src/resources/v1/index.ts +19 -0
  348. package/src/resources/v1/plans/entitlements.ts +123 -41
  349. package/src/resources/v1/plans/index.ts +5 -0
  350. package/src/resources/v1/plans/plans.ts +321 -119
  351. package/src/resources/v1/products.ts +193 -74
  352. package/src/resources/v1/subscriptions/future-update.ts +68 -21
  353. package/src/resources/v1/subscriptions/index.ts +9 -2
  354. package/src/resources/v1/subscriptions/invoice.ts +36 -9
  355. package/src/resources/v1/subscriptions/subscriptions.ts +417 -173
  356. package/src/resources/v1/subscriptions/usage.ts +61 -18
  357. package/src/resources/v1/usage.ts +53 -29
  358. package/src/resources/v1/v1.ts +38 -0
  359. package/src/resources/v1-beta/customers/assignments.ts +328 -0
  360. package/src/resources/{v1/events/beta → v1-beta}/customers/customers.ts +1 -1
  361. package/src/resources/{v1/events/beta → v1-beta}/customers/entities.ts +165 -54
  362. package/src/resources/{v1/events/beta → v1-beta}/customers/entitlements.ts +43 -18
  363. package/src/resources/{v1/events/beta → v1-beta}/entity-types.ts +70 -25
  364. package/src/resources/{v1/events/beta → v1-beta}/index.ts +1 -1
  365. package/src/resources/{v1/events/beta/beta.ts → v1-beta/v1-beta.ts} +5 -5
  366. package/src/resources/{v1/events/beta.ts → v1-beta.ts} +1 -1
  367. package/src/version.ts +1 -1
  368. package/version.d.mts +1 -1
  369. package/version.d.ts +1 -1
  370. package/version.js +1 -1
  371. package/version.mjs +1 -1
  372. package/resources/v1/events/beta/beta.d.mts.map +0 -1
  373. package/resources/v1/events/beta/beta.d.ts.map +0 -1
  374. package/resources/v1/events/beta/beta.js.map +0 -1
  375. package/resources/v1/events/beta/beta.mjs.map +0 -1
  376. package/resources/v1/events/beta/customers/assignments.d.mts +0 -178
  377. package/resources/v1/events/beta/customers/assignments.d.mts.map +0 -1
  378. package/resources/v1/events/beta/customers/assignments.d.ts +0 -178
  379. package/resources/v1/events/beta/customers/assignments.d.ts.map +0 -1
  380. package/resources/v1/events/beta/customers/assignments.js +0 -62
  381. package/resources/v1/events/beta/customers/assignments.js.map +0 -1
  382. package/resources/v1/events/beta/customers/assignments.mjs +0 -58
  383. package/resources/v1/events/beta/customers/assignments.mjs.map +0 -1
  384. package/resources/v1/events/beta/customers/customers.d.mts.map +0 -1
  385. package/resources/v1/events/beta/customers/customers.d.ts.map +0 -1
  386. package/resources/v1/events/beta/customers/customers.js.map +0 -1
  387. package/resources/v1/events/beta/customers/customers.mjs.map +0 -1
  388. package/resources/v1/events/beta/customers/entities.d.mts.map +0 -1
  389. package/resources/v1/events/beta/customers/entities.d.ts.map +0 -1
  390. package/resources/v1/events/beta/customers/entities.js +0 -105
  391. package/resources/v1/events/beta/customers/entities.js.map +0 -1
  392. package/resources/v1/events/beta/customers/entities.mjs +0 -101
  393. package/resources/v1/events/beta/customers/entities.mjs.map +0 -1
  394. package/resources/v1/events/beta/customers/entitlements.d.mts.map +0 -1
  395. package/resources/v1/events/beta/customers/entitlements.d.ts.map +0 -1
  396. package/resources/v1/events/beta/customers/entitlements.js +0 -26
  397. package/resources/v1/events/beta/customers/entitlements.js.map +0 -1
  398. package/resources/v1/events/beta/customers/entitlements.mjs +0 -22
  399. package/resources/v1/events/beta/customers/entitlements.mjs.map +0 -1
  400. package/resources/v1/events/beta/customers/index.d.mts.map +0 -1
  401. package/resources/v1/events/beta/customers/index.d.ts.map +0 -1
  402. package/resources/v1/events/beta/customers/index.js.map +0 -1
  403. package/resources/v1/events/beta/customers/index.mjs.map +0 -1
  404. package/resources/v1/events/beta/customers.d.mts.map +0 -1
  405. package/resources/v1/events/beta/customers.d.ts.map +0 -1
  406. package/resources/v1/events/beta/customers.js.map +0 -1
  407. package/resources/v1/events/beta/customers.mjs.map +0 -1
  408. package/resources/v1/events/beta/entity-types.d.mts.map +0 -1
  409. package/resources/v1/events/beta/entity-types.d.ts.map +0 -1
  410. package/resources/v1/events/beta/entity-types.js +0 -56
  411. package/resources/v1/events/beta/entity-types.js.map +0 -1
  412. package/resources/v1/events/beta/entity-types.mjs +0 -52
  413. package/resources/v1/events/beta/entity-types.mjs.map +0 -1
  414. package/resources/v1/events/beta/index.d.mts.map +0 -1
  415. package/resources/v1/events/beta/index.d.ts.map +0 -1
  416. package/resources/v1/events/beta/index.js.map +0 -1
  417. package/resources/v1/events/beta/index.mjs.map +0 -1
  418. package/resources/v1/events/beta.d.mts +0 -2
  419. package/resources/v1/events/beta.d.mts.map +0 -1
  420. package/resources/v1/events/beta.d.ts +0 -2
  421. package/resources/v1/events/beta.d.ts.map +0 -1
  422. package/resources/v1/events/beta.js.map +0 -1
  423. package/resources/v1/events/beta.mjs.map +0 -1
  424. package/src/resources/v1/events/beta/customers/assignments.ts +0 -228
  425. /package/resources/{v1/events/beta → v1-beta}/customers/index.d.mts +0 -0
  426. /package/resources/{v1/events/beta → v1-beta}/customers/index.d.ts +0 -0
  427. /package/resources/{v1/events/beta → v1-beta}/customers/index.js +0 -0
  428. /package/resources/{v1/events/beta → v1-beta}/customers/index.mjs +0 -0
  429. /package/resources/{v1/events/beta → v1-beta}/customers.d.mts +0 -0
  430. /package/resources/{v1/events/beta → v1-beta}/customers.d.ts +0 -0
  431. /package/resources/{v1/events/beta → v1-beta}/customers.mjs +0 -0
  432. /package/src/resources/{v1/events/beta → v1-beta}/customers/index.ts +0 -0
  433. /package/src/resources/{v1/events/beta → v1-beta}/customers.ts +0 -0
@@ -2,13 +2,25 @@
2
2
 
3
3
  import { APIResource } from '../../../core/resource';
4
4
  import * as FutureUpdateAPI from './future-update';
5
- import { CancelSubscription, FutureUpdate as FutureUpdateAPIFutureUpdate } from './future-update';
5
+ import {
6
+ CancelSubscription,
7
+ FutureUpdate as FutureUpdateAPIFutureUpdate,
8
+ FutureUpdateCancelPendingPaymentParams,
9
+ FutureUpdateCancelScheduleParams,
10
+ } from './future-update';
6
11
  import * as InvoiceAPI from './invoice';
7
- import { Invoice, InvoiceMarkAsPaidResponse } from './invoice';
12
+ import { Invoice, InvoiceMarkAsPaidParams, InvoiceMarkAsPaidResponse } from './invoice';
8
13
  import * as UsageAPI from './usage';
9
- import { Usage, UsageChargeUsageParams, UsageChargeUsageResponse, UsageSyncResponse } from './usage';
14
+ import {
15
+ Usage,
16
+ UsageChargeUsageParams,
17
+ UsageChargeUsageResponse,
18
+ UsageSyncParams,
19
+ UsageSyncResponse,
20
+ } from './usage';
10
21
  import { APIPromise } from '../../../core/api-promise';
11
22
  import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../../core/pagination';
23
+ import { buildHeaders } from '../../../internal/headers';
12
24
  import { RequestOptions } from '../../../internal/request-options';
13
25
  import { path } from '../../../internal/utils/path';
14
26
 
@@ -20,174 +32,211 @@ export class Subscriptions extends APIResource {
20
32
  /**
21
33
  * Retrieves a subscription by its unique identifier, including plan details,
22
34
  * billing period, status, and add-ons.
23
- *
24
- * @example
25
- * ```ts
26
- * const subscription = await client.v1.subscriptions.retrieve(
27
- * 'x',
28
- * );
29
- * ```
30
- */
31
- retrieve(id: string, options?: RequestOptions): APIPromise<Subscription> {
32
- return this._client.get(path`/api/v1/subscriptions/${id}`, options);
35
+ */
36
+ retrieve(
37
+ id: string,
38
+ params: SubscriptionRetrieveParams | null | undefined = {},
39
+ options?: RequestOptions,
40
+ ): APIPromise<Subscription> {
41
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID } = params ?? {};
42
+ return this._client.get(path`/api/v1/subscriptions/${id}`, {
43
+ ...options,
44
+ headers: buildHeaders([
45
+ {
46
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
47
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
48
+ },
49
+ options?.headers,
50
+ ]),
51
+ });
33
52
  }
34
53
 
35
54
  /**
36
55
  * Updates an active subscription's properties including billing period, add-ons,
37
56
  * unit quantities, and discounts.
38
- *
39
- * @example
40
- * ```ts
41
- * const subscription = await client.v1.subscriptions.update(
42
- * 'x',
43
- * );
44
- * ```
45
- */
46
- update(id: string, body: SubscriptionUpdateParams, options?: RequestOptions): APIPromise<Subscription> {
47
- return this._client.patch(path`/api/v1/subscriptions/${id}`, { body, ...options });
57
+ */
58
+ update(id: string, params: SubscriptionUpdateParams, options?: RequestOptions): APIPromise<Subscription> {
59
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...body } = params;
60
+ return this._client.patch(path`/api/v1/subscriptions/${id}`, {
61
+ body,
62
+ ...options,
63
+ headers: buildHeaders([
64
+ {
65
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
66
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
67
+ },
68
+ options?.headers,
69
+ ]),
70
+ });
48
71
  }
49
72
 
50
73
  /**
51
74
  * Retrieves a paginated list of subscriptions, with optional filters for customer,
52
75
  * status, and plan.
53
- *
54
- * @example
55
- * ```ts
56
- * // Automatically fetches more pages as needed.
57
- * for await (const subscriptionListResponse of client.v1.subscriptions.list()) {
58
- * // ...
59
- * }
60
- * ```
61
76
  */
62
77
  list(
63
- query: SubscriptionListParams | null | undefined = {},
78
+ params: SubscriptionListParams | null | undefined = {},
64
79
  options?: RequestOptions,
65
80
  ): PagePromise<SubscriptionListResponsesMyCursorIDPage, SubscriptionListResponse> {
81
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...query } = params ?? {};
66
82
  return this._client.getAPIList('/api/v1/subscriptions', MyCursorIDPage<SubscriptionListResponse>, {
67
83
  query,
68
84
  ...options,
85
+ headers: buildHeaders([
86
+ {
87
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
88
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
89
+ },
90
+ options?.headers,
91
+ ]),
69
92
  });
70
93
  }
71
94
 
72
95
  /**
73
96
  * Cancels an active subscription, either immediately or at a specified time such
74
97
  * as end of billing period.
75
- *
76
- * @example
77
- * ```ts
78
- * const subscription = await client.v1.subscriptions.cancel(
79
- * 'x',
80
- * );
81
- * ```
82
- */
83
- cancel(id: string, body: SubscriptionCancelParams, options?: RequestOptions): APIPromise<Subscription> {
84
- return this._client.post(path`/api/v1/subscriptions/${id}/cancel`, { body, ...options });
98
+ */
99
+ cancel(id: string, params: SubscriptionCancelParams, options?: RequestOptions): APIPromise<Subscription> {
100
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...body } = params;
101
+ return this._client.post(path`/api/v1/subscriptions/${id}/cancel`, {
102
+ body,
103
+ ...options,
104
+ headers: buildHeaders([
105
+ {
106
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
107
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
108
+ },
109
+ options?.headers,
110
+ ]),
111
+ });
85
112
  }
86
113
 
87
114
  /**
88
115
  * Delegates the payment responsibility of a subscription to a different customer.
89
116
  * The delegated customer will be billed for this subscription.
90
- *
91
- * @example
92
- * ```ts
93
- * const subscription = await client.v1.subscriptions.delegate(
94
- * 'x',
95
- * { targetCustomerId: 'targetCustomerId' },
96
- * );
97
- * ```
98
- */
99
- delegate(id: string, body: SubscriptionDelegateParams, options?: RequestOptions): APIPromise<Subscription> {
100
- return this._client.post(path`/api/v1/subscriptions/${id}/delegate`, { body, ...options });
117
+ */
118
+ delegate(
119
+ id: string,
120
+ params: SubscriptionDelegateParams,
121
+ options?: RequestOptions,
122
+ ): APIPromise<Subscription> {
123
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...body } = params;
124
+ return this._client.post(path`/api/v1/subscriptions/${id}/delegate`, {
125
+ body,
126
+ ...options,
127
+ headers: buildHeaders([
128
+ {
129
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
130
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
131
+ },
132
+ options?.headers,
133
+ ]),
134
+ });
101
135
  }
102
136
 
103
137
  /**
104
138
  * Imports multiple subscriptions in bulk. Used for migrating subscription data
105
139
  * from external systems.
106
- *
107
- * @example
108
- * ```ts
109
- * const response = await client.v1.subscriptions.import({
110
- * subscriptions: [
111
- * {
112
- * id: 'id',
113
- * customerId: 'customerId',
114
- * planId: 'planId',
115
- * },
116
- * ],
117
- * });
118
- * ```
119
- */
120
- import(body: SubscriptionImportParams, options?: RequestOptions): APIPromise<SubscriptionImportResponse> {
121
- return this._client.post('/api/v1/subscriptions/import', { body, ...options });
140
+ */
141
+ import(params: SubscriptionImportParams, options?: RequestOptions): APIPromise<SubscriptionImportResponse> {
142
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...body } = params;
143
+ return this._client.post('/api/v1/subscriptions/import', {
144
+ body,
145
+ ...options,
146
+ headers: buildHeaders([
147
+ {
148
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
149
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
150
+ },
151
+ options?.headers,
152
+ ]),
153
+ });
122
154
  }
123
155
 
124
156
  /**
125
157
  * Migrates a subscription to the latest published version of its plan or add-ons.
126
158
  * Handles prorated charges or credits automatically.
127
- *
128
- * @example
129
- * ```ts
130
- * const subscription = await client.v1.subscriptions.migrate(
131
- * 'x',
132
- * );
133
- * ```
134
- */
135
- migrate(id: string, body: SubscriptionMigrateParams, options?: RequestOptions): APIPromise<Subscription> {
136
- return this._client.post(path`/api/v1/subscriptions/${id}/migrate`, { body, ...options });
159
+ */
160
+ migrate(id: string, params: SubscriptionMigrateParams, options?: RequestOptions): APIPromise<Subscription> {
161
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...body } = params;
162
+ return this._client.post(path`/api/v1/subscriptions/${id}/migrate`, {
163
+ body,
164
+ ...options,
165
+ headers: buildHeaders([
166
+ {
167
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
168
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
169
+ },
170
+ options?.headers,
171
+ ]),
172
+ });
137
173
  }
138
174
 
139
175
  /**
140
176
  * Previews the pricing impact of creating or updating a subscription without
141
177
  * making changes. Returns estimated costs, taxes, and proration details.
142
- *
143
- * @example
144
- * ```ts
145
- * const response = await client.v1.subscriptions.preview({
146
- * customerId: 'customerId',
147
- * planId: 'planId',
148
- * });
149
- * ```
150
178
  */
151
179
  preview(
152
- body: SubscriptionPreviewParams,
180
+ params: SubscriptionPreviewParams,
153
181
  options?: RequestOptions,
154
182
  ): APIPromise<SubscriptionPreviewResponse> {
155
- return this._client.post('/api/v1/subscriptions/preview', { body, ...options });
183
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...body } = params;
184
+ return this._client.post('/api/v1/subscriptions/preview', {
185
+ body,
186
+ ...options,
187
+ headers: buildHeaders([
188
+ {
189
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
190
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
191
+ },
192
+ options?.headers,
193
+ ]),
194
+ });
156
195
  }
157
196
 
158
197
  /**
159
198
  * Creates a new subscription for an existing customer. When payment is required
160
199
  * and no payment method exists, returns a checkout URL.
161
- *
162
- * @example
163
- * ```ts
164
- * const response = await client.v1.subscriptions.provision({
165
- * customerId: 'customerId',
166
- * planId: 'planId',
167
- * });
168
- * ```
169
200
  */
170
201
  provision(
171
- body: SubscriptionProvisionParams,
202
+ params: SubscriptionProvisionParams,
172
203
  options?: RequestOptions,
173
204
  ): APIPromise<SubscriptionProvisionResponse> {
174
- return this._client.post('/api/v1/subscriptions', { body, ...options });
205
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...body } = params;
206
+ return this._client.post('/api/v1/subscriptions', {
207
+ body,
208
+ ...options,
209
+ headers: buildHeaders([
210
+ {
211
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
212
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
213
+ },
214
+ options?.headers,
215
+ ]),
216
+ });
175
217
  }
176
218
 
177
219
  /**
178
220
  * Transfers a subscription to a different resource ID. Used for multi-resource
179
221
  * products where subscriptions apply to specific entities like websites or apps.
180
- *
181
- * @example
182
- * ```ts
183
- * const subscription = await client.v1.subscriptions.transfer(
184
- * 'x',
185
- * { destinationResourceId: 'destinationResourceId' },
186
- * );
187
- * ```
188
- */
189
- transfer(id: string, body: SubscriptionTransferParams, options?: RequestOptions): APIPromise<Subscription> {
190
- return this._client.post(path`/api/v1/subscriptions/${id}/transfer`, { body, ...options });
222
+ */
223
+ transfer(
224
+ id: string,
225
+ params: SubscriptionTransferParams,
226
+ options?: RequestOptions,
227
+ ): APIPromise<Subscription> {
228
+ const { 'X-ACCOUNT-ID': xAccountID, 'X-ENVIRONMENT-ID': xEnvironmentID, ...body } = params;
229
+ return this._client.post(path`/api/v1/subscriptions/${id}/transfer`, {
230
+ body,
231
+ ...options,
232
+ headers: buildHeaders([
233
+ {
234
+ ...(xAccountID != null ? { 'X-ACCOUNT-ID': xAccountID } : undefined),
235
+ ...(xEnvironmentID != null ? { 'X-ENVIRONMENT-ID': xEnvironmentID } : undefined),
236
+ },
237
+ options?.headers,
238
+ ]),
239
+ });
191
240
  }
192
241
  }
193
242
 
@@ -3964,56 +4013,114 @@ export namespace SubscriptionProvisionResponse {
3964
4013
  }
3965
4014
  }
3966
4015
 
4016
+ export interface SubscriptionRetrieveParams {
4017
+ /**
4018
+ * Account ID — optional when authenticating with a user JWT (Bearer token); falls
4019
+ * back to the user's first membership. Ignored for API-key auth.
4020
+ */
4021
+ 'X-ACCOUNT-ID'?: string;
4022
+
4023
+ /**
4024
+ * Environment ID — required when authenticating with a user JWT (Bearer token) on
4025
+ * environment-scoped endpoints. Ignored for API-key auth (env is intrinsic to the
4026
+ * key).
4027
+ */
4028
+ 'X-ENVIRONMENT-ID'?: string;
4029
+ }
4030
+
3967
4031
  export interface SubscriptionUpdateParams {
4032
+ /**
4033
+ * Body param
4034
+ */
3968
4035
  addons?: Array<SubscriptionUpdateParams.Addon>;
3969
4036
 
4037
+ /**
4038
+ * Body param
4039
+ */
3970
4040
  appliedCoupon?: SubscriptionUpdateParams.AppliedCoupon;
3971
4041
 
3972
4042
  /**
3973
- * Await payment confirmation
4043
+ * Body param: Await payment confirmation
3974
4044
  */
3975
4045
  awaitPaymentConfirmation?: boolean;
3976
4046
 
4047
+ /**
4048
+ * Body param
4049
+ */
3977
4050
  billingCycleAnchor?: 'UNCHANGED' | 'NOW';
3978
4051
 
4052
+ /**
4053
+ * Body param
4054
+ */
3979
4055
  billingInformation?: SubscriptionUpdateParams.BillingInformation;
3980
4056
 
4057
+ /**
4058
+ * Body param
4059
+ */
3981
4060
  billingPeriod?: 'MONTHLY' | 'ANNUALLY';
3982
4061
 
4062
+ /**
4063
+ * Body param
4064
+ */
3983
4065
  budget?: SubscriptionUpdateParams.Budget | null;
3984
4066
 
3985
4067
  /**
3986
- * Subscription cancellation date
4068
+ * Body param: Subscription cancellation date
3987
4069
  */
3988
4070
  cancellationDate?: string | null;
3989
4071
 
4072
+ /**
4073
+ * Body param
4074
+ */
3990
4075
  charges?: Array<SubscriptionUpdateParams.Charge>;
3991
4076
 
4077
+ /**
4078
+ * Body param
4079
+ */
3992
4080
  entitlements?: Array<SubscriptionUpdateParams.Feature | SubscriptionUpdateParams.Credit>;
3993
4081
 
3994
4082
  /**
3995
- * Additional metadata for the subscription
4083
+ * Body param: Additional metadata for the subscription
3996
4084
  */
3997
4085
  metadata?: { [key: string]: string };
3998
4086
 
3999
4087
  /**
4000
- * Minimum spend amount
4088
+ * Body param: Minimum spend amount
4001
4089
  */
4002
4090
  minimumSpend?: SubscriptionUpdateParams.MinimumSpend | null;
4003
4091
 
4092
+ /**
4093
+ * Body param
4094
+ */
4004
4095
  priceOverrides?: Array<SubscriptionUpdateParams.PriceOverride>;
4005
4096
 
4006
4097
  /**
4007
- * Promotion code
4098
+ * Body param: Promotion code
4008
4099
  */
4009
4100
  promotionCode?: string;
4010
4101
 
4102
+ /**
4103
+ * Body param
4104
+ */
4011
4105
  scheduleStrategy?: 'END_OF_BILLING_PERIOD' | 'END_OF_BILLING_MONTH' | 'IMMEDIATE';
4012
4106
 
4013
4107
  /**
4014
- * Subscription trial end date
4108
+ * Body param: Subscription trial end date
4015
4109
  */
4016
4110
  trialEndDate?: string;
4111
+
4112
+ /**
4113
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
4114
+ * token); falls back to the user's first membership. Ignored for API-key auth.
4115
+ */
4116
+ 'X-ACCOUNT-ID'?: string;
4117
+
4118
+ /**
4119
+ * Header param: Environment ID — required when authenticating with a user JWT
4120
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
4121
+ * intrinsic to the key).
4122
+ */
4123
+ 'X-ENVIRONMENT-ID'?: string;
4017
4124
  }
4018
4125
 
4019
4126
  export namespace SubscriptionUpdateParams {
@@ -4696,35 +4803,49 @@ export namespace SubscriptionUpdateParams {
4696
4803
 
4697
4804
  export interface SubscriptionListParams extends MyCursorIDPageParams {
4698
4805
  /**
4699
- * Filter by creation date using range operators: gt, gte, lt, lte
4806
+ * Query param: Filter by creation date using range operators: gt, gte, lt, lte
4700
4807
  */
4701
4808
  createdAt?: SubscriptionListParams.CreatedAt;
4702
4809
 
4703
4810
  /**
4704
- * Filter by customer ID
4811
+ * Query param: Filter by customer ID
4705
4812
  */
4706
4813
  customerId?: string;
4707
4814
 
4708
4815
  /**
4709
- * Filter by plan ID
4816
+ * Query param: Filter by plan ID
4710
4817
  */
4711
4818
  planId?: string;
4712
4819
 
4713
4820
  /**
4714
- * Filter by pricing type. Supports comma-separated values for multiple types
4821
+ * Query param: Filter by pricing type. Supports comma-separated values for
4822
+ * multiple types
4715
4823
  */
4716
4824
  pricingType?: Array<'FREE' | 'PAID' | 'CUSTOM'>;
4717
4825
 
4718
4826
  /**
4719
- * Filter by resource ID
4827
+ * Query param: Filter by resource ID
4720
4828
  */
4721
4829
  resourceId?: string;
4722
4830
 
4723
4831
  /**
4724
- * Filter by subscription status. Supports comma-separated values for multiple
4725
- * statuses
4832
+ * Query param: Filter by subscription status. Supports comma-separated values for
4833
+ * multiple statuses
4726
4834
  */
4727
4835
  status?: Array<'PAYMENT_PENDING' | 'ACTIVE' | 'EXPIRED' | 'IN_TRIAL' | 'CANCELED' | 'NOT_STARTED'>;
4836
+
4837
+ /**
4838
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
4839
+ * token); falls back to the user's first membership. Ignored for API-key auth.
4840
+ */
4841
+ 'X-ACCOUNT-ID'?: string;
4842
+
4843
+ /**
4844
+ * Header param: Environment ID — required when authenticating with a user JWT
4845
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
4846
+ * intrinsic to the key).
4847
+ */
4848
+ 'X-ENVIRONMENT-ID'?: string;
4728
4849
  }
4729
4850
 
4730
4851
  export namespace SubscriptionListParams {
@@ -4756,45 +4877,86 @@ export namespace SubscriptionListParams {
4756
4877
 
4757
4878
  export interface SubscriptionCancelParams {
4758
4879
  /**
4759
- * Action on cancellation (downgrade or revoke)
4880
+ * Body param: Action on cancellation (downgrade or revoke)
4760
4881
  */
4761
4882
  cancellationAction?: 'DEFAULT' | 'REVOKE_ENTITLEMENTS';
4762
4883
 
4763
4884
  /**
4764
- * When to cancel (immediate, period end, or date)
4885
+ * Body param: When to cancel (immediate, period end, or date)
4765
4886
  */
4766
4887
  cancellationTime?: 'END_OF_BILLING_PERIOD' | 'IMMEDIATE' | 'SPECIFIC_DATE';
4767
4888
 
4768
4889
  /**
4769
- * Subscription end date
4890
+ * Body param: Subscription end date
4770
4891
  */
4771
4892
  endDate?: string;
4772
4893
 
4773
4894
  /**
4774
- * If set, enables or disables prorating of credits on subscription cancellation.
4895
+ * Body param: If set, enables or disables prorating of credits on subscription
4896
+ * cancellation.
4775
4897
  */
4776
4898
  prorate?: boolean;
4899
+
4900
+ /**
4901
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
4902
+ * token); falls back to the user's first membership. Ignored for API-key auth.
4903
+ */
4904
+ 'X-ACCOUNT-ID'?: string;
4905
+
4906
+ /**
4907
+ * Header param: Environment ID — required when authenticating with a user JWT
4908
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
4909
+ * intrinsic to the key).
4910
+ */
4911
+ 'X-ENVIRONMENT-ID'?: string;
4777
4912
  }
4778
4913
 
4779
4914
  export interface SubscriptionDelegateParams {
4780
4915
  /**
4781
- * The unique identifier of the customer who will assume payment responsibility for
4782
- * this subscription. This customer must already exist in your Stigg account and
4783
- * have a valid payment method if the subscription requires payment.
4916
+ * Body param: The unique identifier of the customer who will assume payment
4917
+ * responsibility for this subscription. This customer must already exist in your
4918
+ * Stigg account and have a valid payment method if the subscription requires
4919
+ * payment.
4784
4920
  */
4785
4921
  targetCustomerId: string;
4922
+
4923
+ /**
4924
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
4925
+ * token); falls back to the user's first membership. Ignored for API-key auth.
4926
+ */
4927
+ 'X-ACCOUNT-ID'?: string;
4928
+
4929
+ /**
4930
+ * Header param: Environment ID — required when authenticating with a user JWT
4931
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
4932
+ * intrinsic to the key).
4933
+ */
4934
+ 'X-ENVIRONMENT-ID'?: string;
4786
4935
  }
4787
4936
 
4788
4937
  export interface SubscriptionImportParams {
4789
4938
  /**
4790
- * List of subscription objects to import
4939
+ * Body param: List of subscription objects to import
4791
4940
  */
4792
4941
  subscriptions: Array<SubscriptionImportParams.Subscription>;
4793
4942
 
4794
4943
  /**
4795
- * Integration ID to use for importing subscriptions
4944
+ * Body param: Integration ID to use for importing subscriptions
4796
4945
  */
4797
4946
  integrationId?: string | null;
4947
+
4948
+ /**
4949
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
4950
+ * token); falls back to the user's first membership. Ignored for API-key auth.
4951
+ */
4952
+ 'X-ACCOUNT-ID'?: string;
4953
+
4954
+ /**
4955
+ * Header param: Environment ID — required when authenticating with a user JWT
4956
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
4957
+ * intrinsic to the key).
4958
+ */
4959
+ 'X-ENVIRONMENT-ID'?: string;
4798
4960
  }
4799
4961
 
4800
4962
  export namespace SubscriptionImportParams {
@@ -4890,91 +5052,117 @@ export namespace SubscriptionImportParams {
4890
5052
 
4891
5053
  export interface SubscriptionMigrateParams {
4892
5054
  /**
4893
- * When to migrate (immediate or period end)
5055
+ * Body param: When to migrate (immediate or period end)
4894
5056
  */
4895
5057
  subscriptionMigrationTime?: 'END_OF_BILLING_PERIOD' | 'IMMEDIATE';
5058
+
5059
+ /**
5060
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
5061
+ * token); falls back to the user's first membership. Ignored for API-key auth.
5062
+ */
5063
+ 'X-ACCOUNT-ID'?: string;
5064
+
5065
+ /**
5066
+ * Header param: Environment ID — required when authenticating with a user JWT
5067
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
5068
+ * intrinsic to the key).
5069
+ */
5070
+ 'X-ENVIRONMENT-ID'?: string;
4896
5071
  }
4897
5072
 
4898
5073
  export interface SubscriptionPreviewParams {
4899
5074
  /**
4900
- * Customer ID
5075
+ * Body param: Customer ID
4901
5076
  */
4902
5077
  customerId: string;
4903
5078
 
4904
5079
  /**
4905
- * Plan ID
5080
+ * Body param: Plan ID
4906
5081
  */
4907
5082
  planId: string;
4908
5083
 
4909
5084
  /**
4910
- * Addons to include
5085
+ * Body param: Addons to include
4911
5086
  */
4912
5087
  addons?: Array<SubscriptionPreviewParams.Addon>;
4913
5088
 
4914
5089
  /**
4915
- * Coupon or discount to apply
5090
+ * Body param: Coupon or discount to apply
4916
5091
  */
4917
5092
  appliedCoupon?: SubscriptionPreviewParams.AppliedCoupon;
4918
5093
 
4919
5094
  /**
4920
- * Billable features with quantities
5095
+ * Body param: Billable features with quantities
4921
5096
  */
4922
5097
  billableFeatures?: Array<SubscriptionPreviewParams.BillableFeature>;
4923
5098
 
4924
5099
  /**
4925
- * ISO 3166-1 country code for localization
5100
+ * Body param: ISO 3166-1 country code for localization
4926
5101
  */
4927
5102
  billingCountryCode?: string;
4928
5103
 
4929
5104
  /**
4930
- * Billing cycle anchor behavior for the subscription
5105
+ * Body param: Billing cycle anchor behavior for the subscription
4931
5106
  */
4932
5107
  billingCycleAnchor?: 'UNCHANGED' | 'NOW';
4933
5108
 
4934
5109
  /**
4935
- * Billing and tax configuration
5110
+ * Body param: Billing and tax configuration
4936
5111
  */
4937
5112
  billingInformation?: SubscriptionPreviewParams.BillingInformation;
4938
5113
 
4939
5114
  /**
4940
- * Billing period (MONTHLY or ANNUALLY)
5115
+ * Body param: Billing period (MONTHLY or ANNUALLY)
4941
5116
  */
4942
5117
  billingPeriod?: 'MONTHLY' | 'ANNUALLY';
4943
5118
 
4944
5119
  /**
4945
- * One-time or recurring charges
5120
+ * Body param: One-time or recurring charges
4946
5121
  */
4947
5122
  charges?: Array<SubscriptionPreviewParams.Charge>;
4948
5123
 
4949
5124
  /**
4950
- * Paying customer ID for delegated billing
5125
+ * Body param: Paying customer ID for delegated billing
4951
5126
  */
4952
5127
  payingCustomerId?: string;
4953
5128
 
4954
5129
  /**
4955
- * Resource ID for multi-instance subscriptions
5130
+ * Body param: Resource ID for multi-instance subscriptions
4956
5131
  */
4957
5132
  resourceId?: string;
4958
5133
 
4959
5134
  /**
4960
- * When to apply subscription changes
5135
+ * Body param: When to apply subscription changes
4961
5136
  */
4962
5137
  scheduleStrategy?: 'END_OF_BILLING_PERIOD' | 'END_OF_BILLING_MONTH' | 'IMMEDIATE';
4963
5138
 
4964
5139
  /**
4965
- * Subscription start date
5140
+ * Body param: Subscription start date
4966
5141
  */
4967
5142
  startDate?: string;
4968
5143
 
4969
5144
  /**
4970
- * Trial period override settings
5145
+ * Body param: Trial period override settings
4971
5146
  */
4972
5147
  trialOverrideConfiguration?: SubscriptionPreviewParams.TrialOverrideConfiguration;
4973
5148
 
4974
5149
  /**
4975
- * Unit quantity for per-unit pricing. Minimum is 0 (zero is allowed).
5150
+ * Body param: Unit quantity for per-unit pricing. Minimum is 0 (zero is allowed).
4976
5151
  */
4977
5152
  unitQuantity?: number;
5153
+
5154
+ /**
5155
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
5156
+ * token); falls back to the user's first membership. Ignored for API-key auth.
5157
+ */
5158
+ 'X-ACCOUNT-ID'?: string;
5159
+
5160
+ /**
5161
+ * Header param: Environment ID — required when authenticating with a user JWT
5162
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
5163
+ * intrinsic to the key).
5164
+ */
5165
+ 'X-ENVIRONMENT-ID'?: string;
4978
5166
  }
4979
5167
 
4980
5168
  export namespace SubscriptionPreviewParams {
@@ -5348,121 +5536,153 @@ export namespace SubscriptionPreviewParams {
5348
5536
 
5349
5537
  export interface SubscriptionProvisionParams {
5350
5538
  /**
5351
- * Customer ID to provision the subscription for
5539
+ * Body param: Customer ID to provision the subscription for
5352
5540
  */
5353
5541
  customerId: string;
5354
5542
 
5355
5543
  /**
5356
- * Plan ID to provision
5544
+ * Body param: Plan ID to provision
5357
5545
  */
5358
5546
  planId: string;
5359
5547
 
5360
5548
  /**
5361
- * Unique identifier for the subscription
5549
+ * Body param: Unique identifier for the subscription
5362
5550
  */
5363
5551
  id?: string;
5364
5552
 
5553
+ /**
5554
+ * Body param
5555
+ */
5365
5556
  addons?: Array<SubscriptionProvisionParams.Addon>;
5366
5557
 
5367
5558
  /**
5368
- * Coupon configuration
5559
+ * Body param: Coupon configuration
5369
5560
  */
5370
5561
  appliedCoupon?: SubscriptionProvisionParams.AppliedCoupon;
5371
5562
 
5372
5563
  /**
5373
- * Whether to wait for payment confirmation before returning the subscription
5564
+ * Body param: Whether to wait for payment confirmation before returning the
5565
+ * subscription
5374
5566
  */
5375
5567
  awaitPaymentConfirmation?: boolean;
5376
5568
 
5377
5569
  /**
5378
- * The ISO 3166-1 alpha-2 country code for billing
5570
+ * Body param: The ISO 3166-1 alpha-2 country code for billing
5379
5571
  */
5380
5572
  billingCountryCode?: string | null;
5381
5573
 
5382
5574
  /**
5383
- * Billing cycle anchor behavior for the subscription
5575
+ * Body param: Billing cycle anchor behavior for the subscription
5384
5576
  */
5385
5577
  billingCycleAnchor?: 'UNCHANGED' | 'NOW';
5386
5578
 
5387
5579
  /**
5388
- * External billing system identifier
5580
+ * Body param: External billing system identifier
5389
5581
  */
5390
5582
  billingId?: string | null;
5391
5583
 
5584
+ /**
5585
+ * Body param
5586
+ */
5392
5587
  billingInformation?: SubscriptionProvisionParams.BillingInformation;
5393
5588
 
5394
5589
  /**
5395
- * Billing period (MONTHLY or ANNUALLY)
5590
+ * Body param: Billing period (MONTHLY or ANNUALLY)
5396
5591
  */
5397
5592
  billingPeriod?: 'MONTHLY' | 'ANNUALLY';
5398
5593
 
5594
+ /**
5595
+ * Body param
5596
+ */
5399
5597
  budget?: SubscriptionProvisionParams.Budget | null;
5400
5598
 
5401
5599
  /**
5402
- * Subscription cancellation date
5600
+ * Body param: Subscription cancellation date
5403
5601
  */
5404
5602
  cancellationDate?: string;
5405
5603
 
5604
+ /**
5605
+ * Body param
5606
+ */
5406
5607
  charges?: Array<SubscriptionProvisionParams.Charge>;
5407
5608
 
5408
5609
  /**
5409
- * Checkout page configuration for payment collection
5610
+ * Body param: Checkout page configuration for payment collection
5410
5611
  */
5411
5612
  checkoutOptions?: SubscriptionProvisionParams.CheckoutOptions;
5412
5613
 
5614
+ /**
5615
+ * Body param
5616
+ */
5413
5617
  entitlements?: Array<SubscriptionProvisionParams.Feature | SubscriptionProvisionParams.Credit>;
5414
5618
 
5415
5619
  /**
5416
- * Additional metadata for the subscription
5620
+ * Body param: Additional metadata for the subscription
5417
5621
  */
5418
5622
  metadata?: { [key: string]: string };
5419
5623
 
5420
5624
  /**
5421
- * Minimum spend amount
5625
+ * Body param: Minimum spend amount
5422
5626
  */
5423
5627
  minimumSpend?: SubscriptionProvisionParams.MinimumSpend | null;
5424
5628
 
5425
5629
  /**
5426
- * Optional paying customer ID for split billing scenarios
5630
+ * Body param: Optional paying customer ID for split billing scenarios
5427
5631
  */
5428
5632
  payingCustomerId?: string | null;
5429
5633
 
5430
5634
  /**
5431
- * How payments should be collected for this subscription
5635
+ * Body param: How payments should be collected for this subscription
5432
5636
  */
5433
5637
  paymentCollectionMethod?: 'CHARGE' | 'INVOICE' | 'NONE';
5434
5638
 
5639
+ /**
5640
+ * Body param
5641
+ */
5435
5642
  priceOverrides?: Array<SubscriptionProvisionParams.PriceOverride>;
5436
5643
 
5437
5644
  /**
5438
- * Optional resource ID for multi-instance subscriptions
5645
+ * Body param: Optional resource ID for multi-instance subscriptions
5439
5646
  */
5440
5647
  resourceId?: string | null;
5441
5648
 
5442
5649
  /**
5443
- * Salesforce ID
5650
+ * Body param: Salesforce ID
5444
5651
  */
5445
5652
  salesforceId?: string | null;
5446
5653
 
5447
5654
  /**
5448
- * Strategy for scheduling subscription changes
5655
+ * Body param: Strategy for scheduling subscription changes
5449
5656
  */
5450
5657
  scheduleStrategy?: 'END_OF_BILLING_PERIOD' | 'END_OF_BILLING_MONTH' | 'IMMEDIATE';
5451
5658
 
5452
5659
  /**
5453
- * Subscription start date
5660
+ * Body param: Subscription start date
5454
5661
  */
5455
5662
  startDate?: string;
5456
5663
 
5457
5664
  /**
5458
- * Trial period override settings
5665
+ * Body param: Trial period override settings
5459
5666
  */
5460
5667
  trialOverrideConfiguration?: SubscriptionProvisionParams.TrialOverrideConfiguration;
5461
5668
 
5462
5669
  /**
5463
- * Unit quantity for per-unit pricing. Minimum is 0 (zero is allowed).
5670
+ * Body param: Unit quantity for per-unit pricing. Minimum is 0 (zero is allowed).
5464
5671
  */
5465
5672
  unitQuantity?: number;
5673
+
5674
+ /**
5675
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
5676
+ * token); falls back to the user's first membership. Ignored for API-key auth.
5677
+ */
5678
+ 'X-ACCOUNT-ID'?: string;
5679
+
5680
+ /**
5681
+ * Header param: Environment ID — required when authenticating with a user JWT
5682
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
5683
+ * intrinsic to the key).
5684
+ */
5685
+ 'X-ENVIRONMENT-ID'?: string;
5466
5686
  }
5467
5687
 
5468
5688
  export namespace SubscriptionProvisionParams {
@@ -6578,9 +6798,22 @@ export namespace SubscriptionProvisionParams {
6578
6798
 
6579
6799
  export interface SubscriptionTransferParams {
6580
6800
  /**
6581
- * Resource ID to transfer the subscription to
6801
+ * Body param: Resource ID to transfer the subscription to
6582
6802
  */
6583
6803
  destinationResourceId: string;
6804
+
6805
+ /**
6806
+ * Header param: Account ID — optional when authenticating with a user JWT (Bearer
6807
+ * token); falls back to the user's first membership. Ignored for API-key auth.
6808
+ */
6809
+ 'X-ACCOUNT-ID'?: string;
6810
+
6811
+ /**
6812
+ * Header param: Environment ID — required when authenticating with a user JWT
6813
+ * (Bearer token) on environment-scoped endpoints. Ignored for API-key auth (env is
6814
+ * intrinsic to the key).
6815
+ */
6816
+ 'X-ENVIRONMENT-ID'?: string;
6584
6817
  }
6585
6818
 
6586
6819
  Subscriptions.FutureUpdate = FutureUpdateAPIFutureUpdate;
@@ -6595,6 +6828,7 @@ export declare namespace Subscriptions {
6595
6828
  type SubscriptionPreviewResponse as SubscriptionPreviewResponse,
6596
6829
  type SubscriptionProvisionResponse as SubscriptionProvisionResponse,
6597
6830
  type SubscriptionListResponsesMyCursorIDPage as SubscriptionListResponsesMyCursorIDPage,
6831
+ type SubscriptionRetrieveParams as SubscriptionRetrieveParams,
6598
6832
  type SubscriptionUpdateParams as SubscriptionUpdateParams,
6599
6833
  type SubscriptionListParams as SubscriptionListParams,
6600
6834
  type SubscriptionCancelParams as SubscriptionCancelParams,
@@ -6606,14 +6840,24 @@ export declare namespace Subscriptions {
6606
6840
  type SubscriptionTransferParams as SubscriptionTransferParams,
6607
6841
  };
6608
6842
 
6609
- export { FutureUpdateAPIFutureUpdate as FutureUpdate, type CancelSubscription as CancelSubscription };
6843
+ export {
6844
+ FutureUpdateAPIFutureUpdate as FutureUpdate,
6845
+ type CancelSubscription as CancelSubscription,
6846
+ type FutureUpdateCancelPendingPaymentParams as FutureUpdateCancelPendingPaymentParams,
6847
+ type FutureUpdateCancelScheduleParams as FutureUpdateCancelScheduleParams,
6848
+ };
6610
6849
 
6611
6850
  export {
6612
6851
  Usage as Usage,
6613
6852
  type UsageChargeUsageResponse as UsageChargeUsageResponse,
6614
6853
  type UsageSyncResponse as UsageSyncResponse,
6615
6854
  type UsageChargeUsageParams as UsageChargeUsageParams,
6855
+ type UsageSyncParams as UsageSyncParams,
6616
6856
  };
6617
6857
 
6618
- export { Invoice as Invoice, type InvoiceMarkAsPaidResponse as InvoiceMarkAsPaidResponse };
6858
+ export {
6859
+ Invoice as Invoice,
6860
+ type InvoiceMarkAsPaidResponse as InvoiceMarkAsPaidResponse,
6861
+ type InvoiceMarkAsPaidParams as InvoiceMarkAsPaidParams,
6862
+ };
6619
6863
  }