Retrieve an invoice's line items
GET / v1 / invoices /:id / lines
When retrieving an invoice, you’ll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
Parameters
No parameters.
More parameters
- ending _ before string
- limit integer
- starting _ after string
Returns
Returns a list of line_item objects.
Response
Bulk add invoice line items
POST / v1 / invoices /:id / add_lines
Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
Parameters
- lines array of objects Required The line items to add.
- invoice _ metadata map 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.
Returns
The updated invoice with newly added line items is returned upon success. Otherwise, this call raises an error.
Response
Bulk remove invoice line items
POST / v1 / invoices /:id / remove_lines
Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
Parameters
- lines array of objects Required The line items to remove.
- invoice _ metadata map 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.
Returns
The updated invoice without the removed line items is returned upon success. Otherwise, this call raises an error.
Response
