chargebee 2.8.1 → 2.11.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 CHANGED
@@ -1,3 +1,114 @@
1
+ ### v2.11.0 (2022-04-25)
2
+ * * *
3
+
4
+ #### New endpoints:
5
+ * UnbilledCharge#CreateUnbilledCharge has been added to UnbilledCharge resource. Applicable only for PC1.0.
6
+
7
+ #### New attributes:
8
+ * channel have been added to the Addon, AttachedItem, CreditNote, Customer, Invoice, ItemFamily, ItemPrice, Plan and Subscription resources.
9
+ * external_name and channel have been added to the Item resource.
10
+
11
+ #### New input parameters:
12
+ * external_name have been added to Item#CreateRequest and Item#UpdateRequest.
13
+ * channel have been added to Addon#AddonListRequest.
14
+ * channel have been added to CreditNote#CreditNoteListRequest.
15
+ * channel have been added to Customer#CustomerListRequest.
16
+ * invoice[channel], subscription[channel] and customer[channel] have been added to Export#RevenueRecognitionRequest and Export#DeferredRevenueRequest.
17
+ * plan[channel] have been added to Export#PlansRequest.
18
+ * addon[channel] have been added to Export#AddonsRequest.
19
+ * customer[channel] have been added to Export#CustomersRequest.
20
+ * subscription[channel] have been added to Export#SubscriptionsRequest.
21
+ * invoice[channel] have been added to Export#InvoicesRequest.
22
+ * credit_note[channel] have been added to Export#CreditNotesRequest.
23
+ * item[channel] have been added to Export#ItemsRequest.
24
+ * item_price[channel] have been added to Export#ItemPricesRequest.
25
+ * channel have been added to Invoice#InvoiceListRequest.
26
+ * channel have been added to Item#ItemListRequest.
27
+ * channel have been added to ItemPrice#ItemPriceListRequest.
28
+ * channel have been added to Plan#PlanListRequest.
29
+ * channel have been added to Subscription#SubscriptionListRequest.
30
+
31
+ ### Existing input parameter changes:
32
+ * item_family_id in Item#CreateRequest has been made as required field.
33
+
34
+ ### Removed enum values:
35
+ * coupon_expired has been removed from EventTypeEnum.
36
+
37
+
38
+ ### v2.10.0 (2022-03-08)
39
+ * * *
40
+
41
+ ### Fixes:
42
+ * Fixed metadata for Product Catalog V2 resources, item and item_price.
43
+
44
+ #### New attributes:
45
+ * upi, mandates and their subresources have been added to the payment_source resource.
46
+
47
+ #### New Input parameters:
48
+ * bank_account[phone] have been added to customers#create_bank_account
49
+ * payment_intent[payment_method_type] have been added to customers#create_payment_intent, customers#collect_payment_intent
50
+ * payment_intent[payment_method_type] have been added to estimate#gift_subscription and estimate#gift_subscription_for_items.
51
+ * payment_intent[payment_method_type] have been added to gift#create_payment_intent and gift#create_gift_for_items_payment_intent.
52
+ * customer[is_einvoice_enabled], customer[entity_identifier_scheme], customer[entity_identifier_standard], entity_identifiers[id], entity_identifiers[scheme], entity_identifiers[value], entity_identifiers[operation], entity_identifiers[standard] have been added to hosted_page#checkout_onetime_for_items, hosted_page#checkout_new_for_items and hosted_page#checkout_existing_for_items.
53
+ * bank_account[phone] have been added to invoice#create_bank_account, invoice#create_bank_account_for_chargeitems_and_charges
54
+ * payment_intent[payment_method_type] have been added to invoice#create_payment_intent, invoice#create_payment_intent_for_chargeitems_and_charges
55
+ * bank_account[phone] have been added to payment_source#create_bank_account
56
+ * payment_intent[payment_method_type] have been added to payment_source#create_using_payment_intent
57
+ * subscription_id have been added to payment_source#list_payment_source
58
+ * bank_account[phone] have been added to subscription#create_bank_account
59
+ * payment_intent[payment_method_type] have been added to subscription#create_payment_intent, subscription#create_payment_intent_for_customer, subscription#create_payment_intent_with_items, subscription#update_payment_intent, subscription#update_payment_intent_for_items, subscription#reactivate_payment_intent, subscription#resume_payment_intent
60
+ * activated_at have been added to subscription#import_subscription, subscription#import_subscription_for_customer, subscription#import_subscription_for_items
61
+
62
+ #### New Enum values:
63
+ * upi, netbanking_emandates enum has been added in customer_payment_method_type subresource of customer resource
64
+ * current enum has been added in account_type.
65
+ * quickbooks, razorpay enum has been added in gateway.
66
+ * upi, netbanking_emandates enum has been added in payment_method,payment_method_type, type
67
+ * upi, netbanking_emandates, apple_pay enum has been added in payment_method_type subresource of payment_intent resource
68
+ * current enum has been added in bank_account_type subresource of payment_source.
69
+
70
+ #### Deprecated attributes:
71
+ * coupon attribute have been added and deprecated in hosted_page resource.
72
+
73
+ #### Deprecated enums:
74
+ * NetdPaymentDueReminder have been deprecated in event_type.
75
+
76
+
77
+ ### v2.9.0 (2022-01-21)
78
+ * * *
79
+
80
+ #### New endpoints:
81
+ * credit_notes#download_einvoice has been added to the credit_notes resource.
82
+ * invoice#download_einvoice has been added to the invoice resource.
83
+
84
+ #### New attributes:
85
+ * is_einvoice_enabled, entity_identifier_scheme, entity_identifier_standard and entity_identifiers[] have been added to the customer resource.
86
+ * einvoice has been added to the invoice resource.
87
+ * einvoice has been added to the credit_notes resource.
88
+ * mime_type has been added to the download resource.
89
+
90
+ #### New Input parameters:
91
+ * entity_identifier_scheme, entity_identifier_standard, is_einvoice_enabled, entity_identifiers[id][0..N], entity_identifiers[scheme][0..N], entity_identifiers[value][0..N], entity_identifiers[standard][0..N] have been added to customers#create_a_customer, customers#update_billing_info_for_a_customer apis.
92
+ * customer[entity_identifier_scheme], customer[entity_identifier_standard], customer[is_einvoice_enabled], entity_identifiers[id][0..N], entity_identifiers[scheme][0..N], entity_identifiers[value][0..N], entity_identifiers[standard][0..N] have been added to the subscriptions#create_a_subscription api.
93
+ * customer[entity_identifier_scheme], customer[entity_identifier_standard], customer[is_einvoice_enabled] have been added to subscriptions#update_a_subscription and subscriptions#update_subscription_for_items apis.
94
+
95
+ #### New Enum values:
96
+ * operation enum has been added.
97
+ * status enum has been added in credit_notes_einvoice subresource of credit_notes resource.
98
+
99
+ #### Deprecated attributes:
100
+ * user, type, payment_method and exchange_rate have been deprecated from TaxWithHeld resource.
101
+
102
+ #### Deprecated enums:
103
+ * type and payment_method have been deprecated in TaxWithHeld resource.
104
+
105
+ #### Updated parameters:
106
+ * hierarchy_operation_type has been made mandatory in customers#get_hierarchy api.
107
+
108
+ #### Removed Filter parameters:
109
+ * create_pending_invoices has been removed from subscriptions#list_subscriptions api.
110
+
111
+
1
112
  ### v2.8.1 (2022-01-05)
2
113
  * * *
3
114
 
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License
2
2
 
3
- Copyright (c) 2011-2021 ChargeBee, Inc.
3
+ Copyright (c) 2011-2022 ChargeBee, Inc.
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person
6
6
  obtaining a copy of this software and associated documentation
package/lib/chargebee.js CHANGED
@@ -8,7 +8,7 @@ ChargeBee._env = {
8
8
  hostSuffix: '.chargebee.com',
9
9
  apiPath: '/api/v2',
10
10
  timeout: 80000,
11
- clientVersion: 'v2.8.1',
11
+ clientVersion: 'v2.11.0',
12
12
  port: 443,
13
13
  timemachineWaitInMillis: 3000,
14
14
  exportWaitInMillis: 3000
@@ -328,7 +328,7 @@ ChargeBee._core = (function() {
328
328
  }
329
329
  }
330
330
  }
331
- } else if(key === "meta_data") {
331
+ } else if(["meta_data", "metadata"].indexOf(key) !== -1) {
332
332
  var attrVal="";
333
333
  if(value !== null) {
334
334
  attrVal = encodeURIComponent(Object.prototype.toString.call(value) === "[object String]" ? ChargeBee._util.trim(value) : JSON.stringify(value));
@@ -746,6 +746,13 @@ var _endpoints = {
746
746
  "/pdf",
747
747
  true
748
748
  ],
749
+ [
750
+ "download_einvoice",
751
+ "GET",
752
+ "/invoices",
753
+ "/download_einvoice",
754
+ true
755
+ ],
749
756
  [
750
757
  "add_charge",
751
758
  "POST",
@@ -868,6 +875,13 @@ var _endpoints = {
868
875
  "/pdf",
869
876
  true
870
877
  ],
878
+ [
879
+ "download_einvoice",
880
+ "GET",
881
+ "/credit_notes",
882
+ "/download_einvoice",
883
+ true
884
+ ],
871
885
  [
872
886
  "refund",
873
887
  "POST",
@@ -912,6 +926,13 @@ var _endpoints = {
912
926
  ]
913
927
  ],
914
928
  "unbilled_charge": [
929
+ [
930
+ "create_unbilled_charge",
931
+ "POST",
932
+ "/unbilled_charges",
933
+ "/create",
934
+ false
935
+ ],
915
936
  [
916
937
  "create",
917
938
  "POST",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name":"chargebee",
3
- "version":"2.8.1",
3
+ "version":"2.11.0",
4
4
  "description":"A library for integrating with ChargeBee.",
5
5
  "keywords":[
6
6
  "payments",