# credit\_note

From **Stripe API**.

Issue a credit note to adjust an invoice's amount after the invoice is finalized.

Related guide: [Credit Notes](https://stripe.com/docs/billing/invoices/credit-notes).

- Type: `object`

## Properties

### `amount`

- Required: true
- Type: `integer`

The integer amount in %s representing the total amount of the credit note, including tax.

### `created`

- Required: true
- Type: `integer`
- Format: `unix-time`

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

### `currency`

- Required: true
- Type: `string`

Three-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).

### `customer`

- Required: true
ID of the customer.

### `customer_balance_transaction`

- Required: false
- Nullable: true

Customer balance transaction related to this credit note.

### `discount_amount`

- Required: true
- Type: `integer`

The integer amount in %s representing the total amount of discount that was credited.

### `discount_amounts`

- Required: true
- Type: `array`

The aggregate amounts calculated per discount for all line items.

### `id`

- Required: true
- Type: `string`
- maxLength: `5000`

Unique identifier for the object.

### `invoice`

- Required: true
ID of the invoice.

### `lines`

- Required: true
- Type: `object`

Line items that make up the credit note

### `livemode`

- Required: true
- Type: `boolean`

Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.

### `memo`

- Required: false
- Type: `string`
- Nullable: true
- maxLength: `5000`

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

### `metadata`

- Required: false
- Type: `object`
- Nullable: true

Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.

### `number`

- Required: true
- Type: `string`
- maxLength: `5000`

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

### `object`

- Required: true
- Type: `string`
- Allowed values: `"credit_note"`

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

### `out_of_band_amount`

- Required: false
- Type: `integer`
- Nullable: true

Amount that was credited outside of Stripe.

### `pdf`

- Required: true
- Type: `string`
- maxLength: `5000`

The link to download the PDF of the credit note.

### `reason`

- Required: false
- Type: `string`
- Nullable: true
- Allowed values: `"duplicate"`, `"fraudulent"`, `"order_change"`, `"product_unsatisfactory"`

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

### `refund`

- Required: false
- Nullable: true

Refund related to this credit note.

### `status`

- Required: true
- Type: `string`
- Allowed values: `"issued"`, `"void"`

Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding).

### `subtotal`

- Required: true
- Type: `integer`

The integer amount in %s representing the amount of the credit note, excluding tax and invoice level discounts.

### `tax_amounts`

- Required: true
- Type: `array`

The aggregate amounts calculated per tax rate for all line items.

### `total`

- Required: true
- Type: `integer`

The integer amount in %s representing the total amount of the credit note, including tax and all discount.

### `type`

- Required: true
- Type: `string`
- Allowed values: `"post_payment"`, `"pre_payment"`

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_at`

- Required: false
- Type: `integer`
- Format: `unix-time`
- Nullable: true

The time that the credit note was voided.

## JSON Schema

```json
{"description":"Issue a credit note to adjust an invoice's amount after the invoice is finalized.\n\nRelated guide: [Credit Notes](https://stripe.com/docs/billing/invoices/credit-notes).","properties":{"amount":{"description":"The integer amount in %s representing the total amount of the credit note, including tax.","type":"integer"},"created":{"description":"Time at which the object was created. Measured in seconds since the Unix epoch.","format":"unix-time","type":"integer"},"currency":{"description":"Three-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).","type":"string"},"customer":{"anyOf":[{"maxLength":5000,"type":"string"},{"$ref":"#/components/schemas/customer"},{"$ref":"#/components/schemas/deleted_customer"}],"description":"ID of the customer.","x-expansionResources":{"oneOf":[{"$ref":"#/components/schemas/customer"},{"$ref":"#/components/schemas/deleted_customer"}]}},"customer_balance_transaction":{"anyOf":[{"maxLength":5000,"type":"string"},{"$ref":"#/components/schemas/customer_balance_transaction"}],"description":"Customer balance transaction related to this credit note.","nullable":true,"x-expansionResources":{"oneOf":[{"$ref":"#/components/schemas/customer_balance_transaction"}]}},"discount_amount":{"description":"The integer amount in %s representing the total amount of discount that was credited.","type":"integer"},"discount_amounts":{"description":"The aggregate amounts calculated per discount for all line items.","items":{"$ref":"#/components/schemas/discounts_resource_discount_amount"},"type":"array"},"id":{"description":"Unique identifier for the object.","maxLength":5000,"type":"string"},"invoice":{"anyOf":[{"maxLength":5000,"type":"string"},{"$ref":"#/components/schemas/invoice"}],"description":"ID of the invoice.","x-expansionResources":{"oneOf":[{"$ref":"#/components/schemas/invoice"}]}},"lines":{"description":"Line items that make up the credit note","properties":{"data":{"description":"Details about each object.","items":{"$ref":"#/components/schemas/credit_note_line_item"},"type":"array"},"has_more":{"description":"True if this list has another page of items after this one that can be fetched.","type":"boolean"},"object":{"description":"String representing the object's type. Objects of the same type share the same value. Always has the value `list`.","enum":["list"],"type":"string"},"url":{"description":"The URL where this list can be accessed.","maxLength":5000,"type":"string"}},"required":["data","has_more","object","url"],"title":"CreditNoteLinesList","type":"object","x-expandableFields":["data"]},"livemode":{"description":"Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.","type":"boolean"},"memo":{"description":"Customer-facing text that appears on the credit note PDF.","maxLength":5000,"nullable":true,"type":"string"},"metadata":{"additionalProperties":{"maxLength":500,"type":"string"},"description":"Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.","nullable":true,"type":"object"},"number":{"description":"A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice.","maxLength":5000,"type":"string"},"object":{"description":"String representing the object's type. Objects of the same type share the same value.","enum":["credit_note"],"type":"string"},"out_of_band_amount":{"description":"Amount that was credited outside of Stripe.","nullable":true,"type":"integer"},"pdf":{"description":"The link to download the PDF of the credit note.","maxLength":5000,"type":"string"},"reason":{"description":"Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`","enum":["duplicate","fraudulent","order_change","product_unsatisfactory"],"nullable":true,"type":"string"},"refund":{"anyOf":[{"maxLength":5000,"type":"string"},{"$ref":"#/components/schemas/refund"}],"description":"Refund related to this credit note.","nullable":true,"x-expansionResources":{"oneOf":[{"$ref":"#/components/schemas/refund"}]}},"status":{"description":"Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding).","enum":["issued","void"],"type":"string"},"subtotal":{"description":"The integer amount in %s representing the amount of the credit note, excluding tax and invoice level discounts.","type":"integer"},"tax_amounts":{"description":"The aggregate amounts calculated per tax rate for all line items.","items":{"$ref":"#/components/schemas/credit_note_tax_amount"},"type":"array"},"total":{"description":"The integer amount in %s representing the total amount of the credit note, including tax and all discount.","type":"integer"},"type":{"description":"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.","enum":["post_payment","pre_payment"],"type":"string"},"voided_at":{"description":"The time that the credit note was voided.","format":"unix-time","nullable":true,"type":"integer"}},"required":["amount","created","currency","customer","discount_amount","discount_amounts","id","invoice","lines","livemode","number","object","pdf","status","subtotal","tax_amounts","total","type"],"title":"CreditNote","type":"object","x-expandableFields":["customer","customer_balance_transaction","discount_amounts","invoice","lines","refund","tax_amounts"],"x-resourceId":"credit_note"}
```
