Ruko integration for Flask
Flask-Ruko is a simple Flask integration for ruko server. Connection objects are created and closed in the normal flask way.
pip install flask-ruko
from flask import Flask
from flask_ruko import RukoDB
app = Flask(__name__)
db = RukoDB(app, '0.0.0.0', 44544)
users = db['users']
@app.route('/users/<uuid>', methods=['GET'])
def get_user(uuid):
return users.by('uuid')[uuid]()