v50

latestOpenAPI 3.0.0raw.githubusercontent.com2026-07-295891,4407.6 MB

Preview a credit note

Get a preview of a credit note without creating it.

get/v1/credit_notes/preview

Query parameters

amountinteger

The integer amount in cents (or local equivalent) representing the total amount of the credit note. One of amount, lines, or shipping_cost must be provided.

credit_amountinteger

The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.

effective_atinteger

The date when this credit note is in effect. Same as created unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.

email_type'credit_note' | 'none'

Type of email to send to the customer, one of credit_note or none and the default is credit_note.

expandstring[]

Specifies which fields in the response should be expanded.

invoicestring required

ID of the invoice.

amountinteger
descriptionstring
invoice_line_itemstring
metadataobject
quantityinteger
type'custom_line_item' | 'invoice_line_item' required
unit_amountinteger
unit_amount_decimalstring decimal

Line items that make up the credit note. One of amount, lines, or shipping_cost must be provided.

memostring

The credit note's memo appears on the credit note PDF.

metadataobject

Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata.

out_of_band_amountinteger

The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.

reason'duplicate' | 'fraudulent' | 'order_change' | 'product_unsatisfactory'

Reason for issuing this credit note, one of duplicate, fraudulent, order_change, or product_unsatisfactory

refund_amountinteger

The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.

amount_refundedinteger
refundstring
type'payment_record_refund' | 'refund'

Refunds to link to this credit note.

shipping_ratestring

When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note. One of amount, lines, or shipping_cost must be provided.

Response

Successful response.

amountinteger required

The integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax.

amount_shippinginteger required

This is the sum of all the shipping amounts.

createdinteger required

Time at which the object was created. Measured in seconds since the Unix epoch.

currencystring currency required

Three-letter ISO currency code, in lowercase. Must be a supported currency.

customer_accountstring nullable

ID of the account representing the customer.

discount_amountinteger required

The integer amount in cents (or local equivalent) representing the total amount of discount that was credited.

effective_atinteger nullable

The date when this credit note is in effect. Same as created unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.

idstring required

Unique identifier for the object.

livemodeboolean required

If the object exists in live mode, the value is true. If the object exists in test mode, the value is false.

memostring nullable

Customer-facing text that appears on the credit note PDF.

metadataobject nullable

Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.

numberstring required

A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice.

object'credit_note' required

String representing the object's type. Objects of the same type share the same value.

out_of_band_amountinteger nullable

Amount that was credited outside of Stripe.

pdfstring required

The link to download the PDF of the credit note.

post_payment_amountinteger required

The amount of the credit note that was refunded to the customer, credited to the customer's balance, credited outside of Stripe, or any combination thereof.

pre_payment_amountinteger required

The amount of the credit note by which the invoice's amount_remaining and amount_due were reduced.

reason'duplicate' | 'fraudulent' | 'order_change' | 'product_unsatisfactory' nullable

Reason for issuing this credit note, one of duplicate, fraudulent, order_change, or product_unsatisfactory

status'issued' | 'void' required

Status of this credit note, one of issued or void. Learn more about voiding credit notes.

subtotalinteger required

The integer amount in cents (or local equivalent) representing the amount of the credit note, excluding exclusive tax and invoice level discounts.

subtotal_excluding_taxinteger nullable

The integer amount in cents (or local equivalent) representing the amount of the credit note, excluding all tax and invoice level discounts.

totalinteger required

The integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax and all discount.

total_excluding_taxinteger nullable

The integer amount in cents (or local equivalent) representing the total amount of the credit note, excluding tax, but including discounts.

type'mixed' | 'post_payment' | 'pre_payment' required

Type of this credit note, one of pre_payment or post_payment. A pre_payment credit note means it was issued when the invoice was open. A post_payment credit note means it was issued when the invoice was paid.

voided_atinteger nullable

The time that the credit note was voided.