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
fix(model_prices): add above-272k priority rates to azure us/eu gpt-5.6 entries
mateo-berrie97a84afcf9b
diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.jsonindex 3f1d84cae97..57facc96319 100644--- a/litellm/model_prices_and_context_window_backup.json+++ b/litellm/model_prices_and_context_window_backup.json@@ -6813,12 +6813,15 @@"azure/us/gpt-5.6": {"cache_creation_input_token_cost": 6.875e-06,"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 2.75e-05,"cache_creation_input_token_cost_priority": 1.375e-05,"cache_read_input_token_cost": 5.5e-07,"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,+ "cache_read_input_token_cost_above_272k_tokens_priority": 2.2e-06,"cache_read_input_token_cost_priority": 1.1e-06,"input_cost_per_token": 5.5e-06,"input_cost_per_token_above_272k_tokens": 1.1e-05,+ "input_cost_per_token_above_272k_tokens_priority": 2.2e-05,"input_cost_per_token_priority": 1.1e-05,"litellm_provider": "azure","max_input_tokens": 922000,@@ -6827,6 +6830,7 @@"mode": "chat","output_cost_per_token": 3.3e-05,"output_cost_per_token_above_272k_tokens": 4.95e-05,+ "output_cost_per_token_above_272k_tokens_priority": 9.9e-05,"output_cost_per_token_priority": 6.6e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -6863,13 +6867,16 @@"azure/us/gpt-5.6-sol": {"cache_creation_input_token_cost": 6.875e-06,"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 2.75e-05,"cache_creation_input_token_cost_priority": 1.375e-05,"cache_read_input_token_cost": 5.5e-07,"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,+ "cache_read_input_token_cost_above_272k_tokens_priority": 2.2e-06,"cache_read_input_token_cost_priority": 1.1e-06,"deprecation_date": "2028-01-11","input_cost_per_token": 5.5e-06,"input_cost_per_token_above_272k_tokens": 1.1e-05,+ "input_cost_per_token_above_272k_tokens_priority": 2.2e-05,"input_cost_per_token_priority": 1.1e-05,"litellm_provider": "azure","max_input_tokens": 922000,@@ -6878,6 +6885,7 @@"mode": "chat","output_cost_per_token": 3.3e-05,"output_cost_per_token_above_272k_tokens": 4.95e-05,+ "output_cost_per_token_above_272k_tokens_priority": 9.9e-05,"output_cost_per_token_priority": 6.6e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -6914,13 +6922,16 @@"azure/us/gpt-5.6-terra": {"cache_creation_input_token_cost": 2.75e-06,"cache_creation_input_token_cost_above_272k_tokens": 5.5e-06,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 1.1e-05,"cache_creation_input_token_cost_priority": 5.5e-06,"cache_read_input_token_cost": 2.2e-07,"cache_read_input_token_cost_above_272k_tokens": 4.4e-07,+ "cache_read_input_token_cost_above_272k_tokens_priority": 8.8e-07,"cache_read_input_token_cost_priority": 4.4e-07,"deprecation_date": "2028-01-11","input_cost_per_token": 2.2e-06,"input_cost_per_token_above_272k_tokens": 4.4e-06,+ "input_cost_per_token_above_272k_tokens_priority": 8.8e-06,"input_cost_per_token_priority": 4.4e-06,"litellm_provider": "azure","max_input_tokens": 922000,@@ -6929,6 +6940,7 @@"mode": "chat","output_cost_per_token": 1.32e-05,"output_cost_per_token_above_272k_tokens": 1.98e-05,+ "output_cost_per_token_above_272k_tokens_priority": 3.96e-05,"output_cost_per_token_priority": 2.64e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -6965,13 +6977,16 @@"azure/us/gpt-5.6-luna": {"cache_creation_input_token_cost": 2.75e-07,"cache_creation_input_token_cost_above_272k_tokens": 5.5e-07,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 1.1e-06,"cache_creation_input_token_cost_priority": 5.5e-07,"cache_read_input_token_cost": 2.2e-08,"cache_read_input_token_cost_above_272k_tokens": 4.4e-08,+ "cache_read_input_token_cost_above_272k_tokens_priority": 8.8e-08,"cache_read_input_token_cost_priority": 4.4e-08,"deprecation_date": "2028-01-11","input_cost_per_token": 2.2e-07,"input_cost_per_token_above_272k_tokens": 4.4e-07,+ "input_cost_per_token_above_272k_tokens_priority": 8.8e-07,"input_cost_per_token_priority": 4.4e-07,"litellm_provider": "azure","max_input_tokens": 922000,@@ -6980,6 +6995,7 @@"mode": "chat","output_cost_per_token": 1.32e-06,"output_cost_per_token_above_272k_tokens": 1.98e-06,+ "output_cost_per_token_above_272k_tokens_priority": 3.96e-06,"output_cost_per_token_priority": 2.64e-06,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -7016,12 +7032,15 @@"azure/eu/gpt-5.6": {"cache_creation_input_token_cost": 6.875e-06,"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 2.75e-05,"cache_creation_input_token_cost_priority": 1.375e-05,"cache_read_input_token_cost": 5.5e-07,"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,+ "cache_read_input_token_cost_above_272k_tokens_priority": 2.2e-06,"cache_read_input_token_cost_priority": 1.1e-06,"input_cost_per_token": 5.5e-06,"input_cost_per_token_above_272k_tokens": 1.1e-05,+ "input_cost_per_token_above_272k_tokens_priority": 2.2e-05,"input_cost_per_token_priority": 1.1e-05,"litellm_provider": "azure","max_input_tokens": 922000,@@ -7030,6 +7049,7 @@"mode": "chat","output_cost_per_token": 3.3e-05,"output_cost_per_token_above_272k_tokens": 4.95e-05,+ "output_cost_per_token_above_272k_tokens_priority": 9.9e-05,"output_cost_per_token_priority": 6.6e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -7066,13 +7086,16 @@"azure/eu/gpt-5.6-sol": {"cache_creation_input_token_cost": 6.875e-06,"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 2.75e-05,"cache_creation_input_token_cost_priority": 1.375e-05,"cache_read_input_token_cost": 5.5e-07,"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,+ "cache_read_input_token_cost_above_272k_tokens_priority": 2.2e-06,"cache_read_input_token_cost_priority": 1.1e-06,"deprecation_date": "2028-01-11","input_cost_per_token": 5.5e-06,"input_cost_per_token_above_272k_tokens": 1.1e-05,+ "input_cost_per_token_above_272k_tokens_priority": 2.2e-05,"input_cost_per_token_priority": 1.1e-05,"litellm_provider": "azure","max_input_tokens": 922000,@@ -7081,6 +7104,7 @@"mode": "chat","output_cost_per_token": 3.3e-05,"output_cost_per_token_above_272k_tokens": 4.95e-05,+ "output_cost_per_token_above_272k_tokens_priority": 9.9e-05,"output_cost_per_token_priority": 6.6e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -7117,13 +7141,16 @@"azure/eu/gpt-5.6-terra": {"cache_creation_input_token_cost": 2.75e-06,"cache_creation_input_token_cost_above_272k_tokens": 5.5e-06,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 1.1e-05,"cache_creation_input_token_cost_priority": 5.5e-06,"cache_read_input_token_cost": 2.2e-07,"cache_read_input_token_cost_above_272k_tokens": 4.4e-07,+ "cache_read_input_token_cost_above_272k_tokens_priority": 8.8e-07,"cache_read_input_token_cost_priority": 4.4e-07,"deprecation_date": "2028-01-11","input_cost_per_token": 2.2e-06,"input_cost_per_token_above_272k_tokens": 4.4e-06,+ "input_cost_per_token_above_272k_tokens_priority": 8.8e-06,"input_cost_per_token_priority": 4.4e-06,"litellm_provider": "azure","max_input_tokens": 922000,@@ -7132,6 +7159,7 @@"mode": "chat","output_cost_per_token": 1.32e-05,"output_cost_per_token_above_272k_tokens": 1.98e-05,+ "output_cost_per_token_above_272k_tokens_priority": 3.96e-05,"output_cost_per_token_priority": 2.64e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -7168,13 +7196,16 @@"azure/eu/gpt-5.6-luna": {"cache_creation_input_token_cost": 2.75e-07,"cache_creation_input_token_cost_above_272k_tokens": 5.5e-07,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 1.1e-06,"cache_creation_input_token_cost_priority": 5.5e-07,"cache_read_input_token_cost": 2.2e-08,"cache_read_input_token_cost_above_272k_tokens": 4.4e-08,+ "cache_read_input_token_cost_above_272k_tokens_priority": 8.8e-08,"cache_read_input_token_cost_priority": 4.4e-08,"deprecation_date": "2028-01-11","input_cost_per_token": 2.2e-07,"input_cost_per_token_above_272k_tokens": 4.4e-07,+ "input_cost_per_token_above_272k_tokens_priority": 8.8e-07,"input_cost_per_token_priority": 4.4e-07,"litellm_provider": "azure","max_input_tokens": 922000,@@ -7183,6 +7214,7 @@"mode": "chat","output_cost_per_token": 1.32e-06,"output_cost_per_token_above_272k_tokens": 1.98e-06,+ "output_cost_per_token_above_272k_tokens_priority": 3.96e-06,"output_cost_per_token_priority": 2.64e-06,"search_context_cost_per_query": {"search_context_size_high": 0.01,diff --git a/model_prices_and_context_window.json b/model_prices_and_context_window.jsonindex 3f1d84cae97..57facc96319 100644--- a/model_prices_and_context_window.json+++ b/model_prices_and_context_window.json@@ -6813,12 +6813,15 @@"azure/us/gpt-5.6": {"cache_creation_input_token_cost": 6.875e-06,"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 2.75e-05,"cache_creation_input_token_cost_priority": 1.375e-05,"cache_read_input_token_cost": 5.5e-07,"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,+ "cache_read_input_token_cost_above_272k_tokens_priority": 2.2e-06,"cache_read_input_token_cost_priority": 1.1e-06,"input_cost_per_token": 5.5e-06,"input_cost_per_token_above_272k_tokens": 1.1e-05,+ "input_cost_per_token_above_272k_tokens_priority": 2.2e-05,"input_cost_per_token_priority": 1.1e-05,"litellm_provider": "azure","max_input_tokens": 922000,@@ -6827,6 +6830,7 @@"mode": "chat","output_cost_per_token": 3.3e-05,"output_cost_per_token_above_272k_tokens": 4.95e-05,+ "output_cost_per_token_above_272k_tokens_priority": 9.9e-05,"output_cost_per_token_priority": 6.6e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -6863,13 +6867,16 @@"azure/us/gpt-5.6-sol": {"cache_creation_input_token_cost": 6.875e-06,"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 2.75e-05,"cache_creation_input_token_cost_priority": 1.375e-05,"cache_read_input_token_cost": 5.5e-07,"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,+ "cache_read_input_token_cost_above_272k_tokens_priority": 2.2e-06,"cache_read_input_token_cost_priority": 1.1e-06,"deprecation_date": "2028-01-11","input_cost_per_token": 5.5e-06,"input_cost_per_token_above_272k_tokens": 1.1e-05,+ "input_cost_per_token_above_272k_tokens_priority": 2.2e-05,"input_cost_per_token_priority": 1.1e-05,"litellm_provider": "azure","max_input_tokens": 922000,@@ -6878,6 +6885,7 @@"mode": "chat","output_cost_per_token": 3.3e-05,"output_cost_per_token_above_272k_tokens": 4.95e-05,+ "output_cost_per_token_above_272k_tokens_priority": 9.9e-05,"output_cost_per_token_priority": 6.6e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -6914,13 +6922,16 @@"azure/us/gpt-5.6-terra": {"cache_creation_input_token_cost": 2.75e-06,"cache_creation_input_token_cost_above_272k_tokens": 5.5e-06,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 1.1e-05,"cache_creation_input_token_cost_priority": 5.5e-06,"cache_read_input_token_cost": 2.2e-07,"cache_read_input_token_cost_above_272k_tokens": 4.4e-07,+ "cache_read_input_token_cost_above_272k_tokens_priority": 8.8e-07,"cache_read_input_token_cost_priority": 4.4e-07,"deprecation_date": "2028-01-11","input_cost_per_token": 2.2e-06,"input_cost_per_token_above_272k_tokens": 4.4e-06,+ "input_cost_per_token_above_272k_tokens_priority": 8.8e-06,"input_cost_per_token_priority": 4.4e-06,"litellm_provider": "azure","max_input_tokens": 922000,@@ -6929,6 +6940,7 @@"mode": "chat","output_cost_per_token": 1.32e-05,"output_cost_per_token_above_272k_tokens": 1.98e-05,+ "output_cost_per_token_above_272k_tokens_priority": 3.96e-05,"output_cost_per_token_priority": 2.64e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -6965,13 +6977,16 @@"azure/us/gpt-5.6-luna": {"cache_creation_input_token_cost": 2.75e-07,"cache_creation_input_token_cost_above_272k_tokens": 5.5e-07,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 1.1e-06,"cache_creation_input_token_cost_priority": 5.5e-07,"cache_read_input_token_cost": 2.2e-08,"cache_read_input_token_cost_above_272k_tokens": 4.4e-08,+ "cache_read_input_token_cost_above_272k_tokens_priority": 8.8e-08,"cache_read_input_token_cost_priority": 4.4e-08,"deprecation_date": "2028-01-11","input_cost_per_token": 2.2e-07,"input_cost_per_token_above_272k_tokens": 4.4e-07,+ "input_cost_per_token_above_272k_tokens_priority": 8.8e-07,"input_cost_per_token_priority": 4.4e-07,"litellm_provider": "azure","max_input_tokens": 922000,@@ -6980,6 +6995,7 @@"mode": "chat","output_cost_per_token": 1.32e-06,"output_cost_per_token_above_272k_tokens": 1.98e-06,+ "output_cost_per_token_above_272k_tokens_priority": 3.96e-06,"output_cost_per_token_priority": 2.64e-06,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -7016,12 +7032,15 @@"azure/eu/gpt-5.6": {"cache_creation_input_token_cost": 6.875e-06,"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 2.75e-05,"cache_creation_input_token_cost_priority": 1.375e-05,"cache_read_input_token_cost": 5.5e-07,"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,+ "cache_read_input_token_cost_above_272k_tokens_priority": 2.2e-06,"cache_read_input_token_cost_priority": 1.1e-06,"input_cost_per_token": 5.5e-06,"input_cost_per_token_above_272k_tokens": 1.1e-05,+ "input_cost_per_token_above_272k_tokens_priority": 2.2e-05,"input_cost_per_token_priority": 1.1e-05,"litellm_provider": "azure","max_input_tokens": 922000,@@ -7030,6 +7049,7 @@"mode": "chat","output_cost_per_token": 3.3e-05,"output_cost_per_token_above_272k_tokens": 4.95e-05,+ "output_cost_per_token_above_272k_tokens_priority": 9.9e-05,"output_cost_per_token_priority": 6.6e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -7066,13 +7086,16 @@"azure/eu/gpt-5.6-sol": {"cache_creation_input_token_cost": 6.875e-06,"cache_creation_input_token_cost_above_272k_tokens": 1.375e-05,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 2.75e-05,"cache_creation_input_token_cost_priority": 1.375e-05,"cache_read_input_token_cost": 5.5e-07,"cache_read_input_token_cost_above_272k_tokens": 1.1e-06,+ "cache_read_input_token_cost_above_272k_tokens_priority": 2.2e-06,"cache_read_input_token_cost_priority": 1.1e-06,"deprecation_date": "2028-01-11","input_cost_per_token": 5.5e-06,"input_cost_per_token_above_272k_tokens": 1.1e-05,+ "input_cost_per_token_above_272k_tokens_priority": 2.2e-05,"input_cost_per_token_priority": 1.1e-05,"litellm_provider": "azure","max_input_tokens": 922000,@@ -7081,6 +7104,7 @@"mode": "chat","output_cost_per_token": 3.3e-05,"output_cost_per_token_above_272k_tokens": 4.95e-05,+ "output_cost_per_token_above_272k_tokens_priority": 9.9e-05,"output_cost_per_token_priority": 6.6e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -7117,13 +7141,16 @@"azure/eu/gpt-5.6-terra": {"cache_creation_input_token_cost": 2.75e-06,"cache_creation_input_token_cost_above_272k_tokens": 5.5e-06,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 1.1e-05,"cache_creation_input_token_cost_priority": 5.5e-06,"cache_read_input_token_cost": 2.2e-07,"cache_read_input_token_cost_above_272k_tokens": 4.4e-07,+ "cache_read_input_token_cost_above_272k_tokens_priority": 8.8e-07,"cache_read_input_token_cost_priority": 4.4e-07,"deprecation_date": "2028-01-11","input_cost_per_token": 2.2e-06,"input_cost_per_token_above_272k_tokens": 4.4e-06,+ "input_cost_per_token_above_272k_tokens_priority": 8.8e-06,"input_cost_per_token_priority": 4.4e-06,"litellm_provider": "azure","max_input_tokens": 922000,@@ -7132,6 +7159,7 @@"mode": "chat","output_cost_per_token": 1.32e-05,"output_cost_per_token_above_272k_tokens": 1.98e-05,+ "output_cost_per_token_above_272k_tokens_priority": 3.96e-05,"output_cost_per_token_priority": 2.64e-05,"search_context_cost_per_query": {"search_context_size_high": 0.01,@@ -7168,13 +7196,16 @@"azure/eu/gpt-5.6-luna": {"cache_creation_input_token_cost": 2.75e-07,"cache_creation_input_token_cost_above_272k_tokens": 5.5e-07,+ "cache_creation_input_token_cost_above_272k_tokens_priority": 1.1e-06,"cache_creation_input_token_cost_priority": 5.5e-07,"cache_read_input_token_cost": 2.2e-08,"cache_read_input_token_cost_above_272k_tokens": 4.4e-08,+ "cache_read_input_token_cost_above_272k_tokens_priority": 8.8e-08,"cache_read_input_token_cost_priority": 4.4e-08,"deprecation_date": "2028-01-11","input_cost_per_token": 2.2e-07,"input_cost_per_token_above_272k_tokens": 4.4e-07,+ "input_cost_per_token_above_272k_tokens_priority": 8.8e-07,"input_cost_per_token_priority": 4.4e-07,"litellm_provider": "azure","max_input_tokens": 922000,@@ -7183,6 +7214,7 @@"mode": "chat","output_cost_per_token": 1.32e-06,"output_cost_per_token_above_272k_tokens": 1.98e-06,+ "output_cost_per_token_above_272k_tokens_priority": 3.96e-06,"output_cost_per_token_priority": 2.64e-06,"search_context_cost_per_query": {"search_context_size_high": 0.01,diff --git a/tests/test_litellm/test_cost_calculator.py b/tests/test_litellm/test_cost_calculator.pyindex cd58c780710..5c731d63cda 100644--- a/tests/test_litellm/test_cost_calculator.py+++ b/tests/test_litellm/test_cost_calculator.py@@ -1777,12 +1777,11 @@ def test_azure_gpt_5_6_rates_match_azure_price_page(_local_model_cost_map, modelzone = model.split("/")[1]if zone in ("us", "eu"):global_entry = litellm.model_cost["azure/" + model.split("/", 2)[2]]- token_cost_keys = [- key- for key in entry- if key.startswith(("input_cost_per_token", "output_cost_per_token", "cache_read", "cache_creation"))- ]+ prefixes = ("input_cost_per_token", "output_cost_per_token", "cache_read", "cache_creation")+ token_cost_keys = [key for key in entry if key.startswith(prefixes)]+ global_token_cost_keys = [key for key in global_entry if key.startswith(prefixes)]assert len(token_cost_keys) >= 9+ assert sorted(token_cost_keys) == sorted(global_token_cost_keys)for key in token_cost_keys:assert entry[key] == pytest.approx(global_entry[key] * 1.1), key