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
Add update_headers_with_filtered_beta in anthropic
Sameer Kankute25a19b2091b4
diff --git a/litellm/llms/anthropic/experimental_pass_through/messages/transformation.py b/litellm/llms/anthropic/experimental_pass_through/messages/transformation.pyindex 308bf367d06..df9679c033b 100644--- a/litellm/llms/anthropic/experimental_pass_through/messages/transformation.py+++ b/litellm/llms/anthropic/experimental_pass_through/messages/transformation.py@@ -2,6 +2,9 @@ from typing import Any, AsyncIterator, Dict, List, Optional, Tupleimport httpx+from litellm.anthropic_beta_headers_manager import (+ update_headers_with_filtered_beta,+)from litellm.litellm_core_utils.litellm_logging import Logging as LiteLLMLoggingObjfrom litellm.litellm_core_utils.litellm_logging import verbose_loggerfrom litellm.llms.base_llm.anthropic_messages.transformation import (@@ -90,6 +93,11 @@ class AnthropicMessagesConfig(BaseAnthropicMessagesConfig):optional_params=optional_params,)+ headers = update_headers_with_filtered_beta(+ headers=headers,+ provider="anthropic",+ )+return headers, api_basedef transform_anthropic_messages_request(