diff options
| author | Yuval Adam <_@yuv.al> | 2020-09-21 23:14:32 +0300 |
|---|---|---|
| committer | Yuval Adam <_@yuv.al> | 2020-09-21 23:14:32 +0300 |
| commit | bc6b4ddbdde231f6a55750e2245b018527b5c2b9 (patch) | |
| tree | 7fe5173b00e5551413bcca1ca56f0f09abf4014c /iss.py | |
| parent | d20dc4df2ab191c19394a38a5a3091cce9007a4f (diff) | |
Initial FastAPI server
Diffstat (limited to 'iss.py')
| -rw-r--r-- | iss.py | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -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"} |
