This is possible with the Deploy API 3.3 Retrieve App.
With the retrieveApplicationURL java action from the CommunityCommons you can determine the app id (sub-domain name of the app) to use in the request.
-Edit- Found this, much faster method: https://apidocs.mendix.com/7/runtime/com/mendix/core/Core.html#getProjectId--