provider GET /v1/credit_notes/preview/lines
@utdk/stripe /v1/credit_notes/preview/lines
Retrieve a credit note preview's line items
<p>When retrieving a credit note preview, you’ll get a <strong>lines</strong> property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items.</p>
amount query
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.
integer
credit_amount query
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.
integer
effective_at query
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.
integer
email_type query
Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
enum: credit_note, none
ending_before query
A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
string
expand query
Specifies which fields in the response should be expanded.
array
invoice query required
ID of the invoice.
string
limit query
A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
integer
lines query
Line items that make up the credit note. One of `amount`, `lines`, or `shipping_cost` must be provided.
array
memo query
The credit note's memo appears on the credit note PDF.
string
metadata query
Set 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. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
object
out_of_band_amount query
The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
integer
reason query
Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
enum: duplicate, fraudulent, order_change, product_unsatisfactory
refund_amount query
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.
integer
refunds query
Refunds to link to this credit note.
array
shipping_cost query
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.
object
starting_after query
A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
string

Try it

Authentication
Configure credentials for Stripe API
Gateway
The gateway proxies requests and injects credentials server-side. Configure credentials above, then enter your gateway URL.

Saved automatically to browser storage.

getcreditnotespreviewlines
GET/v1/credit_notes/preview/lines
<p>When retrieving a credit note preview, you’ll get a <strong>lines</strong> property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items.</p>

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.

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.

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.

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

A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.

Specifies which fields in the response should be expanded.

required

ID of the invoice.

A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.

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

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

Set 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. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.

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

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

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.

Refunds to link to this credit note.

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.

A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.

Enter a gateway URL above to enable sending.

Code snippet
Updates live as you fill in the form above.

TypeScript

import stripe from '@utdk/stripe';

await stripe.getcreditnotespreviewlines()