from flask import request, jsonify, redirect, url_for, render_template from app import app, db # from app.models import User @app.route('/api', methods=['POST']) def process_request(): image = request.files.get('image') text = request.form.get('text') blocks = request.form.getlist('blocks') # Process image, text, and blocks as needed # log to flask log the blocks list. app.logger.info(blocks) app.logger.info(text) return jsonify(success=True)