diff --git a/litellm/proxy/auth/auth_utils.py b/litellm/proxy/auth/auth_utils.py index 64766bbaad..33f4134865 100644 --- a/litellm/proxy/auth/auth_utils.py +++ b/litellm/proxy/auth/auth_utils.py @@ -69,7 +69,8 @@ def check_complete_credentials(request_body: dict) -> bool: # complex credentials - easier to make a malicious request return False - if "api_key" in request_body: + api_key_value = request_body.get("api_key") + if api_key_value and isinstance(api_key_value, str) and api_key_value.strip(): return True return False