Allows you to retrieve any sales invoices or purchase bills
GET {{baseUrl}}/Invoices?where=<string>&order=<string>&IDs=<uuid>,<uuid>&InvoiceNumbers=<string>,<string>&ContactIDs=<uuid>,<uuid>&Statuses=<string>,<string>&page=<integer>&includeArchived=<boolean>&createdByMyApp=<boolean>&unitdp=<integer>
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
where | string | Filter by an any element | |
order | string | Order by an any element | |
IDs | string | Filter by a comma-separated list of InvoicesIDs. | |
InvoiceNumbers | string | Filter by a comma-separated list of InvoiceNumbers. | |
ContactIDs | string | Filter by a comma-separated list of ContactIDs. | |
Statuses | string | Filter by a comma-separated list Statuses. For faster response times we recommend using these explicit parameters instead of passing OR conditions into the Where filter. | |
page | string | e.g. page=1 – Up to 100 invoices will be returned in a single API call with line items shown for each invoice | |
includeArchived | string | e.g. includeArchived=true - Contacts with a status of ARCHIVED will be included in the response | |
createdByMyApp | string | When set to true you'll only retrieve Invoices created by your app | |
unitdp | string | e.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts |
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
If-Modified-Since | string | Only records created or modified since this timestamp will be returned | |
xero-tenant-id | string | (Required) Xero identifier for Tenant |
RESPONSES
status: OK
{"Id":"900c500b-e83c-4ce2-902a-b8ba04751748","Status":"OK","ProviderName":"Provider Name Example","DateTimeUTC":"/Date(1552326816230)/","Invoices":[{"Type":"ACCREC","InvoiceID":"d4956132-ed94-4dd7-9eaa-aa22dfdf06f2","InvoiceNumber":"INV-0001","Reference":"Red Fish, Blue Fish","Payments":[],"CreditNotes":[],"Prepayments":[],"Overpayments":[],"AmountDue":0.0,"AmountPaid":0.0,"AmountCredited":0.0,"SentToContact":true,"CurrencyRate":1.0,"HasErrors":false,"IsDiscounted":false,"HasAttachments":false,"RepeatingInvoiceID":"428c0d75-909f-4b04-8403-a48dc27283b0","Contact":{"ContactID":"a3675fc4-f8dd-4f03-ba5b-f1870566bcd7","Name":"Barney Rubble-83203","Addresses":[],"Phones":[],"ContactGroups":[],"ContactPersons":[],"HasValidationErrors":false},"DateString":"2018-10-20T00:00:00","Date":"/Date(1539993600000+0000)/","DueDateString":"2018-12-30T00:00:00","DueDate":"/Date(1546128000000+0000)/","Status":"VOIDED","LineAmountTypes":"Exclusive","LineItems":[],"SubTotal":40.0,"TotalTax":0.0,"Total":40.0,"UpdatedDateUTC":"/Date(1541176290160+0000)/","CurrencyCode":"NZD"},{"Type":"ACCREC","InvoiceID":"046d8a6d-1ae1-4b4d-9340-5601bdf41b87","InvoiceNumber":"INV-0002","Reference":"Red Fish, Blue Fish","Payments":[{"PaymentID":"99ea7f6b-c513-4066-bc27-b7c65dcd76c2","Date":"/Date(1543449600000+0000)/","Amount":46.0,"CurrencyRate":1.0,"HasAccount":false,"HasValidationErrors":false}],"CreditNotes":[],"Prepayments":[],"Overpayments":[],"AmountDue":0.0,"AmountPaid":46.0,"AmountCredited":0.0,"SentToContact":true,"CurrencyRate":1.0,"HasErrors":false,"IsDiscounted":false,"HasAttachments":false,"Contact":{"ContactID":"a3675fc4-f8dd-4f03-ba5b-f1870566bcd7","Name":"Barney Rubble-83203","Addresses":[],"Phones":[],"ContactGroups":[],"ContactPersons":[],"HasValidationErrors":false},"DateString":"2018-10-20T00:00:00","Date":"/Date(1539993600000+0000)/","DueDateString":"2018-12-30T00:00:00","DueDate":"/Date(1546128000000+0000)/","Status":"PAID","LineAmountTypes":"Exclusive","LineItems":[],"SubTotal":40.0,"TotalTax":6.0,"Total":46.0,"UpdatedDateUTC":"/Date(1541176592690+0000)/","CurrencyCode":"NZD","FullyPaidOnDate":"/Date(1543449600000+0000)/"},{"Type":"ACCREC","InvoiceID":"7ef31b20-de17-4312-8382-412f869b1510","InvoiceNumber":"INV-0003","Reference":"","Payments":[],"CreditNotes":[],"Prepayments":[],"Overpayments":[],"AmountDue":115.0,"AmountPaid":0.0,"AmountCredited":0.0,"CurrencyRate":1.0,"HasErrors":false,"IsDiscounted":false,"HasAttachments":false,"Contact":{"ContactID":"a3675fc4-f8dd-4f03-ba5b-f1870566bcd7","Name":"Barney Rubble-83203","Addresses":[],"Phones":[],"ContactGroups":[],"ContactPersons":[],"HasValidationErrors":false},"DateString":"2018-11-02T00:00:00","Date":"/Date(1541116800000+0000)/","DueDateString":"2018-11-07T00:00:00","DueDate":"/Date(1541548800000+0000)/","Status":"AUTHORISED","LineAmountTypes":"Exclusive","LineItems":[],"SubTotal":100.0,"TotalTax":15.0,"Total":115.0,"UpdatedDateUTC":"/Date(1541176648927+0000)/","CurrencyCode":"NZD"}]}