DocsAPI ReferenceInvoice/bff/invoice/lock-snapshot
postInvoiceAdmin BFF

/bff/invoice/lock-snapshot

Freezes the supplier, customer and bank account details into JSONB columns on the invoice. Once locked, downstream renderers (PDF, detail, exports) prefer the snapshot over live data, so the invoice stays unchanged even if the contact or bank account is later edited. Idempotent unless force: true is passed.

InvoicepostBffInvoiceLock-snapshot

Parameters

2 body

2 total
Body · 2
idstringRequired

External invoice ID.

forceboolean

Re-snapshot even if the invoice is already locked. Use only when an admin explicitly accepts overwriting historical data — guard the UI with a confirm dialog.

Default: false

Request

POST /bff/invoice/lock-snapshot

post
curl -X POST "https://api.bizkithub.com/bff/invoice/lock-snapshot" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
  "id": "aB3xKm9pQ2wLn4Yz",
  "force": false
}'

Response

JSON payload

{
  "alreadySnapshotted": false,
  "snapshottedAt": "example_snapshottedAt"
}

All response codes

1 status code documented

Need an API key?

All BizKitHub API endpoints require authentication via API key.

Get API Key