Zum Inhalt springen
Leadtime
Deutsch
Esc
navigateopen⌘Jpreview

Mark invoice as paid

Marks an invoice as paid, indicating that payment has been received from the customer. This changes the invoice status from “New” or “Sent” to “Paid” and records the payment date and runtime.

What happens when you mark an invoice as paid:

  1. Invoice status changes to “Paid”
  2. Payment date (paidAt) is recorded as the current date
  3. Payment runtime (paidRuntime) is calculated as the number of days between invoice creation and payment
  4. Status change timestamp and user are recorded
  5. The invoice moves from the “New” or “Overdue” tab to the “Paid” tab

Important restrictions:

  • Only invoices with status “New” or “Sent” can be marked as paid
  • Invoices that are already “Paid” or “Cancelled” cannot be marked as paid
  • To revert a paid invoice, use the mark as unpaid endpoint

Use cases:

  • Record payment received from customer
  • Update invoice status after manual payment confirmation
  • Track payment timing for financial reporting

What is returned:

  • Success response confirming the invoice was marked as paid
POST/billing/invoices/{id}/mark-as-paid
Authorization
AuthorizationOAuth2 access token · headerrequired
Scopes:api:write
or
AuthorizationBearer token (JWT) · headerrequired
Path parameters
idstring<uuid>required
Invoice ID (UUID)
Responses
200Invoice marked as paid successfully
successbooleanrequired
Operation success flag
400Invoice cannot be marked as paid (only invoices with status "New" or "Sent" can be marked as paid)
401Unauthorized - Invalid or missing authentication token
403Forbidden - Insufficient API scopes or permissions
404Invoice not found
Request
curl -X POST "https://leadtime.app/api/public/billing/invoices/%3Cuuid%3E/mark-as-paid" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
Response
{
  "success": true
}