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 missing extra_headers support for vLLM/openai_like embeddings (#13198)

Cole McIntoshc427531c9c0d
diff --git a/litellm/main.py b/litellm/main.py
index 868f4704544..4fc81cce6db 100644
--- a/litellm/main.py
+++ b/litellm/main.py
@@ -3898,6 +3898,9 @@ def embedding( # noqa: PLR0915
or get_secret_str("OPENAI_LIKE_API_KEY")
)
+ if extra_headers is not None:
+ optional_params["extra_headers"] = extra_headers
+
## EMBEDDING CALL
response = openai_like_embedding.embedding(
model=model,