add docstring for apps_in_domain