The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
chore(proxy): satisfy auth model checks CI
user3b54012b7be3
diff --git a/litellm/proxy/_lazy_openapi_snapshot.json b/litellm/proxy/_lazy_openapi_snapshot.jsonindex 8331f748c6e..43c18922e1c 100644--- a/litellm/proxy/_lazy_openapi_snapshot.json+++ b/litellm/proxy/_lazy_openapi_snapshot.json@@ -3572,7 +3572,7 @@"/anthropic/{endpoint}": {"delete": {"description": "[Docs](https://docs.litellm.ai/docs/pass_through/anthropic_completion)",- "operationId": "anthropic_proxy_route_anthropic__endpoint__put",+ "operationId": "anthropic_proxy_route_anthropic__endpoint__patch","parameters": [{"in": "path",@@ -3616,7 +3616,7 @@},"get": {"description": "[Docs](https://docs.litellm.ai/docs/pass_through/anthropic_completion)",- "operationId": "anthropic_proxy_route_anthropic__endpoint__put",+ "operationId": "anthropic_proxy_route_anthropic__endpoint__patch","parameters": [{"in": "path",@@ -3660,7 +3660,7 @@},"patch": {"description": "[Docs](https://docs.litellm.ai/docs/pass_through/anthropic_completion)",- "operationId": "anthropic_proxy_route_anthropic__endpoint__put",+ "operationId": "anthropic_proxy_route_anthropic__endpoint__patch","parameters": [{"in": "path",@@ -3704,7 +3704,7 @@},"post": {"description": "[Docs](https://docs.litellm.ai/docs/pass_through/anthropic_completion)",- "operationId": "anthropic_proxy_route_anthropic__endpoint__put",+ "operationId": "anthropic_proxy_route_anthropic__endpoint__patch","parameters": [{"in": "path",@@ -3748,7 +3748,7 @@},"put": {"description": "[Docs](https://docs.litellm.ai/docs/pass_through/anthropic_completion)",- "operationId": "anthropic_proxy_route_anthropic__endpoint__put",+ "operationId": "anthropic_proxy_route_anthropic__endpoint__patch","parameters": [{"in": "path",@@ -13260,7 +13260,7 @@"/langfuse/{endpoint}": {"delete": {"description": "Call Langfuse via LiteLLM proxy. Works with Langfuse SDK.\n\n[Docs](https://docs.litellm.ai/docs/pass_through/langfuse)",- "operationId": "langfuse_proxy_route_langfuse__endpoint__put",+ "operationId": "langfuse_proxy_route_langfuse__endpoint__patch","parameters": [{"in": "path",@@ -13299,7 +13299,7 @@},"get": {"description": "Call Langfuse via LiteLLM proxy. Works with Langfuse SDK.\n\n[Docs](https://docs.litellm.ai/docs/pass_through/langfuse)",- "operationId": "langfuse_proxy_route_langfuse__endpoint__put",+ "operationId": "langfuse_proxy_route_langfuse__endpoint__patch","parameters": [{"in": "path",@@ -13338,7 +13338,7 @@},"patch": {"description": "Call Langfuse via LiteLLM proxy. Works with Langfuse SDK.\n\n[Docs](https://docs.litellm.ai/docs/pass_through/langfuse)",- "operationId": "langfuse_proxy_route_langfuse__endpoint__put",+ "operationId": "langfuse_proxy_route_langfuse__endpoint__patch","parameters": [{"in": "path",@@ -13377,7 +13377,7 @@},"post": {"description": "Call Langfuse via LiteLLM proxy. Works with Langfuse SDK.\n\n[Docs](https://docs.litellm.ai/docs/pass_through/langfuse)",- "operationId": "langfuse_proxy_route_langfuse__endpoint__put",+ "operationId": "langfuse_proxy_route_langfuse__endpoint__patch","parameters": [{"in": "path",@@ -13416,7 +13416,7 @@},"put": {"description": "Call Langfuse via LiteLLM proxy. Works with Langfuse SDK.\n\n[Docs](https://docs.litellm.ai/docs/pass_through/langfuse)",- "operationId": "langfuse_proxy_route_langfuse__endpoint__put",+ "operationId": "langfuse_proxy_route_langfuse__endpoint__patch","parameters": [{"in": "path",@@ -26883,7 +26883,7 @@"/toolset/{toolset_name}/mcp": {"delete": {"description": "Namespace a toolset as its own MCP endpoint.\n\nConnecting to /toolset/<name>/mcp exposes exactly the tools defined in\nthe toolset. Access is enforced: non-admin API keys must have the toolset\nlisted in their object_permission.mcp_toolsets grant list, or the request\nwill be rejected with a 403.",- "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_put",+ "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_patch","parameters": [{"in": "path",@@ -26922,7 +26922,7 @@},"get": {"description": "Namespace a toolset as its own MCP endpoint.\n\nConnecting to /toolset/<name>/mcp exposes exactly the tools defined in\nthe toolset. Access is enforced: non-admin API keys must have the toolset\nlisted in their object_permission.mcp_toolsets grant list, or the request\nwill be rejected with a 403.",- "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_put",+ "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_patch","parameters": [{"in": "path",@@ -26961,7 +26961,7 @@},"head": {"description": "Namespace a toolset as its own MCP endpoint.\n\nConnecting to /toolset/<name>/mcp exposes exactly the tools defined in\nthe toolset. Access is enforced: non-admin API keys must have the toolset\nlisted in their object_permission.mcp_toolsets grant list, or the request\nwill be rejected with a 403.",- "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_put",+ "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_patch","parameters": [{"in": "path",@@ -27000,7 +27000,7 @@},"options": {"description": "Namespace a toolset as its own MCP endpoint.\n\nConnecting to /toolset/<name>/mcp exposes exactly the tools defined in\nthe toolset. Access is enforced: non-admin API keys must have the toolset\nlisted in their object_permission.mcp_toolsets grant list, or the request\nwill be rejected with a 403.",- "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_put",+ "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_patch","parameters": [{"in": "path",@@ -27039,7 +27039,7 @@},"patch": {"description": "Namespace a toolset as its own MCP endpoint.\n\nConnecting to /toolset/<name>/mcp exposes exactly the tools defined in\nthe toolset. Access is enforced: non-admin API keys must have the toolset\nlisted in their object_permission.mcp_toolsets grant list, or the request\nwill be rejected with a 403.",- "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_put",+ "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_patch","parameters": [{"in": "path",@@ -27078,7 +27078,7 @@},"post": {"description": "Namespace a toolset as its own MCP endpoint.\n\nConnecting to /toolset/<name>/mcp exposes exactly the tools defined in\nthe toolset. Access is enforced: non-admin API keys must have the toolset\nlisted in their object_permission.mcp_toolsets grant list, or the request\nwill be rejected with a 403.",- "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_put",+ "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_patch","parameters": [{"in": "path",@@ -27117,7 +27117,7 @@},"put": {"description": "Namespace a toolset as its own MCP endpoint.\n\nConnecting to /toolset/<name>/mcp exposes exactly the tools defined in\nthe toolset. Access is enforced: non-admin API keys must have the toolset\nlisted in their object_permission.mcp_toolsets grant list, or the request\nwill be rejected with a 403.",- "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_put",+ "operationId": "toolset_mcp_route_toolset__toolset_name__mcp_patch","parameters": [{"in": "path",diff --git a/litellm/proxy/auth/auth_utils.py b/litellm/proxy/auth/auth_utils.pyindex ba858a89fbc..97870cfcf04 100644--- a/litellm/proxy/auth/auth_utils.py+++ b/litellm/proxy/auth/auth_utils.py@@ -988,16 +988,15 @@ def _append_model_candidates(candidates: List[str], value: Any) -> None:if value is None:return- if isinstance(value, str):- model_names = [model.strip() for model in value.split(",")]- elif isinstance(value, (list, tuple, set)):- for item in value:- _append_model_candidates(candidates=candidates, value=item)- return- else:- model_names = [str(value).strip()]-- candidates.extend(model for model in model_names if model)+ values = value if isinstance(value, (list, tuple, set)) else [value]+ for item in values:+ if item is None:+ continue+ if isinstance(item, str):+ model_names = [model.strip() for model in item.split(",")]+ else:+ model_names = [str(item).strip()]+ candidates.extend(model for model in model_names if model)def _dedupe_model_candidates(candidates: List[str]) -> List[str]: