Xero - Upsert line item to bill or invoice action

The Upsert line item to bill or invoice action allows you to insert or update a single line item on an existing Xero bill. If the line item ID is provided, the action updates the whole line.

Upsert line item to bill or invoice actionXero - Upsert line item to bill or invoice action

Input

Input fieldDescription
Invoice IDEnter the unique identifier of the invoice.
Line item IDProvide the identifier of the line item to update. Leave this field empty to add a new line item.
DescriptionInput a description for the line item.
Item nameSpecify the name of the item for the line item.
QuantityEnter the quantity of the item in the line item.
Unit priceSpecify the price per unit of the item.
Line amountEnter the total amount for the line item.
Discount rateProvide the discount rate, if applicable, for the line item.
Account codeInput the account code from your Xero chart of accounts for this line item.
Tax type nameSpecify the name of the tax type applied to the line item.
Tax amountEnter the amount of tax for the line item, if applicable.
Item codeProvide the item code. If both the item name and item code are provided, the item code takes precedence.

Output

Output fieldDescription
ReferenceReference information for the updated line item.
TypeThe type of document updated (bill or invoice).
Invoice IDThe unique identifier of the invoice or bill.
Invoice numberThe number of the invoice or bill.
PaymentsDetails of payments associated with the invoice.
Credit notesDetails of credit notes applied to the invoice.
Amount dueThe total amount due on the invoice or bill.
Amount paidThe total amount paid on the invoice or bill.
Amount creditedThe total amount credited to the invoice or bill.
URLThe link to the invoice or bill in Xero.
Currency codeThe currency code used for the invoice or bill.
Currency rateThe exchange rate applied to the currency.
Has errorsIndicates if there are errors related to the invoice or bill.
Is discountedIndicates if a discount has been applied to the invoice or bill.
Has attachmentsIndicates if there are attachments included with the invoice or bill.
ContactDetails of the contact associated with the invoice or bill.
DateThe date of the invoice or bill.
Due dateThe due date for payment of the invoice or bill.
StatusThe current status of the invoice or bill.
Branding theme IDThe identifier for the branding theme applied to the invoice or bill.
Line amount typesThe type of line amounts on the invoice or bill.
Line itemsDetails of each item listed on the invoice.
Sub totalThe subtotal amount of the invoice or bill before tax.
Total taxThe total tax amount for the invoice or bill.
TotalThe total amount of the invoice or bill, including tax.
Updated dateThe date when the invoice or bill details were last updated.
Paid dateThe date when the invoice or bill was fully paid, if applicable.

Last updated: