diff --git a/README.md b/README.md index 35c61b0..c90012a 100644 --- a/README.md +++ b/README.md @@ -93,6 +93,8 @@ If you want to add/remove dependencies you have to rebuild the container. # RESTful API +If you go to https://matweb.info/apidocs you can find a Swagger documentation. + ## Upload Endpoint **Endpoint:** `/api/upload` diff --git a/main.py b/main.py index 5e47531..cf75e2d 100644 --- a/main.py +++ b/main.py @@ -14,6 +14,10 @@ def create_app(test_config=None): app.config['UPLOAD_FOLDER'] = os.environ.get('MAT2_WEB_DOWNLOAD_FOLDER', './uploads/') app.config['MAX_CONTENT_LENGTH'] = 16 * 1024 * 1024 # 16MB app.config['CUSTOM_TEMPLATES_DIR'] = 'custom_templates' + app.config['SWAGGER'] = { + 'title': 'Mat2 Web API', + 'version': '1.0.0', + } # optionally load settings from config.py app.config.from_object('config')