Skip to content

Instantly share code, notes, and snippets.

@jattoabdul
Last active July 10, 2018 18:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jattoabdul/abc3cadc88e54fb23309daeabb15018e to your computer and use it in GitHub Desktop.
Save jattoabdul/abc3cadc88e54fb23309daeabb15018e to your computer and use it in GitHub Desktop.
Application entry point and main route
from flask_api import FlaskAPI
from config.env import app_env
from app.utils.slackhelper import SlackHelper
# from flask import request, jsonify
# from re import match
# from app.actions import Actions
def create_app(config_name):
app = FlaskAPI(__name__, instance_relative_config=False)
app.config.from_object(app_env[config_name])
app.config.from_pyfile('../config/env.py')
@app.route("/", methods=["GET"])
def home():
"""This route renders a hello world text."""
# rendering text
return 'Hello World'
return app
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment