swag-shop/app/api/routes/main_routes.py

12 lines
227 B
Python
Raw Normal View History

2024-03-05 16:01:26 +01:00
from flask import jsonify, abort
2024-03-12 20:12:19 +01:00
from app.doc.main import main_swagger
from flasgger import swag_from
2024-03-08 14:05:00 +01:00
from app.api import bp
2024-03-05 16:01:26 +01:00
@bp.route('/')
2024-03-12 20:12:19 +01:00
@swag_from(main_swagger)
2024-03-05 16:01:26 +01:00
def hello():
return jsonify({'message': 'Hello, Flask!'})