from flask import Flask,request,redirect import json,requests,time import simple_cache app = Flask('interverse-proxy') cache = simple_cache.Cache() @app.route("/", methods=['GET']) def interverse_proxy(): url = request.args.get('url') if url == None: return redirect("https://codeberg.org/gabe/Interverse",307) return "See Interverse" data = cache.get_interverse_data(url) return json.dumps(data) if __name__ == '__main__': app.run()