Spaces:
Runtime error
Runtime error
Create app.py
Browse files- run/app.py +14 -0
run/app.py
ADDED
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
from fastapi import FastAPI
|
2 |
+
|
3 |
+
app = FastAPI()
|
4 |
+
|
5 |
+
@app.get("/")
|
6 |
+
def read_root():
|
7 |
+
return {"Hello": "World"}
|
8 |
+
|
9 |
+
@app.get('/hello')
|
10 |
+
def hello():
|
11 |
+
"""
|
12 |
+
Hi!
|
13 |
+
"""
|
14 |
+
return {"From": "Luwi"}
|