diff --git a/auth.py b/auth.py index 066c9d5..29ed9b5 100644 --- a/auth.py +++ b/auth.py @@ -16,7 +16,6 @@ def get_settings(): return Settings() async def get_api_key(settings: Settings = Depends(get_settings), api_key_header: str = Security(api_key_header)): - print(settings) if api_key_header == settings.API_KEY: return api_key_header else: diff --git a/main.py b/main.py index 9405a28..87df814 100644 --- a/main.py +++ b/main.py @@ -45,7 +45,7 @@ def database(query,name,user): app = FastAPI() @app.get("/") -async def notify(): +async def notify(api_key: APIKey = Depends(auth.get_api_key)): return database(f"SELECT * FROM Notifications", "Stines-GmbH","") @app.get("/gettime")