younifyd
Menu

Override Billing Profile

Override billing profile

POST/subscriptions/{subscription-id}/override_billing_profile

Use it in a workflow

  1. Add a step and choose the Chargebee connector.
  2. Pick the Override Billing Profile action (under Chargebee API).
  3. Fill in the fields below, then reference the result from later steps as {{overrideBillingProfile.response.data}}.

Request

Path parameters

subscription-idstringrequired

Headers

chargebee-request-origin-devicestring

The device from which the customer has made the request

chargebee-request-origin-userstring (email)

The email address of your customer/user. Use this when the email address has only ASCII characters.

chargebee-request-origin-user-encodedstring (email)

The Base64-encoded email address of your customer/user. Use this if the email address has UTF-8 characters. When this header is provided, the header chargebee-request-origin-user is ignored.

chargebee-request-origin-ipstring

The IP address of the customer where the request originated

chargebee-event-actionsstring

skip all actions to be done on the events

One ofall-disabled

chargebee-event-emailstring

skip only emails

One ofall-disabled

chargebee-event-webhookstring

skip only webhooks

One ofall-disabled

chargebee-business-entity-idstring

If the site has multiple business entities, you can use this custom HTTP header to specify the business entity for which Chargebee should perform the operation.

Request body

Enter the body as JSON in the step's Body field.

payment_source_idstring

Unique identifier of the payment source to be attached to this subscription.

auto_collectionstring

Defines whether payments need to be collected automatically for this subscription. Overrides customer's auto-collection property. \* off - Automatic collection of charges will not be made for this subscription. Use this for offline payments. \* on - Whenever an invoice is created for this subscription, an automatic charge will be attempted on the payment method available.

One ofonoff

json
{
  "payment_source_id": null,
  "auto_collection": null
}

Response

Returns 200 with an object. Read it in later steps with {{overrideBillingProfile.response.data.<field>}}.

subscriptionobject

<div class="api-description"><p class="mb-2">A Chargebee subscription connects a customer record to products/services. It describes what the customer has signed up for and how often they&#x27;re charged for it. The essential components of a subscription are:</p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">A <a href="/docs/api/item_prices">plan-item price</a>.</li> <li class="text-base leading-relaxed">Any addon- and charge-item prices applied to the subscription.</li> <li class="text-base leading-relaxed">Any <a href="/docs/api/coupons">coupons</a> applied.</li> <li class="text-base leading-relaxed">Any <a href="/docs/api/discounts">discounts</a> applied.</li> </ul><p class="mb-2">The charges in a subscription are billed via invoices.</p><div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Note:</strong> The maximum number of subscriptions for any given <a href="/docs/api/customers">customer</a> (<code><a href="/docs/api/subscriptions/subscription-object#status">active</a></code> or not) is 900.</p></div><div id="subscription-billing-frequencies" class="cb-accordion"><div class="cb-accordion-title collapsed" data-toggle="collapse" data-target="#subscription-billing-frequencies-content" aria-expanded="false" aria-controls="subscription-billing-frequencies-content"><h4>Subscription billing frequencies</h4><i class="fa fa-chevron-circle-down fa-lg" aria-hidden="true"></i></div><div class="collapse" id="subscription-billing-frequencies-content"><p class="mb-2">Chargebee offers two billing frequency options for subscriptions:</p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed"> <p class="mb-2"><strong class="font-semibold">Plan-based billing</strong> (<code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">default</code>): Subscriptions are billed based on the billing period defined for the item price of the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">item_type</code> <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">plan</code>. <a href="https://www.chargebee.com/docs/billing/2.0/subscriptions/subscriptions#plan-based-billing" target="_blank" rel="noopener noreferrer" class="text-blue-600 hover:text-blue-800 underline">Learn more</a>.</p> </li> <li class="text-base leading-relaxed"> <p class="mb-2"><strong class="font-semibold">Multi-frequency billing</strong>: Subscriptions are billed according to the billing period of each recurring item price within the subscription. <a href="https://www.chargebee.com/docs/billing/2.0/subscriptions/multi-frequency-billing" target="_blank" rel="noopener noreferrer" class="text-blue-600 hover:text-blue-800 underline">Learn more</a>.</p> <div class="warning alert alert-warning"><p class="mb-2"><strong class="font-semibold">Important</strong></p><p class="mb-2"><a href="https://www.chargebee.com/docs/billing/2.0/subscriptions/multi-frequency-billing#limitations" target="_blank" rel="noopener noreferrer" class="text-blue-600 hover:text-blue-800 underline">Limitations</a> of Multi-frequency billing.</p></div> <div class="warning alert alert-warning"><p class="mb-2"><strong class="font-semibold">Private Beta</strong></p><p class="mb-2">Multi-frequency billing is in private beta. Please reach out to the Chargebee <a href="https://www.chargebee.com/docs/billing/2.0/kb/getting-started/how-to-contact-chargebees-support-team?utm_source=docs_api&amp;utm_medium=content&amp;utm_campaign=support" target="_blank" rel="noopener noreferrer" class="text-blue-600 hover:text-blue-800 underline">support</a> to enable this feature.</p></div> </li> </ul><p class="mb-2">The selection of the billing frequency preference is configured at the site level.</p></div></div><div id="item-price-compatibility" class="cb-accordion"><div class="cb-accordion-title collapsed" data-toggle="collapse" data-target="#item-price-compatibility-content" aria-expanded="false" aria-controls="item-price-compatibility-content"><h4>Item price compatibility in a subscription</h4><i class="fa fa-chevron-circle-down fa-lg" aria-hidden="true"></i></div><div class="collapse" id="item-price-compatibility-content"><p class="mb-2">When creating or updating a subscription, one of the item prices specified under subscription_items must be a plan-item price. The remaining must be compatible addon- or charge-item prices. An item price is compatible with a plan-item price if their currencies are the same. Additionally, an addon-item price is compatible with a plan-item price only if their billing frequencies meet the following conditions:</p><div class="relative w-full overflow-x-auto"><table class="cb-table" border="2"><thead><tr><th><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period_unit</code> for plan-item price</th><th>Compatible <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period_unit</code> for addon-item price</th><th>Compatible period for addon-item price</th></tr></thead><tbody><tr><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">day</code></td><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">day</code></td><td><p class="mb-2">The <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the plan-item price should be divisible by the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the addon-item price.</p><div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Example</strong></p><p class="mb-2">If the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the plan-item price is <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">10</code>, then the period of the addon-item price can be <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">10</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">5</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">2</code>, or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">1</code>.</p></div></td></tr><tr><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">week</code></td><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">week</code> or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">day</code></td><td><p class="mb-2">The <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> (in days) of the plan-item price should be divisible by the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the addon-item price.</p><div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Example</strong> If the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the plan-item price is <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">2</code>, then the period of the addon-item price can be as follows depending on the value of <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period_unit</code>:</p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">for <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period_unit</code> as <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">week</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> can be <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">2</code> or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">1</code>.</li> <li class="text-base leading-relaxed">for <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period_unit</code> as <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">day</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> can be <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">14</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">7</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">2</code>, or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">1</code>.</li> </ul></div></td></tr><tr><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">month</code></td><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">month</code></td><td><p class="mb-2">The <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the plan-item price should be divisible by the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the addon-item price.</p><div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Example</strong></p><p class="mb-2">If the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the plan-item price is <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">6</code>, then the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the addon-item price can be <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">6</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">3</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">2</code>, or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">1</code>.</p></div></td></tr><tr><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">year</code></td><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">year</code> or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">month</code></td><td><p class="mb-2">The <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> (in months) of the plan-item price should be divisible by the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the addon-item price.</p><div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Example</strong></p><p class="mb-2">If the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the plan-item price is <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">2</code>, then the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> of the addon-item price can be as follows depending on the value of <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period_unit</code>:</p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">for <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period_unit</code> as <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">year</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> can be <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">2</code> or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">1</code>.</li> <li class="text-base leading-relaxed">for <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period_unit</code> as <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">month</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">period</code> can be <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">24</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">12</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">8</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">6</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">4</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">3</code>, <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">2</code>, or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">1</code>.</li> </ul></div></td></tr></tbody></table></div></div></div><div id="tax-provider" class="cb-accordion"><div class="cb-accordion-title collapsed" data-toggle="collapse" data-target="#tax-provider-content" aria-expanded="false" aria-controls="tax-provider-content"><h4>Tax provider fields</h4><i class="fa fa-chevron-circle-down fa-lg" aria-hidden="true"></i></div><div class="collapse" id="tax-provider-content"><p class="mb-2"><strong class="font-semibold">Avalara</strong>: Merchants using <strong class="font-semibold">Avalara Sales Tax</strong> can optionally associate each item price with a locationCode (from their Avalara company locations), so tax can be resolved correctly at the line item level.</p><div class="relative w-full overflow-x-auto"><table class="cb-table" border="2"><thead><tr><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">Field ID</th><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">Field Value</th><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">APIs</th></tr></thead><tbody><tr><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">locationCode</code></td><td colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">Merchant to configure it on Avalara Platform under company locations</td><td colSpan="1" rowspan="4" style="text-align:center;vertical-align:top">APIs having <a href="/docs/api/item_prices/item-price-object" class="text-blue-600 hover:text-blue-800 underline">Item Prices</a> attributes.</td></tr></tbody></table></div><p class="mb-2"><strong class="font-semibold">Anrok</strong>: Canadian customers can have multiple tax registration numbers. We currently support only sharing one tax registration number with Anrok. So we added a new field which can have comma separated multiple tax reg numbers for Anrok. Values configured in the field is passed as it is to Anrok for accurate tax calculation</p><div class="relative w-full overflow-x-auto"><table class="cb-table" border="2"><thead><tr><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">Field ID</th><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">Field Value</th><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">APIs</th></tr></thead><tbody><tr><td><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">additionalTaxRegistrationNumber</code></td><td colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">Canadian tax registration numbers in comma separated fashion.</td><td colSpan="1" rowspan="4" style="text-align:center;vertical-align:top">APIs involving customer attributes. Also includes APIs where we are creating new customers. Eg: estimate, subscription, hosted pages.</td></tr></tbody></table></div><p class="mb-2"><strong class="font-semibold">Vertex</strong>: Chargebee shares field IDs and corresponding values with merchants, who then configure them on the Vertex Platform for seamless integration</p><div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Note:</strong> Field Id like <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">customerCode</code> , <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">customerClass</code> , and<code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">taxExempted</code> belong to the customer object.</p><p class="mb-2">Field Id like <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">productCode</code> , <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">productClass</code> , <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">productTaxCode</code> , and <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">productClass</code> belong to the product object.</p></div><div class="relative w-full overflow-x-auto"><table class="cb-table" border="2"><thead><tr><th colSpan="1" rowspan="1" style="vertical-align:top;text-align:center">Field ID</th><th colSpan="1" rowspan="1" style="vertical-align:top;text-align:center">Field Value</th><th colSpan="1" rowspan="1" style="vertical-align:top;text-align:center">APIs</th></tr></thead><tbody><tr><td colSpan="1" rowspan="1" style="vertical-align:top;text-align:center"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">productCode</code></td><td colSpan="1" rowspan="4" style="vertical-align:top;text-align:center">Merchant to configure it on Vertex Platform</td><td colSpan="1" rowspan="2" style="vertical-align:top;text-align:center">APIs having <a href="/docs/api/item_prices/item-price-object">Item Prices</a> attributes.</td></tr><tr><td colSpan="1" rowspan="1" style="vertical-align:top;text-align:center"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">productClass</code></td></tr><tr><td colSpan="1" rowspan="1" style="vertical-align:top;text-align:center"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">customerCode</code></td><td colSpan="1" rowspan="2" style="vertical-align:top;text-align:center">APIs involving <a href="/docs/api/customers/customer-object">customer</a> attributes. Also includes APIs where we are creating new customers. For example: <a href="/docs/api/estimates/estimate-for-creating-a-customer-and-subscription">estimate</a>, <a href="/docs/api/subscriptions">subscription</a>, <a href="/docs/api/hosted_pages/checkout-charge-items-and-one-time-charges">hosted pages</a>.</td></tr><tr><td colSpan="1" rowspan="1" style="vertical-align:top;text-align:center"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">customerClass</code></td></tr></tbody></table></div><p class="mb-2"><strong class="font-semibold">Taxamo:</strong> Chargebee shares field IDs and corresponding values with merchants, who then configure them on the Taxamo Platform for seamless integration</p><div class="relative w-full overflow-x-auto"><table class="cb-table" border="2"><thead><tr><th colSpan="1" rowspan="1" style="vertical-align:top;text-align:center">Field Id</th><th colSpan="1" rowspan="1" style="vertical-align:top;text-align:center">Field Value</th><th colSpan="1" rowspan="1" style="vertical-align:top;text-align:center">APIs</th></tr></thead><tbody><tr><td colSpan="1" rowspan="1" style="vertical-align:top;text-align:center"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">productTaxCode</code></td><td colSpan="1" rowspan="3" style="vertical-align:top;text-align:center">Merchant to configure it on Taxamo Platform</td><td colSpan="1" rowspan="2" style="vertical-align:top;text-align:center">APIs having <a href="/docs/api/item_prices/item-price-object" class="text-blue-600 hover:text-blue-800 underline">Item Prices</a> attributes.</td></tr><tr><td colSpan="1" rowspan="1" style="vertical-align:top;text-align:center"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">productClass</code></td></tr><tr><td colSpan="1" rowspan="1" style="vertical-align:top;text-align:center"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">taxExempted</code></td><td colSpan="1" rowspan="1" style="vertical-align:top;text-align:center">APIs involving <a href="/docs/api/customers/customer-object">customer</a> attributes. Also includes APIs where we are creating new customers. For example: <a href="/docs/api/estimates/estimate-for-creating-a-customer-and-subscription">estimate</a>, <a href="/docs/api/subscriptions">subscription</a>, <a href="/docs/api/hosted_pages/checkout-charge-items-and-one-time-charges">hosted pages</a>.</td></tr></tbody></table></div><p class="mb-2"><strong class="font-semibold">cbtaxes</strong>: With CBTaxes, you can activate India IGST for customers located in Special Economic Zones (SEZ), implement zero-rated tax for SEZ customers, enable India IGST for customers outside of India, and set up zero-rated tax for customers outside of India.</p><div class="relative w-full overflow-x-auto"><table class="cb-table" border="2"><thead><tr><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">Field ID</th><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">Field Value</th><th colSpan="1" rowspan="1" style="text-align:center;vertical-align:top">APIs</th></tr></thead><tbody><tr><td colSpan="1" rowspan="2" style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">indiaSez</code></td><td colSpan="1" rowspan="1" style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">SEZ_IGST_TAX</code></td><td colSpan="1" rowspan="4" style="text-align:center;vertical-align:top">APIs involving <a href="/docs/api/customers/customer-object">customer</a> attributes. Also includes APIs where we are creating new customers. For example: <a href="/docs/api/estimates/estimate-for-creating-a-customer-and-subscription">estimate</a>, <a href="/docs/api/subscriptions">subscription</a>, <a href="/docs/api/hosted_pages/checkout-charge-items-and-one-time-charges">hosted pages</a>.</td></tr><tr><td colSpan="1" rowspan="1" style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">SEZ_ZERO_RATED_TAX</code></td></tr><tr><td colSpan="1" rowspan="2" style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">indiaExport</code></td><td colSpan="1" rowspan="1" style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">EXPORT_IGST_TAX</code></td></tr><tr><td colSpan="1" rowspan="1" style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">EXPORT_ZERO_RATED_TAX</code></td></tr></tbody></table></div><p class="mb-2"><strong class="font-semibold">All</strong>: For tax inclusive tax calculation, For tax exclusive tax calculation. This is currently used for price type overriding at customer level</p><div class="relative w-full overflow-x-auto"><table class="cb-table" border="2"><thead><tr><th style="text-align:center;vertical-align:top">Field ID</th><th style="text-align:center;vertical-align:top">Field Value</th><th style="text-align:center;vertical-align:top">APIs</th></tr></thead><tbody><tr><td style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">priceType</code></td><td style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">TAX_INCLUSIVE</code></td><td style="text-align:center;vertical-align:top">APIs involving <a href="/docs/api/customers/customer-object">customer</a> attributes. Also includes APIs where we are creating new customers. For example: <a href="/docs/api/estimates/estimate-for-creating-a-customer-and-subscription">estimate</a>, <a href="/docs/api/subscriptions">subscription</a>, <a href="/docs/api/hosted_pages/checkout-charge-items-and-one-time-charges">hosted pages</a>.</td></tr><tr><td style="text-align:center;vertical-align:top"></td><td style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">TAX_EXCLUSIVE</code></td><td style="text-align:center;vertical-align:top"></td></tr><tr><td style="text-align:center;vertical-align:top"></td><td style="text-align:center;vertical-align:top"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">SITE_DEFAULT</code> or blank</td><td style="text-align:center;vertical-align:top">Removes price type override, and allows site level configuration to be used for tax calculation.</td></tr></tbody></table></div></div></div><div id="ramps-compat-mode" class="cb-accordion"><div class="cb-accordion-title collapsed" data-toggle="collapse" data-target="#ramps-compat-mode-content" aria-expanded="false" aria-controls="ramps-compat-mode-content"><h4>Ramps API compatibility mode</h4><i class="fa fa-chevron-circle-down fa-lg" aria-hidden="true"></i></div><div class="collapse" id="ramps-compat-mode-content"><p class="mb-2">If you want to schedule changes on a subscription, use the <a href="/docs/api/ramps" class="text-blue-600 hover:text-blue-800 underline">Ramps API</a>.</p><p class="mb-2">If you are currently scheduling changes through the <a href="/docs/api/subscriptions/update-subscription-for-items" class="text-blue-600 hover:text-blue-800 underline">Update subscription API</a>, migrate to the Ramps API. To get started, <a href="https://app.chargebee.com/login?forward=https://app.chargebee.com/request_access/subscription-ramps&amp;ref=feature" target="_blank" rel="noopener noreferrer" class="text-blue-600 hover:text-blue-800 underline">request access for Subscription Ramps</a>. Chargebee will enable Ramps compatibility mode for your site. Once enabled, you can test the Ramps API without impacting your existing integrations.</p><p class="mb-2">The following parts of the Billing API have subtle differences in behavior when the Ramps feature is disabled versus when it is enabled with compatibility mode. (Follow the links to learn more.)</p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">The value of the <a href="/docs/api/subscriptions/subscription-object#has_scheduled_changes" class="text-blue-600 hover:text-blue-800 underline"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">subscription.has_scheduled_changes</code></a> attribute.</li> <li class="text-base leading-relaxed"><a href="/docs/api/subscriptions/update-subscription-for-items#impact-scheduled-changes" class="text-blue-600 hover:text-blue-800 underline">Update subscription</a></li> <li class="text-base leading-relaxed"><a href="/docs/api/hosted_pages/create-checkout-to-update-a-subscription#impact-scheduled-changes" class="text-blue-600 hover:text-blue-800 underline">Create Checkout for updating a subscription</a></li> <li class="text-base leading-relaxed"><a href="/docs/api/subscriptions/remove-scheduled-changes" class="text-blue-600 hover:text-blue-800 underline">Remove scheduled changes</a></li> <li class="text-base leading-relaxed"><a href="/docs/api/subscriptions/retrieve-with-scheduled-changes" class="text-blue-600 hover:text-blue-800 underline">Retrieve with scheduled changes</a></li> <li class="text-base leading-relaxed"><a href="/docs/api/quotes/create-a-quote-for-update-subscription-items" class="text-blue-600 hover:text-blue-800 underline">Create a quote for updating a subscription</a></li> <li class="text-base leading-relaxed"><a href="/docs/api/quotes/edit-update-subscription-quote-for-items" class="text-blue-600 hover:text-blue-800 underline">Edit a quote for updating a subscription</a></li> <li class="text-base leading-relaxed"><a href="/docs/api/portal_sessions#scheduled-subscription-changes" class="text-blue-600 hover:text-blue-800 underline">Portal sessions</a></li> </ul></div></div></div>

idstringrequired

<p class="mb-2">The unique identifier of the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">subscription</code> resource. You have the option to specify this value when creating a customer. If not specified, Chargebee automatically generates a unique identifier.</p> <div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Note</strong> In the event that the subscription resource is <a href="/docs/api/business_entities/transfer-resources-to-another-business-entity">transferred</a> along with its associated <code><a href="/docs/api/customers">customer</a></code> resource to a different business entity, Chargebee assigns a new random value as the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">id</code> for the subscription. The original identifier is preserved for the transferred copy of the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">subscription</code> resource. (See also: <a href="/docs/api/business_entities">Mechanics of business entity transfer</a>.)</p></div> <span featureId="cb-mbe" isMicro="true"></span>

currency_codestringrequired

The currency code ([ISO 4217 format](https://www.chargebee.com/docs/supported-currencies.html) ) of the subscription

billing_periodinteger (int32)

<p class="mb-2">Specifies the length of each billing cycle (or term) of the subscription, expressed in the unit defined by <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">billing_period_unit</code>.</p>

billing_period_unitstring

<p class="mb-2">Specifies the unit used to measure the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">billing_period</code>.</p> * day - * month - * year - * week -

One ofdayweekmonthyear

start_dateinteger (unix-time)

Applicable only for 'future' subscriptions. The scheduled start time of the subscription.

trial_endinteger (unix-time)

End of the trial period for the subscription. Presence of this value for 'future' subscription implies the subscription will go into 'in_trial' state when it starts.

remaining_billing_cyclesinteger (int32)

* When the subscription is not on a contract term: this value is the number of billing cycles remaining after the current cycle, at the end of which, the subscription cancels. * When the subscription is on a [contract term](/docs/api/contract_terms): this value is the number of billing cycles remaining in the contract term after the current billing cycle.

po_numberstring

Purchase order number for this subscription.

auto_collectionstring

Defines whether payments need to be collected automatically for this subscription. Overrides customer's auto-collection property. \* on - Whenever an invoice is created for this subscription, an automatic charge will be attempted on the payment method available. \* off - Automatic collection of charges will not be made for this subscription. Use this for offline payments.

One ofonoff

plan_quantity_in_decimalstring

The decimal representation of the quantity of the plan purchased. Returned for quantity-based plans when [multi-decimal pricing](/docs/api/currencies) is enabled.

plan_unit_price_in_decimalstring

The decimal representation of the price or per-unit price of the plan. The value is in major units of the currency. Always returned when [multi-decimal pricing](/docs/api/currencies) is enabled.

customer_idstringrequired

Identifier of the customer with whom this subscription is associated.

statusstringrequired

<p class="mb-2">Current state of the subscription</p> * future - <p class="mb-2">The subscription is scheduled to start at a future date.</p> * non_renewing - <p class="mb-2">The subscription will be canceled at the end of the current term.</p> * active - <p class="mb-2">The subscription is active and will be charged for automatically based on the items in it.</p> * cancelled - <p class="mb-2">The subscription has been canceled and is no longer in service.</p> * transferred - <p class="mb-2">The <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">transferred</code> status will be reflected on the source business entity&#x27;s subscription attribute once the <a href="https://www.chargebee.com/docs/2.0/mbe-getting-started-with-customer-transfer.html">customer transfer</a> activity is completed successfully.</p> * in_trial - <p class="mb-2">The subscription is in trial.</p> * paused - <p class="mb-2">The subscription is <a href="https://www.chargebee.com/docs/2.0/pause-subscription.html" target="_blank">paused</a>. The subscription will not renew while in this state.</p>

One offuturein_trialactivenon_renewingpausedcancelledtransferred

trial_startinteger (unix-time)

<p class="mb-2">Start of the trial period for the subscription. Presence of this value for <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">future</code> subscription implies the subscription will go into <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">in_trial</code> state when it starts.</p>

trial_end_actionstring

Applicable only when [End-of-trial Action](https://www.chargebee.com/docs/2.0/trial_periods_hidden.html#how-to-define-the-end-of-trial-actions-for-subscriptions) has been enabled for the site. Whenever the subscription has a trial period, this attribute (parameter) is returned (required) and specifies the operation to be carried out for the subscription once the trial ends. \* activate_subscription - The subscription activates and charges are raised for non-metered items. \* cancel_subscription - The subscription cancels. \* plan_default - The action [configured for the site](https://www.chargebee.com/docs/2.0/trial_periods_hidden.html#how-to-define-the-end-of-trial-actions-for-subscriptions) at the time when the trial ends, takes effect. \* site_default - This is the default value. The action [configured for the site](https://www.chargebee.com/docs/2.0/trial_periods_hidden.html#how-to-define-the-end-of-trial-actions-for-subscriptions) at the time when the trial ends, takes effect.

One ofsite_defaultplan_defaultactivate_subscriptioncancel_subscription

current_term_startinteger (unix-time)

Start of the current billing period of the subscription.

current_term_endinteger (unix-time)

End of the current billing period of the subscription. Subscription is renewed immediately after this.

next_billing_atinteger (unix-time)

<p class="mb-2">The date/time at which the next billing for the subscription happens. This is usually right after <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">current_term_end</code> unless multiple subscription terms were invoiced in advance using the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">terms_to_charge</code> parameter.</p>

created_atinteger (unix-time)

The time at which the subscription was created.

started_atinteger (unix-time)

<p class="mb-2">Time at which the subscription was started. Is <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">null</code> for <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">future</code> subscriptions as it is yet to be started.</p>

activated_atinteger (unix-time)

<p class="mb-2">Time at which the subscription <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">status</code> last changed to <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">active</code>. For example, this value is updated when an <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">in_trial</code> or <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">cancelled</code> subscription activates.</p>

contract_term_billing_cycle_on_renewalinteger (int32)

<p class="mb-2">Number of billing cycles the new contract term should run for, on contract renewal. The default value is the same as <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">billing_cycles</code> or a custom value depending on the <a href="https://www.chargebee.com/docs/contract-terms.html#configuring-contract-terms" target="_blank" rel="noopener noreferrer">site configuration</a> .</p>

override_relationshipboolean

<p class="mb-2">If <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">true</code> , ignores the <a href="/docs/api/customers/customer-object#relationship">hierarchy relationship</a> and uses customer as payment and invoice owner.</p>

pause_dateinteger (unix-time)

<p class="mb-2">When a pause has been scheduled, it is the date/time of scheduled pause. When the subscription is in the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">paused</code> state, it is the date/time when the subscription was paused.</p>

resume_dateinteger (unix-time)

For a paused subscription, it is the date/time when the subscription is scheduled to resume. If the pause is for an indefinite period, this value is not returned.

cancelled_atinteger (unix-time)

Time at which subscription was cancelled or is set to be cancelled.

cancel_reasonstring

The reason for canceling the subscription. Set by Chargebee automatically. \* no_card - No Card \* non_compliant_customer - Non Compliant Customer \* currency_incompatible_with_gateway - Currency incompatible with Gateway \* fraud_review_failed - Fraud Review Failed \* tax_calculation_failed - Tax Calculation Failed \* not_paid - Not Paid \* non_compliant_eu_customer - Non Compliant EU Customer

One ofnot_paidno_cardfraud_review_failednon_compliant_eu_customertax_calculation_failedcurrency_incompatible_with_gatewaynon_compliant_customer

created_from_ipstring

The IP address of the user. Used primarly in Refersion integration. Refersion uses this field to track/log affiliate subscription.

resource_versioninteger (int64)

<p class="mb-2">Version number of this resource. The <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">resource_version</code> is updated with a new timestamp in milliseconds for every change made to the resource. This attribute will be present only if the resource has been updated after 2016-09-28.</p>

updated_atinteger (unix-time)

Timestamp indicating when the item was last updated.

has_scheduled_advance_invoicesbooleanrequired

The subscription has an [advance invoicing schedule](/docs/api/advance_invoice_schedules) .

Default false

has_scheduled_changesbooleanrequired

Indicates whether a change is scheduled on the subscription. **Note** When [Ramps](ramps) are enabled with compatibility mode, this attribute indicates whether one or more ramps are scheduled for the subscription. For more details, see [Ramps API compatibility mode](/docs/api/subscriptions#ramps-compat-mode).

Default false

payment_source_idstring

Payment source attached to this subscription. If present, customer's payment sources won't be used to collect any payment for this subscripiton.

plan_free_quantity_in_decimalstring

The free_quantity_in_decimal as set for the plan. Returned for quantity-based plans when [multi-decimal pricing](/docs/api/currencies) is enabled.

plan_amount_in_decimalstring

The decimal representation of the total amount for the plan, in major units of the currency. Always returned when [multi-decimal pricing](/docs/api/currencies) is enabled.

cancel_schedule_created_atinteger (unix-time)

<p class="mb-2">This is the date/time at which the most recent cancellation schedule for the subscription was created in Chargebee. Applicable only for <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">cancelled</code> subscriptions or subscriptions that are scheduled for cancellation.</p>

offline_payment_methodstring

\* sepa_credit - \* cash - \* no_preference - \* bank_transfer - \* check - \* eu_automated_bank_transfer - \* jp_automated_bank_transfer - \* uk_automated_bank_transfer - \* custom - \* boleto - \* mx_automated_bank_transfer - \* us_automated_bank_transfer - \* ach_credit -

One ofno_preferencecashcheckbank_transferach_creditsepa_creditboletous_automated_bank_transfereu_automated_bank_transferuk_automated_bank_transferjp_automated_bank_transfermx_automated_bank_transfercustom

channelstring

The subscription channel this object originated from and is maintained in. \* play_store - The object data is synchronized with data from [in-app subscription(s)](/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. \* app_store - The object data is synchronized with data from [in-app subscription(s)](/docs/api/in_app_subscriptions) created in Apple App Store. Direct manipulation of this object via UI or API is disallowed.

One ofwebapp_storeplay_store

net_term_daysinteger (int32)

<p class="mb-2">The <a href="https://www.chargebee.com/docs/net_d.html" target="_blank">Net D</a> value explicitly set for this subscription. Net D is the number of days from <a href="/docs/api/invoices/invoice-object#date" class="text-blue-600 hover:text-blue-800 underline"><code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">invoice.date</code></a> until payment for the invoice is due. When an invoice is raised, and this value is unavailable, the net_term_days defined at <a href="/docs/api/customers/customer-object#net_term_days">the customer level</a> is considered.</p>

active_idstring

<div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Note</strong>: Present only when the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">subscription</code> has been <a href="/docs/api/business_entities/transfer-resources-to-another-business-entity">transferred</a> between business entities.</p></div> <p class="mb-2">Represents the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">id</code> of the active version of the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">subscription</code> resource.</p> <div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Tip</strong> If the <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">id</code> and <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">active_id</code> of a <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">subscription</code> resource are the same, this indicates that you are working with the active version of that <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">subscription</code> resource.</p></div> <span featureId="cb-mbe" isMicro="true"></span>

payment_sourceobject

**Updates** This API obsoletes the [Cards API](/docs/api/cards) in Chargebee. Represents the payment source for the customer. Specific types of payment source (Card, Direct Debit, Paypal Express Checkout, etc.) is defined as sub-resource in the response object. You can find the list of supported payment sources and the expected input parameters [here](/docs/api/payment_parameters). See [Payment source attributes](/docs/api/payment_sources/payment-source-object) for a descriptive list of attributes and payment source types.

idstringrequired

Identifier of the payment source

resource_versioninteger (int64)

<p class="mb-2">Version number of this resource. The <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">resource_version</code> is updated with a new timestamp in milliseconds for every change made to the resource. This attribute will be present only if the resource has been updated after 2016-09-28.</p>

updated_atinteger (unix-time)

Timestamp indicating when this payment source resource was last updated.

created_atinteger (unix-time)required

Timestamp indicating when this payment source resource is created.

customer_idstringrequired

Identifier of the customer with whom this payment source is associated.

typestringrequired

Type of payment source \* direct_debit - Represents bank account for which the direct debit or ACH agreement/mandate is created. \* unionpay - Payments made via UnionPay. \* sepa_instant_transfer - Payments made via Sepa Instant Transfer \* dotpay - Payments made via Dotpay. \* klarna - Payments made via Klarna. \* giropay - Payments made via giropay. \* grab_pay - Payments made via GrabPay \* stablecoin - Payments made via Stablecoin. \* bancontact - Payments made via Bancontact Card. \* amazon_payments - Payments made via Amazon Payments. \* pay_by_bank - Pay By Bank \* online_banking_poland - Payments made via Online Banking Poland \* after_pay - Payments made via Afterpay \* paypay - \* generic - Payments made via Generic Payment Method. \* twint - Payments made via Twint \* automated_bank_transfer - Represents virtual bank account using which the payment will be done. \* paypal_express_checkout - Payments made via PayPal Express Checkout. \* trustly - Trustly \* upi - UPI Payments. \* cash_app_pay - Payments made via Cash App Pay. \* south_korean_cards - \* electronic_payment_standard - Electronic Payment Standard \* google_pay - Payments made via Google Pay. \* pay_to - Payments made via PayTo \* revolut_pay - Payments made via Revolut Pay. \* naver_pay - Payments made via Naver Pay. \* alipay - Payments made via Alipay. This payment source is deprecated. \* kakao_pay - Payments made via Kakao Pay. \* sofort - Payments made via Sofort. \* pix - Payments made via Pix \* gcash - \* pay_co - Payments made via PayCo \* wechat_pay - Payments made via WeChat Pay. This payment source is deprecated. \* netbanking_emandates - Netbanking (eMandates) Payments. \* go_pay - Payments made via GoPay \* card - Card based payment including credit cards and debit cards. Details about the card can be obtained from the card resource. \* faster_payments - Payments made via Faster Payments \* alipay_hk - \* payme - Payments made via PayMe \* klarna_pay_now - Payments made via Klarna Pay Now \* swish - Payments made via Swish \* venmo - Payments made via Venmo \* ideal - Payments made via iDEAL. \* kbc_payment_button - KBC Payment Button \* payconiq_by_bancontact - Payments made via Payconiq by Bancontact. \* apple_pay - Payments made via Apple Pay.

One ofcardpaypal_express_checkoutamazon_paymentsdirect_debitgenericalipayunionpayapple_paywechat_payidealgoogle_paysofortbancontactgiropaydotpayupinetbanking_emandatesvenmopay_tofaster_paymentssepa_instant_transferautomated_bank_transferklarna_pay_nowonline_banking_polandpayconiq_by_bancontactelectronic_payment_standardkbc_payment_buttonpay_by_banktrustlystablecoinkakao_paynaver_payrevolut_paycash_app_paytwintgo_paygrab_paypay_coafter_payswish

reference_idstringrequired

The reference id. In the case of Amazon and PayPal this will be the 'billing agreement id'. For GoCardless direct debit this will be 'mandate id'. In the case of card payments this will be the identifier provided by the gateway/card vault for the specific payment method resource. **Note:** This is not the one time temporary token provided by gateways like Stripe.

statusstringrequired

Current status of the payment source. \* valid - A payment source that is valid and active. \* expiring - A payment source that is expiring (like card's status based on its expiry date). \* invalid - The billing agreement cannot be used. It might become valid again either automatically or due to customer action. \* pending_verification - The payment source needs to be verified \* expired - A payment source that has expired

One ofvalidexpiringexpiredinvalidpending_verificationDefault "valid"

gatewaystringrequired

Name of the gateway this payment source is stored with. \* bluesnap - BlueSnap is a payment gateway. \* jp_morgan - J.P. Morgan Mobility Payment Solutions is a payment gateway that enables you to securely accept and manage digital payments across different [payment_source_type](/docs/api/payment_sources/payment_source-object#type). This feature is a **Private Beta Release** . [Request access](https://app.chargebee.com/login?forward=https://app.chargebee.com/request_access/jp-morgan-bacs&ref=feature) to enable the J.P. Morgan Mobility Payment Solutions gateway via payFURL for your test and live sites. \* tco - 2Checkout is a payment gateway. \* payway - \* razorpay - Razorpay is a fast growing payment service provider in India working with all leading banks and support for major local payment methods including Netbanking, UPI etc. \* dlocal - Dlocal provides payment solutions for global commerce by accepting local payment methods. \* checkout_com - Checkout.com is a payment gateway. \* adyen - Adyen is a payment gateway. \* braintree - Braintree is a payment gateway. \* paystack - Paystack is a payment gateway for businesses in Africa. It enables secure payment acceptance both online and offline. This feature is a **Private Beta Release** . [Request access](https://app.chargebee.com/login?forward=https://app.chargebee.com/request_access/paystack&ref=feature) to enable Paystack for your test and live sites. \* pay_com - Pay.com provides payment services focused on simplicity and hassle-free operations for businesses of all sizes. \* moneris_us - Moneris USA is a payment gateway. \* pin - Pin is a payment gateway \* moneris - Moneris is a payment gateway. \* chargebee - Chargebee test gateway. \* cybersource - CyberSource is a payment gateway. \* ecentric - Ecentric provides a seamless payment processing service in South Africa specializing on omnichannel capabilities. \* first_data_global - First Data Global Gateway Virtual Terminal Account \* exact - Exact Payments is a payment gateway. \* nuvei - Nuvei is a secure and reliable payment processing solution that allows you to accept payments from customers and suitable for various types of businesses. This feature is a **Private Beta Release** . [Request access](https://app.chargebee.com/login?forward=https://app.chargebee.com/request_access/nuvei&ref=feature) to enable Nuvei for your test and live sites. \* eway - eWAY Account is a payment gateway. \* amazon_payments - Amazon Payments is a payment service provider. \* sage_pay - Sage Pay is a payment gateway. \* elavon - Elavon Virtual Merchant is a payment solution. \* orbital - Chase Paymentech(Orbital) is a payment gateway. \* beanstream - Bambora(formerly known as Beanstream) is a payment gateway. \* hdfc - HDFC Account is a payment gateway. \* bank_of_america - Bank of America Gateway \* gocardless - GoCardless is a payment service provider. \* paymill - PAYMILL is a payment gateway. \* balanced_payments - Balanced is a payment gateway \* twikey - Twikey is a payment service provider that specializes in processing direct debit payments across the EU. \* moyasar - \* deutsche_bank - Deutsche Bank is the leading German bank with strong European roots and a global network. This feature is a **Private Beta Release**. \* bluepay - BluePay is a payment gateway. \* paypal_express_checkout - PayPal Express Checkout is a payment gateway. \* paypal_payflow_pro - PayPal Payflow Pro is a payment gateway. \* global_payments - Global Payments is a payment service provider. \* not_applicable - Indicates that payment gateway is not applicable for this resource. \* nmi - NMI is a payment gateway. \* worldpay - WorldPay is a payment gateway \* authorize_net - Authorize.net is a payment gateway \* tempus - \* stripe - Stripe is a payment gateway. \* metrics_global - Metrics global is a leading payment service provider providing unified payment services in the US. \* windcave - Windcave provides an end to end payment processing solution in ANZ and other leading global markets. \* quickbooks - Intuit QuickBooks Payments gateway \* wepay - WePay is a payment gateway. \* ezidebit - Ezidebit is a payment gateway integration based in Australia that supports automated direct debit, BPAY, and card payments for businesses. This feature is a **Private Beta Release**. \* wirecard - WireCard Account is a payment service provider. \* chargebee_payments - Chargebee Payments gateway \* paypal_pro - PayPal Pro Account is a payment gateway. \* paypal - PayPal Commerce is a payment gateway. \* ingenico_direct - Worldline Online Payments is a payment gateway. \* ogone - Ingenico ePayments (formerly known as Ogone) is a payment gateway. \* migs - MasterCard Internet Gateway Service payment gateway. \* vantiv - Vantiv is a payment gateway. \* eway_rapid - eWAY Rapid is a payment gateway. \* mollie - Mollie is a payment gateway. \* solidgate - Solidgate is a secure and reliable payment processing solution that allows you to accept payments from customers and suitable for various types of businesses. This feature is a **Private Beta Release**. \* ebanx - EBANX is a payment gateway, enabling businesses to accept diverse local payment methods from various countries for increased market reach and conversion.

One ofchargebeechargebee_paymentsadyenstripewepaybraintreeauthorize_netpaypal_propinewayeway_rapidworldpaybalanced_paymentsbeanstreambluepayelavonfirst_data_globalhdfcmigsnmiogonepaymillpaypal_payflow_prosage_paytcowirecardamazon_paymentspaypal_express_checkoutgocardlessorbitalmoneris_usmonerisbluesnapcybersourcevantivcheckout_compaypalingenico_directexactmollie

gateway_account_idstring

The gateway account to which this payment source is stored with.

ip_addressstring

The IP address of the customer. Used primarily for referral integration and EU VAT validation.

issuing_countrystring

[two-letter(alpha2)](https://www.iso.org/iso-3166-country-codes.html) ISO country code.

deletedbooleanrequired

Indicates that this resource has been deleted.

business_entity_idstring

<p class="mb-2">The unique ID of the <a href="/docs/api/advanced-features">business entity</a> of this <code class="bg-gray-100 text-gray-800 font-medium border border-gray-300 rounded px-1.5 py-0.5 mx-1 text-sm font-mono whitespace-nowrap">payment_source</code>. This is always the same as the business entity of the <a href="/docs/api/payment_sources/payment_source-object#customer_id">customer</a>.</p> <span featureId="cb-mbe" isMicro="true"></span>

cardobject17 fields

Card details associated with this payment source.

bank_accountobject11 fields

Bank account details the direct debit or ACH or NetBanking agreement/mandate created with this payment source.

boletoobject4 fields

Boleto payment source details of the customer

billing_addressobject14 fields

Billing address for the payment source.

amazon_paymentobject2 fields

Amazon payments details associated with this payment source.

upiobject1 fields

Represents the payment method that allows you to make payments directly using a bank account.

paypalobject2 fields

PayPal Express Checkout details associated with this payment source.

venmoobject1 fields

Venmo details associated with this payment source.

klarna_pay_nowobject1 fields

Klarna Pay Now payment source details of the customer

mandatesarray<object>3 fields

Mandate details associated with the payment source.

json
{
  "subscription": null,
  "payment_source": null
}

Need more? See the Chargebee guide for connection setup and behaviour shared by every action.