From d8259388477814f1bac5fefaeb7db2a82b1d3acd Mon Sep 17 00:00:00 2001 From: Alexander Song Date: Thu, 19 Sep 2024 17:52:17 -0700 Subject: [PATCH] remove the explicit routes --- src/phoenix/server/api/routers/auth.py | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/src/phoenix/server/api/routers/auth.py b/src/phoenix/server/api/routers/auth.py index d8e52f22dd..8faefc6a0f 100644 --- a/src/phoenix/server/api/routers/auth.py +++ b/src/phoenix/server/api/routers/auth.py @@ -45,21 +45,13 @@ UserId, ) -rate_limiter = ServerRateLimiter( - per_second_rate_limit=0.2, - enforcement_window_seconds=30, - partition_seconds=60, - active_partitions=2, -) login_rate_limiter = fastapi_ip_rate_limiter( - rate_limiter, - paths=[ - "/auth/login", - "/auth/logout", - "/auth/refresh", - "/auth/password-reset-email", - "/auth/password-reset", - ], + ServerRateLimiter( + per_second_rate_limit=0.2, + enforcement_window_seconds=30, + partition_seconds=60, + active_partitions=2, + ) ) router = APIRouter( prefix="/auth", include_in_schema=False, dependencies=[Depends(login_rate_limiter)]