mirror of
https://github.com/timmypidashev/web.git
synced 2026-04-14 19:13:51 +00:00
16 lines
237 B
Python
16 lines
237 B
Python
from flask import Flask
|
|
|
|
|
|
app = Flask(__name__)
|
|
|
|
|
|
@app.route("/")
|
|
def home():
|
|
return "Home Page Route"
|
|
|
|
@app.route("/api")
|
|
def api():
|
|
with open("data.json", mode="r") as my_file:
|
|
text = my_file.read()
|
|
return text
|