Update an invoice

This route needs a token including an access to on of theses scopes bills.write, bills

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
integer
required

billId

Body Params

Editable fields depend on the bill state: validated (exported, dueDate), draft advance (advanceRate XOR atiTotal), draft work/direct (thirdId, businessId, yardId, object, defaultTaxRateId, clientOrderNumber, content). Mixing fields from different modes is rejected.

number
0 to 100

Draft advance bill only — advance rate (percentage). Exclusive with atiTotal.

number

Draft advance bill only — advance amount, tax included. Exclusive with advanceRate.

integer

Draft work/direct bill only — client id.

integer

Draft work/direct bill only — business id.

integer

Draft work/direct bill only — yard id.

string

Draft work/direct bill only — bill object.

integer

Draft work/direct bill only — default tax rate id.

string

Draft work/direct bill only — client order number.

content
array of objects

Draft work/direct bill only — replaces the full bill content and recalculates all totals. Bill lines. Allowed lineType: title, element, comment. Two title levels are allowed: a title's content can hold elements, comments and sub-titles (themselves title lines), but a sub-title's content can only hold element or comment lines, never another title (titles are nested at most two levels deep). Allowed fields per line: label, quantity, unit, netUnitPrice, taxRateId, elementId, lineType (plus content on title and sub-title lines). element lines require quantity, unit, netUnitPrice and taxRateId. When an elementId (a catalog element or structure/ouvrage) is provided, only quantity is required: unit, netUnitPrice and taxRateId are inherited from the element when omitted (any value you pass takes precedence). If the elementId is a structure (ouvrage), its composition is loaded and saved into the bill.

content
boolean

Validated bill only — accounting export flag.

date

Validated bill only — due date (cannot be earlier than the initial due date).

Responses

204

Successful response - The invoice has been updated

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json