from flask import Flask, jsonify
app = Flask(__name__)
i = [
{
'id': 1,
'title': 'Hello'
},
{
'id': 2,
'title': 'World'
}
]
@app.route('/', methods=['GET'])
def get_task():
return jsonify({'i': i})
if __name__ == '__main__':
app.run(debug=True)