[Python-modules-commits] [chargebee2-python] 01/03: Imported Upstream version 2.3.0

Scott Kitterman kitterman at moszumanska.debian.org
Tue Jun 20 18:40:51 UTC 2017


This is an automated email from the git hooks/post-receive script.

kitterman pushed a commit to branch debian/master
in repository chargebee2-python.

commit db0588093a135f7d53b1853cb355c35c76dac392
Author: Scott Kitterman <scott at kitterman.com>
Date:   Tue Jun 20 13:41:59 2017 -0400

    Imported Upstream version 2.3.0
---
 CHANGELOG.md                                   | 214 +++++++++++++++++++++++--
 chargebee/models/__init__.py                   |   4 +
 chargebee/models/card.py                       |   8 +-
 chargebee/models/credit_note.py                |   9 +-
 chargebee/models/credit_note_estimate.py       |   8 +-
 chargebee/models/customer.py                   |  16 +-
 chargebee/models/estimate.py                   |   8 +-
 chargebee/models/hosted_page.py                |  10 +-
 chargebee/models/invoice.py                    |  11 +-
 chargebee/models/invoice_estimate.py           |   7 +-
 chargebee/models/payment_source.py             |  54 +++++++
 chargebee/models/resource_migration.py         |  13 ++
 chargebee/models/site_migration_detail.py      |  14 ++
 chargebee/models/subscription.py               |  20 ++-
 chargebee/models/third_party_payment_method.py |   2 +-
 chargebee/models/transaction.py                |  10 +-
 chargebee/models/unbilled_charge.py            |  27 ++++
 chargebee/result.py                            |  61 +++++--
 chargebee/version.py                           |   2 +-
 19 files changed, 441 insertions(+), 57 deletions(-)

diff --git a/CHANGELOG.md b/CHANGELOG.md
index d7a3d2f..d19a84b 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,4 +1,190 @@
-###v2.2.3 (2017-01-12)
+### v2.3.0 (2017-06-01)
+* * * 
+
+The endpoint Invoice Now Estimate has been added to the Unbilled Charge resource.
+See : https://apidocs.chargebee.com/docs/api/customers#assign_payment_role
+
+** APIs updated**: 
+
+The filter  param "phone" has been added to the List Customer API.
+See : https://apidocs.chargebee.com/docs/api/customers#list_customers
+
+The subresource "invoice_estimates" has been added to the Estimate resource. 
+See : https://apidocs.chargebee.com/docs/api/estimates#invoice_estimate_attributes
+
+### v2.2.9 (2017-05-04)
+* * * 
+
+** APIs added**:
+The new resources Payment Source has been added.
+See: https://apidocs.chargebee.com/docs/api/payment_sources
+
+The new resources Unbilled Charge has been added.
+See : https://apidocs.chargebee.com/docs/api/unbilled_charges
+
+The endpoint Assign payment role has been added to the Customer resource.
+See : https://apidocs.chargebee.com/docs/api/customers#assign_payment_role
+
+The endpoint Override Billing Profile has been added to the Subscription resource.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#override_billing_profile
+
+
+** APIs updated**: 
+The attribute payment_source_id has been added to the Card resource.
+See : https://apidocs.chargebee.com/docs/api/cards#card_attributes
+
+The attribute subscription_id has been added to the lineitems subresource in Invoice , Credit Note , Invoice estimate , Next invoice estimate and Credit Note estimate .
+See : https://apidocs.chargebee.com/docs/api/invoices#invoice_attributes
+
+The attributes consolidated_invoicing, primary_payment_source_id, backup_payment_source_id and the subresource list referral_urls have been added to the Customer resource.
+See : https://apidocs.chargebee.com/docs/api/customers#customer_attributes
+
+The attributes payment_source_id and auto_collection have been added to the Subscription resource.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#subscription_attributes
+
+The subresource unbilled_charge_estimates has been added to the Estimate resource.
+See : https://apidocs.chargebee.com/docs/api/estimates#unbilled_charge_estimate_attributes
+
+The param consolidated_invoicing has been added to Create a customer and Update a customer APIs.
+See : https://apidocs.chargebee.com/docs/api/customers#create_a_customer
+
+The input params auto_collection, invoice_immediately and consolidated_invoicing have been added to Create subscription API.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#create_a_subscription
+
+The input params auto_collection, payment_source_id and invoice_immediately have been added to Create subscription for customer API.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#create_subscription_for_customer
+
+The input params credit_type and reference have been added to Add promotional credits for a customer , Deduct promotional credits for a customer and Set promotional credits for a customer APIs.
+See : https://apidocs.chargebee.com/docs/api/customers#add_promotional_credits_to_a_customer
+
+The input param invoice_immediately has been added to the Update a subscription , Reactivate subscription , Create subscription estimate , Create subscription for customer estimate and Update subscription estimate APIs.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#update_a_subscription
+
+The input param auto_collection has been added to the Subscription subresource and consolidated_invoicing have been added to the Customer subresource in Checkout new subscription API.
+See : https://apidocs.chargebee.com/docs/api/hosted_pages#checkout_new_subscription
+
+The input param payment_source_id has been added to Import a subscription , Create an invoice , Create invoice for charge , Create invoice for addon and Collect payment for an invoice APIs.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#import_a_subscription
+
+The event types payment_source_added, payment_source_updated and payment_source_deleted have been added.
+See : https://apidocs.chargebee.com/docs/api/events#event_types
+
+### v2.2.8 (2017-04-19)
+* * * 
+
+** APIs added**:
+The endpoints 'List' and 'Acknowledge' APIs have been added to the Hosted page resource. 
+See : https://apidocs.chargebee.com/docs/api/hosted_pages
+
+** APIs updated**:
+A new subresource 'line_item_discounts' has been added to the Invoice, Credit note, Invoice estimates and Credit note estimates resources.
+See : https://apidocs.chargebee.com/docs/api/invoices#invoice_attributes
+
+The Card statuses 'pending_verification' and 'invalid' have been added to the Customer resource.
+See : https://apidocs.chargebee.com/docs/api/customers#customer_attributes
+
+The Payment Method types 'generic', 'alipay' and 'unionpay' have been added to the Payment Method type in the Customer resource.
+See : https://apidocs.chargebee.com/docs/api/customers#customer_attributes
+
+The state 'failed' and the attribute 'failure_reason' have been deprecated in the Hosted Page resource.
+
+The attribues 'updated_at', 'resource_version' and 'checkout_info' have been added.
+See : https://apidocs.chargebee.com/docs/api/hosted_pages#hosted_page_attributes
+
+A new gateway 'adyen' has been added.
+See : https://apidocs.chargebee.com/docs/api/cards#card_attributes
+
+### v2.2.7 (2017-03-16)
+* * * 
+
+** APIs updated**:
+The input parameter 'id' have been removed in Update a Plan and Update an addon resources.
+See: https://apidocs.chargebee.com/docs/api/plans#update_a_plan
+
+The input parameter 'terms_to_charge' have been added in Create a subscription,Create subscription for a customer, Create subscription estimate, create subscription for customer estimate, Reactivate a subscription and Checkout new hosted pages APIs.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#create_subscription_for_customer
+
+The filter input parameter 'next_billing_at' have been added in List Subscriptions API.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#list_subscriptions
+
+The input parameter 'force_term_reset' have been added to Checkout existing hosted pages API.
+See : https://apidocs.chargebee.com/docs/api/hosted_pages#checkout_existing_subscription
+
+A new attribute 'has_advance_charges' have been added to the Invoice resource.
+See : https://apidocs.chargebee.com/docs/api/invoices#invoice_attributes
+
+
+### v2.2.6 (2017-02-24)
+* * * 
+
+** APIs added**:
+New resources 'Site Migration Details' and 'Resource Migrations' have been added.
+See : https://apidocs.chargebee.com/docs/api/site_migration_details
+
+A new endpoint 'Move a customer' has been added.
+See : https://apidocs.chargebee.com/docs/api/customers#move_a_customer
+
+** APIs updated**:
+The attributes 'id' and 'for_site_merging' have been added to Copy an addon, Copy a coupon and Copy a plan API.
+See : https://apidocs.chargebee.com/docs/api/plans#copy_a_plan
+
+The event types 'customer_moved_out' and 'customer_moved_in' have been added.
+See : https://apidocs.chargebee.com/docs/api/events#event_types
+
+The input parameters 'ignore_scheduled_cancellation' and 'ignore_scheduled_changes' have been added to the Subscription renewal estimate API.
+See : https://apidocs.chargebee.com/docs/api/estimates#subscription_renewal_estimate
+
+
+### v2.2.5 (2017-01-30)
+* * * 
+
+** APIs updated**:
+A new reason code 'Subscription cancellation' has been added to the Credit note resource.
+See : https://apidocs.chargebee.com/docs/api/credit_notes#credit_note_attributes
+
+A attribute 'has_advance_charges' has been added to the Invoice resource and the input filter parameter 'has_advance_charges' has been added to List Invoice API.
+See : https://apidocs.chargebee.com/docs/api/invoices#invoice_attributes
+
+A new attribute 'next_billing_at' has been added to the Subscription resource.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#subscription_attributes
+
+The input parameters 'terms_to_charge', 'reactivate', 'reactivate_from' have been added to Update a Subscription, Update a subscription estimate and Checkout existing hosted page APIs. 
+See : https://apidocs.chargebee.com/docs/api/subscriptions#update_a_subscription
+
+The input parameter 'reactivate_from' has been added to Reactivate a subscription API.
+See : https://apidocs.chargebee.com/docs/api/subscriptions#reactivate_a_subscription
+
+** APIs added**:
+A new endpoint 'Charge Future Renewals' has been added to the Subscription API.
+https://apidocs.chargebee.com/docs/api/subscriptions#charge_future_renewals
+
+### v2.2.4 (2017-01-27)
+* * * 
+
+** APIs updated**:
+A new attribute 'gateway_account_id' has been added to Card resource. A input param 'gateway' has been deprecated and a new input param 'gateway_account_id' has been added from Update card for customer, Switch gateway and Copy card APIs.
+See: https://apidocs.chargebee.com/docs/api/cards
+
+ A input param 'gateway' has been deprecated and  a new input param 'gateway_account_id'  has been added to Card and Payment method sub resource in Create customer, Create subscription, Update Subscription and Import subscription API.
+ See: https://apidocs.chargebee.com/docs/api/customers 
+
+A input param 'fraud_flag' has been added to Update customer API.
+See: https://apidocs.chargebee.com/docs/api/customers#update_a_customer
+
+A input param 'gateway' has been deprecated and  a new input param 'gateway_account_id'  has been added to Payment method sub resource in Update card for a customer API.
+See: https://apidocs.chargebee.com/docs/api/cards#update_card_for_a_customer
+
+A input param 'gateway' has been deprecated and  a new input param 'gateway_account_id'  has been added to the Card resource in Checkout new, Checkout existing and Update card and Update Payment method APIs.
+See: https://apidocs.chargebee.com/docs/api/hosted_pages#checkout_new_subscription
+
+A new input params 'billing_address' and 'shipping_address' has been added to Checkout new hosted page API.
+See: https://apidocs.chargebee.com/docs/api/hosted_pages#checkout_new_subscription
+
+** APIs added**:
+A new endpoint Create subscription for a customer estimate has been added to the Estimate resource.
+See: https://apidocs.chargebee.com/docs/api/estimates#create_subscription_for_a_customer_estimate
+
+### v2.2.3 (2017-01-12)
 * * * 
 
 ** APIs added**:
@@ -12,7 +198,7 @@ A new endpoint, Unarchive a coupon has been added to the Coupon resource.
 See : https://apidocs.chargebee.com/docs/api/coupons#unarchive_a_coupon
 
 
-###v2.2.2 (2016-12-30)
+### v2.2.2 (2016-12-30)
 * * * 
 
 ** APIs updated**:
@@ -29,7 +215,7 @@ See : https://apidocs.chargebee.com/docs/api/invoices#create_an_invoice
 An attribute 'tax_exempt_reason' has been added to line items sub resource in Invoice, Credit Note and Estimate resources.
 See : https://apidocs.chargebee.com/docs/api/invoices#invoice_attributes
 
-###v2.2.1 (2016-12-09)
+### v2.2.1 (2016-12-09)
 * * * 
 
 ** APIs updated**:
@@ -57,7 +243,7 @@ See : https://apidocs.chargebee.com/docs/api/plans#create_a_plan
 The input parameters 'transaction_id_at_gateway', 'transaction_status', 'transaction_error_code' and 'transaction_error_text' have been added to Record payment for an invoice API.
 See : https://apidocs.chargebee.com/docs/api/invoices#record_an_invoice_payment
 
-###v2.2.0 (2016-11-24)
+### v2.2.0 (2016-11-24)
 * * * 
 
 ** APIs updated**:
@@ -88,7 +274,7 @@ See : https://apidocs.chargebee.com/docs/api/invoices#import_invoice
 
 
 
-###v2.1.9 (2016-11-18)
+### v2.1.9 (2016-11-18)
 * * * 
 
 ** APIs updated**:
@@ -102,7 +288,7 @@ The new cancel reason type 'non_compliant_customer' has been added to the Subscr
 See : https://apidocs.chargebee.com/docs/api/subscriptions#subscription_attributes
 
 
-###v2.1.8 (2016-11-09)
+### v2.1.8 (2016-11-09)
 * * * 
 
 ** APIs updated**:
@@ -131,7 +317,7 @@ The input parameter "net_term_days" is added to Create a Subscription API. See :
 The attributes "net_term_days" and "due_date" is added to the Invoice resource. See : https://apidocs.chargebee.com/docs/api/invoices
 
 
-###v2.1.7 (2016-10-27)
+### v2.1.7 (2016-10-27)
 * * * 
 
 ** APIs updated**:
@@ -139,7 +325,7 @@ The attributes "net_term_days" and "due_date" is added to the Invoice resource.
 The attribute "preferred_currency_code" is added to Customer and a new input parameter "preferred_currency_code" is added  Create Customer and Update Customer API.
 See : https://apidocs.chargebee.com/docs/api/customers#customer_attributes
 
-###v2.1.6 (2016-09-30)
+### v2.1.6 (2016-09-30)
 * * * 
 
 ** APIs updated**:
@@ -152,7 +338,7 @@ See : https://apidocs.chargebee.com/docs/api/customers#list_customers
 The new parameter "date" is added to Create Credit Note API.
 See : https://apidocs.chargebee.com/docs/api/credit_notes#create_credit_note
 
-###v2.1.5 (2016-09-03)
+### v2.1.5 (2016-09-03)
 * * * 
 ** APIs added**:
 A new endpoint to create Credit Note is added. See : https://apidocs.chargebee.com/docs/api/credit_notes#create_credit_note
@@ -163,7 +349,7 @@ A new endpoint to write off Invoice is added. See : https://apidocs.chargebee.co
 The attribute "forward_url" is given as input for Create a Portal Session API.
 See : https://apidocs.chargebee.com/docs/api/portal_sessions#create_a_portal_session
 
-###v2.1.4 (2016-08-25)
+### v2.1.4 (2016-08-25)
 * * * 
 
 ** APIs updated**:
@@ -192,7 +378,7 @@ The status "pending_verification" added to Payment Method status.
 See : https://apidocs.chargebee.com/docs/api/customers#customer_attributes
 
 
-###v2.1.3 (2016-08-02)
+### v2.1.3 (2016-08-02)
 * * * 
 ** APIs added**:
 A new endpoint to retrieve Credit Note as PDF. See : https://apidocs.chargebee.com/docs/api/credit_notes#retrieve_credit_note_as_pdf
@@ -205,18 +391,18 @@ The filter parameter "paid_at" is added to list invoices and "paid_on_after" is
 
 The filter parameter "occurred_at", "webhook_status", "event_type" is added to list events and parameter "start_time", "end_time", "webhook_status", "event_type" is deprecated. See : https://apidocs.chargebee.com/docs/api/events#list_events
 
-###v2.1.2 (2016-07-18)
+### v2.1.2 (2016-07-18)
 * * * 
 ** APIs added**:
 A new endpoint to remove coupons associated with the subscription is added. See : https://apidocs.chargebee.com/docs/api/subscriptions#remove_coupons
 A new endpoint to record excess payments for a customer is added. See : https://apidocs.chargebee.com/docs/api/customers#record_an_excess_payment_for_a_customer
 
-###v2.1.1 (2016-07-06)
+### v2.1.1 (2016-07-06)
 * * * 
 ** APIs added**:
 A new endpoint to delete a coupon added. See : https://apidocs.chargebee.com/docs/api/coupons#delete_a_coupon
 
-###v2.1.0 (2016-07-04)
+### v2.1.0 (2016-07-04)
 * * * 
 ** APIs updated**:
 The attribute "currency_code" is added as part of Plans, Addons, Coupons, Subscription, Transaction and Estimate resource.
diff --git a/chargebee/models/__init__.py b/chargebee/models/__init__.py
index 92efbdd..1fc10f7 100644
--- a/chargebee/models/__init__.py
+++ b/chargebee/models/__init__.py
@@ -20,4 +20,8 @@ from chargebee.models.comment import Comment
 from chargebee.models.portal_session import PortalSession
 from chargebee.models.download import Download
 from chargebee.models.third_party_payment_method import ThirdPartyPaymentMethod
+from chargebee.models.site_migration_detail import SiteMigrationDetail
+from chargebee.models.resource_migration import ResourceMigration
+from chargebee.models.payment_source import PaymentSource
+from chargebee.models.unbilled_charge import UnbilledCharge
 from chargebee.models.content import Content
diff --git a/chargebee/models/card.py b/chargebee/models/card.py
index ec09970..f4af37e 100644
--- a/chargebee/models/card.py
+++ b/chargebee/models/card.py
@@ -5,10 +5,10 @@ from chargebee import APIError
 
 class Card(Model):
 
-    fields = ["customer_id", "status", "gateway", "first_name", "last_name", "iin", "last4", \
-    "card_type", "funding_type", "expiry_month", "expiry_year", "billing_addr1", "billing_addr2", \
-    "billing_city", "billing_state_code", "billing_state", "billing_country", "billing_zip", "ip_address", \
-    "masked_number"]
+    fields = ["payment_source_id", "status", "gateway", "gateway_account_id", "first_name", \
+    "last_name", "iin", "last4", "card_type", "funding_type", "expiry_month", "expiry_year", "billing_addr1", \
+    "billing_addr2", "billing_city", "billing_state_code", "billing_state", "billing_country", "billing_zip", \
+    "ip_address", "customer_id", "masked_number"]
 
 
     @staticmethod
diff --git a/chargebee/models/credit_note.py b/chargebee/models/credit_note.py
index 605e7e7..dae5b38 100644
--- a/chargebee/models/credit_note.py
+++ b/chargebee/models/credit_note.py
@@ -5,11 +5,14 @@ from chargebee import APIError
 
 class CreditNote(Model):
     class LineItem(Model):
-      fields = ["id", "date_from", "date_to", "unit_amount", "quantity", "is_taxed", "tax_amount", "tax_rate", "amount", "discount_amount", "item_level_discount_amount", "description", "entity_type", "tax_exempt_reason", "entity_id"]
+      fields = ["id", "subscription_id", "date_from", "date_to", "unit_amount", "quantity", "is_taxed", "tax_amount", "tax_rate", "amount", "discount_amount", "item_level_discount_amount", "description", "entity_type", "tax_exempt_reason", "entity_id"]
       pass
     class Discount(Model):
       fields = ["amount", "description", "entity_type", "entity_id"]
       pass
+    class LineItemDiscount(Model):
+      fields = ["line_item_id", "discount_type", "coupon_id", "discount_amount"]
+      pass
     class Tax(Model):
       fields = ["name", "amount", "description"]
       pass
@@ -26,8 +29,8 @@ class CreditNote(Model):
     fields = ["id", "customer_id", "subscription_id", "reference_invoice_id", "type", "reason_code", \
     "status", "vat_number", "date", "price_type", "currency_code", "total", "amount_allocated", \
     "amount_refunded", "amount_available", "refunded_at", "voided_at", "resource_version", "updated_at", \
-    "sub_total", "line_items", "discounts", "taxes", "line_item_taxes", "linked_refunds", "allocations", \
-    "deleted"]
+    "sub_total", "line_items", "discounts", "line_item_discounts", "taxes", "line_item_taxes", "linked_refunds", \
+    "allocations", "deleted"]
 
 
     @staticmethod
diff --git a/chargebee/models/credit_note_estimate.py b/chargebee/models/credit_note_estimate.py
index 5478cad..82b6f6e 100644
--- a/chargebee/models/credit_note_estimate.py
+++ b/chargebee/models/credit_note_estimate.py
@@ -5,7 +5,7 @@ from chargebee import APIError
 
 class CreditNoteEstimate(Model):
     class LineItem(Model):
-      fields = ["id", "date_from", "date_to", "unit_amount", "quantity", "is_taxed", "tax_amount", "tax_rate", "amount", "discount_amount", "item_level_discount_amount", "description", "entity_type", "tax_exempt_reason", "entity_id"]
+      fields = ["id", "subscription_id", "date_from", "date_to", "unit_amount", "quantity", "is_taxed", "tax_amount", "tax_rate", "amount", "discount_amount", "item_level_discount_amount", "description", "entity_type", "tax_exempt_reason", "entity_id"]
       pass
     class Discount(Model):
       fields = ["amount", "description", "entity_type", "entity_id"]
@@ -16,7 +16,11 @@ class CreditNoteEstimate(Model):
     class LineItemTax(Model):
       fields = ["line_item_id", "tax_name", "tax_rate", "tax_amount", "tax_juris_type", "tax_juris_name", "tax_juris_code"]
       pass
+    class LineItemDiscount(Model):
+      fields = ["line_item_id", "discount_type", "coupon_id", "discount_amount"]
+      pass
 
     fields = ["reference_invoice_id", "type", "price_type", "currency_code", "sub_total", "total", \
-    "amount_allocated", "amount_available", "line_items", "discounts", "taxes", "line_item_taxes"]
+    "amount_allocated", "amount_available", "line_items", "discounts", "taxes", "line_item_taxes", \
+    "line_item_discounts"]
 
diff --git a/chargebee/models/customer.py b/chargebee/models/customer.py
index 9fb3dcf..7eed459 100644
--- a/chargebee/models/customer.py
+++ b/chargebee/models/customer.py
@@ -7,16 +7,20 @@ class Customer(Model):
     class BillingAddress(Model):
       fields = ["first_name", "last_name", "email", "company", "phone", "line1", "line2", "line3", "city", "state_code", "state", "country", "zip", "validation_status"]
       pass
+    class ReferralUrl(Model):
+      fields = ["external_customer_id", "referral_sharing_url", "created_at", "updated_at", "referral_campaign_id", "referral_account_id", "referral_external_campaign_id", "referral_system"]
+      pass
     class Contact(Model):
       fields = ["id", "first_name", "last_name", "email", "phone", "label", "enabled", "send_account_email", "send_billing_email"]
       pass
     class PaymentMethod(Model):
-      fields = ["type", "gateway", "status", "reference_id"]
+      fields = ["type", "gateway", "gateway_account_id", "status", "reference_id"]
       pass
 
     fields = ["id", "first_name", "last_name", "email", "phone", "company", "vat_number", "auto_collection", \
     "net_term_days", "allow_direct_debit", "created_at", "created_from_ip", "taxability", "entity_code", \
-    "exempt_number", "resource_version", "updated_at", "locale", "card_status", "fraud_flag", "billing_address", \
+    "exempt_number", "resource_version", "updated_at", "locale", "consolidated_invoicing", "card_status", \
+    "fraud_flag", "primary_payment_source_id", "backup_payment_source_id", "billing_address", "referral_urls", \
     "contacts", "payment_method", "invoice_notes", "preferred_currency_code", "promotional_credits", \
     "refundable_credits", "excess_payments", "meta_data", "deleted"]
 
@@ -46,6 +50,10 @@ class Customer(Model):
         return request.send('post', request.uri_path("customers",id,"update_billing_info"), params, env, headers)
 
     @staticmethod
+    def assign_payment_role(id, params, env=None, headers=None):
+        return request.send('post', request.uri_path("customers",id,"assign_payment_role"), params, env, headers)
+
+    @staticmethod
     def add_contact(id, params, env=None, headers=None):
         return request.send('post', request.uri_path("customers",id,"add_contact"), params, env, headers)
 
@@ -76,3 +84,7 @@ class Customer(Model):
     @staticmethod
     def delete(id, params=None, env=None, headers=None):
         return request.send('post', request.uri_path("customers",id,"delete"), params, env, headers)
+
+    @staticmethod
+    def move(params, env=None, headers=None):
+        return request.send('post', request.uri_path("customers","move"), params, env, headers)
diff --git a/chargebee/models/estimate.py b/chargebee/models/estimate.py
index f838739..d1f174a 100644
--- a/chargebee/models/estimate.py
+++ b/chargebee/models/estimate.py
@@ -5,8 +5,8 @@ from chargebee import APIError
 
 class Estimate(Model):
 
-    fields = ["created_at", "subscription_estimate", "invoice_estimate", "next_invoice_estimate", \
-    "credit_note_estimates"]
+    fields = ["created_at", "subscription_estimate", "invoice_estimate", "invoice_estimates", \
+    "next_invoice_estimate", "credit_note_estimates", "unbilled_charge_estimates"]
 
 
     @staticmethod
@@ -14,6 +14,10 @@ class Estimate(Model):
         return request.send('post', request.uri_path("estimates","create_subscription"), params, env, headers)
 
     @staticmethod
+    def create_sub_for_customer_estimate(id, params, env=None, headers=None):
+        return request.send('get', request.uri_path("customers",id,"create_subscription_estimate"), params, env, headers)
+
+    @staticmethod
     def update_subscription(params, env=None, headers=None):
         return request.send('post', request.uri_path("estimates","update_subscription"), params, env, headers)
 
diff --git a/chargebee/models/hosted_page.py b/chargebee/models/hosted_page.py
index 02272c8..d635895 100644
--- a/chargebee/models/hosted_page.py
+++ b/chargebee/models/hosted_page.py
@@ -6,7 +6,7 @@ from chargebee import APIError
 class HostedPage(Model):
 
     fields = ["id", "type", "url", "state", "failure_reason", "pass_thru_content", "embed", \
-    "created_at", "expires_at"]
+    "created_at", "expires_at", "updated_at", "resource_version", "checkout_info"]
 
     @property
     def content(self):
@@ -32,5 +32,13 @@ class HostedPage(Model):
         return request.send('post', request.uri_path("hosted_pages","update_payment_method"), params, env, headers)
 
     @staticmethod
+    def acknowledge(id, env=None, headers=None):
+        return request.send('post', request.uri_path("hosted_pages",id,"acknowledge"), None, env, headers)
+
+    @staticmethod
     def retrieve(id, env=None, headers=None):
         return request.send('get', request.uri_path("hosted_pages",id), None, env, headers)
+
+    @staticmethod
+    def list(params=None, env=None, headers=None):
+        return request.send_list_request('get', request.uri_path("hosted_pages"), params, env, headers)
diff --git a/chargebee/models/invoice.py b/chargebee/models/invoice.py
index 3abcff5..1854942 100644
--- a/chargebee/models/invoice.py
+++ b/chargebee/models/invoice.py
@@ -5,11 +5,14 @@ from chargebee import APIError
 
 class Invoice(Model):
     class LineItem(Model):
-      fields = ["id", "date_from", "date_to", "unit_amount", "quantity", "is_taxed", "tax_amount", "tax_rate", "amount", "discount_amount", "item_level_discount_amount", "description", "entity_type", "tax_exempt_reason", "entity_id"]
+      fields = ["id", "subscription_id", "date_from", "date_to", "unit_amount", "quantity", "is_taxed", "tax_amount", "tax_rate", "amount", "discount_amount", "item_level_discount_amount", "description", "entity_type", "tax_exempt_reason", "entity_id"]
       pass
     class Discount(Model):
       fields = ["amount", "description", "entity_type", "entity_id"]
       pass
+    class LineItemDiscount(Model):
+      fields = ["line_item_id", "discount_type", "coupon_id", "discount_amount"]
+      pass
     class Tax(Model):
       fields = ["name", "amount", "description"]
       pass
@@ -45,9 +48,9 @@ class Invoice(Model):
     "price_type", "date", "due_date", "net_term_days", "currency_code", "total", "amount_paid", \
     "amount_adjusted", "write_off_amount", "credits_applied", "amount_due", "paid_at", "dunning_status", \
     "next_retry_at", "voided_at", "resource_version", "updated_at", "sub_total", "tax", "first_invoice", \
-    "line_items", "discounts", "taxes", "line_item_taxes", "linked_payments", "applied_credits", \
-    "adjustment_credit_notes", "issued_credit_notes", "linked_orders", "notes", "shipping_address", \
-    "billing_address", "deleted"]
+    "has_advance_charges", "line_items", "discounts", "line_item_discounts", "taxes", "line_item_taxes", \
+    "linked_payments", "applied_credits", "adjustment_credit_notes", "issued_credit_notes", "linked_orders", \
+    "notes", "shipping_address", "billing_address", "deleted"]
 
 
     @staticmethod
diff --git a/chargebee/models/invoice_estimate.py b/chargebee/models/invoice_estimate.py
index cfc57d4..b83ff8d 100644
--- a/chargebee/models/invoice_estimate.py
+++ b/chargebee/models/invoice_estimate.py
@@ -5,7 +5,7 @@ from chargebee import APIError
 
 class InvoiceEstimate(Model):
     class LineItem(Model):
-      fields = ["id", "date_from", "date_to", "unit_amount", "quantity", "is_taxed", "tax_amount", "tax_rate", "amount", "discount_amount", "item_level_discount_amount", "description", "entity_type", "tax_exempt_reason", "entity_id"]
+      fields = ["id", "subscription_id", "date_from", "date_to", "unit_amount", "quantity", "is_taxed", "tax_amount", "tax_rate", "amount", "discount_amount", "item_level_discount_amount", "description", "entity_type", "tax_exempt_reason", "entity_id"]
       pass
     class Discount(Model):
       fields = ["amount", "description", "entity_type", "entity_id"]
@@ -16,7 +16,10 @@ class InvoiceEstimate(Model):
     class LineItemTax(Model):
       fields = ["line_item_id", "tax_name", "tax_rate", "tax_amount", "tax_juris_type", "tax_juris_name", "tax_juris_code"]
       pass
+    class LineItemDiscount(Model):
+      fields = ["line_item_id", "discount_type", "coupon_id", "discount_amount"]
+      pass
 
     fields = ["recurring", "price_type", "currency_code", "sub_total", "total", "credits_applied", \
-    "amount_paid", "amount_due", "line_items", "discounts", "taxes", "line_item_taxes"]
+    "amount_paid", "amount_due", "line_items", "discounts", "taxes", "line_item_taxes", "line_item_discounts"]
 
diff --git a/chargebee/models/payment_source.py b/chargebee/models/payment_source.py
new file mode 100644
index 0000000..11d17cc
--- /dev/null
+++ b/chargebee/models/payment_source.py
@@ -0,0 +1,54 @@
+import json
+from chargebee.model import Model
+from chargebee import request
+from chargebee import APIError
+
+class PaymentSource(Model):
+    class Card(Model):
+      fields = ["first_name", "last_name", "iin", "last4", "brand", "funding_type", "expiry_month", "expiry_year", "billing_addr1", "billing_addr2", "billing_city", "billing_state_code", "billing_state", "billing_country", "billing_zip", "masked_number"]
+      pass
+    class BankAccount(Model):
+      fields = ["name_on_account", "bank_name", "mandate_id", "account_type"]
+      pass
+    class AmazonPayment(Model):
+      fields = ["email", "agreement_id"]
+      pass
+    class Paypal(Model):
+      fields = ["email", "agreement_id"]
+      pass
+
+    fields = ["id", "customer_id", "type", "reference_id", "status", "gateway", "gateway_account_id", \
+    "ip_address", "card", "bank_account", "amazon_payment", "paypal"]
+
+
+    @staticmethod
+    def create_using_temp_token(params, env=None, headers=None):
+        return request.send('post', request.uri_path("payment_sources","create_using_temp_token"), params, env, headers)
+
+    @staticmethod
+    def create_using_permanent_token(params, env=None, headers=None):
+        return request.send('post', request.uri_path("payment_sources","create_using_permanent_token"), params, env, headers)
+
+    @staticmethod
+    def create_card(params, env=None, headers=None):
+        return request.send('post', request.uri_path("payment_sources","create_card"), params, env, headers)
+
+    @staticmethod
+    def retrieve(id, env=None, headers=None):
+        return request.send('get', request.uri_path("payment_sources",id), None, env, headers)
+
+    @staticmethod
+    def list(params=None, env=None, headers=None):
+        return request.send_list_request('get', request.uri_path("payment_sources"), params, env, headers)
+
+    @staticmethod
+    def switch_gateway_account(id, params, env=None, headers=None):
+        return request.send('post', request.uri_path("payment_sources",id,"switch_gateway_account"), params, env, headers)
+
+    @staticmethod
+    def export_payment_source(id, params, env=None, headers=None):
+        return request.send('post', request.uri_path("payment_sources",id,"export_payment_source"), params, env, headers)
+
+    @staticmethod
+    def delete(id, env=None, headers=None):
+        return request.send('post', request.uri_path("payment_sources",id,"delete"), None, env, headers)
diff --git a/chargebee/models/resource_migration.py b/chargebee/models/resource_migration.py
new file mode 100644
index 0000000..898ee17
--- /dev/null
+++ b/chargebee/models/resource_migration.py
@@ -0,0 +1,13 @@
+import json
+from chargebee.model import Model
+from chargebee import request
+from chargebee import APIError
+
+class ResourceMigration(Model):
+
+    fields = ["from_site", "entity_type", "entity_id", "status", "errors", "created_at", "updated_at"]
+
+
+    @staticmethod
+    def retrieve_latest(params, env=None, headers=None):
+        return request.send('get', request.uri_path("resource_migrations","retrieve_latest"), params, env, headers)
diff --git a/chargebee/models/site_migration_detail.py b/chargebee/models/site_migration_detail.py
new file mode 100644
index 0000000..c12ef57
--- /dev/null
+++ b/chargebee/models/site_migration_detail.py
@@ -0,0 +1,14 @@
+import json
+from chargebee.model import Model
+from chargebee import request
+from chargebee import APIError
+
+class SiteMigrationDetail(Model):
+
+    fields = ["entity_id", "other_site_name", "entity_id_at_other_site", "migrated_at", "entity_type", \
+    "status"]
+
+
+    @staticmethod
+    def list(params=None, env=None, headers=None):
+        return request.send_list_request('get', request.uri_path("site_migration_details"), params, env, headers)
diff --git a/chargebee/models/subscription.py b/chargebee/models/subscription.py
index be43424..7d06893 100644
--- a/chargebee/models/subscription.py
+++ b/chargebee/models/subscription.py
@@ -13,14 +13,18 @@ class Subscription(Model):
     class ShippingAddress(Model):
       fields = ["first_name", "last_name", "email", "company", "phone", "line1", "line2", "line3", "city", "state_code", "state", "country", "zip", "validation_status"]
       pass
+    class ReferralInfo(Model):
+      fields = ["referral_code", "coupon_code", "referrer_id", "external_reference_id", "reward_status", "referral_system", "account_id", "campaign_id", "external_campaign_id", "friend_offer_type", "referrer_reward_type", "notify_referral_system", "destination_url", "post_purchase_widget_enabled"]
+      pass
 
     fields = ["id", "customer_id", "currency_code", "plan_id", "plan_quantity", "plan_unit_price", \
     "setup_fee", "billing_period", "billing_period_unit", "plan_free_quantity", "status", "start_date", \
-    "trial_start", "trial_end", "current_term_start", "current_term_end", "remaining_billing_cycles", \
+    "trial_start", "trial_end", "current_term_start", "current_term_end", "next_billing_at", "remaining_billing_cycles", \
     "po_number", "created_at", "started_at", "activated_at", "cancelled_at", "cancel_reason", "affiliate_token", \
-    "created_from_ip", "resource_version", "updated_at", "has_scheduled_changes", "due_invoices_count", \
-    "due_since", "total_dues", "mrr", "exchange_rate", "base_currency_code", "addons", "coupon", \
-    "coupons", "shipping_address", "invoice_notes", "meta_data", "deleted"]
+    "created_from_ip", "resource_version", "updated_at", "has_scheduled_changes", "payment_source_id", \
+    "auto_collection", "due_invoices_count", "due_since", "total_dues", "mrr", "exchange_rate", \
+    "base_currency_code", "addons", "coupon", "coupons", "shipping_address", "referral_info", "invoice_notes", \
+    "meta_data", "deleted"]
 
 
     @staticmethod
@@ -84,6 +88,10 @@ class Subscription(Model):
         return request.send('post', request.uri_path("subscriptions",id,"charge_addon_at_term_end"), params, env, headers)
 
     @staticmethod
+    def charge_future_renewals(id, params=None, env=None, headers=None):
+        return request.send('post', request.uri_path("subscriptions",id,"charge_future_renewals"), params, env, headers)
+
+    @staticmethod
     def import_subscription(params, env=None, headers=None):
         return request.send('post', request.uri_path("subscriptions","import_subscription"), params, env, headers)
 
@@ -92,5 +100,9 @@ class Subscription(Model):
         return request.send('post', request.uri_path("customers",id,"import_subscription"), params, env, headers)
 
     @staticmethod
+    def override_billing_profile(id, params=None, env=None, headers=None):
+        return request.send('post', request.uri_path("subscriptions",id,"override_billing_profile"), params, env, headers)
+
+    @staticmethod
     def delete(id, env=None, headers=None):
         return request.send('post', request.uri_path("subscriptions",id,"delete"), None, env, headers)
diff --git a/chargebee/models/third_party_payment_method.py b/chargebee/models/third_party_payment_method.py
index a4f9720..6c9fa4b 100644
--- a/chargebee/models/third_party_payment_method.py
+++ b/chargebee/models/third_party_payment_method.py
@@ -5,5 +5,5 @@ from chargebee import APIError
 
 class ThirdPartyPaymentMethod(Model):
 
-    fields = ["type", "gateway", "reference_id"]
+    fields = ["type", "gateway", "gateway_account_id", "reference_id"]
 
diff --git a/chargebee/models/transaction.py b/chargebee/models/transaction.py
index 8a4f265..00c0f0b 100644
--- a/chargebee/models/transaction.py
+++ b/chargebee/models/transaction.py
@@ -14,11 +14,11 @@ class Transaction(Model):
       fields = ["txn_id", "txn_status", "txn_date", "txn_amount"]
       pass
 
-    fields = ["id", "customer_id", "subscription_id", "payment_method", "reference_number", \
-    "gateway", "type", "date", "currency_code", "amount", "id_at_gateway", "status", "error_code", \
-    "error_text", "voided_at", "resource_version", "updated_at", "amount_unused", "masked_card_number", \
-    "reference_transaction_id", "refunded_txn_id", "reversal_transaction_id", "linked_invoices", \
-    "linked_credit_notes", "linked_refunds", "deleted"]
+    fields = ["id", "customer_id", "subscription_id", "gateway_account_id", "payment_method", \
+    "reference_number", "gateway", "type", "date", "currency_code", "amount", "id_at_gateway", "status", \
+    "error_code", "error_text", "voided_at", "resource_version", "updated_at", "amount_unused", \
+    "masked_card_number", "reference_transaction_id", "refunded_txn_id", "reversal_transaction_id", \
+    "linked_invoices", "linked_credit_notes", "linked_refunds", "deleted"]
 
 
     @staticmethod
diff --git a/chargebee/models/unbilled_charge.py b/chargebee/models/unbilled_charge.py
new file mode 100644
index 0000000..770a688
--- /dev/null
+++ b/chargebee/models/unbilled_charge.py
@@ -0,0 +1,27 @@
+import json
+from chargebee.model import Model
+from chargebee import request
+from chargebee import APIError
+
+class UnbilledCharge(Model):
+
+    fields = ["id", "customer_id", "subscription_id", "date_from", "date_to", "unit_amount", \
+    "quantity", "amount", "currency_code", "discount_amount", "description", "entity_type", "entity_id", \
+    "is_voided", "voided_at"]
+
+
+    @staticmethod
+    def invoice_unbilled_charges(params=None, env=None, headers=None):
+        return request.send('post', request.uri_path("unbilled_charges","invoice_unbilled_charges"), params, env, headers)
+
+    @staticmethod
+    def delete(id, env=None, headers=None):
+        return request.send('post', request.uri_path("unbilled_charges",id,"delete"), None, env, headers)
+
+    @staticmethod
+    def list(params=None, env=None, headers=None):
+        return request.send_list_request('get', request.uri_path("unbilled_charges"), params, env, headers)
+
+    @staticmethod
+    def invoice_now_estimate(params=None, env=None, headers=None):
+        return request.send('post', request.uri_path("unbilled_charges","invoice_now_estimate"), params, env, headers)
diff --git a/chargebee/result.py b/chargebee/result.py
index b9ff884..cec588d 100644
--- a/chargebee/result.py
+++ b/chargebee/result.py
@@ -11,19 +11,20 @@ class Result(object):
     @property
     def subscription(self):
         subscription = self._get('subscription', Subscription,
-        {'addons' : Subscription.Addon, 'coupons' : Subscription.Coupon, 'shipping_address' : Subscription.ShippingAddress});
+        {'addons' : Subscription.Addon, 'coupons' : Subscription.Coupon, 'shipping_address' : Subscription.ShippingAddress, 'referral_info' : Subscription.ReferralInfo});
         return subscription;
 
     @property
     def customer(self):
         customer = self._get('customer', Customer,
-        {'billing_address' : Customer.BillingAddress, 'contacts' : Customer.Contact, 'payment_method' : Customer.PaymentMethod});
+        {'billing_address' : Customer.BillingAddress, 'referral_urls' : Customer.ReferralUrl, 'contacts' : Customer.Contact, 'payment_method' : Customer.PaymentMethod});
         return customer;
 
     @property
-    def card(self):
-        card = self._get('card', Card);
-        return card;
+    def payment_source(self):
+        payment_source = self._get('payment_source', PaymentSource,
+        {'card' : PaymentSource.Card, 'bank_account' : PaymentSource.BankAccount, 'amazon_payment' : PaymentSource.AmazonPayment, 'paypal' : PaymentSource.Paypal});
+        return payment_source;
 
     @property
     def third_party_payment_method(self):
@@ -31,18 +32,28 @@ class Result(object):
         return third_party_payment_method;
 
     @property
+    def card(self):
+        card = self._get('card', Card);
+        return card;
+
+    @property
     def invoice(self):
         invoice = self._get('invoice', Invoice,
-        {'line_items' : Invoice.LineItem, 'discounts' : Invoice.Discount, 'taxes' : Invoice.Tax, 'line_item_taxes' : Invoice.LineItemTax, 'linked_payments' : Invoice.LinkedPayment, 'applied_credits' : Invoice.AppliedCredit, 'adjustment_credit_notes' : Invoice.AdjustmentCreditNote, 'issued_credit_notes' : Invoice.IssuedCreditNote, 'linked_orders' : Invoice.LinkedOrder, 'notes' : Invoice.Note, 'shipping_address' : Invoice.ShippingAddress, 'billing_address' : Invoice.BillingAddress});
+        {'line_items' : Invoice.LineItem, 'discounts' : Invoice.Discount, 'line_item_discounts' : Invoice.LineItemDiscount, 'taxes' : Invoice.Tax, 'line_item_taxes' : Invoice.LineItemTax, 'linked_payments' : Invoice.LinkedPayment, 'applied_credits' : Invoice.AppliedCredit, 'adjustment_credit_notes' : Invoice.AdjustmentCreditNote, 'issued_credit_notes' : Invoice.IssuedCreditNote, 'linked_orders' : Invoice.LinkedOrder, 'notes' : Invoice.Note, 'shipping_address' : Invoice.ShippingAddress, ' [...]
         return invoice;
 
     @property
     def credit_note(self):
         credit_note = self._get('credit_note', CreditNote,
-        {'line_items' : CreditNote.LineItem, 'discounts' : CreditNote.Discount, 'taxes' : CreditNote.Tax, 'line_item_taxes' : CreditNote.LineItemTax, 'linked_refunds' : CreditNote.LinkedRefund, 'allocations' : CreditNote.Allocation});
+        {'line_items' : CreditNote.LineItem, 'discounts' : CreditNote.Discount, 'line_item_discounts' : CreditNote.LineItemDiscount, 'taxes' : CreditNote.Tax, 'line_item_taxes' : CreditNote.LineItemTax, 'linked_refunds' : CreditNote.LinkedRefund, 'allocations' : CreditNote.Allocation});
         return credit_note;
 
     @property
+    def unbilled_charge(self):
+        unbilled_charge = self._get('unbilled_charge', UnbilledCharge);
+        return unbilled_charge;
+
+    @property
     def order(self):
         order = self._get('order', Order);
         return order;
@@ -61,15 +72,19 @@ class Result(object):
     @property
     def estimate(self):
         estimate = self._get('estimate', Estimate, {},
-        {'subscription_estimate' : SubscriptionEstimate, 'invoice_estimate' : InvoiceEstimate, 'next_invoice_estimate' : InvoiceEstimate, 'credit_note_estimates' : CreditNoteEstimate});
+        {'subscription_estimate' : SubscriptionEstimate, 'invoice_estimate' : InvoiceEstimate, 'invoice_estimates' : InvoiceEstimate, 'next_invoice_estimate' : InvoiceEstimate, 'credit_note_estimates' : CreditNoteEstimate, 'unbilled_charge_estimates' : UnbilledCharge});
         estimate.init_dependant(self._response['estimate'], 'subscription_estimate',
         {'shipping_address' : SubscriptionEstimate.ShippingAddress});
         estimate.init_dependant(self._response['estimate'], 'invoice_estimate',
-        {'line_items' : InvoiceEstimate.LineItem, 'discounts' : InvoiceEstimate.Discount, 'taxes' : InvoiceEstimate.Tax, 'line_item_taxes' : InvoiceEstimate.LineItemTax});
+        {'line_items' : InvoiceEstimate.LineItem, 'discounts' : InvoiceEstimate.Discount, 'taxes' : InvoiceEstimate.Tax, 'line_item_taxes' : InvoiceEstimate.LineItemTax, 'line_item_discounts' : InvoiceEstimate.LineItemDiscount});
         estimate.init_dependant(self._response['estimate'], 'next_invoice_estimate',
-        {'line_items' : InvoiceEstimate.LineItem, 'discounts' : InvoiceEstimate.Discount, 'taxes' : InvoiceEstimate.Tax, 'line_item_taxes' : InvoiceEstimate.LineItemTax});
+        {'line_items' : InvoiceEstimate.LineItem, 'discounts' : InvoiceEstimate.Discount, 'taxes' : InvoiceEstimate.Tax, 'line_item_taxes' : InvoiceEstimate.LineItemTax, 'line_item_discounts' : InvoiceEstimate.LineItemDiscount});
+        estimate.init_dependant_list(self._response['estimate'], 'invoice_estimates',
+        {'line_items' : InvoiceEstimate.LineItem, 'discounts' : InvoiceEstimate.Discount, 'taxes' : InvoiceEstimate.Tax, 'line_item_taxes' : InvoiceEstimate.LineItemTax, 'line_item_discounts' : InvoiceEstimate.LineItemDiscount});
         estimate.init_dependant_list(self._response['estimate'], 'credit_note_estimates',
-        {'line_items' : CreditNoteEstimate.LineItem, 'discounts' : CreditNoteEstimate.Discount, 'taxes' : CreditNoteEstimate.Tax, 'line_item_taxes' : CreditNoteEstimate.LineItemTax});
+        {'line_items' : CreditNoteEstimate.LineItem, 'discounts' : CreditNoteEstimate.Discount, 'taxes' : CreditNoteEstimate.Tax, 'line_item_taxes' : CreditNoteEstimate.LineItemTax, 'line_item_discounts' : CreditNoteEstimate.LineItemDiscount});
+        estimate.init_dependant_list(self._response['estimate'], 'unbilled_charge_estimates',
+        {});
         return estimate;
 
     @property
@@ -119,13 +134,35 @@ class Result(object):
         {'linked_customers' : PortalSession.LinkedCustomer});
         return portal_session;
 
+    @property
+    def site_migration_detail(self):
+        site_migration_detail = self._get('site_migration_detail', SiteMigrationDetail);
+        return site_migration_detail;
+
+    @property
+    def resource_migration(self):
+        resource_migration = self._get('resource_migration', ResourceMigration);
+        return resource_migration;
+
+
+    @property
+    def unbilled_charges(self):
+        unbilled_charges = self._get_list('unbilled_charges', UnbilledCharge,
+        {});
+        return unbilled_charges;
 
     @property
     def credit_notes(self):
         credit_notes = self._get_list('credit_notes', CreditNote,
-        {'line_items' : CreditNote.LineItem, 'discounts' : CreditNote.Discount, 'taxes' : CreditNote.Tax, 'line_item_taxes' : CreditNote.LineItemTax, 'linked_refunds' : CreditNote.LinkedRefund, 'allocations' : CreditNote.Allocation});
+        {'line_items' : CreditNote.LineItem, 'discounts' : CreditNote.Discount, 'line_item_discounts' : CreditNote.LineItemDiscount, 'taxes' : CreditNote.Tax, 'line_item_taxes' : CreditNote.LineItemTax, 'linked_refunds' : CreditNote.LinkedRefund, 'allocations' : CreditNote.Allocation});
         return credit_notes;
 
+    @property
+    def invoices(self):
+        invoices = self._get_list('invoices', Invoice,
+        {'line_items' : Invoice.LineItem, 'discounts' : Invoice.Discount, 'line_item_discounts' : Invoice.LineItemDiscount, 'taxes' : Invoice.Tax, 'line_item_taxes' : Invoice.LineItemTax, 'linked_payments' : Invoice.LinkedPayment, 'applied_credits' : Invoice.AppliedCredit, 'adjustment_credit_notes' : Invoice.AdjustmentCreditNote, 'issued_credit_notes' : Invoice.IssuedCreditNote, 'linked_orders' : Invoice.LinkedOrder, 'notes' : Invoice.Note, 'shipping_address' : Invoice.ShippingAddress, ' [...]
+        return invoices;
+
 
     def _get_list(self, type, cls, sub_types={}, dependant_types={}, dependant_sub_types={}):
         if not type in self._response:
diff --git a/chargebee/version.py b/chargebee/version.py
index 2914e9b..0f572f9 100644
--- a/chargebee/version.py
+++ b/chargebee/version.py
@@ -1 +1 @@
-VERSION = '2.2.3'
+VERSION = '2.3.0'

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/chargebee2-python.git



More information about the Python-modules-commits mailing list