tfse-model-api-v0.2/app.py

27 lines
752 B
Python
Raw Normal View History

2021-10-11 17:19:00 +08:00
from flask import Flask
2021-11-19 14:38:49 +08:00
from flask_cors import *
2021-10-11 17:19:00 +08:00
2021-12-15 00:38:23 +08:00
from Rating.routes import rating_route
from Report.ReportRoute import report_route
2022-02-23 16:48:30 +08:00
from Esg.routes import esg_route
from Certificate.CertificateRoute import certificate_route
2021-10-11 17:19:00 +08:00
2021-11-19 14:38:49 +08:00
app = Flask(__name__)
app.config['JSON_SORT_KEYS'] = False
CORS(app, supports_credentials=True)
2021-10-11 17:19:00 +08:00
2021-12-15 00:38:23 +08:00
app.register_blueprint(report_route, url_prefix='/tfse_rating/report')
app.register_blueprint(rating_route, url_prefix='/tfse_rating/rating')
2022-03-08 16:17:18 +08:00
app.register_blueprint(esg_route, url_prefix='/tfse_rating/esg')
2022-01-12 14:44:37 +08:00
app.register_blueprint(certificate_route, url_prefix='/tfse_rating/certificate')
2021-12-15 00:38:23 +08:00
2022-03-08 16:15:45 +08:00
@app.route('/tfse_rating/version')
2022-03-08 16:13:59 +08:00
def hello_world():
return 'WideRating TFSE_Rating v0.2'
2021-10-11 17:19:00 +08:00
if __name__ == '__main__':
app.run()