Update backend/routes/api_key_routes.py

This commit is contained in:
Matt 2023-06-14 16:54:37 +01:00 committed by GitHub
parent 0bc4221b2c
commit 2ee66b876a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -74,7 +74,7 @@ async def delete_api_key(key_id: str, commons: CommonsDep, current_user: User =
@api_key_router.get("/api-keys", response_model=List[ApiKeyInfo], dependencies=[Depends(JWTBearer())])
async def get_api_keys(commons: CommonsDep, current_user: User = Depends(get_current_user)):
"""Get all active API keys for current user."""
"""Get all active API keys for the current user. Return only the key_id and the creation_time."""
user_id = fetch_user_id_from_credentials(commons, time.strftime("%Y%m%d"), {"email": current_user.email})