chargebee 3.0.0-beta.5 → 3.0.1

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 (82) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/README.md +9 -8
  3. package/cjs/environment.js +1 -1
  4. package/esm/environment.js +1 -1
  5. package/package.json +1 -1
  6. package/types/core.d.ts +0 -574
  7. package/types/index.d.ts +0 -167
  8. package/types/resources/Address.d.ts +0 -71
  9. package/types/resources/AdvanceInvoiceSchedule.d.ts +0 -29
  10. package/types/resources/AttachedItem.d.ts +0 -114
  11. package/types/resources/Attribute.d.ts +0 -9
  12. package/types/resources/BusinessEntity.d.ts +0 -64
  13. package/types/resources/BusinessEntityTransfer.d.ts +0 -15
  14. package/types/resources/Card.d.ts +0 -171
  15. package/types/resources/Comment.d.ts +0 -89
  16. package/types/resources/Contact.d.ts +0 -16
  17. package/types/resources/ContractTerm.d.ts +0 -19
  18. package/types/resources/Coupon.d.ts +0 -314
  19. package/types/resources/CouponCode.d.ts +0 -70
  20. package/types/resources/CouponSet.d.ts +0 -111
  21. package/types/resources/CreditNote.d.ts +0 -628
  22. package/types/resources/CreditNoteEstimate.d.ts +0 -143
  23. package/types/resources/Currency.d.ts +0 -91
  24. package/types/resources/Customer.d.ts +0 -962
  25. package/types/resources/CustomerEntitlement.d.ts +0 -36
  26. package/types/resources/DifferentialPrice.d.ts +0 -142
  27. package/types/resources/Discount.d.ts +0 -24
  28. package/types/resources/Download.d.ts +0 -10
  29. package/types/resources/Entitlement.d.ts +0 -66
  30. package/types/resources/EntitlementOverride.d.ts +0 -76
  31. package/types/resources/Estimate.d.ts +0 -1237
  32. package/types/resources/Event.d.ts +0 -81
  33. package/types/resources/Export.d.ts +0 -607
  34. package/types/resources/Feature.d.ts +0 -142
  35. package/types/resources/GatewayErrorDetail.d.ts +0 -20
  36. package/types/resources/Gift.d.ts +0 -296
  37. package/types/resources/Hierarchy.d.ts +0 -12
  38. package/types/resources/HostedPage.d.ts +0 -1112
  39. package/types/resources/ImpactedItem.d.ts +0 -20
  40. package/types/resources/ImpactedItemPrice.d.ts +0 -20
  41. package/types/resources/ImpactedSubscription.d.ts +0 -20
  42. package/types/resources/InAppSubscription.d.ts +0 -116
  43. package/types/resources/Invoice.d.ts +0 -1691
  44. package/types/resources/InvoiceEstimate.d.ts +0 -143
  45. package/types/resources/Item.d.ts +0 -204
  46. package/types/resources/ItemEntitlement.d.ts +0 -103
  47. package/types/resources/ItemFamily.d.ts +0 -89
  48. package/types/resources/ItemPrice.d.ts +0 -328
  49. package/types/resources/Metadata.d.ts +0 -8
  50. package/types/resources/NonSubscription.d.ts +0 -48
  51. package/types/resources/Order.d.ts +0 -586
  52. package/types/resources/PaymentIntent.d.ts +0 -178
  53. package/types/resources/PaymentReferenceNumber.d.ts +0 -11
  54. package/types/resources/PaymentSchedule.d.ts +0 -28
  55. package/types/resources/PaymentScheduleEstimate.d.ts +0 -25
  56. package/types/resources/PaymentScheduleScheme.d.ts +0 -62
  57. package/types/resources/PaymentSource.d.ts +0 -529
  58. package/types/resources/PaymentVoucher.d.ts +0 -107
  59. package/types/resources/PortalSession.d.ts +0 -88
  60. package/types/resources/PriceVariant.d.ts +0 -112
  61. package/types/resources/PricingPageSession.d.ts +0 -130
  62. package/types/resources/PromotionalCredit.d.ts +0 -111
  63. package/types/resources/Purchase.d.ts +0 -202
  64. package/types/resources/Quote.d.ts +0 -1467
  65. package/types/resources/QuoteLineGroup.d.ts +0 -136
  66. package/types/resources/QuotedCharge.d.ts +0 -56
  67. package/types/resources/QuotedSubscription.d.ts +0 -114
  68. package/types/resources/Ramp.d.ts +0 -260
  69. package/types/resources/ResourceMigration.d.ts +0 -36
  70. package/types/resources/SiteMigrationDetail.d.ts +0 -46
  71. package/types/resources/Subscription.d.ts +0 -2443
  72. package/types/resources/SubscriptionEntitlement.d.ts +0 -79
  73. package/types/resources/SubscriptionEstimate.d.ts +0 -59
  74. package/types/resources/TaxWithheld.d.ts +0 -19
  75. package/types/resources/ThirdPartyPaymentMethod.d.ts +0 -11
  76. package/types/resources/TimeMachine.d.ts +0 -57
  77. package/types/resources/Token.d.ts +0 -19
  78. package/types/resources/Transaction.d.ts +0 -313
  79. package/types/resources/UnbilledCharge.d.ts +0 -209
  80. package/types/resources/Usage.d.ts +0 -113
  81. package/types/resources/VirtualBankAccount.d.ts +0 -125
  82. package/types/resources/filter.d.ts +0 -52
@@ -1,89 +0,0 @@
1
- ///<reference path='./../core.d.ts'/>
2
- ///<reference path='./../index.d.ts'/>
3
- ///<reference path='./filter.d.ts'/>
4
- declare module 'chargebee' {
5
- export interface Comment {
6
- id: string;
7
- entity_type: EntityTypeEnum;
8
- added_by?: string;
9
- notes: string;
10
- created_at: number;
11
- type: 'user' | 'system';
12
- entity_id: string;
13
- }
14
-
15
- export namespace Comment {
16
- export class CommentResource {
17
- create(
18
- input: CreateInputParam,
19
- headers?: ChargebeeRequestHeader,
20
- ): Promise<ChargebeeResponse<CreateResponse>>;
21
-
22
- retrieve(
23
- comment_id: string,
24
- headers?: ChargebeeRequestHeader,
25
- ): Promise<ChargebeeResponse<RetrieveResponse>>;
26
-
27
- list(
28
- input?: ListInputParam,
29
- headers?: ChargebeeRequestHeader,
30
- ): Promise<ChargebeeResponse<ListResponse>>;
31
-
32
- delete(
33
- comment_id: string,
34
- headers?: ChargebeeRequestHeader,
35
- ): Promise<ChargebeeResponse<DeleteResponse>>;
36
- }
37
-
38
- export interface CreateResponse {
39
- comment: Comment;
40
- }
41
-
42
- export interface RetrieveResponse {
43
- comment: Comment;
44
- }
45
-
46
- export interface ListResponse {
47
- list: { comment: Comment }[];
48
- next_offset?: string;
49
- }
50
-
51
- export interface DeleteResponse {
52
- comment: Comment;
53
- }
54
-
55
- // REQUEST PARAMS
56
- //---------------
57
-
58
- export interface CreateInputParam {
59
- entity_type: EntityTypeEnum;
60
- entity_id: string;
61
- notes: string;
62
- added_by?: string;
63
- }
64
- export interface ListInputParam {
65
- limit?: number;
66
- offset?: string;
67
- entity_type?:
68
- | 'customer'
69
- | 'subscription'
70
- | 'invoice'
71
- | 'quote'
72
- | 'credit_note'
73
- | 'transaction'
74
- | 'plan'
75
- | 'addon'
76
- | 'coupon'
77
- | 'order'
78
- | 'business_entity'
79
- | 'item_family'
80
- | 'item'
81
- | 'item_price'
82
- | 'price_variant';
83
- entity_id?: string;
84
- created_at?: filter.Timestamp;
85
- 'sort_by[asc]'?: string;
86
- 'sort_by[desc]'?: string;
87
- }
88
- }
89
- }
@@ -1,16 +0,0 @@
1
- ///<reference path='./../core.d.ts'/>
2
- ///<reference path='./../index.d.ts'/>
3
-
4
- declare module 'chargebee' {
5
- export interface Contact {
6
- id: string;
7
- first_name?: string;
8
- last_name?: string;
9
- email: string;
10
- phone?: string;
11
- label?: string;
12
- enabled: boolean;
13
- send_account_email: boolean;
14
- send_billing_email: boolean;
15
- }
16
- }
@@ -1,19 +0,0 @@
1
- ///<reference path='./../core.d.ts'/>
2
- ///<reference path='./../index.d.ts'/>
3
-
4
- declare module 'chargebee' {
5
- export interface ContractTerm {
6
- id: string;
7
- status: 'active' | 'completed' | 'cancelled' | 'terminated';
8
- contract_start: number;
9
- contract_end: number;
10
- billing_cycle: number;
11
- action_at_term_end: 'renew' | 'evergreen' | 'cancel' | 'renew_once';
12
- total_contract_value: number;
13
- total_contract_value_before_tax: number;
14
- cancellation_cutoff_period?: number;
15
- created_at: number;
16
- subscription_id: string;
17
- remaining_billing_cycles?: number;
18
- }
19
- }
@@ -1,314 +0,0 @@
1
- ///<reference path='./../core.d.ts'/>
2
- ///<reference path='./../index.d.ts'/>
3
- ///<reference path='./filter.d.ts'/>
4
- declare module 'chargebee' {
5
- export interface Coupon {
6
- [key: string]: unknown;
7
- id: string;
8
- name: string;
9
- invoice_name?: string;
10
- discount_type: 'fixed_amount' | 'percentage' | 'offer_quantity';
11
- discount_percentage?: number;
12
- discount_amount?: number;
13
- discount_quantity?: number;
14
- currency_code?: string;
15
- duration_type: 'one_time' | 'forever' | 'limited_period';
16
- duration_month?: number;
17
- valid_till?: number;
18
- max_redemptions?: number;
19
- status?: 'active' | 'expired' | 'archived' | 'deleted';
20
- apply_discount_on:
21
- | 'plans'
22
- | 'plans_and_addons'
23
- | 'plans_with_quantity'
24
- | 'not_applicable';
25
- apply_on: 'invoice_amount' | 'each_specified_item';
26
- plan_constraint: 'none' | 'all' | 'specific' | 'not_applicable';
27
- addon_constraint: 'none' | 'all' | 'specific' | 'not_applicable';
28
- created_at: number;
29
- archived_at?: number;
30
- resource_version?: number;
31
- updated_at?: number;
32
- included_in_mrr?: boolean;
33
- period?: number;
34
- period_unit?: PeriodUnitEnum;
35
- plan_ids?: string[];
36
- addon_ids?: string[];
37
- item_constraints?: Coupon.ItemConstraint[];
38
- item_constraint_criteria?: Coupon.ItemConstraintCriteria[];
39
- redemptions?: number;
40
- invoice_notes?: string;
41
- meta_data?: any;
42
- coupon_constraints?: Coupon.CouponConstraint[];
43
- }
44
-
45
- export namespace Coupon {
46
- export class CouponResource {
47
- create(
48
- input: CreateInputParam,
49
- headers?: ChargebeeRequestHeader,
50
- ): Promise<ChargebeeResponse<CreateResponse>>;
51
-
52
- createForItems(
53
- input: CreateForItemsInputParam,
54
- headers?: ChargebeeRequestHeader,
55
- ): Promise<ChargebeeResponse<CreateForItemsResponse>>;
56
-
57
- updateForItems(
58
- coupon_id: string,
59
- input: UpdateForItemsInputParam,
60
- headers?: ChargebeeRequestHeader,
61
- ): Promise<ChargebeeResponse<UpdateForItemsResponse>>;
62
-
63
- list(
64
- input?: ListInputParam,
65
- headers?: ChargebeeRequestHeader,
66
- ): Promise<ChargebeeResponse<ListResponse>>;
67
-
68
- retrieve(
69
- coupon_id: string,
70
- headers?: ChargebeeRequestHeader,
71
- ): Promise<ChargebeeResponse<RetrieveResponse>>;
72
-
73
- update(
74
- coupon_id: string,
75
- input?: UpdateInputParam,
76
- headers?: ChargebeeRequestHeader,
77
- ): Promise<ChargebeeResponse<UpdateResponse>>;
78
-
79
- delete(
80
- coupon_id: string,
81
- headers?: ChargebeeRequestHeader,
82
- ): Promise<ChargebeeResponse<DeleteResponse>>;
83
-
84
- copy(
85
- input: CopyInputParam,
86
- headers?: ChargebeeRequestHeader,
87
- ): Promise<ChargebeeResponse<CopyResponse>>;
88
-
89
- unarchive(
90
- coupon_id: string,
91
- headers?: ChargebeeRequestHeader,
92
- ): Promise<ChargebeeResponse<UnarchiveResponse>>;
93
- }
94
-
95
- export interface CreateResponse {
96
- coupon: Coupon;
97
- }
98
-
99
- export interface CreateForItemsResponse {
100
- coupon: Coupon;
101
- }
102
-
103
- export interface UpdateForItemsResponse {
104
- coupon: Coupon;
105
- }
106
-
107
- export interface ListResponse {
108
- list: { coupon: Coupon }[];
109
- next_offset?: string;
110
- }
111
-
112
- export interface RetrieveResponse {
113
- coupon: Coupon;
114
- }
115
-
116
- export interface UpdateResponse {
117
- coupon: Coupon;
118
- }
119
-
120
- export interface DeleteResponse {
121
- coupon: Coupon;
122
- }
123
-
124
- export interface CopyResponse {
125
- coupon: Coupon;
126
- }
127
-
128
- export interface UnarchiveResponse {
129
- coupon: Coupon;
130
- }
131
-
132
- export interface ItemConstraint {
133
- item_type: 'plan' | 'addon' | 'charge';
134
- constraint: 'none' | 'all' | 'specific' | 'criteria';
135
- item_price_ids?: any[];
136
- }
137
- export interface ItemConstraintCriteria {
138
- item_type: 'plan' | 'addon' | 'charge';
139
- currencies?: any[];
140
- item_family_ids?: any[];
141
- item_price_periods?: any[];
142
- }
143
- export interface CouponConstraint {
144
- entity_type: 'customer';
145
- type: 'max_redemptions' | 'unique_by';
146
- value?: string;
147
- }
148
- // REQUEST PARAMS
149
- //---------------
150
-
151
- export interface CreateInputParam {
152
- id: string;
153
- name: string;
154
- invoice_name?: string;
155
- discount_type?: 'fixed_amount' | 'percentage' | 'offer_quantity';
156
- discount_amount?: number;
157
- currency_code?: string;
158
- discount_percentage?: number /**
159
- * @deprecated Please refer API docs to use other attributes
160
- */;
161
-
162
- discount_quantity?: number;
163
- apply_on: 'invoice_amount' | 'each_specified_item';
164
- duration_type?: 'one_time' | 'forever' | 'limited_period';
165
- duration_month?: number;
166
- valid_till?: number;
167
- max_redemptions?: number;
168
- invoice_notes?: string;
169
- meta_data?: any;
170
- included_in_mrr?: boolean;
171
- period?: number;
172
- period_unit?: PeriodUnitEnum;
173
- plan_constraint?: 'none' | 'all' | 'specific';
174
- addon_constraint?: 'none' | 'all' | 'specific';
175
- plan_ids?: string[];
176
- addon_ids?: string[];
177
- status?: 'active' | 'archived';
178
- }
179
- export interface CreateForItemsInputParam {
180
- id: string;
181
- name: string;
182
- invoice_name?: string;
183
- discount_type?: 'fixed_amount' | 'percentage' | 'offer_quantity';
184
- discount_amount?: number;
185
- currency_code?: string;
186
- discount_percentage?: number /**
187
- * @deprecated Please refer API docs to use other attributes
188
- */;
189
-
190
- discount_quantity?: number;
191
- apply_on: 'invoice_amount' | 'each_specified_item';
192
- duration_type?: 'one_time' | 'forever' | 'limited_period';
193
- duration_month?: number;
194
- valid_till?: number;
195
- max_redemptions?: number;
196
- invoice_notes?: string;
197
- meta_data?: any;
198
- included_in_mrr?: boolean;
199
- period?: number;
200
- period_unit?: PeriodUnitEnum;
201
- status?: 'active' | 'archived';
202
- item_constraints?: ItemConstraintsCreateForItemsInputParam[];
203
- item_constraint_criteria?: ItemConstraintCriteriaCreateForItemsInputParam[];
204
- coupon_constraints?: CouponConstraintsCreateForItemsInputParam[];
205
- [key: `cf_${string}`]: unknown;
206
- }
207
- export interface UpdateForItemsInputParam {
208
- name?: string;
209
- invoice_name?: string;
210
- discount_type?: 'fixed_amount' | 'percentage' | 'offer_quantity';
211
- discount_amount?: number;
212
- currency_code?: string;
213
- discount_percentage?: number /**
214
- * @deprecated Please refer API docs to use other attributes
215
- */;
216
-
217
- discount_quantity?: number;
218
- apply_on?: 'invoice_amount' | 'each_specified_item';
219
- duration_type?: 'one_time' | 'forever' | 'limited_period';
220
- duration_month?: number;
221
- valid_till?: number;
222
- max_redemptions?: number;
223
- invoice_notes?: string;
224
- meta_data?: any;
225
- included_in_mrr?: boolean;
226
- period?: number;
227
- period_unit?: PeriodUnitEnum;
228
- item_constraints?: ItemConstraintsUpdateForItemsInputParam[];
229
- item_constraint_criteria?: ItemConstraintCriteriaUpdateForItemsInputParam[];
230
- coupon_constraints?: CouponConstraintsUpdateForItemsInputParam[];
231
- [key: `cf_${string}`]: unknown;
232
- }
233
- export interface ListInputParam {
234
- limit?: number;
235
- offset?: string;
236
- id?: filter.String;
237
- name?: filter.String;
238
- discount_type?: filter.Enum;
239
- duration_type?: filter.Enum;
240
- status?: filter.Enum;
241
- apply_on?: filter.Enum;
242
- created_at?: filter.Timestamp;
243
- updated_at?: filter.Timestamp;
244
- currency_code?: filter.String;
245
- 'sort_by[asc]'?: string;
246
- 'sort_by[desc]'?: string;
247
- [key: `cf_${string}`]: unknown;
248
- }
249
- export interface UpdateInputParam {
250
- name?: string;
251
- invoice_name?: string;
252
- discount_type?: 'fixed_amount' | 'percentage' | 'offer_quantity';
253
- discount_amount?: number;
254
- currency_code?: string;
255
- discount_percentage?: number /**
256
- * @deprecated Please refer API docs to use other attributes
257
- */;
258
-
259
- discount_quantity?: number;
260
- apply_on?: 'invoice_amount' | 'each_specified_item';
261
- duration_type?: 'one_time' | 'forever' | 'limited_period';
262
- duration_month?: number;
263
- valid_till?: number;
264
- max_redemptions?: number;
265
- invoice_notes?: string;
266
- meta_data?: any;
267
- included_in_mrr?: boolean;
268
- period?: number;
269
- period_unit?: PeriodUnitEnum;
270
- plan_constraint?: 'none' | 'all' | 'specific';
271
- addon_constraint?: 'none' | 'all' | 'specific';
272
- plan_ids?: string[];
273
- addon_ids?: string[];
274
- }
275
- export interface CopyInputParam {
276
- from_site: string;
277
- id_at_from_site: string;
278
- id?: string;
279
- for_site_merging?: boolean;
280
- }
281
- export interface ItemConstraintCriteriaCreateForItemsInputParam {
282
- item_type?: 'plan' | 'addon' | 'charge';
283
- item_family_ids?: any;
284
- currencies?: any;
285
- item_price_periods?: any;
286
- }
287
- export interface CouponConstraintsCreateForItemsInputParam {
288
- entity_type: 'customer';
289
- type: 'max_redemptions' | 'unique_by';
290
- value?: string;
291
- }
292
- export interface ItemConstraintsCreateForItemsInputParam {
293
- constraint: 'none' | 'all' | 'specific' | 'criteria';
294
- item_type: 'plan' | 'addon' | 'charge';
295
- item_price_ids?: any;
296
- }
297
- export interface ItemConstraintCriteriaUpdateForItemsInputParam {
298
- item_type?: 'plan' | 'addon' | 'charge';
299
- item_family_ids?: any;
300
- currencies?: any;
301
- item_price_periods?: any;
302
- }
303
- export interface CouponConstraintsUpdateForItemsInputParam {
304
- entity_type: 'customer';
305
- type: 'max_redemptions' | 'unique_by';
306
- value?: string;
307
- }
308
- export interface ItemConstraintsUpdateForItemsInputParam {
309
- constraint: 'none' | 'all' | 'specific' | 'criteria';
310
- item_type: 'plan' | 'addon' | 'charge';
311
- item_price_ids?: any;
312
- }
313
- }
314
- }
@@ -1,70 +0,0 @@
1
- ///<reference path='./../core.d.ts'/>
2
- ///<reference path='./../index.d.ts'/>
3
- ///<reference path='./filter.d.ts'/>
4
- declare module 'chargebee' {
5
- export interface CouponCode {
6
- code: string;
7
- status: 'not_redeemed' | 'redeemed' | 'archived';
8
- coupon_id: string;
9
- coupon_set_id: string;
10
- coupon_set_name: string;
11
- }
12
-
13
- export namespace CouponCode {
14
- export class CouponCodeResource {
15
- create(
16
- input: CreateInputParam,
17
- headers?: ChargebeeRequestHeader,
18
- ): Promise<ChargebeeResponse<CreateResponse>>;
19
-
20
- retrieve(
21
- coupon_code_code: string,
22
- headers?: ChargebeeRequestHeader,
23
- ): Promise<ChargebeeResponse<RetrieveResponse>>;
24
-
25
- list(
26
- input?: ListInputParam,
27
- headers?: ChargebeeRequestHeader,
28
- ): Promise<ChargebeeResponse<ListResponse>>;
29
-
30
- archive(
31
- coupon_code_code: string,
32
- headers?: ChargebeeRequestHeader,
33
- ): Promise<ChargebeeResponse<ArchiveResponse>>;
34
- }
35
-
36
- export interface CreateResponse {
37
- coupon_code: CouponCode;
38
- }
39
-
40
- export interface RetrieveResponse {
41
- coupon_code: CouponCode;
42
- }
43
-
44
- export interface ListResponse {
45
- list: { coupon_code: CouponCode }[];
46
- next_offset?: string;
47
- }
48
-
49
- export interface ArchiveResponse {
50
- coupon_code: CouponCode;
51
- }
52
-
53
- // REQUEST PARAMS
54
- //---------------
55
-
56
- export interface CreateInputParam {
57
- coupon_id: string;
58
- coupon_set_name: string;
59
- code: string;
60
- }
61
- export interface ListInputParam {
62
- limit?: number;
63
- offset?: string;
64
- code?: filter.String;
65
- coupon_id?: filter.String;
66
- coupon_set_name?: filter.String;
67
- status?: filter.Enum;
68
- }
69
- }
70
- }
@@ -1,111 +0,0 @@
1
- ///<reference path='./../core.d.ts'/>
2
- ///<reference path='./../index.d.ts'/>
3
- ///<reference path='./filter.d.ts'/>
4
- declare module 'chargebee' {
5
- export interface CouponSet {
6
- id: string;
7
- coupon_id: string;
8
- name: string;
9
- total_count?: number;
10
- redeemed_count?: number;
11
- archived_count?: number;
12
- meta_data?: any;
13
- }
14
-
15
- export namespace CouponSet {
16
- export class CouponSetResource {
17
- create(
18
- input: CreateInputParam,
19
- headers?: ChargebeeRequestHeader,
20
- ): Promise<ChargebeeResponse<CreateResponse>>;
21
-
22
- addCouponCodes(
23
- coupon_set_id: string,
24
- input?: AddCouponCodesInputParam,
25
- headers?: ChargebeeRequestHeader,
26
- ): Promise<ChargebeeResponse<AddCouponCodesResponse>>;
27
-
28
- list(
29
- input?: ListInputParam,
30
- headers?: ChargebeeRequestHeader,
31
- ): Promise<ChargebeeResponse<ListResponse>>;
32
-
33
- retrieve(
34
- coupon_set_id: string,
35
- headers?: ChargebeeRequestHeader,
36
- ): Promise<ChargebeeResponse<RetrieveResponse>>;
37
-
38
- update(
39
- coupon_set_id: string,
40
- input?: UpdateInputParam,
41
- headers?: ChargebeeRequestHeader,
42
- ): Promise<ChargebeeResponse<UpdateResponse>>;
43
-
44
- delete(
45
- coupon_set_id: string,
46
- headers?: ChargebeeRequestHeader,
47
- ): Promise<ChargebeeResponse<DeleteResponse>>;
48
-
49
- deleteUnusedCouponCodes(
50
- coupon_set_id: string,
51
- headers?: ChargebeeRequestHeader,
52
- ): Promise<ChargebeeResponse<DeleteUnusedCouponCodesResponse>>;
53
- }
54
-
55
- export interface CreateResponse {
56
- coupon_set: CouponSet;
57
- }
58
-
59
- export interface AddCouponCodesResponse {
60
- coupon_set: CouponSet;
61
- }
62
-
63
- export interface ListResponse {
64
- list: { coupon_set: CouponSet }[];
65
- next_offset?: string;
66
- }
67
-
68
- export interface RetrieveResponse {
69
- coupon_set: CouponSet;
70
- }
71
-
72
- export interface UpdateResponse {
73
- coupon_set: CouponSet;
74
- }
75
-
76
- export interface DeleteResponse {
77
- coupon_set: CouponSet;
78
- }
79
-
80
- export interface DeleteUnusedCouponCodesResponse {
81
- coupon_set: CouponSet;
82
- }
83
-
84
- // REQUEST PARAMS
85
- //---------------
86
-
87
- export interface CreateInputParam {
88
- coupon_id: string;
89
- name: string;
90
- id: string;
91
- meta_data?: any;
92
- }
93
- export interface AddCouponCodesInputParam {
94
- code?: string[];
95
- }
96
- export interface ListInputParam {
97
- limit?: number;
98
- offset?: string;
99
- id?: filter.String;
100
- name?: filter.String;
101
- coupon_id?: filter.String;
102
- total_count?: filter.Number;
103
- redeemed_count?: filter.Number;
104
- archived_count?: filter.Number;
105
- }
106
- export interface UpdateInputParam {
107
- name?: string;
108
- meta_data?: any;
109
- }
110
- }
111
- }