Prepare an invoice for the owner's approval

Gets the next invoice ready – unbilled tracked time over the period plus optional manual lines and a note – and leaves it waiting on the Invoices page, where the owner reads its PDF (marked DRAFT) and approves or discards it. Nothing is numbered, issued or billed here, and no endpoint approves: only the owner issues an invoice, in the web app. One draft per workspace; preparing again replaces it. Requires the invoices:prepare scope and a token of the workspace owner (403 for a member).

post/api/v1/invoices/draft

Request

  • Base URL: https://tallymeter.com
  • URL: https://tallymeter.com/api/v1/invoices/draft
  • Auth: HTTP bearer

Request body

fromstring date

Period start in the owner's timezone. Omit to start where the Invoices page does (the day after the last invoice's period, earlier when unbilled time was tracked into it).

tostring date required

Period end, inclusive; today at the latest.

notestring

Shown to the owner above the Approve button.

Response

The draft is waiting for approval

fromstring date
tostring date
invoice_numberstring

the number it gets if approved now

issue_datestring date

today: an invoice is issued on the day it is approved

due_datestring date
total_hoursnumber
tracked_costnumber
manual_costnumber
total_costnumber
notestring nullable
source'api' | 'mcp' | 'cli'
prepared_atstring date-time
prepared_total_hoursnumber
prepared_total_costnumber
changed_since_preparedboolean

the tracker moved since the draft was prepared (time logged, retitled or billed elsewhere); the lines above are as of now

fingerprintstring

SHA-256 of the lines and totals above

review_urlstring uri

where the owner reads the PDF and approves or discards it

Changes

No recorded changes to this operation across all 1 revision of this API.