Allows you to update a specified sales invoices or purchase bills

POST {{baseUrl}}/Invoices/:InvoiceID?unitdp=<integer>

Request Params

KeyDatatypeRequiredDescription
unitdpstringe.g. unitdp=4 – (Unit Decimal Places) You can opt in to use four decimal places for unit amounts

Request Body

{"Invoices"=>[{"Type"=>"<string>", "Contact"=>{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, "LineItems"=>[{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, {"value"=>"<Error: Too many levels of nesting to fake this schema>"}], "Date"=>"<string>", "DueDate"=>"<string>", "LineAmountTypes"=>{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, "InvoiceNumber"=>"<string>", "Reference"=>"<string>", "BrandingThemeID"=>"<uuid>", "Url"=>"<string>", "CurrencyCode"=>"<string>", "CurrencyRate"=>"<double>", "Status"=>"<string>", "SentToContact"=>"<boolean>", "ExpectedPaymentDate"=>"<string>", "PlannedPaymentDate"=>"<string>", "InvoiceID"=>"<uuid>", "RepeatingInvoiceID"=>"<uuid>", "Attachments"=>[{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, {"value"=>"<Error: Too many levels of nesting to fake this schema>"}], "HasErrors"=>"false", "StatusAttributeString"=>"<string>", "ValidationErrors"=>[{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, {"value"=>"<Error: Too many levels of nesting to fake this schema>"}], "Warnings"=>[{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, {"value"=>"<Error: Too many levels of nesting to fake this schema>"}]}, {"Type"=>"<string>", "Contact"=>{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, "LineItems"=>[{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, {"value"=>"<Error: Too many levels of nesting to fake this schema>"}], "Date"=>"<string>", "DueDate"=>"<string>", "LineAmountTypes"=>{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, "InvoiceNumber"=>"<string>", "Reference"=>"<string>", "BrandingThemeID"=>"<uuid>", "Url"=>"<string>", "CurrencyCode"=>"<string>", "CurrencyRate"=>"<double>", "Status"=>"<string>", "SentToContact"=>"<boolean>", "ExpectedPaymentDate"=>"<string>", "PlannedPaymentDate"=>"<string>", "InvoiceID"=>"<uuid>", "RepeatingInvoiceID"=>"<uuid>", "Attachments"=>[{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, {"value"=>"<Error: Too many levels of nesting to fake this schema>"}], "HasErrors"=>"false", "StatusAttributeString"=>"<string>", "ValidationErrors"=>[{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, {"value"=>"<Error: Too many levels of nesting to fake this schema>"}], "Warnings"=>[{"value"=>"<Error: Too many levels of nesting to fake this schema>"}, {"value"=>"<Error: Too many levels of nesting to fake this schema>"}]}]}

HEADERS

KeyDatatypeRequiredDescription
xero-tenant-idstring(Required) Xero identifier for Tenant
Content-Typestring

RESPONSES

status: OK

{&quot;Id&quot;:&quot;bd83b60e-9d16-4a3b-9f59-0a2d0ccd35f2&quot;,&quot;Status&quot;:&quot;OK&quot;,&quot;ProviderName&quot;:&quot;Provider Name Example&quot;,&quot;DateTimeUTC&quot;:&quot;/Date(1552329729002)/&quot;,&quot;Invoices&quot;:[{&quot;Type&quot;:&quot;ACCREC&quot;,&quot;InvoiceID&quot;:&quot;4074292c-09b3-456d-84e7-add864c6c39b&quot;,&quot;InvoiceNumber&quot;:&quot;INV-0008&quot;,&quot;Reference&quot;:&quot;My the Force be With You&quot;,&quot;Prepayments&quot;:[],&quot;Overpayments&quot;:[],&quot;AmountDue&quot;:575.0,&quot;AmountPaid&quot;:0.0,&quot;SentToContact&quot;:false,&quot;CurrencyRate&quot;:1.0,&quot;HasErrors&quot;:false,&quot;IsDiscounted&quot;:false,&quot;Contact&quot;:{&quot;ContactID&quot;:&quot;be392c72-c121-4f83-9512-03ac71e54c20&quot;,&quot;ContactStatus&quot;:&quot;ACTIVE&quot;,&quot;Name&quot;:&quot;Luke Skywalker&quot;,&quot;EmailAddress&quot;:&quot;&quot;,&quot;BankAccountDetails&quot;:&quot;&quot;,&quot;Addresses&quot;:[{&quot;AddressType&quot;:&quot;STREET&quot;,&quot;City&quot;:&quot;&quot;,&quot;Region&quot;:&quot;&quot;,&quot;PostalCode&quot;:&quot;&quot;,&quot;Country&quot;:&quot;&quot;},{&quot;AddressType&quot;:&quot;POBOX&quot;,&quot;City&quot;:&quot;&quot;,&quot;Region&quot;:&quot;&quot;,&quot;PostalCode&quot;:&quot;&quot;,&quot;Country&quot;:&quot;&quot;}],&quot;Phones&quot;:[{&quot;PhoneType&quot;:&quot;DEFAULT&quot;,&quot;PhoneNumber&quot;:&quot;&quot;,&quot;PhoneAreaCode&quot;:&quot;&quot;,&quot;PhoneCountryCode&quot;:&quot;&quot;},{&quot;PhoneType&quot;:&quot;DDI&quot;,&quot;PhoneNumber&quot;:&quot;&quot;,&quot;PhoneAreaCode&quot;:&quot;&quot;,&quot;PhoneCountryCode&quot;:&quot;&quot;},{&quot;PhoneType&quot;:&quot;FAX&quot;,&quot;PhoneNumber&quot;:&quot;&quot;,&quot;PhoneAreaCode&quot;:&quot;&quot;,&quot;PhoneCountryCode&quot;:&quot;&quot;},{&quot;PhoneType&quot;:&quot;MOBILE&quot;,&quot;PhoneNumber&quot;:&quot;&quot;,&quot;PhoneAreaCode&quot;:&quot;&quot;,&quot;PhoneCountryCode&quot;:&quot;&quot;}],&quot;UpdatedDateUTC&quot;:&quot;/Date(1552329691573+0000)/&quot;,&quot;ContactGroups&quot;:[],&quot;IsSupplier&quot;:false,&quot;IsCustomer&quot;:true,&quot;DefaultCurrency&quot;:&quot;NZD&quot;,&quot;SalesTrackingCategories&quot;:[],&quot;PurchasesTrackingCategories&quot;:[],&quot;ContactPersons&quot;:[],&quot;HasValidationErrors&quot;:false},&quot;DateString&quot;:&quot;2019-03-11T00:00:00&quot;,&quot;Date&quot;:&quot;/Date(1552262400000+0000)/&quot;,&quot;DueDateString&quot;:&quot;2019-03-12T00:00:00&quot;,&quot;DueDate&quot;:&quot;/Date(1552348800000+0000)/&quot;,&quot;Status&quot;:&quot;SUBMITTED&quot;,&quot;LineAmountTypes&quot;:&quot;Exclusive&quot;,&quot;LineItems&quot;:[{&quot;Description&quot;:&quot;Light Saber&quot;,&quot;UnitAmount&quot;:500.0,&quot;TaxType&quot;:&quot;OUTPUT2&quot;,&quot;TaxAmount&quot;:75.0,&quot;LineAmount&quot;:500.0,&quot;AccountCode&quot;:&quot;200&quot;,&quot;Tracking&quot;:[],&quot;Quantity&quot;:1.0,&quot;LineItemID&quot;:&quot;6de1bf9f-de95-4c47-9287-37305db758c9&quot;,&quot;ValidationErrors&quot;:[]}],&quot;SubTotal&quot;:500.0,&quot;TotalTax&quot;:75.0,&quot;Total&quot;:575.0,&quot;UpdatedDateUTC&quot;:&quot;/Date(1552329728987+0000)/&quot;,&quot;CurrencyCode&quot;:&quot;NZD&quot;}]}