replaced /data endpoint

This commit is contained in:
ishak jmilou.ishak
2025-01-09 12:56:25 +01:00
parent d90ac72591
commit d066f68ad2

View File

@@ -57,6 +57,10 @@ def control():
else: else:
return ('Unauthorized', 401, {'WWW-Authenticate': 'Basic realm="Login Required"'}) return ('Unauthorized', 401, {'WWW-Authenticate': 'Basic realm="Login Required"'})
@app.route('/data', methods=['GET'])
def data():
return kobuki_message
@app.route('/move', methods=['POST']) @app.route('/move', methods=['POST'])
def move(): def move():
data = request.get_json() data = request.get_json()
@@ -77,10 +81,6 @@ def move():
return jsonify({"status": "success", "direction": direction}) return jsonify({"status": "success", "direction": direction})
@app.route('/data', methods=['GET'])
def data():
return kobuki_message
@app.route("/database") @app.route("/database")
def database(): def database():
db = get_db() db = get_db()