younifyd
Menu

Refund A Credit Note

Refund a credit note

POST/credit_notes/{credit-note-id}/refund

Use it in a workflow

  1. Add a step and choose the Chargebee connector.
  2. Pick the Refund A Credit Note action (under Chargebee API).
  3. Fill in the fields below, then reference the result from later steps as {{refundACreditNote.response.data}}.

Request

Path parameters

credit-note-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.

refund_amountinteger (int64)

<p class="mb-2">The amount to be refunded.</p> <div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Constraints</strong></p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">If multiple <a href="/docs/api/invoices/invoice-object#linked_payments" class="text-blue-600 hover:text-blue-800 underline">transactions</a> are associated with the credit note, the refund can be processed only for one transaction at a time.</li> <li class="text-base leading-relaxed">Offline refunds, including those for <a href="/docs/api/invoices/invoice-object#linked_taxes_withheld" 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">linked_taxes_withheld</code></a>, cannot be refunded via this operation. Use the <a href="/docs/api/credit_notes/refund-a-credit-note" class="text-blue-600 hover:text-blue-800 underline">Record refund for a credit note</a> API instead.</li> </ul></div> <div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Default behavior</strong></p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">If not specified, 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">amount_available</code> for this credit note is implied.</li> </ul></div>

customer_notesstring

A note to be added for this operation, to the credit note. This note is displayed on customer-facing documents such as the [Credit Note PDF](/docs/api/credit_notes/retrieve-credit-note-as-pdf) .

refund_reason_codestring

Reason code for the refund. Must be one from a list of reason codes set in the Chargebee app in **Settings \> Configure Chargebee \> Reason Codes \> Credit Notes \> Refund Credit Note**. Must be passed if set as mandatory in the app. The codes are case-sensitive.

json
{
  "refund_amount": null,
  "customer_notes": null,
  "refund_reason_code": null
}

Response

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

credit_noteobject

<div class="api-description"><p class="mb-2">A <a href="https://www.chargebee.com/docs/credit-notes.html" target="_blank">Credit Note</a> is a document that specifies the money owed by a business to its customer. The seller usually issues a Credit Note for the same or lower amount than the invoice, and then repays the money to the customer or set it off against other &#x27;due&#x27; invoices.</p><h3>Credit Note Types</h3><p class="mb-2">Credit notes in Chargebee are categorized into three types: 1. <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">adjustment</code>: Adjustment credit notes are used to adjust the amount of an existing invoice 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">payment_due</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">not_paid</code> <a href="/docs/api/invoices/invoice-object#status">status</a>. Use this type of credit note to reduce the invoice amount, typically as a discount to the customer. Adjustment credit notes are automatically created in the following cases:</p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">When an invoice is written off.</li> <li class="text-base leading-relaxed">When a subscription is modified with proration enabled, and the invoice for the current term 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">payment_due</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">not_paid</code> <a href="/docs/api/invoices/invoice-object#status">status</a>. 2. <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">refundable</code>: Refundable credit notes allow you to return a certain amount to the customer. These credits can be:</li> <li class="text-base leading-relaxed">Retained for automatic application on future invoices.</li> <li class="text-base leading-relaxed">Applied to existing unpaid invoices.</li> <li class="text-base leading-relaxed">Refunded to the customer. Refundable credit notes are automatically created in the following cases:</li> <li class="text-base leading-relaxed">When an invoice is refunded.</li> <li class="text-base leading-relaxed">When a subscription is changed or canceled with proration enabled, the invoice for the current term 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">paid</code> <a href="/docs/api/invoices/invoice-object#status">status</a>. Refundable credits are applied to future invoices or can be refunded to the original payment method. 3. <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">store</code>: Store credit notes are created 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">paid</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">partially_paid</code> invoice <a href="/docs/api/invoices/invoice-object#status">status</a> during subscription changes, such as upgrades, downgrades, or cancellations. Key characteristics of store credits:</li> <li class="text-base leading-relaxed">No tax component is included at the time of creation.</li> <li class="text-base leading-relaxed">A credit note document is generated, similar to refundable credits.</li> <li class="text-base leading-relaxed">Store credits are applied before tax calculations on future invoices.</li> </ul><div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Note:</strong> If you have enabled <em class="italic">consolidated invoicing</em> , to know the subscriptions attached with a credit note you have to refer <a href="/docs/api/credit_notes/credit_note-object#line_items">line_item&#x27;s</a> <em class="italic">subscription_id</em> . The credit note&#x27;s <em class="italic">subscription_id</em> should <strong class="font-semibold">not</strong> be used (which will be <em class="italic">null</em> if the credit note has lines from multiple subscriptions).</p></div><div id="ref-invoice-impact" class="cb-accordion"><div class="cb-accordion-title collapsed" data-toggle="collapse" data-target="#ref-invoice-impact-content" aria-expanded="false" aria-controls="ref-invoice-impact-content"><p class="mb-2">Impact on reference invoice</p><i class="fa fa-chevron-circle-down fa-lg" aria-hidden="true"></i></div><div class="collapse" id="ref-invoice-impact-content"><p class="mb-2">The following updates are made to the reference invoice when a credit note is created/imported:</p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">If the credit note <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">type</code> 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">adjustment</code>: <ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">The adjustment credit note details are added to 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">adjustment_credit_notes[]</code> attribute of the invoice.</li> <li class="text-base leading-relaxed">The invoice <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">amount_due</code> is reduced by the credit note <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">total</code>.</li> <li class="text-base leading-relaxed">The invoice <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> is updated 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">paid</code> if the invoice <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">amount_due</code> equals the credit note <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">total</code>.</li> <li class="text-base leading-relaxed">The invoice <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> does not change if the invoice <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">amount_due</code> is greater than credit note <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">total</code>.</li> </ul> </li> <li class="text-base leading-relaxed">If the credit note <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">type</code> 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">refundable</code>: <ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">The refundable credit note details are added to 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">issued_credit_notes[]</code> attribute of the invoice.</li> <li class="text-base leading-relaxed">The invoice <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> does not change.</li> </ul> </li> <li class="text-base leading-relaxed">If the credit note <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">type</code> 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">store</code>: <ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">The store credit note details are added to 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">issued_credit_notes[]</code> attribute of the invoice.</li> <li class="text-base leading-relaxed">The invoice <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> does not change.</li> </ul> </li> </ul></div></div></div>

idstringrequired

Credit-note id.

customer_idstringrequired

The identifier of the customer this credit note belongs to.

subscription_idstring

The identifier of the subscription this Credit Note belongs to. **Note:** If *consolidated invoicing* is enabled, to know the subscriptions attached with this Credit Note you have to refer [line_item's](/docs/api/credit_notes/credit_note-object#line_items) *subscription_id* . This attribute should **not** be used (which will be *null* if this credit note has lines from multiple subscriptions).

reference_invoice_idstring

The identifier of the invoice against which this Credit Note is issued

typestringrequired

The credit note type. [Learn more](/docs/api/credit_notes/credit-note-object) about credit note types. \* store - Store Credit Note \* refundable - Refundable Credit Note \* adjustment - Adjustment Credit Note

One ofadjustmentrefundablestore

reason_codestring

The reason for issuing this credit note. The following reason codes are supported now\[Deprecated; use the [create_reason_code](/docs/api/credit_notes/credit_note-object#create_reason_code) parameter instead\] \* subscription_change - This reason will be set automatically for Credit Notes created during Change Subscription operation when [proration](https://www.chargebee.com/docs/proration.html) is enabled \* order_change - Order Change \* other - Can be set when none of the above reason codes are applicable \* fraudulent - FRAUDULENT \* chargeback - Can be set when you are recording your customer Chargebacks \* subscription_pause - This reason will be automatically set to credit notes created during pause/resume subscription operation. \* waiver - Waiver \* subscription_cancellation - This reason will be set automatically for Credit Notes created during cancel subscription operation \* product_unsatisfactory - Product Unsatisfactory \* order_cancellation - Order Cancellation \* write_off - This reason will be set automatically for the Credit Notes created during invoice [Write Off](https://www.chargebee.com/docs/invoice-operations.html#write-off) operation. \* service_unsatisfactory - Service Unsatisfactory

One ofwrite_offsubscription_changesubscription_cancellationsubscription_pausechargebackproduct_unsatisfactoryservice_unsatisfactoryorder_changeorder_cancellationwaiverotherfraudulent

statusstringrequired

The credit note status. \* voided - When the Credit Note has been cancelled. \* refund_due - When the credits are yet to be used, or have been partially used. \* refunded - When the entire credits (Credit Note amount) have been used (i.e either allocated to invoices or refunded). \* adjusted - When the Credit Note has been adjusted against an invoice.

One ofadjustedrefundedrefund_duevoided

vat_numberstring

VAT number of the customer for whom this credit note is raised.

dateinteger (unix-time)

The date the credit note is issued.

price_typestringrequired

The price type of the credit note. \* tax_inclusive - All amounts in the document are inclusive of tax. \* tax_exclusive - All amounts in the document are exclusive of tax.

One oftax_exclusivetax_inclusiveDefault "tax_exclusive"

currency_codestringrequired

The currency code (ISO 4217 format) for the credit note

totalinteger (int64)

Credit Note amount in cents.

Default 0

amount_allocatedinteger (int64)

The amount allocated to invoices from the credit note.

Default 0

amount_refundedinteger (int64)

The refunds issued from this credit note.

Default 0

amount_availableinteger (int64)

The yet to be used credits of this credit note.

Default 0

refunded_atinteger (unix-time)

The time this credit note gets fully used. Please note that this field is not present when partial refunds are issued.

voided_atinteger (unix-time)

Timestamp indicating the date and time this credit note gets voided.

generated_atinteger (unix-time)

The date/time when the credit note was raised. This date/time can be backdated, which means that the date/time can be earlier than the date/time the credit note was created.

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 credit note was last updated. This attribute will be present only if the resource has been updated after 2016-09-28.

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. In-App Subscriptions is currently in early access. Contact [eap@chargebee.com](mailto:eap@chargebee.com) for more information. \* 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

line_items_next_offsetstring

<p class="mb-2">This attribute is returned only if additional resources are available. Use this value as the input parameter 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">line_items_offset</code> to retrieve the next set of resources.</p> <div class="alert alert-info"><p class="mb-2"><strong class="font-semibold">Note:</strong></p><ul class="list-disc list-outside ml-6 my-4 space-y-2"> <li class="text-base leading-relaxed">Applicable only when Enterprise-scale Invoicing is enabled.</li> <li class="text-base leading-relaxed">Enterprise-scale Invoicing is currently in <strong class="font-semibold">Private Beta</strong>. Please reach out to <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">Chargebee Support</a> to enable this feature.</li> </ul></div>

sub_totalinteger (int64)required

The Credit Note sub-total

sub_total_in_local_currencyinteger (int64)

Invoice subtotal in the currency of the place of supply.

total_in_local_currencyinteger (int64)

Total invoice amount in the currency of the place of supply.

local_currency_codestring

The currency code (ISO 4217 format) of the place of supply in which VAT needs to be converted and displayed.

round_off_amountinteger (int64)

<p class="mb-2">Indicates the rounded-off amount. For example, if your invoice amount is $99.99, and the amount is rounded off to $100.00, in this case, $100.00 is your invoice amount, $0.01 is 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">round_off_amount</code>. If there is no <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">round-off amount</code> , it will display <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">0</code> .</p>

fractional_correctioninteger (int64)

Indicates the fractional correction amount.

notesarray<string>

The list of notes attached to this credit note. Each note is displayed on customer-facing documents such as the [Credit Note PDF](/docs/api/credit_notes#retrieve_credit_note_as_pdf). Currently this list contains the note configured for the customer; additional note types may be added in future.

deletedbooleanrequired

Indicates that this resource has been deleted.

tax_categorystring

Specifies the customer's category for the Goods and Services Tax (GST). This field is returned only if you've configured GST for the India region.

local_currency_exchange_ratenumber (decimal)

This parameter represents the exchange rate as a relative price of the base currency that appears as local currency in invoices and credit notes. The local currency exchange rate specifically refers to the exchange rate of a country's currency when converting it to another currency. For example, if you want to convert US dollars to euros, the local currency exchange rate would be the rate at which you can convert US dollars to euros.

create_reason_codestring

Reason code for creating the credit note. Must be one from a list of reason codes set in the Chargebee app in **Settings \> Configure Chargebee \> Reason Codes \> Credit Notes \> Create Credit Note**. Must be passed if set as mandatory in the app. The codes are case-sensitive

vat_number_prefixstring

<p class="mb-2">An overridden value for the first two characters of the <a href="https://en.wikipedia.org/wiki/VAT_identification_number" target="_blank">full VAT number</a>. Only applicable specifically for customers with <code><a href="/docs/api/customers/customer-object#billing_address">billing_address</a></code></p> <p class="mb-2"><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">country</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">XI</code> (which is <strong class="font-semibold">United Kingdom - Northern Ireland</strong> ).</p> <p class="mb-2">When you have enabled <a href="https://www.chargebee.com/docs/eu-vat.html" target="_blank">EU VAT</a> in 2021 or have <a href="https://www.chargebee.com/docs/brexit.html#what-needs-to-be-done-in-chargebee" target="_blank">manually enabled</a> the Brexit configuration, you have the option of setting <code><a href="/docs/api/customers/customer-object#billing_address">billing_address</a></code></p> <p class="mb-2"><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">country</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">XI</code>. That&#x27;s the code for <strong class="font-semibold">United Kingdom - Northern Ireland</strong>. The first two characters of the VAT number in such a case 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">XI</code> by default. However, if the VAT number was registered in UK, the value should 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">GB</code>. Set <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">vat_number_prefix</code> 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">GB</code> for such cases.</p>

business_entity_idstring

<p class="mb-2">The unique ID of the <a href="/docs/api/advanced-features">business entity</a> of this credit_note. This is always the same as the business entity of the invoice referred to by <code><a href="/docs/api/credit_notes/credit_note-object#reference_invoice_id">reference_invoice_id</a></code>.</p> <span featureId="cb-mbe" isMicro="true"></span>

line_itemsarray<object>26 fields

The line items of this credit note

line_item_tiersarray<object>11 fields

The list of tiers applicable for this line item

line_item_discountsarray<object>5 fields

The list of discount(s) applied for each line item of this credit note.

line_item_taxesarray<object>15 fields

The list of taxes applied on line items

line_item_addressesarray<object>15 fields

The list of addresses used for tax calculation on line items.

transactionobject

This resource represents the [transaction](https://www.chargebee.com/docs/transactions.html) event that has happened in your account.

idstringrequired

Uniquely identifies the transaction.

customer_idstring

Identifier of the customer for which this transaction is made

subscription_idstring

Identifier of the subscription for which this transaction is made.

gateway_account_idstring

The gateway account used for this transaction

payment_source_idstring

Identifier of the payment source for which this transaction is made

payment_methodstringrequired

<p class="mb-2">The payment method of this transaction</p> * naver_pay - <p class="mb-2">Payments made via Naver Pay.</p> <span featureId="cb-naver-pay" isMicro="true"></span> * unionpay - <p class="mb-2">Unionpay</p> * paypay - * online_banking_poland - <p class="mb-2">Online Banking Poland</p> <span featureId="cb-online-banking-poland" isMicro="true"></span> * upi - <p class="mb-2">upi</p> * payconiq_by_bancontact - <p class="mb-2">Payments made via Payconiq by Bancontact.</p> <span featureId="cb-payconiq-by-bancontact" isMicro="true"></span> * kakao_pay - <p class="mb-2">Payments made via Kakao Pay.</p> <span featureId="cb-kakao-pay" isMicro="true"></span> * check - <p class="mb-2">Check</p> * payme - <p class="mb-2">Payments made via PayMe</p> <span featureId="cb-payme" isMicro="true"></span> * cash_app_pay - <p class="mb-2">Payments made via Cash App Pay.</p> <span featureId="cb-cash-app-pay" isMicro="true"></span> * custom - <p class="mb-2">Custom</p> * amazon_payments - <p class="mb-2">Amazon Payments</p> * boleto - <p class="mb-2">boleto</p> * klarna - <p class="mb-2">Payments made via Klarna.</p> <span featureId="cb-klarna" isMicro="true"></span> * direct_debit - <p class="mb-2">Direct Debit</p> * klarna_pay_now - <p class="mb-2">Klarna Pay Now</p> <span featureId="cb-klarna-pay-now" isMicro="true"></span> * sepa_instant_transfer - <p class="mb-2">Sepa Instant Transfer</p> <span featureId="cb-sepa-instant-transfer" isMicro="true"></span> * apple_pay - <p class="mb-2">Apple Pay</p> * wechat_pay - <p class="mb-2">Payments made via WeChat Pay.</p> <span featureId="cb-wechat-pay" isMicro="true"></span> * twint - <p class="mb-2">Payments made via Twint</p> <span featureId="cb-twint" isMicro="true"></span> * kbc_payment_button - <p class="mb-2">KBC Payment Button</p> * bancontact - <p class="mb-2">Bancontact</p> * faster_payments - <p class="mb-2">Faster Payments</p> <span featureId="cb-faster-payments" isMicro="true"></span> * go_pay - <p class="mb-2">Payments made via GoPay</p> <span featureId="cb-go-pay" isMicro="true"></span> * stablecoin - <p class="mb-2">Payments made via Stablecoin.</p> <span featureId="cb-stablecoin" isMicro="true"></span> * venmo - <p class="mb-2">Venmo</p> <span featureId="cb-venmo" isMicro="true"></span> * bank_transfer - <p class="mb-2">Bank Transfer</p> * paypal_express_checkout - <p class="mb-2">Paypal Express Checkout</p> * electronic_payment_standard - <p class="mb-2">Electronic Payment Standard</p> * other - <p class="mb-2">Payment Methods other than the above types</p> * trustly - <p class="mb-2">Trustly</p> * ach_credit - <p class="mb-2">ACH Credit</p> * sepa_credit - <p class="mb-2">SEPA Credit</p> * alipay_hk - * card - <p class="mb-2">Card</p> * ideal - <p class="mb-2">IDEAL</p> * gcash - * chargeback - <p class="mb-2">Only applicable for a transaction of <code><a href="/docs/api/transactions/transaction-object#type">type</a></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">refund</code>. This value is set by Chargebee when an automated <a href="https://www.chargebee.com/docs/chargeback.html#chargeback-process" target="_blank" rel="noopener noreferrer">chargeback</a> occurs. You can also set this explicitly when <a href="/docs/api/transactions/record-an-offline-refund">recording a refund</a> .</p> * automated_bank_transfer - <p class="mb-2">Automated Bank Transfer</p> <span featureId="cb-bank-transfer" isMicro="true"></span> * google_pay - <p class="mb-2">Google Pay</p> * netbanking_emandates - <p class="mb-2">netbanking_emandates</p> * pay_to - <p class="mb-2">PayTo</p> <span featureId="cb-pay-to" isMicro="true"></span> * pay_by_bank - <p class="mb-2">Pay By Bank</p> * dotpay - <p class="mb-2">Dotpay</p> * alipay - <p class="mb-2">Payments made via Alipay.</p> <span featureId="cb-alipay" isMicro="true"></span> * sofort - <p class="mb-2">Sofort</p> * swish - <p class="mb-2">Payments made via Swish</p> <span featureId="cb-swish" isMicro="true"></span> * grab_pay - <p class="mb-2">Payments made via GrabPay</p> <span featureId="cb-grab-pay" isMicro="true"></span> * pix - <p class="mb-2">Pix</p> <span featureId="cb-pix" isMicro="true"></span> * giropay - <p class="mb-2">giropay</p> * pay_co - <p class="mb-2">Payments made via PayCo</p> <span featureId="cb-pay-co" isMicro="true"></span> * revolut_pay - <p class="mb-2">Payments made via Revolut Pay.</p> <span featureId="cb-revolut-pay" isMicro="true"></span> * cash - <p class="mb-2">Cash</p> * after_pay - <p class="mb-2">Payments made via Afterpay</p> <span featureId="cb-after-pay" isMicro="true"></span> * south_korean_cards -

One ofcardcashcheckchargebackbank_transferamazon_paymentspaypal_express_checkoutdirect_debitalipayunionpayapple_paywechat_payach_creditsepa_creditidealgoogle_paysofortbancontactgiropaydotpayotherupinetbanking_emandatescustomboletovenmopay_tofaster_paymentssepa_instant_transferautomated_bank_transferklarna_pay_nowonline_banking_polandpayconiq_by_bancontactelectronic_payment_standardkbc_payment_buttonpay_by_banktrustlystablecoinkakao_paynaver_payDefault "card"

reference_numberstring

<p class="mb-2">The reference number for this transaction. For example, the check number when <code><a href="/docs/api/transactions/transaction-object#payment_method">payment_method</a></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">check</code> .</p>

gatewaystringrequired

Gateway through which this transaction was done. Applicable only for 'Card' Payment Method \* 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

typestringrequired

<p class="mb-2">Type of the transaction.</p> * authorization - <p class="mb-2">The transaction represents an authorization for capturing the <code><a href="/docs/api/transactions/transaction-object#amount">amount</a></code> from the customer&#x27;s <code><a href="/docs/api/payment_sources">payment_source</a></code> .</p> * payment - <p class="mb-2">The transaction represents capture of <code><a href="/docs/api/transactions/transaction-object#amount">amount</a></code> from the customer&#x27;s <code><a href="/docs/api/payment_sources">payment_source</a></code> .</p> * refund - <p class="mb-2">The transaction represents a refund of <code><a href="/docs/api/transactions/transaction-object#amount">amount</a></code> to the customer&#x27;s <code><a href="/docs/api/payment_sources">payment_source</a></code> .</p> * payment_reversal - <p class="mb-2">Indicates a reversal transaction.</p>

One ofauthorizationpaymentrefundpayment_reversal

dateinteger (unix-time)

Indicates when this transaction occurred.

settled_atinteger (unix-time)

Indicates the time at which the final status of the transaction has been marked.

exchange_ratenumber (decimal)

Exchange rate used for base currency conversion

currency_codestringrequired

The currency code (ISO 4217 format) for the transaction.

amountinteger (int64)

Amount for this transaction.

id_at_gatewaystring

The id with which this transaction is referred in gateway.

statusstring

<p class="mb-2">The status of this transaction.</p> * in_progress - <p class="mb-2">Transaction is being processed by the gateway. This typically happens for <a href="https://www.chargebee.com/docs/direct-debit-payments.html" target="_blank">direct debit transactions</a> or, in case of cards, refund transactions. Such transactions can take 2-7 days to complete, depending on the gateway and payment method.</p> * timeout - <p class="mb-2">Transaction failed because of Gateway not accepting the connection.</p> * success - <p class="mb-2">The transaction is successful.</p> * voided - <p class="mb-2">The transaction got voided or authorization expired at gateway.</p> * needs_attention - <p class="mb-2">When connection with the Gateway gets terminated abruptly. 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">needs_attention</code> status Chargebee automatically reconcile the transaction for few gateways, for rest of the gateways you have to use the <a href="/docs/api/transactions/reconcile-transaction">Reconcile transaction API</a>. You can use this API to update 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_at_gateway</code> (Gateway Transaction ID) 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">status</code> for a <a href="/docs/api/transactions/transaction-object#status"><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">needs_attention</code></a> transaction to be reconciled at par with the gateway.</p> <div class="alert alert-info"><p class="mb-2"><a href="https://www.chargebee.com/docs/payments/2.0/needs-attention-transactions.html">Learn more</a> about <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">needs_attention</code> transaction status</p></div> * late_failure - <p class="mb-2">Indicates that a successful payment transaction has failed now due to a late failure notification from the payment gateway, typically caused by issues like insufficient funds or a closed bank account.</p> * failure - <p class="mb-2">Transaction failed. Refer the &#x27;error_code&#x27; and &#x27;error_text&#x27; fields to know the reason for failure</p>

One ofin_progresssuccessvoidedfailuretimeoutneeds_attentionlate_failure

fraud_flagstring

Indicates whether or not the transaction has been [identified as fraudulent](https://www.chargebee.com/docs/payments/2.0/fraud-management/chargebee-fraud-management). \* suspicious - The transaction has been identified as potentially fraudulent by the gateway \* safe - The transaction has been marked as safe \* fraudulent - The transaction has been marked as fraudulent

One ofsafesuspiciousfraudulent

initiator_typestring

Marker for on-session payments (3DS). null indicates 'merchant'. \* merchant - Payment initiated on stored payment method by the merchant \* customer - Customer initiated 3DS payment

One ofcustomermerchant

three_d_secureboolean

Indicates whether this transaction has gone through 3DS. Applicable only for 'on-session' payments \& verifications.If 3DS is not enforced by the gateway/bank or if the customers' card is not enrolled, this will be false.

authorization_reasonstring

<p class="mb-2">Type of authorization transaction.</p> * scheduled_capture - <p class="mb-2">The transaction was authorized in advance for capture at a later time by a scheduled system job. The capture may succeed or fail, and its outcome is recorded as a linked transaction under <code><a href="">linked_payments</a></code> .</p> * verification - <p class="mb-2">The transaction has been created for payment method verification.</p> * blocking_funds - <p class="mb-2">The transaction has been created to block the funds from payment method.</p>

One ofblocking_fundsverificationscheduled_capture

error_codestring

Error code received from the payment gateway on failure.

error_textstring

Error message received from the payment gateway on failure.

voided_atinteger (unix-time)

Timestamp indicating when the payment was voided or authorization expired at gateway.

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 transaction was last updated. This attribute will be present only if the resource has been updated after 2016-09-28.

fraud_reasonstring

Short description why the transaction was marked as fraud/suspicious

custom_payment_method_idstring

Identifier of the custom payment method of this transaction.

amount_unusedinteger (int64)

<p class="mb-2">This is the part 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">amount</code> which has not been invoiced yet and is therefore added to <code><a href="/docs/api/customers/customer-object#excess_payments">excess_payments</a></code> for the customer. Applicable only for a transaction 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">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">payment</code> .</p>

masked_card_numberstring

The masked card number used for this transaction. Applicable only for 'Card' Payment Method

reference_transaction_idstring

<p class="mb-2">This is 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 offline transaction that is being refunded or reversed. Applicable only for transaction 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">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">refund</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">payment_reversal</code> .</p>

refunded_txn_idstring

<p class="mb-2">This is 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 transaction (always 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">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">payment</code> ) being refunded. Applicable only for transaction 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">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">refund</code> .</p>

reference_authorization_idstring

<p class="mb-2">This is 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 transaction (always 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">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">authorization</code> ) which authorizes the payment being captured. Applicable only for transaction 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">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">payment</code> .</p>

amount_capturableinteger (int64)

<p class="mb-2">This is the part of the authorized <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">amount</code> that is yet to be captured. The payment capture is recorded as a transaction of 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">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">payment</code>. Applicable only for a transaction 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">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">authorization</code> .</p>

reversal_transaction_idstring

Reversal transaction id. Applicable only for payment transactions.

deletedbooleanrequired

Indicates that this resource has been deleted.

iinstring

First 6 digits of the card payment method.

last4string

Last 4 digits of the card payment method.

merchant_reference_idstring

A unique id used to track this transaction across various systems you integrate with. This id is passed to the payment gateway when the transaction is initiated. Supported only for the [Exact payment gateway](https://www.chargebee.com/docs/exact-direct.html) .

business_entity_idstring

<p class="mb-2">The unique ID of the <a href="/docs/api/getting-started">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">transaction</code>. This is always the same as the business entity of the <a href="/docs/api/transactions/transaction-object#customer_id">customer</a>.</p> <span featureId="cb-mbe" isMicro="true"></span>

payment_method_detailsstring

Payment method details of the corresponding transaction

json
{
  "credit_note": null,
  "transaction": null
}

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