Posted Customer Invoices Realtime-enabled
GETTable: EONE Posted Ledger Doc
Read-only posted customer invoices as they hit the customer ledger, a webhook source: subscribe to be pushed the "invoice posted" event. Captures both documents posted through a sales/purchase document and through the journal-wrapper endpoint.
The "posted" event
You are pushed one notification on postedCustomerInvoices when a invoice is posted. integrationId carries the originating invoice/order key; amount, remainingAmount and status reflect the invoice at posting time.
For live settlement, how much has been paid and whether it is closed, watch the postedCustomerPayments feed, whose applications report each invoice's resulting balance. This feed is the "created" event; the payment feed is settlement truth.
Subscribing
Register a subscription against the entity set; Business Central notifies your endpoint when a row changes. The notification carries the record id. GET it to read the current values.
POST /subscriptions
{
"resource": "/postedCustomerInvoices",
"notificationUrl": "https://your-endpoint",
"clientState": "<secret>"
}Status
status is the human-readable settlement state (Open, Partially Settled, or Settled) computed from the ledger entry, so you write status back without interpreting raw open/remaining-amount semantics. remainingAmount and settledAmount carry the figures behind it.
Retention
The projection is a short-lived event feed, not a store: rows are purged by the background job once their posting date is older than the configured retention window, 7 days by default (options 7, 14, 28 on the setup page, or via the integrationSetup API). The backfill only seeds documents within that window, and a purge sends subscribers a delete notification. Consume and reconcile within the window.