Build REST API for Flask using Marshmallow.
Example “Hello User” with the Flask-resler:
from flask_restler import Api, Resource # flask_restler.Api is subclass of Flask.Blueprint api = Api('My awesome API', __name__, url_prefix='/api/v1') # flask_restler.Resource is subclass of Flask.views.View @api.connect class HelloResource(Resource): def get(self, resource=None): return 'Hello World!' # Register with your application from your_project import app app.register_blueprint(api) if __name__ == '__main__': app.run()
Run the application and open http://localhost:5000/api/v1/ in your browser.
Flask-RESTler should be installed using pip:
pip install flask-restler
Docs in progress. Would like to help? Create a PR.
If you have any suggestions, bug reports or annoyances please report them to the issue tracker at https://github.com/klen/flask-restler/issues
Development of The Flask-restler happens at: https://github.com/klen/flask-restler
Licensed under a MIT license (See LICENSE)
If you wish to express your appreciation for the project, you are welcome to send a postcard to:
Kirill Klenov pos. Severny 8-3 MO, Istra, 143500 Russia
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.