@stigg/typescript 0.1.0-alpha.7 → 0.1.0-alpha.8

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 (190) hide show
  1. package/CHANGELOG.md +33 -0
  2. package/client.d.mts.map +1 -1
  3. package/client.d.ts.map +1 -1
  4. package/client.js +7 -0
  5. package/client.js.map +1 -1
  6. package/client.mjs +7 -0
  7. package/client.mjs.map +1 -1
  8. package/package.json +1 -1
  9. package/resources/v1/coupons.d.mts +25 -1
  10. package/resources/v1/coupons.d.mts.map +1 -1
  11. package/resources/v1/coupons.d.ts +25 -1
  12. package/resources/v1/coupons.d.ts.map +1 -1
  13. package/resources/v1/coupons.js +12 -0
  14. package/resources/v1/coupons.js.map +1 -1
  15. package/resources/v1/coupons.mjs +12 -0
  16. package/resources/v1/coupons.mjs.map +1 -1
  17. package/resources/v1/customers/customers.d.mts +2 -2
  18. package/resources/v1/customers/customers.d.mts.map +1 -1
  19. package/resources/v1/customers/customers.d.ts +2 -2
  20. package/resources/v1/customers/customers.d.ts.map +1 -1
  21. package/resources/v1/customers/customers.js.map +1 -1
  22. package/resources/v1/customers/customers.mjs.map +1 -1
  23. package/resources/v1/customers/index.d.mts +1 -1
  24. package/resources/v1/customers/index.d.mts.map +1 -1
  25. package/resources/v1/customers/index.d.ts +1 -1
  26. package/resources/v1/customers/index.d.ts.map +1 -1
  27. package/resources/v1/customers/index.js.map +1 -1
  28. package/resources/v1/customers/index.mjs.map +1 -1
  29. package/resources/v1/customers/promotional-entitlements.d.mts +155 -9
  30. package/resources/v1/customers/promotional-entitlements.d.mts.map +1 -1
  31. package/resources/v1/customers/promotional-entitlements.d.ts +155 -9
  32. package/resources/v1/customers/promotional-entitlements.d.ts.map +1 -1
  33. package/resources/v1/customers/promotional-entitlements.js +11 -4
  34. package/resources/v1/customers/promotional-entitlements.js.map +1 -1
  35. package/resources/v1/customers/promotional-entitlements.mjs +11 -4
  36. package/resources/v1/customers/promotional-entitlements.mjs.map +1 -1
  37. package/resources/v1/events/addons/addons.d.mts +605 -0
  38. package/resources/v1/events/addons/addons.d.mts.map +1 -0
  39. package/resources/v1/events/addons/addons.d.ts +605 -0
  40. package/resources/v1/events/addons/addons.d.ts.map +1 -0
  41. package/resources/v1/events/addons/addons.js +60 -0
  42. package/resources/v1/events/addons/addons.js.map +1 -0
  43. package/resources/v1/events/addons/addons.mjs +55 -0
  44. package/resources/v1/events/addons/addons.mjs.map +1 -0
  45. package/resources/v1/events/addons/draft.d.mts +121 -0
  46. package/resources/v1/events/addons/draft.d.mts.map +1 -0
  47. package/resources/v1/events/addons/draft.d.ts +121 -0
  48. package/resources/v1/events/addons/draft.d.ts.map +1 -0
  49. package/resources/v1/events/addons/draft.js +22 -0
  50. package/resources/v1/events/addons/draft.js.map +1 -0
  51. package/resources/v1/events/addons/draft.mjs +18 -0
  52. package/resources/v1/events/addons/draft.mjs.map +1 -0
  53. package/resources/v1/events/addons/index.d.mts +3 -0
  54. package/resources/v1/events/addons/index.d.mts.map +1 -0
  55. package/resources/v1/events/addons/index.d.ts +3 -0
  56. package/resources/v1/events/addons/index.d.ts.map +1 -0
  57. package/resources/v1/events/addons/index.js +9 -0
  58. package/resources/v1/events/addons/index.js.map +1 -0
  59. package/resources/v1/events/addons/index.mjs +4 -0
  60. package/resources/v1/events/addons/index.mjs.map +1 -0
  61. package/resources/v1/events/addons.d.mts +2 -0
  62. package/resources/v1/events/addons.d.mts.map +1 -0
  63. package/resources/v1/events/addons.d.ts +2 -0
  64. package/resources/v1/events/addons.d.ts.map +1 -0
  65. package/resources/v1/events/addons.js +6 -0
  66. package/resources/v1/events/addons.js.map +1 -0
  67. package/resources/v1/events/addons.mjs +3 -0
  68. package/resources/v1/events/addons.mjs.map +1 -0
  69. package/resources/v1/events/events.d.mts +75 -0
  70. package/resources/v1/events/events.d.mts.map +1 -0
  71. package/resources/v1/events/events.d.ts +75 -0
  72. package/resources/v1/events/events.d.ts.map +1 -0
  73. package/resources/v1/events/events.js +32 -0
  74. package/resources/v1/events/events.js.map +1 -0
  75. package/resources/v1/events/events.mjs +27 -0
  76. package/resources/v1/events/events.mjs.map +1 -0
  77. package/resources/v1/events/features.d.mts +856 -0
  78. package/resources/v1/events/features.d.mts.map +1 -0
  79. package/resources/v1/events/features.d.ts +856 -0
  80. package/resources/v1/events/features.d.ts.map +1 -0
  81. package/resources/v1/events/features.js +51 -0
  82. package/resources/v1/events/features.js.map +1 -0
  83. package/resources/v1/events/features.mjs +47 -0
  84. package/resources/v1/events/features.mjs.map +1 -0
  85. package/resources/v1/events/index.d.mts +5 -0
  86. package/resources/v1/events/index.d.mts.map +1 -0
  87. package/resources/v1/events/index.d.ts +5 -0
  88. package/resources/v1/events/index.d.ts.map +1 -0
  89. package/resources/v1/events/index.js +13 -0
  90. package/resources/v1/events/index.js.map +1 -0
  91. package/resources/v1/events/index.mjs +6 -0
  92. package/resources/v1/events/index.mjs.map +1 -0
  93. package/resources/v1/events/plans.d.mts +348 -0
  94. package/resources/v1/events/plans.d.mts.map +1 -0
  95. package/resources/v1/events/plans.d.ts +348 -0
  96. package/resources/v1/events/plans.d.ts.map +1 -0
  97. package/resources/v1/events/plans.js +30 -0
  98. package/resources/v1/events/plans.js.map +1 -0
  99. package/resources/v1/events/plans.mjs +26 -0
  100. package/resources/v1/events/plans.mjs.map +1 -0
  101. package/resources/v1/events.d.mts +1 -62
  102. package/resources/v1/events.d.mts.map +1 -1
  103. package/resources/v1/events.d.ts +1 -62
  104. package/resources/v1/events.d.ts.map +1 -1
  105. package/resources/v1/events.js +2 -12
  106. package/resources/v1/events.js.map +1 -1
  107. package/resources/v1/events.mjs +1 -10
  108. package/resources/v1/events.mjs.map +1 -1
  109. package/resources/v1/index.d.mts +3 -3
  110. package/resources/v1/index.d.mts.map +1 -1
  111. package/resources/v1/index.d.ts +3 -3
  112. package/resources/v1/index.d.ts.map +1 -1
  113. package/resources/v1/index.js +4 -4
  114. package/resources/v1/index.js.map +1 -1
  115. package/resources/v1/index.mjs +1 -1
  116. package/resources/v1/index.mjs.map +1 -1
  117. package/resources/v1/products.d.mts +547 -1
  118. package/resources/v1/products.d.mts.map +1 -1
  119. package/resources/v1/products.d.ts +547 -1
  120. package/resources/v1/products.d.ts.map +1 -1
  121. package/resources/v1/products.js +33 -0
  122. package/resources/v1/products.js.map +1 -1
  123. package/resources/v1/products.mjs +33 -0
  124. package/resources/v1/products.mjs.map +1 -1
  125. package/resources/v1/subscriptions/index.d.mts +2 -0
  126. package/resources/v1/subscriptions/index.d.mts.map +1 -1
  127. package/resources/v1/subscriptions/index.d.ts +2 -0
  128. package/resources/v1/subscriptions/index.d.ts.map +1 -1
  129. package/resources/v1/subscriptions/index.js +5 -1
  130. package/resources/v1/subscriptions/index.js.map +1 -1
  131. package/resources/v1/subscriptions/index.mjs +2 -0
  132. package/resources/v1/subscriptions/index.mjs.map +1 -1
  133. package/resources/v1/subscriptions/invoice.d.mts +34 -0
  134. package/resources/v1/subscriptions/invoice.d.mts.map +1 -0
  135. package/resources/v1/subscriptions/invoice.d.ts +34 -0
  136. package/resources/v1/subscriptions/invoice.d.ts.map +1 -0
  137. package/resources/v1/subscriptions/invoice.js +17 -0
  138. package/resources/v1/subscriptions/invoice.js.map +1 -0
  139. package/resources/v1/subscriptions/invoice.mjs +13 -0
  140. package/resources/v1/subscriptions/invoice.mjs.map +1 -0
  141. package/resources/v1/subscriptions/subscriptions.d.mts +15 -7
  142. package/resources/v1/subscriptions/subscriptions.d.mts.map +1 -1
  143. package/resources/v1/subscriptions/subscriptions.d.ts +15 -7
  144. package/resources/v1/subscriptions/subscriptions.d.ts.map +1 -1
  145. package/resources/v1/subscriptions/subscriptions.js +8 -0
  146. package/resources/v1/subscriptions/subscriptions.js.map +1 -1
  147. package/resources/v1/subscriptions/subscriptions.mjs +8 -0
  148. package/resources/v1/subscriptions/subscriptions.mjs.map +1 -1
  149. package/resources/v1/subscriptions/usage.d.mts +98 -0
  150. package/resources/v1/subscriptions/usage.d.mts.map +1 -0
  151. package/resources/v1/subscriptions/usage.d.ts +98 -0
  152. package/resources/v1/subscriptions/usage.d.ts.map +1 -0
  153. package/resources/v1/subscriptions/usage.js +24 -0
  154. package/resources/v1/subscriptions/usage.js.map +1 -0
  155. package/resources/v1/subscriptions/usage.mjs +20 -0
  156. package/resources/v1/subscriptions/usage.mjs.map +1 -0
  157. package/resources/v1/v1.d.mts +6 -6
  158. package/resources/v1/v1.d.mts.map +1 -1
  159. package/resources/v1/v1.d.ts +6 -6
  160. package/resources/v1/v1.d.ts.map +1 -1
  161. package/resources/v1/v1.js +2 -2
  162. package/resources/v1/v1.js.map +1 -1
  163. package/resources/v1/v1.mjs +2 -2
  164. package/resources/v1/v1.mjs.map +1 -1
  165. package/src/client.ts +8 -0
  166. package/src/resources/v1/coupons.ts +32 -0
  167. package/src/resources/v1/customers/customers.ts +10 -4
  168. package/src/resources/v1/customers/index.ts +5 -2
  169. package/src/resources/v1/customers/promotional-entitlements.ts +217 -16
  170. package/src/resources/v1/events/addons/addons.ts +761 -0
  171. package/src/resources/v1/events/addons/draft.ts +151 -0
  172. package/src/resources/v1/events/addons/index.ts +17 -0
  173. package/src/resources/v1/events/addons.ts +3 -0
  174. package/src/resources/v1/events/events.ts +160 -0
  175. package/src/resources/v1/events/features.ts +1066 -0
  176. package/src/resources/v1/events/index.ts +39 -0
  177. package/src/resources/v1/events/plans.ts +429 -0
  178. package/src/resources/v1/events.ts +1 -72
  179. package/src/resources/v1/index.ts +10 -1
  180. package/src/resources/v1/products.ts +667 -0
  181. package/src/resources/v1/subscriptions/index.ts +7 -0
  182. package/src/resources/v1/subscriptions/invoice.ts +42 -0
  183. package/src/resources/v1/subscriptions/subscriptions.ts +24 -7
  184. package/src/resources/v1/subscriptions/usage.ts +126 -0
  185. package/src/resources/v1/v1.ts +20 -2
  186. package/src/version.ts +1 -1
  187. package/version.d.mts +1 -1
  188. package/version.d.ts +1 -1
  189. package/version.js +1 -1
  190. package/version.mjs +1 -1
@@ -0,0 +1,605 @@
1
+ import { APIResource } from "../../../../core/resource.js";
2
+ import * as DraftAPI from "./draft.js";
3
+ import { Draft, DraftCreateAddonDraftResponse, DraftRemoveAddonDraftResponse } from "./draft.js";
4
+ import { APIPromise } from "../../../../core/api-promise.js";
5
+ import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from "../../../../core/pagination.js";
6
+ import { RequestOptions } from "../../../../internal/request-options.js";
7
+ export declare class Addons extends APIResource {
8
+ draft: DraftAPI.Draft;
9
+ /**
10
+ * Archives an addon, preventing it from being used in new subscriptions.
11
+ */
12
+ archiveAddon(id: string, options?: RequestOptions): APIPromise<AddonArchiveAddonResponse>;
13
+ /**
14
+ * Creates a new addon in draft status, associated with a specific product.
15
+ */
16
+ createAddon(body: AddonCreateAddonParams, options?: RequestOptions): APIPromise<AddonCreateAddonResponse>;
17
+ /**
18
+ * Retrieves a paginated list of addons in the environment.
19
+ */
20
+ listAddons(query?: AddonListAddonsParams | null | undefined, options?: RequestOptions): PagePromise<AddonListAddonsResponsesMyCursorIDPage, AddonListAddonsResponse>;
21
+ /**
22
+ * Publishes a draft addon, making it available for use in subscriptions.
23
+ */
24
+ publishAddon(id: string, body: AddonPublishAddonParams, options?: RequestOptions): APIPromise<AddonPublishAddonResponse>;
25
+ /**
26
+ * Retrieves an addon by its unique identifier, including entitlements and pricing
27
+ * details.
28
+ */
29
+ retrieveAddon(id: string, options?: RequestOptions): APIPromise<AddonRetrieveAddonResponse>;
30
+ /**
31
+ * Updates an existing addon's properties such as display name, description, and
32
+ * metadata.
33
+ */
34
+ updateAddon(id: string, body: AddonUpdateAddonParams, options?: RequestOptions): APIPromise<AddonUpdateAddonResponse>;
35
+ }
36
+ export type AddonListAddonsResponsesMyCursorIDPage = MyCursorIDPage<AddonListAddonsResponse>;
37
+ /**
38
+ * Response object
39
+ */
40
+ export interface AddonArchiveAddonResponse {
41
+ /**
42
+ * Addon configuration object
43
+ */
44
+ data: AddonArchiveAddonResponse.Data;
45
+ }
46
+ export declare namespace AddonArchiveAddonResponse {
47
+ /**
48
+ * Addon configuration object
49
+ */
50
+ interface Data {
51
+ /**
52
+ * The unique identifier for the entity
53
+ */
54
+ id: string;
55
+ /**
56
+ * The unique identifier for the entity in the billing provider
57
+ */
58
+ billingId: string | null;
59
+ /**
60
+ * Timestamp of when the record was created
61
+ */
62
+ createdAt: string;
63
+ /**
64
+ * List of addons the addon is dependant on
65
+ */
66
+ dependencies: Array<string> | null;
67
+ /**
68
+ * The description of the package
69
+ */
70
+ description: string | null;
71
+ /**
72
+ * The display name of the package
73
+ */
74
+ displayName: string;
75
+ /**
76
+ * List of entitlements of the package
77
+ */
78
+ entitlements: Array<Data.Entitlement>;
79
+ /**
80
+ * Indicates if the package is the latest version
81
+ */
82
+ isLatest: boolean | null;
83
+ /**
84
+ * The maximum quantity of this addon that can be added to a subscription
85
+ */
86
+ maxQuantity: number | null;
87
+ /**
88
+ * Metadata associated with the entity
89
+ */
90
+ metadata: {
91
+ [key: string]: string;
92
+ };
93
+ /**
94
+ * The pricing type of the package
95
+ */
96
+ pricingType: 'FREE' | 'PAID' | 'CUSTOM' | null;
97
+ /**
98
+ * The product id of the package
99
+ */
100
+ productId: string;
101
+ /**
102
+ * The status of the package
103
+ */
104
+ status: 'DRAFT' | 'PUBLISHED' | 'ARCHIVED';
105
+ /**
106
+ * Timestamp of when the record was last updated
107
+ */
108
+ updatedAt: string;
109
+ /**
110
+ * The version number of the package
111
+ */
112
+ versionNumber: number;
113
+ }
114
+ namespace Data {
115
+ /**
116
+ * Entitlement reference with type and identifier
117
+ */
118
+ interface Entitlement {
119
+ /**
120
+ * The unique identifier for the entity
121
+ */
122
+ id: string;
123
+ type: 'FEATURE' | 'CREDIT';
124
+ }
125
+ }
126
+ }
127
+ /**
128
+ * Response object
129
+ */
130
+ export interface AddonCreateAddonResponse {
131
+ /**
132
+ * Addon configuration object
133
+ */
134
+ data: AddonCreateAddonResponse.Data;
135
+ }
136
+ export declare namespace AddonCreateAddonResponse {
137
+ /**
138
+ * Addon configuration object
139
+ */
140
+ interface Data {
141
+ /**
142
+ * The unique identifier for the entity
143
+ */
144
+ id: string;
145
+ /**
146
+ * The unique identifier for the entity in the billing provider
147
+ */
148
+ billingId: string | null;
149
+ /**
150
+ * Timestamp of when the record was created
151
+ */
152
+ createdAt: string;
153
+ /**
154
+ * List of addons the addon is dependant on
155
+ */
156
+ dependencies: Array<string> | null;
157
+ /**
158
+ * The description of the package
159
+ */
160
+ description: string | null;
161
+ /**
162
+ * The display name of the package
163
+ */
164
+ displayName: string;
165
+ /**
166
+ * List of entitlements of the package
167
+ */
168
+ entitlements: Array<Data.Entitlement>;
169
+ /**
170
+ * Indicates if the package is the latest version
171
+ */
172
+ isLatest: boolean | null;
173
+ /**
174
+ * The maximum quantity of this addon that can be added to a subscription
175
+ */
176
+ maxQuantity: number | null;
177
+ /**
178
+ * Metadata associated with the entity
179
+ */
180
+ metadata: {
181
+ [key: string]: string;
182
+ };
183
+ /**
184
+ * The pricing type of the package
185
+ */
186
+ pricingType: 'FREE' | 'PAID' | 'CUSTOM' | null;
187
+ /**
188
+ * The product id of the package
189
+ */
190
+ productId: string;
191
+ /**
192
+ * The status of the package
193
+ */
194
+ status: 'DRAFT' | 'PUBLISHED' | 'ARCHIVED';
195
+ /**
196
+ * Timestamp of when the record was last updated
197
+ */
198
+ updatedAt: string;
199
+ /**
200
+ * The version number of the package
201
+ */
202
+ versionNumber: number;
203
+ }
204
+ namespace Data {
205
+ /**
206
+ * Entitlement reference with type and identifier
207
+ */
208
+ interface Entitlement {
209
+ /**
210
+ * The unique identifier for the entity
211
+ */
212
+ id: string;
213
+ type: 'FEATURE' | 'CREDIT';
214
+ }
215
+ }
216
+ }
217
+ /**
218
+ * Addon configuration object
219
+ */
220
+ export interface AddonListAddonsResponse {
221
+ /**
222
+ * The unique identifier for the entity
223
+ */
224
+ id: string;
225
+ /**
226
+ * The unique identifier for the entity in the billing provider
227
+ */
228
+ billingId: string | null;
229
+ /**
230
+ * Timestamp of when the record was created
231
+ */
232
+ createdAt: string;
233
+ /**
234
+ * List of addons the addon is dependant on
235
+ */
236
+ dependencies: Array<string> | null;
237
+ /**
238
+ * The description of the package
239
+ */
240
+ description: string | null;
241
+ /**
242
+ * The display name of the package
243
+ */
244
+ displayName: string;
245
+ /**
246
+ * List of entitlements of the package
247
+ */
248
+ entitlements: Array<AddonListAddonsResponse.Entitlement>;
249
+ /**
250
+ * Indicates if the package is the latest version
251
+ */
252
+ isLatest: boolean | null;
253
+ /**
254
+ * The maximum quantity of this addon that can be added to a subscription
255
+ */
256
+ maxQuantity: number | null;
257
+ /**
258
+ * Metadata associated with the entity
259
+ */
260
+ metadata: {
261
+ [key: string]: string;
262
+ };
263
+ /**
264
+ * The pricing type of the package
265
+ */
266
+ pricingType: 'FREE' | 'PAID' | 'CUSTOM' | null;
267
+ /**
268
+ * The product id of the package
269
+ */
270
+ productId: string;
271
+ /**
272
+ * The status of the package
273
+ */
274
+ status: 'DRAFT' | 'PUBLISHED' | 'ARCHIVED';
275
+ /**
276
+ * Timestamp of when the record was last updated
277
+ */
278
+ updatedAt: string;
279
+ /**
280
+ * The version number of the package
281
+ */
282
+ versionNumber: number;
283
+ }
284
+ export declare namespace AddonListAddonsResponse {
285
+ /**
286
+ * Entitlement reference with type and identifier
287
+ */
288
+ interface Entitlement {
289
+ /**
290
+ * The unique identifier for the entity
291
+ */
292
+ id: string;
293
+ type: 'FEATURE' | 'CREDIT';
294
+ }
295
+ }
296
+ /**
297
+ * Response containing task ID for publish operation
298
+ */
299
+ export interface AddonPublishAddonResponse {
300
+ data: AddonPublishAddonResponse.Data;
301
+ }
302
+ export declare namespace AddonPublishAddonResponse {
303
+ interface Data {
304
+ /**
305
+ * Task ID for tracking the async publish operation
306
+ */
307
+ taskId: string | null;
308
+ }
309
+ }
310
+ /**
311
+ * Response object
312
+ */
313
+ export interface AddonRetrieveAddonResponse {
314
+ /**
315
+ * Addon configuration object
316
+ */
317
+ data: AddonRetrieveAddonResponse.Data;
318
+ }
319
+ export declare namespace AddonRetrieveAddonResponse {
320
+ /**
321
+ * Addon configuration object
322
+ */
323
+ interface Data {
324
+ /**
325
+ * The unique identifier for the entity
326
+ */
327
+ id: string;
328
+ /**
329
+ * The unique identifier for the entity in the billing provider
330
+ */
331
+ billingId: string | null;
332
+ /**
333
+ * Timestamp of when the record was created
334
+ */
335
+ createdAt: string;
336
+ /**
337
+ * List of addons the addon is dependant on
338
+ */
339
+ dependencies: Array<string> | null;
340
+ /**
341
+ * The description of the package
342
+ */
343
+ description: string | null;
344
+ /**
345
+ * The display name of the package
346
+ */
347
+ displayName: string;
348
+ /**
349
+ * List of entitlements of the package
350
+ */
351
+ entitlements: Array<Data.Entitlement>;
352
+ /**
353
+ * Indicates if the package is the latest version
354
+ */
355
+ isLatest: boolean | null;
356
+ /**
357
+ * The maximum quantity of this addon that can be added to a subscription
358
+ */
359
+ maxQuantity: number | null;
360
+ /**
361
+ * Metadata associated with the entity
362
+ */
363
+ metadata: {
364
+ [key: string]: string;
365
+ };
366
+ /**
367
+ * The pricing type of the package
368
+ */
369
+ pricingType: 'FREE' | 'PAID' | 'CUSTOM' | null;
370
+ /**
371
+ * The product id of the package
372
+ */
373
+ productId: string;
374
+ /**
375
+ * The status of the package
376
+ */
377
+ status: 'DRAFT' | 'PUBLISHED' | 'ARCHIVED';
378
+ /**
379
+ * Timestamp of when the record was last updated
380
+ */
381
+ updatedAt: string;
382
+ /**
383
+ * The version number of the package
384
+ */
385
+ versionNumber: number;
386
+ }
387
+ namespace Data {
388
+ /**
389
+ * Entitlement reference with type and identifier
390
+ */
391
+ interface Entitlement {
392
+ /**
393
+ * The unique identifier for the entity
394
+ */
395
+ id: string;
396
+ type: 'FEATURE' | 'CREDIT';
397
+ }
398
+ }
399
+ }
400
+ /**
401
+ * Response object
402
+ */
403
+ export interface AddonUpdateAddonResponse {
404
+ /**
405
+ * Addon configuration object
406
+ */
407
+ data: AddonUpdateAddonResponse.Data;
408
+ }
409
+ export declare namespace AddonUpdateAddonResponse {
410
+ /**
411
+ * Addon configuration object
412
+ */
413
+ interface Data {
414
+ /**
415
+ * The unique identifier for the entity
416
+ */
417
+ id: string;
418
+ /**
419
+ * The unique identifier for the entity in the billing provider
420
+ */
421
+ billingId: string | null;
422
+ /**
423
+ * Timestamp of when the record was created
424
+ */
425
+ createdAt: string;
426
+ /**
427
+ * List of addons the addon is dependant on
428
+ */
429
+ dependencies: Array<string> | null;
430
+ /**
431
+ * The description of the package
432
+ */
433
+ description: string | null;
434
+ /**
435
+ * The display name of the package
436
+ */
437
+ displayName: string;
438
+ /**
439
+ * List of entitlements of the package
440
+ */
441
+ entitlements: Array<Data.Entitlement>;
442
+ /**
443
+ * Indicates if the package is the latest version
444
+ */
445
+ isLatest: boolean | null;
446
+ /**
447
+ * The maximum quantity of this addon that can be added to a subscription
448
+ */
449
+ maxQuantity: number | null;
450
+ /**
451
+ * Metadata associated with the entity
452
+ */
453
+ metadata: {
454
+ [key: string]: string;
455
+ };
456
+ /**
457
+ * The pricing type of the package
458
+ */
459
+ pricingType: 'FREE' | 'PAID' | 'CUSTOM' | null;
460
+ /**
461
+ * The product id of the package
462
+ */
463
+ productId: string;
464
+ /**
465
+ * The status of the package
466
+ */
467
+ status: 'DRAFT' | 'PUBLISHED' | 'ARCHIVED';
468
+ /**
469
+ * Timestamp of when the record was last updated
470
+ */
471
+ updatedAt: string;
472
+ /**
473
+ * The version number of the package
474
+ */
475
+ versionNumber: number;
476
+ }
477
+ namespace Data {
478
+ /**
479
+ * Entitlement reference with type and identifier
480
+ */
481
+ interface Entitlement {
482
+ /**
483
+ * The unique identifier for the entity
484
+ */
485
+ id: string;
486
+ type: 'FEATURE' | 'CREDIT';
487
+ }
488
+ }
489
+ }
490
+ export interface AddonCreateAddonParams {
491
+ /**
492
+ * The unique identifier for the entity
493
+ */
494
+ id: string;
495
+ /**
496
+ * The display name of the package
497
+ */
498
+ displayName: string;
499
+ /**
500
+ * The product id of the package
501
+ */
502
+ productId: string;
503
+ /**
504
+ * The unique identifier for the entity in the billing provider
505
+ */
506
+ billingId?: string | null;
507
+ /**
508
+ * The description of the package
509
+ */
510
+ description?: string | null;
511
+ /**
512
+ * The maximum quantity of this addon that can be added to a subscription
513
+ */
514
+ maxQuantity?: number | null;
515
+ /**
516
+ * Metadata associated with the entity
517
+ */
518
+ metadata?: {
519
+ [key: string]: string;
520
+ };
521
+ /**
522
+ * The pricing type of the package
523
+ */
524
+ pricingType?: 'FREE' | 'PAID' | 'CUSTOM' | null;
525
+ /**
526
+ * The status of the package
527
+ */
528
+ status?: 'DRAFT' | 'PUBLISHED' | 'ARCHIVED';
529
+ }
530
+ export interface AddonListAddonsParams extends MyCursorIDPageParams {
531
+ /**
532
+ * Filter by creation date using range operators: gt, gte, lt, lte
533
+ */
534
+ createdAt?: AddonListAddonsParams.CreatedAt;
535
+ /**
536
+ * Filter by product ID
537
+ */
538
+ productId?: string;
539
+ /**
540
+ * Filter by status. Supports comma-separated values for multiple statuses
541
+ */
542
+ status?: string;
543
+ }
544
+ export declare namespace AddonListAddonsParams {
545
+ /**
546
+ * Filter by creation date using range operators: gt, gte, lt, lte
547
+ */
548
+ interface CreatedAt {
549
+ /**
550
+ * Greater than the specified createdAt value
551
+ */
552
+ gt?: string;
553
+ /**
554
+ * Greater than or equal to the specified createdAt value
555
+ */
556
+ gte?: string;
557
+ /**
558
+ * Less than the specified createdAt value
559
+ */
560
+ lt?: string;
561
+ /**
562
+ * Less than or equal to the specified createdAt value
563
+ */
564
+ lte?: string;
565
+ }
566
+ }
567
+ export interface AddonPublishAddonParams {
568
+ /**
569
+ * The migration type of the package
570
+ */
571
+ migrationType: 'NEW_CUSTOMERS' | 'ALL_CUSTOMERS';
572
+ }
573
+ export interface AddonUpdateAddonParams {
574
+ /**
575
+ * The unique identifier for the entity in the billing provider
576
+ */
577
+ billingId?: string | null;
578
+ /**
579
+ * List of addons the addon is dependant on
580
+ */
581
+ dependencies?: Array<string> | null;
582
+ /**
583
+ * The description of the package
584
+ */
585
+ description?: string | null;
586
+ /**
587
+ * The display name of the package
588
+ */
589
+ displayName?: string;
590
+ /**
591
+ * The maximum quantity of this addon that can be added to a subscription
592
+ */
593
+ maxQuantity?: number | null;
594
+ /**
595
+ * Metadata associated with the entity
596
+ */
597
+ metadata?: {
598
+ [key: string]: string;
599
+ };
600
+ }
601
+ export declare namespace Addons {
602
+ export { type AddonArchiveAddonResponse as AddonArchiveAddonResponse, type AddonCreateAddonResponse as AddonCreateAddonResponse, type AddonListAddonsResponse as AddonListAddonsResponse, type AddonPublishAddonResponse as AddonPublishAddonResponse, type AddonRetrieveAddonResponse as AddonRetrieveAddonResponse, type AddonUpdateAddonResponse as AddonUpdateAddonResponse, type AddonListAddonsResponsesMyCursorIDPage as AddonListAddonsResponsesMyCursorIDPage, type AddonCreateAddonParams as AddonCreateAddonParams, type AddonListAddonsParams as AddonListAddonsParams, type AddonPublishAddonParams as AddonPublishAddonParams, type AddonUpdateAddonParams as AddonUpdateAddonParams, };
603
+ export { Draft as Draft, type DraftCreateAddonDraftResponse as DraftCreateAddonDraftResponse, type DraftRemoveAddonDraftResponse as DraftRemoveAddonDraftResponse, };
604
+ }
605
+ //# sourceMappingURL=addons.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"addons.d.ts","sourceRoot":"","sources":["../../../../src/resources/v1/events/addons/addons.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,QAAQ;OACb,EAAE,KAAK,EAAE,6BAA6B,EAAE,6BAA6B,EAAE;OACvE,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE,KAAK,oBAAoB,EAAE,WAAW,EAAE;OAC1D,EAAE,cAAc,EAAE;AAGzB,qBAAa,MAAO,SAAQ,WAAW;IACrC,KAAK,EAAE,QAAQ,CAAC,KAAK,CAAoC;IAEzD;;OAEG;IACH,YAAY,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,yBAAy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KAAK,sCAAsC,IAAI,sCAAsC,EACrF,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,sBAAsB,IAAI,sBAAsB,GACtD,CAAC;IAEF,OAAO,EACL,KAAK,IAAI,KAAK,EACd,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,6BAA6B,IAAI,6BAA6B,GACpE,CAAC;CACH"}
@@ -0,0 +1,60 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.Addons = void 0;
5
+ const tslib_1 = require("../../../../internal/tslib.js");
6
+ const resource_1 = require("../../../../core/resource.js");
7
+ const DraftAPI = tslib_1.__importStar(require("./draft.js"));
8
+ const draft_1 = require("./draft.js");
9
+ const pagination_1 = require("../../../../core/pagination.js");
10
+ const path_1 = require("../../../../internal/utils/path.js");
11
+ class Addons extends resource_1.APIResource {
12
+ constructor() {
13
+ super(...arguments);
14
+ this.draft = new DraftAPI.Draft(this._client);
15
+ }
16
+ /**
17
+ * Archives an addon, preventing it from being used in new subscriptions.
18
+ */
19
+ archiveAddon(id, options) {
20
+ return this._client.post((0, path_1.path) `/api/v1/addons/${id}/archive`, options);
21
+ }
22
+ /**
23
+ * Creates a new addon in draft status, associated with a specific product.
24
+ */
25
+ createAddon(body, options) {
26
+ return this._client.post('/api/v1/addons', { body, ...options });
27
+ }
28
+ /**
29
+ * Retrieves a paginated list of addons in the environment.
30
+ */
31
+ listAddons(query = {}, options) {
32
+ return this._client.getAPIList('/api/v1/addons', (pagination_1.MyCursorIDPage), {
33
+ query,
34
+ ...options,
35
+ });
36
+ }
37
+ /**
38
+ * Publishes a draft addon, making it available for use in subscriptions.
39
+ */
40
+ publishAddon(id, body, options) {
41
+ return this._client.post((0, path_1.path) `/api/v1/addons/${id}/publish`, { body, ...options });
42
+ }
43
+ /**
44
+ * Retrieves an addon by its unique identifier, including entitlements and pricing
45
+ * details.
46
+ */
47
+ retrieveAddon(id, options) {
48
+ return this._client.get((0, path_1.path) `/api/v1/addons/${id}`, options);
49
+ }
50
+ /**
51
+ * Updates an existing addon's properties such as display name, description, and
52
+ * metadata.
53
+ */
54
+ updateAddon(id, body, options) {
55
+ return this._client.patch((0, path_1.path) `/api/v1/addons/${id}`, { body, ...options });
56
+ }
57
+ }
58
+ exports.Addons = Addons;
59
+ Addons.Draft = draft_1.Draft;
60
+ //# sourceMappingURL=addons.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"addons.js","sourceRoot":"","sources":["../../../../src/resources/v1/events/addons/addons.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,2DAAwD;AACxD,6DAAoC;AACpC,sCAA8F;AAE9F,+DAAqG;AAErG,6DAAuD;AAEvD,MAAa,MAAO,SAAQ,sBAAW;IAAvC;;QACE,UAAK,GAAmB,IAAI,QAAQ,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IA2D3D,CAAC;IAzDC;;OAEG;IACH,YAAY,CAAC,EAAU,EAAE,OAAwB;QAC/C,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAA,WAAI,EAAA,kBAAkB,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC;IACxE,CAAC;IAED;;OAEG;IACH,WAAW,CAAC,IAA4B,EAAE,OAAwB;QAChE,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,gBAAgB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACnE,CAAC;IAED;;OAEG;IACH,UAAU,CACR,QAAkD,EAAE,EACpD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,gBAAgB,EAAE,CAAA,2BAAuC,CAAA,EAAE;YACxF,KAAK;YACL,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;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