Skip to content

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]

fix linting

Ishaan Jaffer724d8b5afa53
diff --git a/litellm/main.py b/litellm/main.py
index 924e06492a6..f9c44b00e86 100644
--- a/litellm/main.py
+++ b/litellm/main.py
@@ -3615,7 +3615,7 @@ def completion( # type: ignore # noqa: PLR0915
async_fn=acompletion, stream=stream, custom_llm=custom_handler
)
- headers = headers or litellm.headers
+ headers = headers or litellm.headers or {}
## CALL FUNCTION
response = handler_fn(
diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.json
index 578523abff4..5ca0bf08ba9 100644
--- a/litellm/model_prices_and_context_window_backup.json
+++ b/litellm/model_prices_and_context_window_backup.json
@@ -12332,6 +12332,7 @@
"supports_response_schema": true,
"supports_system_messages": true,
"supports_tool_choice": true,
+ "supports_service_tier": true,
"supports_vision": true
},
"gpt-5-chat": {
@@ -12479,6 +12480,7 @@
"cache_read_input_token_cost_flex": 2.5e-09,
"input_cost_per_token": 5e-08,
"input_cost_per_token_flex": 2.5e-08,
+ "input_cost_per_token_priority": 2.5e-06,
"litellm_provider": "openai",
"max_input_tokens": 400000,
"max_output_tokens": 128000,
@@ -15452,7 +15454,7 @@
},
"o4-mini": {
"cache_read_input_token_cost": 2.75e-07,
- "cache_read_input_token_cost_flex": 1.38e-07,
+ "cache_read_input_token_cost_flex": 1.375e-07,
"cache_read_input_token_cost_priority": 5e-07,
"input_cost_per_token": 1.1e-06,
"input_cost_per_token_flex": 5.5e-07,
diff --git a/litellm/proxy/_experimental/mcp_server/server.py b/litellm/proxy/_experimental/mcp_server/server.py
index 8558229cf0b..1205d3790af 100644
--- a/litellm/proxy/_experimental/mcp_server/server.py
+++ b/litellm/proxy/_experimental/mcp_server/server.py
@@ -674,7 +674,7 @@ if MCP_AVAILABLE:
server_name = single_server_match.group(1)
mcp_servers_from_path = [server_name]
else:
- mcp_servers_from_path = [servers_and_path]
+ mcp_servers_from_path = [mcp_servers_str]
return mcp_servers_from_path
async def extract_mcp_auth_context(scope, path):
diff --git a/litellm/proxy/management_endpoints/ui_sso.py b/litellm/proxy/management_endpoints/ui_sso.py
index 3828f7318c1..e8074332f5a 100644
--- a/litellm/proxy/management_endpoints/ui_sso.py
+++ b/litellm/proxy/management_endpoints/ui_sso.py
@@ -810,7 +810,7 @@ async def cli_poll_key(key_id: str):
key_obj = await prisma_client.db.litellm_verificationtoken.find_unique(
where={"token": hashed_token}
)
- key_obj: LiteLLM_VerificationToken = cast(LiteLLM_VerificationToken, key_obj)
+ key_obj = cast(LiteLLM_VerificationToken, key_obj)
if key_obj:
verbose_proxy_logger.info(f"CLI key found: {key_id}")
@@ -1503,7 +1503,7 @@ class SSOAuthenticationHandler:
## CHECK IF ROLE ALLOWED TO USE PROXY ##
is_admin_only_access = check_is_admin_only_access(ui_access_mode or {})
if is_admin_only_access:
- has_access = has_admin_ui_access(user_role)
+ has_access = has_admin_ui_access(user_role or "")
if not has_access:
raise HTTPException(
status_code=401,