diff --git a/api/hanyadikhetvan/__init__.py b/api/hanyadikhetvan/__init__.py index 7d15c36..44a9cae 100644 --- a/api/hanyadikhetvan/__init__.py +++ b/api/hanyadikhetvan/__init__.py @@ -1,11 +1,13 @@ from math import floor from datetime import date +from urllib import request import azure.functions as func def main(req: func.HttpRequest) -> func.HttpResponse: startdate = date(2022, 8, 29) currentweek = floor((date.today() - startdate).days / 7) + request.get("https://tormakristof.eu/") return func.HttpResponse( str(currentweek), status_code=200) diff --git a/api/requirements.txt b/api/requirements.txt new file mode 100644 index 0000000..ce86af0 --- /dev/null +++ b/api/requirements.txt @@ -0,0 +1,2 @@ +azure-functions +requests \ No newline at end of file