feat: faker api: swagger

This commit is contained in:
Zhaolong
2022-02-07 22:16:52 +08:00
parent 5f56feffb2
commit 608dcae3ce
4 changed files with 214 additions and 11 deletions

View File

@@ -10,8 +10,16 @@ SQLALCHEMY_DATABASE_URI = f'{DIALECT}+{DRIVER}://{USERNAME}:{PASSWORD}@{HOST}:{P
SQLALCHEMY_TRACK_MODIFICATIONS = False
SQLALCHEMY_ECHO = True
SWAGGER_CONFIG = {
"title": "nCovTrack-Faker",
"description": "API for nCovTrack-Faker",
'uiversion': 3,
"version": "0.0.1"
}
def init_config(app):
app.config["SQLALCHEMY_DATABASE_URI"] = SQLALCHEMY_DATABASE_URI
app.config["SQLALCHEMY_TRACK_MODIFICATIONS"] = False
app.config["SQLALCHEMY_ECHO"] = True
app.config["SWAGGER"] = SWAGGER_CONFIG