Update a draft bill
Changes a draft bill's dates, lines or vendor. Anything you leave out keeps its current value; sending lineItems replaces the whole set. Requires the work_orders:write permission.
Authorization
AuthorizationstringrequiredPath parameters
workOrderIdstringrequiredThe work order to act on. A Snowflake id, sent as a decimal string.
draftBillIdstringrequiredThe draft bill on this work order. A Snowflake id, sent as a decimal string.
Body
application/json
billDatestring · dateThe bill's date.
dueDatestring · dateWhen the bill is due.
lineItemsobject[]The complete new set of lines. Sending this replaces every existing line.
approvedbooleanWhether the draft is approved.
vendorIdstringThe vendor to be paid.
billIdstringThe real vendor bill this draft corresponds to, when linking one by hand.
Response
200 · The updated draft bill.
idstringrequiredThe draft bill. Once converted, this is the id of the real vendor bill instead.
billDatestring · daterequiredThe bill's date, in the company's timezone.
dueDatestring · dateWhen the bill is due, in the company's timezone. Absent when no date was set.
lineItemsobject[]requiredWhat is being charged.
filesobject[]requiredInvoices and receipts attached to the bill. An empty array when there are none.
addedOnstring · date-timerequiredWhen the draft bill was added, in the company's timezone and without an offset.
addedByVendorbooleanrequiredWhether the vendor added it through their own portal rather than staff adding it here.
approvedbooleanrequiredWhether the draft has been approved. Drafts created through this API are approved from the start.
vendorIdstringThe vendor to be paid. Absent while unset — it is needed before the bill can be converted.
billIdstringThe real vendor bill this draft became. Absent until it is converted.