This topic is quite lengthy and different approaches might be suitable depending on the complexity of the app dependencies.
Splunk wrote a whole article about this topic as part of the PAS reference app:
There are basically four approaches:
Creating an installer inside a Splunk app
Taking this approach, we could package all the dependencies inside the main app and include logic that installs them as and when they are required. The Splunk App for VMware plans to use this approach in the future.
A variation on this approach is to have a dedicated installer app that sets up the main app and all of its dependencies, and then redirects requests to the main app it installed. The Splunk App for Enterprise Security uses this approach.
Using an external installer
Using this approach, we could create a script that automatically installs an app and its dependencies. Alternatively, we could use a third-party installer tool to build the installation scripts.
Ask the customer to install the app and its dependencies manually from a single ZIP file
Taking this approach, we could package the main app and all the add-on apps in a single ZIP archive. We would then ask the customer to unpack the archive into the etc/apps/ folder. The Splunk App for VMware currently uses this approach.
Ask the customer to install the main app and each dependent add-on individually
Taking this approach, we would add detailed installation instructions to the documentation explaining how the customer should obtain and install each of the apps individually. Optionally, we could add logic to the main app that detects missing dependencies and then prompts the customer to install them. The Splunk App for Microsoft Exchange uses this approach.
Let me know how you get along.
Thank you for the details, I plan to incorporate one of these strategies in my app. As far as the custom response handler class is concerned, since the documentation says to add the class to restta/bin/responsehandlers.py, is there a way to include an additional file from my app? or programmatically add my code to the restta after it is installed?