"""Integration with Apollo services. """ import glob from os.path import basename, dirname, isfile from flask import Blueprint from external_api.views import ApolloSearchView modules = glob.glob(dirname(__file__) + "/*.py") __all__ = [basename(f)[:-3] for f in modules if isfile(f) and not f.endswith("__init__.py")] blueprint = Blueprint("external_api", __name__) blueprint.add_url_rule("/apollo/search", view_func=ApolloSearchView.as_view("apollo_search"))