from flask import Flask, render_template, jsonify import random from datetime import datetime import json import os app = Flask('app') @app.route('/') def index(): return render_template('index.html') @app.route('/api/datapoint') def api_datapoint(): metaDict = open('meta.json',) meta = json.load(metaDict) dictionary_to_return = { 'meta': meta, # 'pics': pics } return jsonify(dictionary_to_return) app.run(host='0.0.0.0', port=8080, debug=True)