anyway/backend/src/main_example.py
Kilian Scheidecker 03da8441f2
Some checks failed
Build and push docker image / Build (pull_request) Failing after 2m14s
Build and release APK / Build APK (pull_request) Successful in 5m15s
Build web / Build Web (pull_request) Successful in 2m32s
cleaned up folders and defined proper structs
2024-05-29 22:57:11 +02:00

24 lines
347 B
Python

import fastapi
from dataclasses import dataclass
@dataclass
class Destination:
name: str
location: tuple
attractiveness: int
d = Destination()
def get_route() -> list[Destination]:
return {"route": "Hello World"}
endpoint = ("/get_route", get_route)
end
if __name__ == "__main__":
fastapi.run()