Overview

Upload a PDF invoice document separately from debt creation. GetBill maps the document to one existing debt using one of these identifiers:
  • debt_id: stable encrypted debt ID from the Debts API
  • invoice_reference: invoice reference stored on the debt
  • internal_id: your internal debt ID
Use debt_id when possible. invoice_reference and internal_id are useful when your billing system exports documents separately from the debt creation flow.

Authentication

Requires a valid OAuth 2.0 access token with the invoice_documents:write scope. The legacy debts:write scope is also accepted during the transition.

Example Request

curl

Success Response

Errors

  • 400 - Missing file, invalid upload, non-PDF file, or file too large
  • 403 - Missing scope or invoice documents feature is not enabled
  • 404 - No matching accessible debt was found
  • 409 - The debt already has an invoice document and replace_manual was not set