The line items of a quote are grouped by charge event. Each of these groups is called a quote line group. A quote would have at least one quote line group. Let’s look at an example.

Consider the following:

  • A monthly plan A for $500 per month.
  • A non-recurring addon B for $50.
Now consider a quote that is created for 3 billing cycles of the plan with the addon applied immediately. This quote would be associated with a list of quote line groups: one for each charge event as shown below:

Quote Line group 1

Plan A: $500
Addon B: $50
Total: $550

Quote Line group 2

Plan A: $500
Total: $500

Quote Line group 3

Plan A: $500
Total: $500

Sample quote line group [ JSON ]

[{ "id": "qlg___dev__XpbSss5Rp3qHPdF", "sub_total": 67, "total": 67, "credits_applied": 0, "amount_paid": 0, "amount_due": 67, "charge_event": "subscription_change", "object": "quote_line_group", "line_items": [ { "id": "__dev__XpbSss5Rp3qHPeG", "date_from": 1580385923, "date_to": 1582199436, "unit_amount": 67, "quantity": 1, "amount": 67, "pricing_model": "per_unit", "is_taxed": false, "tax_amount": 0, "object": "line_item", "customer_id": "active_direct", "description": "SMS Credits - Prorated Charges", "entity_type": "addon", "entity_id": "sms-credits", "discount_amount": 0, "item_level_discount_amount": 0 }, {..} ], "line_item_discounts": [], "taxes": [], "line_item_taxes": [] }]

API Index URL GET

https://{site}.chargebee.com/api/v2/quote_line_groups
version

optional, integer, default=1
id
Uniquely identifies a quote line group.
optional, string, max chars=40
sub_total
Subtotal in cents.
in cents, min=0
total
Total in cents.
optional, in cents, default=0, min=0
credits_applied
Credits (in cents) applied to this quote line group.
optional, in cents, default=0, min=0
amount_paid
Existing outstanding payments (in cents) if any, applied to this quote line group.
optional, in cents, default=0, min=0
amount_due
Amount due in cents.
optional, in cents, default=0, min=0
charge_event
Describes the time in the subscription lifecycle when the charge is to occur.
optional, enumerated string
Possible values are
immediateImmediate.subscription_creationSubscription Creation.trial_startTrial Start.subscription_changeSubscription Change.subscription_renewalSubscription Renewal.
billing_cycle_number
The serial number of the billing cycle of which the quote line group is a part.
optional, integer
line_items
Show attributes[+]
The list of items in this quote line group.
optional, list of line_item
Line item attributes
id
Uniquely identifies a line_item.
optional, string, max chars=40
subscription_id
A unique identifier for the subscription this line item belongs to.
optional, string, max chars=3
date_from
Start date of this line item.
timestamp(UTC) in seconds
date_to
End date of this line item.
timestamp(UTC) in seconds
unit_amount
Unit amount of the line item.
in cents
quantity
  • Product Catalog 2.0: Quantity of the recurring item which is represented by this line item. For metered line items, this value is updated from usages once when the invoice is generated as pending and finally when the invoice is closed.
  • Product Catalog 1.0: Quantity of the recurring item which is represented by this line item.
.
optional, integer, default=1
amount
Total amount of this line item. Typically equals to unit amount x quantity.
optional, in cents
pricing_model
The pricing scheme for this item. In Product Catalog v2, the pricing scheme for this item price.
optional, enumerated string
Possible values are
flat_feeA fixed price that is not quantity-based.per_unitA fixed price per unit quantity.tieredThe per unit price is based on the tier that the total quantity falls in.volumeThere are quantity tiers for which per unit prices are set. Quantities are purchased from successive tiers.stairstepA quantity-based pricing scheme. The item is charged a fixed price based on the tier that the total quantity falls in.
is_taxed
Specifies whether this line item is taxed or not.
boolean, default=false
tax_amount
The tax amount charged for this item.
optional, in cents, default=0, min=0
tax_rate
Rate of tax used to calculate tax for this lineitem.
optional, double, min=0.0, max=100.0
unit_amount_in_decimal
The decimal representation of the unit amount of the line_item. The value is in major units of the currency. Returned when the line_item is quantity-based and multi-decimal pricing is enabled.
optional, string, max chars=33
quantity_in_decimal
The decimal representation of the quantity of this line_item. Returned when the line_item is quantity-based and multi-decimal pricing is enabled.
optional, string, max chars=33
amount_in_decimal
The decimal representation of the amount for the line_item, in major units of the currency. Typically equals to unit_amount_in_decimal x quantity_in_decimal. Returned when multi-decimal pricing is enabled.
optional, string, max chars=33
discount_amount
Total discounts for this line.
optional, in cents, min=0
item_level_discount_amount
Line Item-level discounts for this line.
optional, in cents, min=0
description
Detailed description about this line item.
string, max chars=250
entity_description
Detailed description about this item.
string, max chars=500
entity_type
Specifies the modelled entity this line item is based on.
enumerated string
Possible values are
plan_setupIndicates that this lineitem is based on 'Plan Setup' charge. The 'entity_id' attribute specifies the plan id.planIndicates that this lineitem is based on 'Plan' entity. The 'entity_id' attribute specifies the plan id.addonIndicates that this lineitem is based on 'Addon' entity. The 'entity_id' attribute specifies the addon id.adhocIndicates that this lineitem is not modelled. i.e created adhoc. So the 'entity_id' attribute will be null in this case.
tax_exempt_reason
The reason due to which the line item price/amount is exempted from tax.
optional, enumerated string
Possible values are
tax_not_configuredIf tax is not enabled for the site.region_non_taxableIf the product sold is not taxable in this region, but it is taxable in other regions, hence this region is not part of the Taxable jurisdiction.exportYou are not registered for tax in the customer’s region. This is also the reason code when both billing_address and shipping_address have not been provided for the customer and subscription respectively.customer_exemptIf the Customer is marked as Tax exempt.product_exemptIf the Plan or Addon is marked as Tax exempt.zero_ratedIf the rate of tax is 0% and no Sales/ GST tax is collectable for that line item.reverse_chargeIf the Customer is identified as B2B customer (when VAT Number is entered), applicable for EU only.high_value_physical_goodsIf physical goods are sold from outside Australia to customers in Australia, and the price of all the physical good line items is greater than AUD 1000, then tax will not be applied.
entity_id
The identifier of the modelled entity this line item is based on. Will be null for 'adhoc' entity type.
optional, string, max chars=100
customer_id
A unique identifier for the customer this line item belongs to.
optional, string, max chars=100
discounts
Show attributes[+]
The list of discounts applied to this quote line group.
optional, list of discount
Discount attributes
amount
Discount amount.
in cents, min=0
description
Detailed description of this discount line item.
optional, string, max chars=250
entity_type
Type of this Discount line item.
enumerated string
Possible values are
item_level_couponRepresents the 'Item' level coupons applied to this invoice. Further the 'entity_id' attribute specifies the coupon id this discount is based on.document_level_couponRepresents the 'Document' level coupons applied to this document. Further the 'entity_id' attribute specifies the coupon id this discount is based on.promotional_creditsRepresents the Promotional Credits item in invoice. The 'entity_id' attribute will be null in this case.prorated_creditsRepresents the credit adjustment items in invoice. The 'entity_id' attribute will be null in this case.
entity_id
The identifier of the modelled entity this line item is based on. Will be null for 'Prorated Credits' & 'Promotional Credits'.
optional, string, max chars=100
line_item_discounts
Show attributes[+]
The list of discount(s) applied for line items in this quote line group.
optional, list of line_item_discount
Line item discount attributes
line_item_id
The unique reference id of the line item for which the discount is applicable.
string, max chars=50
discount_type
Type of this discount line item.
enumerated string
Possible values are
item_level_couponRepresents the 'Item' level coupons applied to this invoice. Further the 'coupon_id' attribute specifies the coupon id this discount is based on.document_level_couponRepresents the 'Document' level coupons applied to this document. Further the 'coupon_id' attribute specifies the coupon id this discount is based on.promotional_creditsRepresents the Promotional Credits item in invoice. The 'coupon_id' attribute will be null in this case.prorated_creditsRepresents the credit adjustment items in invoice. The 'coupon_id' attribute will be null in this case.
coupon_id
Coupon id.
optional, string, max chars=50
discount_amount
Discount amount.
in cents, min=0
The list of taxes applied to this quote line group.
optional, list of tax
Tax attributes
name
The name of the tax applied. E.g. GST.
string, max chars=100
amount
The tax amount.
in cents, min=0
description
Description of the tax item.
optional, string, max chars=250
line_item_taxes
Show attributes[+]
The list of taxes applied on line items in this quote line group.
optional, list of line_item_tax
Line item tax attributes
line_item_id
The unique reference id of the line item for which the tax is applicable.
optional, string, max chars=40
tax_name
The name of the tax applied.
string, max chars=100
tax_rate
The rate of tax used to calculate tax amount.
double, default=0.0, min=0.0, max=100.0
is_partial_tax_applied
Indicates if tax is applied only on a portion of the line item amount.
optional, boolean
is_non_compliance_tax
Indicates the non-compliance tax that should not be reported to the jurisdiction.
optional, boolean
taxable_amount
Indicates the actual portion of the line item amount that is taxable.
in cents, min=0
tax_amount
The tax amount.
in cents, min=0
tax_juris_type
The type of tax jurisdiction.
optional, enumerated string
Possible values are
countryThe tax jurisdiction is a country.federalThe tax jurisdiction is a federal.stateThe tax jurisdiction is a state.countyThe tax jurisdiction is a county.cityThe tax jurisdiction is a city.specialSpecial tax jurisdiction.unincorporatedCombined tax of state and county.otherJurisdictions other than the ones listed above.
tax_juris_name
The name of the tax jurisdiction.
optional, string, max chars=250
tax_juris_code
The tax jurisdiction code.
optional, string, max chars=250
tax_amount_in_local_currency
Total tax amount in the currency of the place of supply. This is applicable only for Invoice and Credit Notes API.
optional, in cents, min=0
local_currency_code
The currency code (ISO 4217 format) of the place of supply in which VAT needs to be converted and displayed. This is applicable only for Invoice and Credit Notes API.
optional, string, max chars=null