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
build(model_prices_and_context_window.json): add azure gpt-4.1 pricing
Krrish Dholakia614d80cb1bf0
diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.jsonindex 9918743bc9f..d30a4d863b0 100644--- a/litellm/model_prices_and_context_window_backup.json+++ b/litellm/model_prices_and_context_window_backup.json@@ -1471,6 +1471,64 @@"litellm_provider": "openai","supported_endpoints": ["/v1/audio/speech"]},+ "azure/gpt-4.1": {+ "max_tokens": 32768,+ "max_input_tokens": 1047576,+ "max_output_tokens": 32768,+ "input_cost_per_token": 2e-6,+ "output_cost_per_token": 8e-6,+ "input_cost_per_token_batches": 1e-6,+ "output_cost_per_token_batches": 4e-6,+ "cache_read_input_token_cost": 0.5e-6,+ "litellm_provider": "azure",+ "mode": "chat",+ "supported_endpoints": ["/v1/chat/completions", "/v1/batch", "/v1/responses"],+ "supported_modalities": ["text", "image"],+ "supported_output_modalities": ["text"],+ "supports_function_calling": true,+ "supports_parallel_function_calling": true,+ "supports_response_schema": true,+ "supports_vision": true,+ "supports_prompt_caching": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "supports_native_streaming": true,+ "supports_web_search": true,+ "search_context_cost_per_query": {+ "search_context_size_low": 30e-3,+ "search_context_size_medium": 35e-3,+ "search_context_size_high": 50e-3+ }+ },+ "azure/gpt-4.1-2025-04-14": {+ "max_tokens": 32768,+ "max_input_tokens": 1047576,+ "max_output_tokens": 32768,+ "input_cost_per_token": 2e-6,+ "output_cost_per_token": 8e-6,+ "input_cost_per_token_batches": 1e-6,+ "output_cost_per_token_batches": 4e-6,+ "cache_read_input_token_cost": 0.5e-6,+ "litellm_provider": "azure",+ "mode": "chat",+ "supported_endpoints": ["/v1/chat/completions", "/v1/batch", "/v1/responses"],+ "supported_modalities": ["text", "image"],+ "supported_output_modalities": ["text"],+ "supports_function_calling": true,+ "supports_parallel_function_calling": true,+ "supports_response_schema": true,+ "supports_vision": true,+ "supports_prompt_caching": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "supports_native_streaming": true,+ "supports_web_search": true,+ "search_context_cost_per_query": {+ "search_context_size_low": 30e-3,+ "search_context_size_medium": 35e-3,+ "search_context_size_high": 50e-3+ }+ },"azure/gpt-4o-mini-realtime-preview-2024-12-17": {"max_tokens": 4096,"max_input_tokens": 128000,diff --git a/litellm/proxy/_new_secret_config.yaml b/litellm/proxy/_new_secret_config.yamlindex e166133cec4..b1c4959e0b8 100644--- a/litellm/proxy/_new_secret_config.yaml+++ b/litellm/proxy/_new_secret_config.yaml@@ -21,13 +21,12 @@ model_list:model: databricks/databricks-claude-3-7-sonnetapi_key: os.environ/DATABRICKS_API_KEYapi_base: os.environ/DATABRICKS_API_BASE- - model_name: "gpt-4o-realtime-preview"+ - model_name: "gpt-4.1"litellm_params:- model: azure/gpt-4o-realtime-preview-2+ model: azure/gpt-4.1api_key: os.environ/AZURE_API_KEY_REALTIMEapi_base: https://krris-m2f9a9i7-eastus2.openai.azure.com/- model_info:- base_model: azure/gpt-4o-realtime-preview-2024-10-01+litellm_settings:diff --git a/model_prices_and_context_window.json b/model_prices_and_context_window.jsonindex 9918743bc9f..d30a4d863b0 100644--- a/model_prices_and_context_window.json+++ b/model_prices_and_context_window.json@@ -1471,6 +1471,64 @@"litellm_provider": "openai","supported_endpoints": ["/v1/audio/speech"]},+ "azure/gpt-4.1": {+ "max_tokens": 32768,+ "max_input_tokens": 1047576,+ "max_output_tokens": 32768,+ "input_cost_per_token": 2e-6,+ "output_cost_per_token": 8e-6,+ "input_cost_per_token_batches": 1e-6,+ "output_cost_per_token_batches": 4e-6,+ "cache_read_input_token_cost": 0.5e-6,+ "litellm_provider": "azure",+ "mode": "chat",+ "supported_endpoints": ["/v1/chat/completions", "/v1/batch", "/v1/responses"],+ "supported_modalities": ["text", "image"],+ "supported_output_modalities": ["text"],+ "supports_function_calling": true,+ "supports_parallel_function_calling": true,+ "supports_response_schema": true,+ "supports_vision": true,+ "supports_prompt_caching": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "supports_native_streaming": true,+ "supports_web_search": true,+ "search_context_cost_per_query": {+ "search_context_size_low": 30e-3,+ "search_context_size_medium": 35e-3,+ "search_context_size_high": 50e-3+ }+ },+ "azure/gpt-4.1-2025-04-14": {+ "max_tokens": 32768,+ "max_input_tokens": 1047576,+ "max_output_tokens": 32768,+ "input_cost_per_token": 2e-6,+ "output_cost_per_token": 8e-6,+ "input_cost_per_token_batches": 1e-6,+ "output_cost_per_token_batches": 4e-6,+ "cache_read_input_token_cost": 0.5e-6,+ "litellm_provider": "azure",+ "mode": "chat",+ "supported_endpoints": ["/v1/chat/completions", "/v1/batch", "/v1/responses"],+ "supported_modalities": ["text", "image"],+ "supported_output_modalities": ["text"],+ "supports_function_calling": true,+ "supports_parallel_function_calling": true,+ "supports_response_schema": true,+ "supports_vision": true,+ "supports_prompt_caching": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "supports_native_streaming": true,+ "supports_web_search": true,+ "search_context_cost_per_query": {+ "search_context_size_low": 30e-3,+ "search_context_size_medium": 35e-3,+ "search_context_size_high": 50e-3+ }+ },"azure/gpt-4o-mini-realtime-preview-2024-12-17": {"max_tokens": 4096,"max_input_tokens": 128000,