Auto create billing account for ports

Hello gents,
I am new in LibreNMS and currently playing with. For my purpose I would have a function or rule, which will automatically create billing account for newly created port. It should be based on a specific port setting (ie string in ifAlias etc…)

Anyway, I was trying to solve the issue by myself and have created some triggers in database - on tables ports, bills and bill_ports. If create port manually (by inserting into table ports), all triggers working as expected, billing accounts and port assignments are created. Unfortunately the trigger does not work, if ports are created from LibreNMS itself - by discovering.
It’s possible append that functionality into application?
Many thanks