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(router): resolve litellm_credential_name in get_deployment_credentials_with_provider

Milanb601d8855b11
diff --git a/litellm/router.py b/litellm/router.py
index 4e268a94a2d..52ada36abf8 100644
--- a/litellm/router.py
+++ b/litellm/router.py
@@ -6750,6 +6750,13 @@ class Router:
**deployment.litellm_params.model_dump(exclude_none=True)
).model_dump(exclude_none=True)
+ # Resolve litellm_credential_name to actual credentials
+ if deployment.litellm_params.litellm_credential_name is not None:
+ credential_values = CredentialAccessor.get_credential_values(
+ deployment.litellm_params.litellm_credential_name
+ )
+ credentials.update(credential_values)
+
# Add custom_llm_provider
if deployment.litellm_params.custom_llm_provider:
credentials[