Invoices

Preview invoice bundle lines

POST
/orgs/{organizationId}/invoices/preview-bundle-lines

Resolves bundle child lines for a product with metadata.invoiceBundle using the same resolver and expand rules as replaceInvoice when that invoice rebuild runs for an anchor. Pass anchorLineQuantity when bundle steps use quantityScale anchor_line_quantity so preview matches the extend-occupation / period main line. When the anchor is Extend occupation period, pass terrainId so ICY meter steps match that terrain, and invoiceBillingAnchorEndDateIso (anchor endDate) when steps use extendAccessMethod. Pass invoiceItemsForBillOnceContext and anchorItemListIndex together so steps with billOncePerInvoice behave like replaceInvoice (shared steps only under the first eligible anchor in array order). Optional existingAnchorSnapshots aligns regenerate detection with the last-loaded invoice for preview.

Authorization

ApiKeyAuth
headerx-api-key<token>

API key for authentication

Path Parameters

organizationId*string

The ID or slug of the organization

Request Body

application/json
  1. body
customerId*string
anchorProductId*string
anchorLineQuantity?number
terrainId?string
invoiceBillingAnchorEndDateIso?string|null
invoiceItemsForBillOnceContext?array<>
anchorItemListIndex?integer
Range0 <= value <= 9007199254740991
existingAnchorSnapshots?array<>

Response Body

OK

application/json
  1. response
[index: integer]?
curl -X POST 'https://api.tillor.eu/orgs/string/invoices/preview-bundle-lines' \  -H 'Content-Type: application/json' \  -d '{  "customerId": "string",  "anchorProductId": "string"}'
[  {    "description": "string",    "quantity": 0,    "taxPercentage": 0,    "amountPerUnitWithTax": 0,    "amountPerUnit": 0,    "amountSubtotal": 0,    "amountTax": 0,    "amountTotal": 0,    "productId": "string",    "style": "DEFAULT",    "actions": []  }]