Launching Scan via php application

I do have a custom ERP for my company and this ERP is creating folders for clients automatically in my data folder of our NextCloud instance

Those folders do not automatically show up in the web interface.

During my research I found out about the occ scan command which works great but I need this scan to be automatic when a client is created in my ERP.

I am a bit clueless about cron which makes it that I don’t seem to understand what I need to do with the cron.php file.

Thanks in advance for your help.