summaryrefslogtreecommitdiff
path: root/iss.py
diff options
context:
space:
mode:
authorYuval Adam <_@yuv.al>2020-09-21 23:14:32 +0300
committerYuval Adam <_@yuv.al>2020-09-21 23:14:32 +0300
commitbc6b4ddbdde231f6a55750e2245b018527b5c2b9 (patch)
tree7fe5173b00e5551413bcca1ca56f0f09abf4014c /iss.py
parentd20dc4df2ab191c19394a38a5a3091cce9007a4f (diff)
Initial FastAPI server
Diffstat (limited to 'iss.py')
-rw-r--r--iss.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/iss.py b/iss.py
index fa4aeff..215b7c3 100644
--- a/iss.py
+++ b/iss.py
@@ -1,3 +1,4 @@
+from fastapi import FastAPI
from skyfield.api import Topos, load
TEL_AVIV = Topos('32.0853 N', '34.7817 E')
@@ -21,3 +22,12 @@ def get_predictions(location=TEL_AVIV, satellite_name=ISS):
name = ('rise above 30°', 'culminate', 'set below 30°')[event]
print(ti)
print(ti.utc_strftime('%Y %b %d %H:%M:%S'), name)
+
+
+
+app = FastAPI()
+
+
+@app.get("/")
+async def root():
+ return {"message": "Hello World"}