Commit c09f89ce authored by Sebastien Robin's avatar Sebastien Robin

setup dummy code for platform

parent 182dc645
from flask import Flask, jsonify
from flask import request
from crossdomain import crossdomain
app = Flask(__name__)
@app.route("/")
def welcome():
app.logger.debug('welcome')
return "Welcome to DREAM Simulation"
@app.route("/addModel")
def addModel():
pass
def main(*args):
app.run(debug=True)
@app.route("/someTest", methods=["POST", "OPTIONS"])
@crossdomain(origin='*')
def someTest():
app.logger.debug('someTest')
app.logger.debug(request)
app.logger.debug(request.__dict__)
app.logger.debug("request headers content type: %r" % (request.headers['Content-Type'],))
app.logger.debug("request.json: %r" % (request.json,))
response =request.json
return jsonify(request.json)
if __name__ == "__main__":
main()
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment