List all invoice items 

Returns a list of your invoice items. Invoice items are returned sorted by creation date, with the most recently created invoice items appearing first.

Parameters

  • customerstring

    The identifier of the customer whose invoice items to return. If none is provided, returns all invoice items.

  • customer_accountstring

    The identifier of the account representing the customer whose invoice items to return. If none is provided, returns all invoice items.

More parameters

  • createdobject

  • ending_beforestring

  • invoicestring

  • limitinteger

  • pendingboolean

  • starting_afterstring

Returns

A dictionary with a data property that contains an array of up to limit invoice items, starting after invoice item starting_after. Each entry in the array is a separate invoice item object. If no more invoice items are available, the resulting array will be empty.

GET /v1/invoiceitems
curl -G https://api.stripe.com/v1/invoiceitems \
-u "sk_test_Gx4mWEg...4DYMUIqfIrszsk_test_Gx4mWEgHtCMr4DYMUIqfIrsz:" \
-d limit=3
Response
{
"object": "list",
"url": "/v1/invoiceitems",
"has_more": false,
"data": [
{
"id": "ii_1MtGUtLkdIwHu7ixBYwjAM00",
"object": "invoiceitem",
"amount": 1099,
"currency": "usd",
"customer": "cus_NeZei8imSbMVvi",
"date": 1680640231,
"description": "T-shirt",
"discountable": true,
"discounts": [],
"invoice": null,
"livemode": false,
"metadata": {},
"parent": null,
"period": {
"end": 1680640231,
"start": 1680640231
},
"pricing": {
"price_details": {
"price": "price_1MtGUsLkdIwHu7ix1be5Ljaj",
"product": "prod_NeZe7xbBdJT8EN"
},
"type": "price_details",
"unit_amount_decimal": "1099"
},
"proration": false,
"quantity": 1,
"tax_rates": [],
"test_clock": null
}
]
}

Delete an invoice item 

Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they’re not attached to invoices, or if it’s attached to a draft invoice.

Parameters

No parameters.

Returns

An object with the deleted invoice item’s ID and a deleted flag upon success. Otherwise, this call raises an error, such as if the invoice item has already been deleted.

DELETE /v1/invoiceitems/:id
curl -X DELETE https://api.stripe.com/v1/invoiceitems/ii_1MtGUtLkdIwHu7ixBYwjAM00 \
-u "sk_test_Gx4mWEg...4DYMUIqfIrszsk_test_Gx4mWEgHtCMr4DYMUIqfIrsz:"
Response
{
"id": "ii_1MtGUtLkdIwHu7ixBYwjAM00",
"object": "invoiceitem",
"deleted": true
}