Invoice

experimental

Invoices with gapless atomic numbering, per-line tax, an enforced draft->open->paid->void lifecycle, idempotent payment application, and dunning hooks.

Invoice is source-visible, contract-first code — your agent reads the whole interface before it composes, never a black box.

Every hook has typed I/O and required tests, and the composition is pinned in microservices.lock.json — what you inspect here is exactly what pnpm microservices check verifies and deploys.

Typed hooks

Extension points with typed input/output and required tests — customize behavior without forking the module.

  • beforeInvoiceIssue
  • onInvoiceIssued
  • onInvoicePaid

Events emitted

A stable, documented event surface other modules can subscribe to.

  • invoice.created
  • invoice.issued
  • invoice.paid
  • invoice.voided
  • invoice.overdue

Permissions

Scoped capabilities the module declares; the gateway enforces them at the boundary.

  • invoice.read
  • invoice.write
  • invoice.admin

Experimental listing. Generated from the canonical module manifest via `registry build`.