chargebee 2.42.0 → 2.44.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.
@@ -214,7 +214,7 @@ declare module 'chargebee' {
214
214
  }
215
215
  export interface CreateInputParam {
216
216
  [key : string] : any;
217
- card?:{additional_information?:object,billing_addr1?:string,billing_addr2?:string,billing_city?:string,billing_country?:string,billing_state?:string,billing_state_code?:string,billing_zip?:string,cvv?:string,expiry_month?:number,expiry_year?:number,first_name?:string,gateway?:Gateway,gateway_account_id?:string,ip_address?:string,last_name?:string,number?:string,tmp_token?:string};
217
+ card?:{additional_information?:object,billing_addr1?:string,billing_addr2?:string,billing_city?:string,billing_country?:string,billing_state?:string,billing_state_code?:string,billing_zip?:string,cvv?:string,expiry_month?:number,expiry_year?:number,first_name?:string,gateway?:Gateway,gateway_account_id?:string,ip_address?:string,last_name?:string,number?:string,preferred_scheme?:'cartes_bancaires' | 'mastercard' | 'visa',tmp_token?:string};
218
218
 
219
219
  bank_account?:{account_holder_type?:AccountHolderType,account_number?:string,account_type?:AccountType,bank_code?:string,bank_name?:string,billing_address?:object,company?:string,echeck_type?:EcheckType,email?:string,first_name?:string,gateway_account_id?:string,iban?:string,issuing_country?:string,last_name?:string,phone?:string,routing_number?:string,swedish_identity_number?:string};
220
220
 
@@ -660,7 +660,7 @@ The ID of the business entity created for the site. For Product Catalog 1.0, all
660
660
 
661
661
  payment_method?:{additional_information?:object,gateway_account_id?:string,reference_id?:string,tmp_token?:string,type?:Type};
662
662
 
663
- card?:{additional_information?:object,billing_addr1?:string,billing_addr2?:string,billing_city?:string,billing_country?:string,billing_state?:string,billing_state_code?:string,billing_zip?:string,cvv?:string,expiry_month?:number,expiry_year?:number,first_name?:string,gateway_account_id?:string,last_name?:string,number?:string};
663
+ card?:{additional_information?:object,billing_addr1?:string,billing_addr2?:string,billing_city?:string,billing_country?:string,billing_state?:string,billing_state_code?:string,billing_zip?:string,cvv?:string,expiry_month?:number,expiry_year?:number,first_name?:string,gateway_account_id?:string,last_name?:string,number?:string,preferred_scheme?:'cartes_bancaires' | 'mastercard' | 'visa'};
664
664
 
665
665
  payment_intent?:{additional_information?:object,gateway_account_id?:string,gw_payment_method_id?:string,gw_token?:string,id?:string,payment_method_type?:'card' | 'ideal' | 'sofort' | 'bancontact' | 'google_pay' | 'dotpay' | 'giropay' | 'apple_pay' | 'upi' | 'netbanking_emandates' | 'paypal_express_checkout' | 'direct_debit' | 'boleto' | 'venmo' | 'amazon_payments' | 'pay_to' | 'faster_payments' | 'sepa_instant_transfer' | 'klarna_pay_now' | 'online_banking_poland',reference_id?:string};
666
666
 
@@ -92,6 +92,8 @@ declare module 'chargebee' {
92
92
  */
93
93
 
94
94
  parent_periods?:DifferentialPrice.ParentPeriod[];
95
+
96
+ business_entity_id?:string;
95
97
  }
96
98
  export namespace DifferentialPrice {
97
99
  export class DifferentialPriceResource {
@@ -169,6 +171,8 @@ declare module 'chargebee' {
169
171
  */
170
172
 
171
173
  tiers?:{ending_unit?:number,ending_unit_in_decimal?:string,price?:number,price_in_decimal?:string,starting_unit?:number,starting_unit_in_decimal?:string}[];
174
+
175
+ business_entity_id?:string;
172
176
  }
173
177
  export interface RetrieveResponse {
174
178
  differential_price:DifferentialPrice;
@@ -3,21 +3,25 @@
3
3
  declare module 'chargebee' {
4
4
  export interface Estimate {
5
5
 
6
+
6
7
  created_at:number;
7
-
8
+
8
9
  subscription_estimate?:SubscriptionEstimate;
9
-
10
+
10
11
  subscription_estimates?:SubscriptionEstimate[];
11
-
12
+
12
13
  invoice_estimate?:InvoiceEstimate;
13
-
14
+
14
15
  invoice_estimates?:InvoiceEstimate[];
15
-
16
+
17
+ payment_schedule_estimates?:PaymentScheduleEstimate[];
18
+
16
19
  next_invoice_estimate?:InvoiceEstimate;
17
-
20
+
18
21
  credit_note_estimates?:CreditNoteEstimate[];
19
-
22
+
20
23
  unbilled_charge_estimates?:UnbilledCharge[];
24
+
21
25
  }
22
26
  export namespace Estimate {
23
27
  export class EstimateResource {
@@ -58,6 +62,8 @@ declare module 'chargebee' {
58
62
  create_invoice(input?:CreateInvoiceInputParam):ChargebeeRequest<CreateInvoiceResponse>;
59
63
 
60
64
  create_invoice_for_items(input:CreateInvoiceForItemsInputParam):ChargebeeRequest<CreateInvoiceForItemsResponse>;
65
+
66
+ payment_schedules(input:PaymentSchedulesInputParam):ChargebeeRequest<PaymentSchedulesResponse>;
61
67
  }
62
68
  export interface CreateSubscriptionResponse {
63
69
  estimate:Estimate;
@@ -565,6 +571,19 @@ declare module 'chargebee' {
565
571
 
566
572
  invoice_date?:number;
567
573
  }
574
+ export interface PaymentSchedulesResponse {
575
+ estimate:Estimate;
576
+ }
577
+ export interface PaymentSchedulesInputParam {
578
+
579
+ scheme_id:string;
580
+
581
+ amount?:number;
582
+
583
+ invoice_id?:string;
584
+
585
+ payment_schedule_start_date?:number;
586
+ }
568
587
 
569
588
  }
570
589
  }
@@ -630,6 +630,10 @@ Total amount charged for the order.
630
630
  */
631
631
 
632
632
  item_family?:{id?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string},name?:{is?:string,is_not?:string,starts_with?:string},updated_at?:{after?:string,before?:string,between?:string,on?:string}};
633
+
634
+ business_entity_id?:{is?:string,is_present?:'true' | 'false'};
635
+
636
+ include_site_level_resources?:{is?:'true' | 'false'};
633
637
  }
634
638
  export interface ItemsResponse {
635
639
  export:Export;
@@ -642,6 +646,10 @@ Total amount charged for the order.
642
646
  */
643
647
 
644
648
  item?:{channel?:{in?:string,is?:'app_store' | 'web' | 'play_store',is_not?:'app_store' | 'web' | 'play_store',not_in?:string},enabled_for_checkout?:{is?:'true' | 'false'},enabled_in_portal?:{is?:'true' | 'false'},id?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string},is_giftable?:{is?:'true' | 'false'},item_applicability?:{in?:string,is?:'all' | 'restricted',is_not?:'all' | 'restricted',not_in?:string},item_family_id?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string},metered?:{is?:'true' | 'false'},name?:{is?:string,is_not?:string,starts_with?:string},status?:{in?:string,is?:'archived' | 'deleted' | 'active',is_not?:'archived' | 'deleted' | 'active',not_in?:string},type?:{in?:string,is?:'charge' | 'addon' | 'plan',is_not?:'charge' | 'addon' | 'plan',not_in?:string},updated_at?:{after?:string,before?:string,between?:string,on?:string},usage_calculation?:{in?:string,is?:'max_usage' | 'sum_of_usages' | 'last_usage',is_not?:'max_usage' | 'sum_of_usages' | 'last_usage',not_in?:string}};
649
+
650
+ business_entity_id?:{is?:string,is_present?:'true' | 'false'};
651
+
652
+ include_site_level_resources?:{is?:'true' | 'false'};
645
653
  }
646
654
  export interface ItemPricesResponse {
647
655
  export:Export;
@@ -687,6 +695,10 @@ Filter item prices based on their &#x60;currency_code&#x60;.
687
695
  */
688
696
 
689
697
  item_price?:{channel?:{in?:string,is?:'app_store' | 'web' | 'play_store',is_not?:'app_store' | 'web' | 'play_store',not_in?:string},id?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string},item_id?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string},name?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string},period?:{between?:string,gt?:string,gte?:string,is?:string,is_not?:string,lt?:string,lte?:string},period_unit?:{in?:string,is?:'week' | 'month' | 'year' | 'day',is_not?:'week' | 'month' | 'year' | 'day',not_in?:string},pricing_model?:{in?:string,is?:'volume' | 'per_unit' | 'tiered' | 'flat_fee' | 'stairstep',is_not?:'volume' | 'per_unit' | 'tiered' | 'flat_fee' | 'stairstep',not_in?:string},status?:{in?:string,is?:'archived' | 'deleted' | 'active',is_not?:'archived' | 'deleted' | 'active',not_in?:string},trial_period?:{between?:string,gt?:string,gte?:string,is?:string,is_not?:string,lt?:string,lte?:string},trial_period_unit?:{in?:string,is?:'month' | 'day',is_not?:'month' | 'day',not_in?:string},updated_at?:{after?:string,before?:string,between?:string,on?:string}};
698
+
699
+ business_entity_id?:{is?:string,is_present?:'true' | 'false'};
700
+
701
+ include_site_level_resources?:{is?:'true' | 'false'};
690
702
  }
691
703
  export interface AttachedItemsResponse {
692
704
  export:Export;
@@ -740,6 +752,10 @@ Item Id of Addon / Charge item price for which differential pricing is applied t
740
752
  export interface PriceVariantsInputParam {
741
753
 
742
754
  price_variant?:{created_at?:{after?:string,before?:string,between?:string,on?:string},id?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string},name?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string},status?:{in?:string,is?:'active' | 'archived',is_not?:'active' | 'archived',not_in?:string},updated_at?:{after?:string,before?:string,between?:string,on?:string}};
755
+
756
+ business_entity_id?:{is?:string,is_present?:'true' | 'false'};
757
+
758
+ include_site_level_resources?:{is?:'true' | 'false'};
743
759
  }
744
760
  export interface Download {
745
761
  /**
@@ -906,7 +906,7 @@ This endpoint schedules e-invoices manually. This operation is not allowed when
906
906
 
907
907
  */
908
908
 
909
- card?:{additional_information?:object,billing_addr1?:string,billing_addr2?:string,billing_city?:string,billing_country?:string,billing_state?:string,billing_state_code?:string,billing_zip?:string,cvv?:string,expiry_month?:number,expiry_year?:number,first_name?:string,gateway_account_id?:string,last_name?:string,number?:string};
909
+ card?:{additional_information?:object,billing_addr1?:string,billing_addr2?:string,billing_city?:string,billing_country?:string,billing_state?:string,billing_state_code?:string,billing_zip?:string,cvv?:string,expiry_month?:number,expiry_year?:number,first_name?:string,gateway?:Gateway,gateway_account_id?:string,ip_address?:string,last_name?:string,number?:string,preferred_scheme?:'cartes_bancaires' | 'mastercard' | 'visa',tmp_token?:string};
910
910
 
911
911
  /**
912
912
  * @description Parameters for bank_account
@@ -1088,7 +1088,7 @@ The invoice is [linked](/docs/api?prod_cat_ver&#x3D;2#mbe-linked-be) to the same
1088
1088
 
1089
1089
  */
1090
1090
 
1091
- card?:{additional_information?:object,billing_addr1?:string,billing_addr2?:string,billing_city?:string,billing_country?:string,billing_state?:string,billing_state_code?:string,billing_zip?:string,cvv?:string,expiry_month?:number,expiry_year?:number,first_name?:string,gateway_account_id?:string,last_name?:string,number?:string};
1091
+ card?:{additional_information?:object,billing_addr1?:string,billing_addr2?:string,billing_city?:string,billing_country?:string,billing_state?:string,billing_state_code?:string,billing_zip?:string,cvv?:string,expiry_month?:number,expiry_year?:number,first_name?:string,gateway?:Gateway,gateway_account_id?:string,ip_address?:string,last_name?:string,number?:string,preferred_scheme?:'cartes_bancaires' | 'mastercard' | 'visa',tmp_token?:string};
1092
1092
 
1093
1093
  /**
1094
1094
  * @description Parameters for bank_account
@@ -56,6 +56,8 @@ declare module 'chargebee' {
56
56
 
57
57
  metadata?:object;
58
58
 
59
+ business_entity_id?:string;
60
+
59
61
  }
60
62
  export namespace Item {
61
63
  export class ItemResource {
@@ -115,6 +117,8 @@ declare module 'chargebee' {
115
117
  usage_calculation?:'sum_of_usages' | 'last_usage' | 'max_usage';
116
118
 
117
119
  metadata?:object;
120
+
121
+ business_entity_id?:string;
118
122
  }
119
123
  export interface RetrieveResponse {
120
124
  item:Item;
@@ -292,6 +296,19 @@ declare module 'chargebee' {
292
296
 
293
297
  channel?:{in?:string,is?:'web' | 'app_store' | 'play_store',is_not?:'web' | 'app_store' | 'play_store',not_in?:string};
294
298
 
299
+ /**
300
+ * @description The unique ID of the [business entity](/docs/api?prod_cat_ver&#x3D;2#mbe) of this subscription. This is always the same as the [business entity](/docs/api/subscriptions?prod_cat_ver&#x3D;2#subscription_customer_id) of the customer.
301
+ The ID of the business entity created for the site. For Product Catalog 1.0, all the site data is tied to this business entity.
302
+ **Note**
303
+
304
+ [Multiple Business Entities](/docs/api?prod_cat_ver&#x3D;2#mbe) is a feature available only on Product Catalog 2.0.
305
+
306
+ */
307
+
308
+ business_entity_id?:{is?:string,is_present?:'true' | 'false'};
309
+
310
+ include_site_level_resources?:{is?:'true' | 'false'};
311
+
295
312
  sort_by?:{asc?:'name' | 'id' | 'updated_at',desc?:'name' | 'id' | 'updated_at'};
296
313
  }
297
314
  export interface DeleteResponse {
@@ -1,91 +1,36 @@
1
1
  ///<reference path='./../core.d.ts'/>
2
+ ///<reference path='./../index.d.ts'/>
2
3
  declare module 'chargebee' {
3
4
  export interface ItemFamily {
4
5
  [key : string] : any;
5
- /**
6
- * @description The identifier for the item family. It is unique and immutable.
7
6
 
8
- */
9
-
10
7
  id:string;
11
-
12
- /**
13
- * @description A unique display name for the item family. This is visible only in Chargebee and not to customers.
14
8
 
15
- */
16
-
17
9
  name:string;
18
-
19
- /**
20
- * @description Description of the item family. This is visible only in Chargebee and not to customers.
21
10
 
22
- */
23
-
24
11
  description?:string;
25
-
26
- /**
27
- * @description Status of the item family. \* active - The item family is active and can be used to create new items. \* deleted - The item family has been deleted and cannot be used to create new items. The &#x60;id&#x60; and &#x60;name&#x60; can be reused to create a new item family.
28
12
 
29
- */
30
-
31
- status?:'deleted' | 'active';
32
-
33
- /**
34
- * @description The version number of this resource. For every change made to the resource, &#x60;resource_version&#x60; is updated with a new timestamp in milliseconds.
13
+ status?:'active' | 'deleted';
35
14
 
36
- */
37
-
38
15
  resource_version?:number;
39
-
40
- /**
41
- * @description When the item family was last updated.
42
16
 
43
- */
44
-
45
17
  updated_at?:number;
46
-
47
- /**
48
- * @description The subscription channel this object originated from and is maintained in. \* app_store - The object data is synchronized with data from [in-app subscription(s)](https://apidocs.chargebee.com/docs/api/in_app_subscriptions) created in Apple App Store. Direct manipulation of this object via UI or API is disallowed. \* play_store - The object data is synchronized with data from [in-app subscription(s)](https://apidocs.chargebee.com/docs/api/in_app_subscriptions) created in Google Play Store. Direct manipulation of this object via UI or API is disallowed. \* web - The object was created (and is maintained) for the web channel directly in Chargebee via API or UI.
49
18
 
50
- */
51
-
52
19
  channel?:Channel;
20
+
21
+ business_entity_id?:string;
22
+
53
23
  }
54
24
  export namespace ItemFamily {
55
25
  export class ItemFamilyResource {
56
- /**
57
- * @description This endpoint creates an item family for your product line or service.
58
-
59
- */
60
-
61
26
  create(input:CreateInputParam):ChargebeeRequest<CreateResponse>;
62
27
 
63
- /**
64
- * @description This endpoint retrieves an item family based on the item family id.
65
-
66
- */
67
-
68
28
  retrieve(item_family_id:string):ChargebeeRequest<RetrieveResponse>;
69
29
 
70
- /**
71
- * @description Returns a list of item families satisfying **all** the conditions specified in the filter parameters below. The list is sorted by date of creation, in descending order.
72
-
73
- */
74
-
75
30
  list(input?:ListInputParam):ChargebeeRequest<ListResponse>;
76
31
 
77
- /**
78
- * @description This endpoint updates the name and/or description of the item family.
79
-
80
- */
81
-
82
32
  update(item_family_id:string, input?:UpdateInputParam):ChargebeeRequest<UpdateResponse>;
83
33
 
84
- /**
85
- * @description Deletes an item family, marking its &#x60;status&#x60; as &#x60;deleted&#x60;. This is not allowed if there are &#x60;active&#x60; items under the item family. Once deleted, the &#x60;id&#x60; and &#x60;name&#x60; of the item family can be reused to create a new item family.
86
-
87
- */
88
-
89
34
  delete(item_family_id:string):ChargebeeRequest<DeleteResponse>;
90
35
  }
91
36
  export interface CreateResponse {
@@ -93,100 +38,80 @@ declare module 'chargebee' {
93
38
  }
94
39
  export interface CreateInputParam {
95
40
  [key : string] : any;
96
- /**
97
- * @description The identifier for the item family. Must be unique and is immutable.
98
-
99
- */
100
-
101
41
  id:string;
102
42
 
103
- /**
104
- * @description The display name for the item family. Must be unique. This is visible only in Chargebee and not to customers.
105
-
106
- */
107
-
108
43
  name:string;
109
44
 
110
- /**
111
- * @description Description of the item family. This is visible only in Chargebee and not to customers.
112
-
113
- */
114
-
115
45
  description?:string;
46
+
47
+ business_entity_id?:string;
116
48
  }
117
49
  export interface RetrieveResponse {
118
50
  item_family:ItemFamily;
119
51
  }
120
52
 
121
53
  export interface ListResponse {
122
- /**
123
- * @description Returns a list of item families satisfying **all** the conditions specified in the filter parameters below. The list is sorted by date of creation, in descending order.
124
-
125
- */
126
-
127
54
  list:{item_family:ItemFamily}[];
128
55
 
129
- /**
130
- * @description Returns a list of item families satisfying **all** the conditions specified in the filter parameters below. The list is sorted by date of creation, in descending order.
131
-
132
- */
133
-
134
56
  next_offset?:string;
135
57
  }
136
58
  export interface ListInputParam {
137
59
  [key : string]: any;
138
60
  /**
139
- * @description Returns a list of item families satisfying **all** the conditions specified in the filter parameters below. The list is sorted by date of creation, in descending order.
61
+ * @description The number of resources to be returned.
140
62
 
141
63
  */
142
64
 
143
65
  limit?:number;
144
66
 
145
67
  /**
146
- * @description Returns a list of item families satisfying **all** the conditions specified in the filter parameters below. The list is sorted by date of creation, in descending order.
68
+ * @description Determines your position in the list for pagination. To ensure that the next page is retrieved correctly, always set \&#x60;offset\&#x60; to the value of \&#x60;next_offset\&#x60; obtained in the previous iteration of the API call.
147
69
 
148
70
  */
149
71
 
150
72
  offset?:string;
151
73
 
152
74
  /**
153
- * @description Returns a list of item families satisfying **all** the conditions specified in the filter parameters below. The list is sorted by date of creation, in descending order.
75
+ * @description The identifier for the item family. It is unique and immutable.
154
76
 
155
77
  */
156
78
 
157
79
  id?:{in?:string,is?:string,is_not?:string,not_in?:string,starts_with?:string};
158
80
 
159
81
  /**
160
- * @description Returns a list of item families satisfying **all** the conditions specified in the filter parameters below. The list is sorted by date of creation, in descending order.
82
+ * @description A unique display name for the item family. This is visible only in Chargebee and not to customers.
161
83
 
162
84
  */
163
85
 
164
86
  name?:{is?:string,is_not?:string,starts_with?:string};
165
87
 
166
88
  /**
167
- * @description Returns a list of item families satisfying **all** the conditions specified in the filter parameters below. The list is sorted by date of creation, in descending order.
89
+ * @description When the item family was last updated.
168
90
 
169
91
  */
170
92
 
171
93
  updated_at?:{after?:string,before?:string,between?:string,on?:string};
94
+
95
+ /**
96
+ * @description The unique ID of the [business entity](/docs/api?prod_cat_ver&#x3D;2#mbe) of this subscription. This is always the same as the [business entity](/docs/api/subscriptions?prod_cat_ver&#x3D;2#subscription_customer_id) of the customer.
97
+ The ID of the business entity created for the site. For Product Catalog 1.0, all the site data is tied to this business entity.
98
+ **Note**
99
+
100
+ [Multiple Business Entities](/docs/api?prod_cat_ver&#x3D;2#mbe) is a feature available only on Product Catalog 2.0.
101
+
102
+ */
103
+
104
+ business_entity_id?:{is?:string,is_present?:'true' | 'false'};
105
+
106
+ include_site_level_resources?:{is?:'true' | 'false'};
172
107
  }
173
108
  export interface UpdateResponse {
174
109
  item_family:ItemFamily;
175
110
  }
176
111
  export interface UpdateInputParam {
177
112
  [key : string] : any;
178
- /**
179
- * @description The display name for the item family. Must be unique. This is visible only in Chargebee and not to customers.
180
-
181
- */
182
-
183
113
  name?:string;
184
114
 
185
- /**
186
- * @description Description of the item family. This is visible only in Chargebee and not to customers.
187
-
188
- */
189
-
190
115
  description?:string;
191
116
  }
192
117
  export interface DeleteResponse {