flask-restless icon indicating copy to clipboard operation
flask-restless copied to clipboard

Mongodb supported example?

Open scheung38 opened this issue 8 years ago • 1 comments

Hi, does this support mongodB ?

from flask_restless import APIManager

app = Flask(__name__)
app.config.from_object('config')
# db = SQLA(app)
dbmongo = MongoEngine(app)
# appbuilder = AppBuilder(app, db.session)
appbuilder = AppBuilder(app, security_manager_class=SecurityManager)

api_manager = APIManager(app, flask_sqlalchemy_db=dbmongo)
api_manager.create_api(Activities, methods=['GET', 'POST', 'DELETE', 'PUT'])
api_manager.create_api(Projects, methods=['GET', 'POST', 'DELETE', 'PUT'])

Not sure if this is valid?

scheung38 avatar Aug 05 '17 11:08 scheung38

I would say it definitely does not. This module is for relational databases, ie SQLite, MySQL, MariaDB, etc. Mongo DB does not fit into this category.

jasonrhaas avatar Sep 08 '17 15:09 jasonrhaas