Child Invoice Detail in Hierarchical Account Invoices

13 views
Skip to first unread message

Pete Capra

unread,
Nov 26, 2025, 4:14:10 AMNov 26
to Kill Bill users mailing-list
Hi there, 

I'm currently evaluating Kill Bill and I'm using the Hierarchical Accounts (HA) feature to have one parent invoice that details all of the line items for the child accounts.  I've noticed that when the invoice is generated neither the database nor the invoice HTML has child account details like plan, product, etc, but I would like to show this in the invoice. Is this expected behaviour?

If so, is the correct way to get this detail to use a custom plugin that extends from InvoicePluginApi? And then a custom invoice template to display the data?

Thanks, 

Pete

Pete Capra

unread,
Nov 27, 2025, 6:07:07 AMNov 27
to Kill Bill users mailing-list
I really can't get this to work, here's what I've tried so far:

* Custom Plugin that adds the detail when the parent invoice is generated - it doesn't look like InvoicePluginApi.getAdditionalInvoiceItems() is called for parent account invoices only child account invoices
* Custom Plugin that adds a $0 external charge with the detail when each child invoice is created - this only adds to the child invoices, not the parent account invoice. 
* Custom Plugin that uses invoiceUserApi.insertExternalCharges() to add an external charge per child invoice when the child invoices is processed - doesn't work because it effectively creates a new draft invoice for the parent multiple times with only the single child invoice data rather than adding all to one invoice. 

I'm now thinking the best option is to remove the custom plugin altogether and move this functionality into a separate process outside of the Kill Bill ecosystem that uses the APIs to enrich the invoice html with more data. 

Am I missing anything?

karan bansal

unread,
Nov 27, 2025, 9:47:07 PMNov 27
to Kill Bill users mailing-list
Hi Pete,

The parent invoice line items have summary for each child account and the child invoice line items will have the subscription/plan details. I need to check if the plugin is called for the parent invoice, will check and get back on this. Though getting the details via the API is possible. Please check this endpoint https://killbill.github.io/slate/invoice.html#retrieve-an-invoice-by-id with 'withChildrenItems' flag set to true. 

Regards
Karan

Reply all
Reply to author
Forward
0 new messages