I need to extract the APK of my application when it is installed, I know there is an application called APK EXTRACTOR which performs this task, but in my case I want to extract the apk myself from delphi code.
So far I have only been able to find the APKs of pre-installed applications on the phone in the path "/system/app" and "system/priv-app" but internally I cannot find the apk of my app.

I recall a long time ago a file manager did a backup of all the applications. It puts all the APKs in a directory on the phone It was on the GOOGLE market. It might help to find out how he does it.