Skip to content

Stripe: Credit notes schemas

7 Stripe schemas with complete fields and constraints.

← Credit notes operations · All schemas

Create a credit note — request body — body lines item

FieldTypePresenceDescription and constraints
$objectRoot
amountintegerOptional
descriptionstringOptionalMaximum length: 5000
invoice_line_itemstringOptionalMaximum length: 5000
metadataobjectOptionalAdditional keys: see wildcard field
metadata.*stringAdditional keys
quantityintegerOptional
tax_amountsJSONOptional
tax_amounts (anyOf 1)arrayAlternative
tax_amounts (anyOf 1)[]objectEach item
tax_amounts (anyOf 1)[].amountintegerRequired within parent
tax_amounts (anyOf 1)[].tax_ratestringRequired within parentMaximum length: 5000
tax_amounts (anyOf 1)[].taxable_amountintegerRequired within parent
tax_amounts (anyOf 2)stringAlternativeOne of:
tax_ratesJSONOptional
tax_rates (anyOf 1)arrayAlternative
tax_rates (anyOf 1)[]stringEach itemMaximum length: 5000
tax_rates (anyOf 2)stringAlternativeOne of:
typestringRequired within parentOne of: custom_line_item, invoice_line_item
unit_amountintegerOptional
unit_amount_decimalstringOptionalFormat: decimal

Retrieve a credit note's line items — response body — data item

FieldTypePresenceDescription and constraints
$objectRootThe credit note line item object
amountJSONRequired within parent
amount (anyOf 1)integerAlternativeThe integer amount in cents (or local equivalent) representing the gross amount being credited for this line item, excluding (exclusive) tax and discounts.
amount (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
descriptionJSONOptional
description (anyOf 1)stringAlternativeDescription of the item being credited.
Maximum length: 5000
description (anyOf 2)nullAlternative
discount_amountJSONRequired within parent
discount_amount (anyOf 1)integerAlternativeThe integer amount in cents (or local equivalent) representing the discount being credited for this line item.
discount_amount (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
discount_amountsarrayRequired within parentThe amount of discount calculated per discount for this line item
discount_amounts[]ModelEach itemExpand Void a credit note — response body — discount amounts item
idstringRequired within parentUnique identifier for the object.
Maximum length: 5000
invoice_line_itemstringOptionalID of the invoice line item being credited
Maximum length: 5000
livemodebooleanRequired within parentIf the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`.
metadataJSONOptional
metadata (anyOf 1)objectAlternativeSet of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
Additional keys: see wildcard field
metadata (anyOf 1).*stringAdditional keysMaximum length: 500
metadata (anyOf 2)nullAlternative
objectstringRequired within parentString representing the object's type. Objects of the same type share the same value.
Known values: credit_note_line_item
pretax_credit_amountsarrayRequired within parentThe pretax credit amounts (ex: discount, credit grants, etc) for this line item.
pretax_credit_amounts[]ModelEach itemExpand Void a credit note — response body — pretax credit amounts item
quantityJSONOptional
quantity (anyOf 1)JSONAlternative
quantity (anyOf 1) (anyOf 1)integerAlternativeThe number of units of product being credited.
quantity (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
quantity (anyOf 2)nullAlternative
tax_ratesarrayRequired within parentThe tax rates which apply to the line item.
tax_rates[]ModelEach itemExpand Create a tax rate — response body
taxesJSONOptional
taxes (anyOf 1)arrayAlternativeThe tax information of the line item.
taxes (anyOf 1)[]ModelEach itemExpand Update an invoice's line item — response body — taxes The tax information of the line item item
taxes (anyOf 2)nullAlternative
typestringRequired within parentThe type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice.
Known values: custom_line_item, invoice_line_item
unit_amountJSONOptional
unit_amount (anyOf 1)JSONAlternative
unit_amount (anyOf 1) (anyOf 1)integerAlternativeThe cost of each unit of product being credited.
unit_amount (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
unit_amount (anyOf 2)nullAlternative
unit_amount_decimalJSONOptional
unit_amount_decimal (anyOf 1)stringAlternativeSame as `unit_amount`, but contains a decimal value with at most 12 decimal places.
Format: decimal
unit_amount_decimal (anyOf 2)nullAlternative

Referenced models: Update an invoice's line item — response body — taxes The tax information of the line item item, Void a credit note — response body — pretax credit amounts item, Void a credit note — response body — discount amounts item, Create a tax rate — response body

Void a credit note — response body

FieldTypePresenceDescription and constraints
$objectRootIssue a credit note to adjust an invoice's amount after the invoice is finalized.

Related guide: [Credit notes](https://docs.stripe.com/billing/invoices/credit-notes)
amountJSONRequired within parent
amount (anyOf 1)integerAlternativeThe integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax.
amount (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
amount_shippingJSONRequired within parent
amount_shipping (anyOf 1)integerAlternativeThis is the sum of all the shipping amounts.
amount_shipping (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
createdJSONRequired within parent
created (anyOf 1)integerAlternativeTime at which the object was created. Measured in seconds since the Unix epoch.
Format: unix-time
created (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
currencystringRequired within parentThree-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
Format: currency
customerJSONRequired within parentID of the customer.
customer (anyOf 1)stringAlternativeMaximum length: 5000
customer (anyOf 2)ModelAlternativeExpand Create a customer — response body
customer (anyOf 3)ModelAlternativeExpand Delete a customer — response body
customer_accountJSONOptional
customer_account (anyOf 1)stringAlternativeID of the account representing the customer.
Maximum length: 5000
customer_account (anyOf 2)nullAlternative
customer_balance_transactionJSONOptional
customer_balance_transaction (anyOf 1)JSONAlternativeCustomer balance transaction related to this credit note.
customer_balance_transaction (anyOf 1) (anyOf 1)stringAlternativeMaximum length: 5000
customer_balance_transaction (anyOf 1) (anyOf 2)ModelAlternativeExpand Create a customer balance transaction — response body
customer_balance_transaction (anyOf 2)nullAlternative
discount_amountJSONRequired within parent
discount_amount (anyOf 1)integerAlternativeThe integer amount in cents (or local equivalent) representing the total amount of discount that was credited.
discount_amount (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
discount_amountsarrayRequired within parentThe aggregate amounts calculated per discount for all line items.
discount_amounts[]ModelEach itemExpand Void a credit note — response body — discount amounts item
effective_atJSONOptional
effective_at (anyOf 1)JSONAlternative
effective_at (anyOf 1) (anyOf 1)integerAlternativeThe 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.
Format: unix-time
effective_at (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
effective_at (anyOf 2)nullAlternative
idstringRequired within parentUnique identifier for the object.
Maximum length: 5000
invoiceJSONRequired within parentID of the invoice.
invoice (anyOf 1)stringAlternativeMaximum length: 5000
invoice (anyOf 2)ModelAlternativeExpand Pay an invoice — response body
linesobjectRequired within parentLine items that make up the credit note
lines.dataarrayRequired within parentDetails about each object.
lines.data[]ModelEach itemExpand Retrieve a credit note's line items — response body — data item
lines.has_morebooleanRequired within parentTrue if this list has another page of items after this one that can be fetched.
lines.objectstringRequired within parentString representing the object's type. Objects of the same type share the same value. Always has the value `list`.
Known values: list
lines.urlstringRequired within parentThe URL where this list can be accessed.
Maximum length: 5000
livemodebooleanRequired within parentIf the object exists in live mode, the value is `true`. If the object exists in test mode, the value is `false`.
memoJSONOptional
memo (anyOf 1)stringAlternativeCustomer-facing text that appears on the credit note PDF.
Maximum length: 5000
memo (anyOf 2)nullAlternative
metadataJSONOptional
metadata (anyOf 1)objectAlternativeSet of [key-value pairs](https://docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
Additional keys: see wildcard field
metadata (anyOf 1).*stringAdditional keysMaximum length: 500
metadata (anyOf 2)nullAlternative
numberstringRequired within parentA unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice.
Maximum length: 5000
objectstringRequired within parentString representing the object's type. Objects of the same type share the same value.
Known values: credit_note
out_of_band_amountJSONOptional
out_of_band_amount (anyOf 1)JSONAlternative
out_of_band_amount (anyOf 1) (anyOf 1)integerAlternativeAmount that was credited outside of Stripe.
out_of_band_amount (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
out_of_band_amount (anyOf 2)nullAlternative
pdfstringRequired within parentThe link to download the PDF of the credit note.
Maximum length: 5000
post_payment_amountJSONRequired within parent
post_payment_amount (anyOf 1)integerAlternativeThe 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.
post_payment_amount (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
pre_payment_amountJSONRequired within parent
pre_payment_amount (anyOf 1)integerAlternativeThe amount of the credit note by which the invoice's `amount_remaining` and `amount_due` were reduced.
pre_payment_amount (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
pretax_credit_amountsarrayRequired within parentThe pretax credit amounts (ex: discount, credit grants, etc) for all line items.
pretax_credit_amounts[]ModelEach itemExpand Void a credit note — response body — pretax credit amounts item
reasonJSONOptional
reason (anyOf 1)stringAlternativeReason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
Known values: duplicate, fraudulent, order_change, product_unsatisfactory
reason (anyOf 2)nullAlternative
refundsarrayRequired within parentRefunds related to this credit note.
refunds[]ModelEach itemExpand Void a credit note — response body — refunds item
shipping_costJSONOptional
shipping_cost (anyOf 1)JSONAlternativeThe details of the cost of shipping, including the ShippingRate applied to the invoice.
shipping_cost (anyOf 1) (anyOf 1)ModelAlternativeExpand Pay an invoice — response body — shipping cost value amount subtotal, amount tax, amount total, shipping rate, taxes
shipping_cost (anyOf 2)nullAlternative
statusstringRequired within parentStatus of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://docs.stripe.com/billing/invoices/credit-notes#voiding).
Known values: issued, void
subtotalJSONRequired within parent
subtotal (anyOf 1)integerAlternativeThe integer amount in cents (or local equivalent) representing the amount of the credit note, excluding exclusive tax and invoice level discounts.
subtotal (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
subtotal_excluding_taxJSONOptional
subtotal_excluding_tax (anyOf 1)JSONAlternative
subtotal_excluding_tax (anyOf 1) (anyOf 1)integerAlternativeThe integer amount in cents (or local equivalent) representing the amount of the credit note, excluding all tax and invoice level discounts.
subtotal_excluding_tax (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
subtotal_excluding_tax (anyOf 2)nullAlternative
totalJSONRequired within parent
total (anyOf 1)integerAlternativeThe integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax and all discount.
total (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
total_excluding_taxJSONOptional
total_excluding_tax (anyOf 1)JSONAlternative
total_excluding_tax (anyOf 1) (anyOf 1)integerAlternativeThe integer amount in cents (or local equivalent) representing the total amount of the credit note, excluding tax, but including discounts.
total_excluding_tax (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
total_excluding_tax (anyOf 2)nullAlternative
total_taxesJSONOptional
total_taxes (anyOf 1)arrayAlternativeThe aggregate tax information for all line items.
total_taxes (anyOf 1)[]ModelEach itemExpand Update an invoice's line item — response body — taxes The tax information of the line item item
total_taxes (anyOf 2)nullAlternative
typestringRequired within parentType 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.
Known values: mixed, post_payment, pre_payment
voided_atJSONOptional
voided_at (anyOf 1)JSONAlternative
voided_at (anyOf 1) (anyOf 1)integerAlternativeThe time that the credit note was voided.
Format: unix-time
voided_at (anyOf 1) (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
voided_at (anyOf 2)nullAlternative

Referenced models: Update an invoice's line item — response body — taxes The tax information of the line item item, Retrieve a credit note's line items — response body — data item, Void a credit note — response body — refunds item, Void a credit note — response body — pretax credit amounts item, Create a customer — response body, Create a customer balance transaction — response body, Delete a customer — response body, Void a credit note — response body — discount amounts item, Pay an invoice — response body, Pay an invoice — response body — shipping cost value amount subtotal, amount tax, amount total, shipping rate, taxes

Void a credit note — response body — discount amounts item

FieldTypePresenceDescription and constraints
$objectRoot
amountJSONRequired within parent
amount (anyOf 1)integerAlternativeThe amount, in cents (or local equivalent), of the discount.
amount (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
discountJSONRequired within parentThe discount that was applied to get this discount amount.
discount (anyOf 1)stringAlternativeMaximum length: 5000
discount (anyOf 2)ModelAlternativeExpand Get Customers Customer Discount — response body
discount (anyOf 3)ModelAlternativeExpand Delete a subscription discount — response body

Referenced models: Delete a subscription discount — response body, Get Customers Customer Discount — response body

Void a credit note — response body — pretax credit amounts item

FieldTypePresenceDescription and constraints
$objectRoot
amountJSONRequired within parent
amount (anyOf 1)integerAlternativeThe amount, in cents (or local equivalent), of the pretax credit amount.
amount (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
credit_balance_transactionJSONOptionalThe credit balance transaction that was applied to get this pretax credit amount.
credit_balance_transaction (anyOf 1)stringAlternativeMaximum length: 5000
credit_balance_transaction (anyOf 2)ModelAlternativeExpand Retrieve a credit balance transaction — response body
discountJSONOptionalThe discount that was applied to get this pretax credit amount.
discount (anyOf 1)stringAlternativeMaximum length: 5000
discount (anyOf 2)ModelAlternativeExpand Get Customers Customer Discount — response body
discount (anyOf 3)ModelAlternativeExpand Delete a subscription discount — response body
typestringRequired within parentType of the pretax credit amount referenced.
Known values: credit_balance_transaction, discount

Referenced models: Retrieve a credit balance transaction — response body, Delete a subscription discount — response body, Get Customers Customer Discount — response body

Void a credit note — response body — refunds item

FieldTypePresenceDescription and constraints
$objectRoot
amount_refundedJSONRequired within parent
amount_refunded (anyOf 1)integerAlternativeAmount of the refund that applies to this credit note, in cents (or local equivalent).
amount_refunded (anyOf 2)stringAlternativePattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
payment_record_refundJSONOptional
payment_record_refund (anyOf 1)JSONAlternativeThe PaymentRecord refund details associated with this credit note refund.
payment_record_refund (anyOf 1) (anyOf 1)ModelAlternativeExpand Void a credit note — response body — refunds item payment record refund value payment record, refund group
payment_record_refund (anyOf 2)nullAlternative
refundJSONRequired within parentID of the refund.
refund (anyOf 1)stringAlternativeMaximum length: 5000
refund (anyOf 2)ModelAlternativeExpand Cancel a refund — response body
typeJSONOptional
type (anyOf 1)stringAlternativeType of the refund, one of `refund` or `payment_record_refund`.
Known values: payment_record_refund, refund
type (anyOf 2)nullAlternative

Referenced models: Void a credit note — response body — refunds item payment record refund value payment record, refund group, Cancel a refund — response body

Void a credit note — response body — refunds item payment record refund value payment record, refund group

FieldTypePresenceDescription and constraints
$objectRoot
payment_recordstringRequired within parentID of the payment record.
Maximum length: 5000
refund_groupstringRequired within parentID of the refund group.
Maximum length: 5000

Report an issue with this page

Necessary

Required for sign-in, security, authorization, and remembering your choices.

Always active

Analytics

Helps us understand which product and documentation features are useful.

Performance diagnostics

Uses performance tracing and privacy-masked session replay to diagnose problems.

You can change these choices at any time from Cookie settings.