chargebee 3.13.0 → 3.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +56 -0
- package/cjs/coreCommon.js +1 -1
- package/cjs/environment.js +1 -1
- package/cjs/resources/api_endpoints.js +66 -0
- package/esm/coreCommon.js +1 -1
- package/esm/environment.js +1 -1
- package/esm/resources/api_endpoints.js +66 -0
- package/package.json +1 -1
- package/types/core.d.ts +8 -1
- package/types/index.d.ts +7 -0
- package/types/resources/Comment.d.ts +0 -9
- package/types/resources/Content.d.ts +4 -0
- package/types/resources/CreditNote.d.ts +3 -1
- package/types/resources/CreditNoteEstimate.d.ts +31 -31
- package/types/resources/Currency.d.ts +11 -5
- package/types/resources/Customer.d.ts +1 -0
- package/types/resources/Estimate.d.ts +2 -0
- package/types/resources/Event.d.ts +2 -0
- package/types/resources/GatewayErrorDetail.d.ts +1 -0
- package/types/resources/HostedPage.d.ts +2 -0
- package/types/resources/Invoice.d.ts +5 -1
- package/types/resources/InvoiceEstimate.d.ts +42 -42
- package/types/resources/OfferEvent.d.ts +25 -0
- package/types/resources/OfferFulfillment.d.ts +77 -0
- package/types/resources/OmnichannelOneTimeOrder.d.ts +1 -13
- package/types/resources/OmnichannelSubscription.d.ts +13 -12
- package/types/resources/OmnichannelSubscriptionItem.d.ts +1 -0
- package/types/resources/OmnichannelSubscriptionItemOffer.d.ts +22 -0
- package/types/resources/OmnichannelTransaction.d.ts +13 -0
- package/types/resources/Order.d.ts +0 -1
- package/types/resources/PersonalizedOffer.d.ts +64 -0
- package/types/resources/Quote.d.ts +35 -34
- package/types/resources/QuoteLineGroup.d.ts +21 -21
- package/types/resources/Ramp.d.ts +46 -0
- package/types/resources/SalesOrder.d.ts +1 -1
- package/types/resources/Subscription.d.ts +1 -1
- package/types/resources/SubscriptionEstimate.d.ts +0 -1
- package/types/resources/Transaction.d.ts +1 -0
- package/types/resources/UsageFile.d.ts +2 -0
- package/types/resources/WebhookEvent.d.ts +12 -0
|
@@ -19,6 +19,7 @@ declare module 'chargebee' {
|
|
|
19
19
|
items_to_remove?: string[];
|
|
20
20
|
coupons_to_remove?: string[];
|
|
21
21
|
discounts_to_remove?: string[];
|
|
22
|
+
contract_term?: Ramp.ContractTerm;
|
|
22
23
|
deleted: boolean;
|
|
23
24
|
status_transition_reason?: Ramp.StatusTransitionReason;
|
|
24
25
|
}
|
|
@@ -88,6 +89,13 @@ declare module 'chargebee' {
|
|
|
88
89
|
billing_cycles?: number;
|
|
89
90
|
service_period_days?: number;
|
|
90
91
|
metered_quantity?: string;
|
|
92
|
+
charge_once?: boolean;
|
|
93
|
+
charge_on_option?: 'immediately' | 'on_event';
|
|
94
|
+
charge_on_event?:
|
|
95
|
+
| 'subscription_trial_start'
|
|
96
|
+
| 'plan_activation'
|
|
97
|
+
| 'subscription_activation'
|
|
98
|
+
| 'contract_termination';
|
|
91
99
|
}
|
|
92
100
|
export interface ItemsToUpdate {
|
|
93
101
|
item_price_id: string;
|
|
@@ -103,6 +111,13 @@ declare module 'chargebee' {
|
|
|
103
111
|
billing_cycles?: number;
|
|
104
112
|
service_period_days?: number;
|
|
105
113
|
metered_quantity?: string;
|
|
114
|
+
charge_once?: boolean;
|
|
115
|
+
charge_on_option?: 'immediately' | 'on_event';
|
|
116
|
+
charge_on_event?:
|
|
117
|
+
| 'subscription_trial_start'
|
|
118
|
+
| 'plan_activation'
|
|
119
|
+
| 'subscription_activation'
|
|
120
|
+
| 'contract_termination';
|
|
106
121
|
}
|
|
107
122
|
export interface CouponsToAdd {
|
|
108
123
|
coupon_id: string;
|
|
@@ -134,6 +149,11 @@ declare module 'chargebee' {
|
|
|
134
149
|
package_size?: number;
|
|
135
150
|
index: number;
|
|
136
151
|
}
|
|
152
|
+
export interface ContractTerm {
|
|
153
|
+
cancellation_cutoff_period?: number;
|
|
154
|
+
renewal_billing_cycles?: number;
|
|
155
|
+
action_at_term_end: 'renew' | 'evergreen' | 'cancel' | 'renew_once';
|
|
156
|
+
}
|
|
137
157
|
export interface StatusTransitionReason {
|
|
138
158
|
code?: string;
|
|
139
159
|
message?: string;
|
|
@@ -147,6 +167,7 @@ declare module 'chargebee' {
|
|
|
147
167
|
coupons_to_remove?: string[];
|
|
148
168
|
discounts_to_remove?: string[];
|
|
149
169
|
items_to_remove?: string[];
|
|
170
|
+
contract_term?: ContractTermCreateForSubscriptionInputParam;
|
|
150
171
|
items_to_add?: ItemsToAddCreateForSubscriptionInputParam[];
|
|
151
172
|
items_to_update?: ItemsToUpdateCreateForSubscriptionInputParam[];
|
|
152
173
|
item_tiers?: ItemTiersCreateForSubscriptionInputParam[];
|
|
@@ -159,6 +180,7 @@ declare module 'chargebee' {
|
|
|
159
180
|
coupons_to_remove?: string[];
|
|
160
181
|
discounts_to_remove?: string[];
|
|
161
182
|
items_to_remove?: string[];
|
|
183
|
+
contract_term?: ContractTermUpdateInputParam;
|
|
162
184
|
items_to_add?: ItemsToAddUpdateInputParam[];
|
|
163
185
|
items_to_update?: ItemsToUpdateUpdateInputParam[];
|
|
164
186
|
item_tiers?: ItemTiersUpdateInputParam[];
|
|
@@ -176,6 +198,12 @@ declare module 'chargebee' {
|
|
|
176
198
|
'sort_by[asc]'?: string;
|
|
177
199
|
'sort_by[desc]'?: string;
|
|
178
200
|
}
|
|
201
|
+
export interface ContractTermCreateForSubscriptionInputParam {
|
|
202
|
+
action_at_term_end?: 'renew' | 'evergreen' | 'cancel' | 'renew_once';
|
|
203
|
+
cancellation_cutoff_period?: number;
|
|
204
|
+
renewal_billing_cycles?: number;
|
|
205
|
+
}
|
|
206
|
+
|
|
179
207
|
export interface ItemsToAddCreateForSubscriptionInputParam {
|
|
180
208
|
item_price_id: string;
|
|
181
209
|
quantity?: number;
|
|
@@ -184,6 +212,9 @@ declare module 'chargebee' {
|
|
|
184
212
|
unit_price_in_decimal?: string;
|
|
185
213
|
billing_cycles?: number;
|
|
186
214
|
service_period_days?: number;
|
|
215
|
+
charge_on_event?: ChargeOnEventEnum;
|
|
216
|
+
charge_once?: boolean;
|
|
217
|
+
charge_on_option?: ChargeOnOptionEnum;
|
|
187
218
|
}
|
|
188
219
|
export interface CouponsToAddCreateForSubscriptionInputParam {
|
|
189
220
|
coupon_id?: string;
|
|
@@ -208,6 +239,9 @@ declare module 'chargebee' {
|
|
|
208
239
|
unit_price_in_decimal?: string;
|
|
209
240
|
billing_cycles?: number;
|
|
210
241
|
service_period_days?: number;
|
|
242
|
+
charge_on_event?: ChargeOnEventEnum;
|
|
243
|
+
charge_once?: boolean;
|
|
244
|
+
charge_on_option?: ChargeOnOptionEnum;
|
|
211
245
|
}
|
|
212
246
|
export interface DiscountsToAddCreateForSubscriptionInputParam {
|
|
213
247
|
apply_on: ApplyOnEnum;
|
|
@@ -219,6 +253,12 @@ declare module 'chargebee' {
|
|
|
219
253
|
included_in_mrr?: boolean;
|
|
220
254
|
item_price_id?: string;
|
|
221
255
|
}
|
|
256
|
+
export interface ContractTermUpdateInputParam {
|
|
257
|
+
action_at_term_end?: 'renew' | 'evergreen' | 'cancel' | 'renew_once';
|
|
258
|
+
cancellation_cutoff_period?: number;
|
|
259
|
+
renewal_billing_cycles?: number;
|
|
260
|
+
}
|
|
261
|
+
|
|
222
262
|
export interface ItemsToAddUpdateInputParam {
|
|
223
263
|
item_price_id: string;
|
|
224
264
|
quantity?: number;
|
|
@@ -227,6 +267,9 @@ declare module 'chargebee' {
|
|
|
227
267
|
unit_price_in_decimal?: string;
|
|
228
268
|
billing_cycles?: number;
|
|
229
269
|
service_period_days?: number;
|
|
270
|
+
charge_on_event?: ChargeOnEventEnum;
|
|
271
|
+
charge_once?: boolean;
|
|
272
|
+
charge_on_option?: ChargeOnOptionEnum;
|
|
230
273
|
}
|
|
231
274
|
export interface CouponsToAddUpdateInputParam {
|
|
232
275
|
coupon_id?: string;
|
|
@@ -251,6 +294,9 @@ declare module 'chargebee' {
|
|
|
251
294
|
unit_price_in_decimal?: string;
|
|
252
295
|
billing_cycles?: number;
|
|
253
296
|
service_period_days?: number;
|
|
297
|
+
charge_on_event?: ChargeOnEventEnum;
|
|
298
|
+
charge_once?: boolean;
|
|
299
|
+
charge_on_option?: ChargeOnOptionEnum;
|
|
254
300
|
}
|
|
255
301
|
export interface DiscountsToAddUpdateInputParam {
|
|
256
302
|
apply_on: ApplyOnEnum;
|
|
@@ -15,6 +15,7 @@ declare module 'chargebee' {
|
|
|
15
15
|
end_date?: number;
|
|
16
16
|
business_entity_id?: string;
|
|
17
17
|
customer_id: string;
|
|
18
|
+
subscription_id: string;
|
|
18
19
|
currency_code: string;
|
|
19
20
|
line_items?: SalesOrder.LineItem[];
|
|
20
21
|
billing_addresses?: SalesOrder.BillingAddress[];
|
|
@@ -106,7 +107,6 @@ declare module 'chargebee' {
|
|
|
106
107
|
| 'valid'
|
|
107
108
|
| 'partially_valid'
|
|
108
109
|
| 'invalid';
|
|
109
|
-
index: number;
|
|
110
110
|
}
|
|
111
111
|
export interface LineItemTier {
|
|
112
112
|
starting_unit: string;
|
|
@@ -650,7 +650,6 @@ declare module 'chargebee' {
|
|
|
650
650
|
country?: string;
|
|
651
651
|
zip?: string;
|
|
652
652
|
validation_status?: ValidationStatusEnum;
|
|
653
|
-
index: number;
|
|
654
653
|
}
|
|
655
654
|
export interface ReferralInfo {
|
|
656
655
|
referral_code?: string;
|
|
@@ -825,6 +824,7 @@ declare module 'chargebee' {
|
|
|
825
824
|
auto_collection?: AutoCollectionEnum;
|
|
826
825
|
terms_to_charge?: number;
|
|
827
826
|
billing_alignment_mode?: BillingAlignmentModeEnum;
|
|
827
|
+
offline_payment_method?: OfflinePaymentMethodEnum;
|
|
828
828
|
po_number?: string;
|
|
829
829
|
coupon_ids?: string[];
|
|
830
830
|
payment_source_id?: string;
|
|
@@ -57,6 +57,7 @@ declare module 'chargebee' {
|
|
|
57
57
|
SubscriptionAdvanceInvoiceScheduleUpdated = 'subscription_advance_invoice_schedule_updated',
|
|
58
58
|
ItemDeleted = 'item_deleted',
|
|
59
59
|
SubscriptionRampDrafted = 'subscription_ramp_drafted',
|
|
60
|
+
DunningUpdated = 'dunning_updated',
|
|
60
61
|
ItemEntitlementsUpdated = 'item_entitlements_updated',
|
|
61
62
|
TokenConsumed = 'token_consumed',
|
|
62
63
|
HierarchyDeleted = 'hierarchy_deleted',
|
|
@@ -150,6 +151,7 @@ declare module 'chargebee' {
|
|
|
150
151
|
SubscriptionScheduledCancellationRemoved = 'subscription_scheduled_cancellation_removed',
|
|
151
152
|
PaymentRefunded = 'payment_refunded',
|
|
152
153
|
UsageFileIngested = 'usage_file_ingested',
|
|
154
|
+
OmnichannelSubscriptionMovedIn = 'omnichannel_subscription_moved_in',
|
|
153
155
|
DifferentialPriceCreated = 'differential_price_created',
|
|
154
156
|
TransactionCreated = 'transaction_created',
|
|
155
157
|
PaymentSucceeded = 'payment_succeeded',
|
|
@@ -266,6 +268,7 @@ declare module 'chargebee' {
|
|
|
266
268
|
[WebhookContentType.SubscriptionAdvanceInvoiceScheduleUpdated]: SubscriptionAdvanceInvoiceScheduleUpdatedContent;
|
|
267
269
|
[WebhookContentType.ItemDeleted]: ItemDeletedContent;
|
|
268
270
|
[WebhookContentType.SubscriptionRampDrafted]: SubscriptionRampDraftedContent;
|
|
271
|
+
[WebhookContentType.DunningUpdated]: DunningUpdatedContent;
|
|
269
272
|
[WebhookContentType.ItemEntitlementsUpdated]: ItemEntitlementsUpdatedContent;
|
|
270
273
|
[WebhookContentType.TokenConsumed]: TokenConsumedContent;
|
|
271
274
|
[WebhookContentType.HierarchyDeleted]: HierarchyDeletedContent;
|
|
@@ -359,6 +362,7 @@ declare module 'chargebee' {
|
|
|
359
362
|
[WebhookContentType.SubscriptionScheduledCancellationRemoved]: SubscriptionScheduledCancellationRemovedContent;
|
|
360
363
|
[WebhookContentType.PaymentRefunded]: PaymentRefundedContent;
|
|
361
364
|
[WebhookContentType.UsageFileIngested]: UsageFileIngestedContent;
|
|
365
|
+
[WebhookContentType.OmnichannelSubscriptionMovedIn]: OmnichannelSubscriptionMovedInContent;
|
|
362
366
|
[WebhookContentType.DifferentialPriceCreated]: DifferentialPriceCreatedContent;
|
|
363
367
|
[WebhookContentType.TransactionCreated]: TransactionCreatedContent;
|
|
364
368
|
[WebhookContentType.PaymentSucceeded]: PaymentSucceededContent;
|
|
@@ -753,6 +757,9 @@ declare module 'chargebee' {
|
|
|
753
757
|
export type SubscriptionRampDraftedContent = {
|
|
754
758
|
ramp: Ramp;
|
|
755
759
|
};
|
|
760
|
+
export type DunningUpdatedContent = {
|
|
761
|
+
invoice: Invoice;
|
|
762
|
+
};
|
|
756
763
|
export type ItemEntitlementsUpdatedContent = {
|
|
757
764
|
feature: Feature;
|
|
758
765
|
|
|
@@ -1288,6 +1295,11 @@ declare module 'chargebee' {
|
|
|
1288
1295
|
export type UsageFileIngestedContent = {
|
|
1289
1296
|
usage_file: UsageFile;
|
|
1290
1297
|
};
|
|
1298
|
+
export type OmnichannelSubscriptionMovedInContent = {
|
|
1299
|
+
omnichannel_subscription: OmnichannelSubscription;
|
|
1300
|
+
|
|
1301
|
+
customer: Customer;
|
|
1302
|
+
};
|
|
1291
1303
|
export type DifferentialPriceCreatedContent = {
|
|
1292
1304
|
differential_price: DifferentialPrice;
|
|
1293
1305
|
};
|