Commit Graph
1008 Commits
Author SHA1 Message Date
boarder7395andGitHub 8e4f06583a Fix team cli auth flow (#19666)
* Cleanup code for user cli auth, and make sure not to prompt user for team multiple times while polling

* Adding tests

* Cleanup normalize teams some more
2026-01-28 08:52:52 -08:00
yuneng-jiang 28ca991296 Allow dynamic setting of store_prompts_in_spend_logs 2026-01-27 20:52:07 -08:00
yuneng-jiang 1581bcf985 add sortBy and sortOrder params for /v2/model/info 2026-01-27 16:54:52 -08:00
yuneng-jiangandGitHub 45954155d7 Merge pull request #19799 from BerriAI/litellm_sso_email_casing
[Fix] SSO Email Case Sensitivity
2026-01-27 09:52:03 -08:00
yuneng-jiangandGitHub 50612715a5 Merge pull request #19814 from BerriAI/litellm_team_member_add_fix
[Fix] /team/member_add User Email and ID Verifications
2026-01-27 09:49:01 -08:00
michelligabrieleandGitHub 388b4c90b6 fix(proxy): handle agent parameter in /interactions endpoint (#19866) 2026-01-27 09:34:58 -08:00
Sameer KankuteandGitHub 0214cb04cd Merge branch 'main' into litellm_oss_staging_01_26_2026 2026-01-27 17:00:58 +05:30
Sameer KankuteandGitHub adf6d7e1db Merge pull request #19692 from BerriAI/litellm_oss_staging_01_24_2026
Litellm oss staging 01 24 2026
2026-01-27 16:59:28 +05:30
yuneng-jiang b10f71d583 fixing breaking change: just user_id provided should upsert still 2026-01-26 18:10:51 -08:00
c442fcd922 CI/CD: Increase retries and stabilize litellm_mapped_tests_core (#19826)
* Fix PLR0915: Extract system message handling to reduce statement count

* fix mypy

* fix: add host_progress_callback parameter to mock_call_tool in test

The test_call_tool_without_broken_pipe_error was failing because the mock function did not accept the host_progress_callback keyword argument that the actual implementation passes to client.call_tool(). Updated the mock to accept this parameter to match the real implementation signature.

* fixing flaky tests around oidc and email

* Add documentation comment to test file

* add retry

* add dependency

* increase retry

---------

Co-authored-by: yuneng-jiang <yuneng.jiang@gmail.com>
2026-01-26 17:00:18 -08:00
mubashir1osmaniandGitHub 8908eff7b1 Fix(#19781): Unable to reset user max budget to unlimited
Fix(#19781): Unable to reset user max budget to unlimited
2026-01-26 18:37:49 -05:00
Ishaan JaffandGitHub cec1a3c858 [Feat] CLI Auth - Add configurable CLI JWT expiration via environment variable (#19780)
* fix: add CLI_JWT_EXPIRATION_HOURS

* docs: CLI_JWT_EXPIRATION_HOURS

* fix: get_cli_jwt_auth_token

* test_get_cli_jwt_auth_token_custom_expiration
2026-01-26 14:56:17 -08:00
yuneng-jiang f879b8b1cb fixing team member add 2026-01-26 14:35:35 -08:00
yuneng-jiang 4ee00cfda5 fix sso email case sensitivity 2026-01-26 10:33:57 -08:00
yogeshwaran10 228aff9b9f Fix user max budget reset to unlimited
- Added a Pydantic validator to convert empty string inputs for max_budget to None, preventing float parsing errors from the frontend.
- Modified the internal user update logic to explicitly allow max_budget to be None, ensuring the value isn't filtered out and can be reset to unlimited in the database.
- Added unit tests for validation and logic.

 Closes #19781
2026-01-26 23:30:36 +05:30
558f01e848 fix(proxy): use return value from CustomLogger.async_post_call_success_hook (#19670)
* fix(proxy): use return value from CustomLogger.async_post_call_success_hook

Previously the return value was ignored for CustomLogger callbacks,
preventing users from modifying responses. Now the return value is
captured and used to replace the response (if not None), consistent
with CustomGuardrail and streaming iterator hook behavior.

Fixes issue with custom_callbacks not being able to inject data into
LLM responses.

* fix(proxy): also fix async_post_call_streaming_hook to use return value

Previously the streaming hook only used return values that started with
"data: " (SSE format). Now any non-None return value is used, consistent
with async_post_call_success_hook and streaming iterator hook behavior.

Added tests for streaming hook transformation.

---------

Co-authored-by: Gabriele Michelli <michelligabriele0@gmail.com>
2026-01-26 08:48:22 -08:00
Tamir KivitiandGitHub aa8134fee9 add timeout to onyx guardrail (#19731)
* add timeout to onyx guardrail

* add tests
2026-01-25 23:13:46 -08:00
Jay PrajapatiandGitHub 582d324a76 fix(proxy): support slashes in google generateContent model names (#19737)
* fix(proxy): support slashes in google route params

* fix(proxy): extract google model ids with slashes

* test(proxy): cover google model ids with slashes
2026-01-25 22:59:50 -08:00
Harshit Jain 6df0406cf6 fix: args issue & refactor into helper function to reduce bloat for both(#19441) 2026-01-25 10:21:20 +05:30
Harshit JainandGitHub 05fdd099ba fix(presidio): resolve runtime error by handling asyncio loops in bac… (#19714)
* fix(presidio): resolve runtime error by handling asyncio loops in background threads

* add test case for thread safety
2026-01-24 15:36:49 -08:00
yuneng-jiangandGitHub 99e9462ec9 Merge pull request #19713 from BerriAI/litellm_model_search_id_team
[Feature] UI - Model Page: Filter by Model ID and Team ID
2026-01-24 15:04:20 -08:00
yuneng-jiang 47810f1523 Model and Team filtering 2026-01-24 14:45:14 -08:00
Ishaan Jaffer 31a4cb65bf test_get_default_unvicorn_init_args 2026-01-24 12:59:51 -08:00
yuneng-jiangandGitHub 5e395db1dc Merge pull request #19604 from BerriAI/litellm_team_update_org
[Fix] Team Update with Organization having All Proxy Models
2026-01-24 09:09:55 -08:00
yuneng-jiangandGitHub f88a32de05 Merge pull request #19622 from BerriAI/litellm_ui_model_backend
[Feature] UI - Models Page: Model Search
2026-01-24 09:09:03 -08:00
yuneng-jiang b44ac6c682 Fixing ruff check 2026-01-24 09:08:29 -08:00
Harshit JainandGitHub 09b07df587 fix: propagate JWT auth metadata to OTEL spans (#19627) 2026-01-23 21:21:23 -08:00
f43757f71b Feature/guardrail model argument (#19619)
* [Feat] Add model parameter to Generic Guardrail API

Add model information to guardrail requests, allowing guardrails to make
model-specific security decisions.

Changes:
- Add `model` field to GenericGuardrailAPIInputs TypedDict
- Add `model` field to GenericGuardrailAPIRequest Pydantic model
- Update OpenAI and Anthropic handlers to pass model from request/response
- Add unit tests for model parameter handling

* [Feat] Add model parameter to all guardrail_translation handlers

Extend model parameter support to all guardrail handlers for consistent
implementation across all endpoint types:
- OpenAI Responses API (input/output + streaming)
- OpenAI Image Generation (input only)
- OpenAI Text Completion (input/output)
- OpenAI Text-to-Speech (input only)
- OpenAI Audio Transcription (output only)
- Cohere Rerank (input only)
- Pass-through Endpoints (input/output)
- MCP Server (input only)

This addresses the review feedback requesting consistent model parameter
handling across all guardrail_translation/handler.py files.

---------

Co-authored-by: Igal Boxerman <igal@pillar.security>
2026-01-23 20:48:42 -08:00
John GreekandGitHub 4c5351f43b [Fix] Password comparison with non-ASCII characters (#19559) (#19568) 2026-01-23 20:27:42 -08:00
MishaandGitHub de538456e3 feat: support role_mappings from environment variables (#19498)
* feat: support role_mappings from environment variables

* fix linter
2026-01-23 19:54:23 -08:00
Ishaan JaffandGitHub a870722f65 [Feat] UI + Backend - Allow adding policies on Keys/Teams + Viewing on Info panels (#19688)
* ui for policy mgmt

* test_add_guardrails_from_policy_engine_accepts_dynamic_policies_and_pops_from_data
2026-01-23 19:03:44 -08:00
yuneng-jiang 8b5b343841 attempt fix flaky tests 2026-01-23 12:10:08 -08:00
xqe2011andGitHub ca8c2c3938 fix #19620: SSO user roles are not updated for existing users (#19621)
* Fix: SSO user roles are not updated for existing users
Fixes #19620

* Refactor: Remove redundant user_info retrieval in SSOAuthenticationHandler

* Test: add new tests for user creation and updates in get_user_info_from_db
2026-01-23 09:05:29 -08:00
Sameer KankuteandGitHub 9894721285 Merge pull request #19548 from BerriAI/litellm_staging_01_22_2026
Litellm staging 01 22 2026
2026-01-23 20:03:11 +05:30
Sameer KankuteandGitHub 12463809bd Merge pull request #19638 from BerriAI/main
merge main in stagin 1 22 26
2026-01-23 14:54:17 +05:30
Yuta Saito 695fbf4ec5 feat: hashicorp vault rotate support 2026-01-23 17:32:55 +09:00
yuneng-jiang 3ee7aab5f2 All Models Backend Search 2026-01-22 22:00:22 -08:00
Harshit JainandGitHub 69c8698e62 fix: pass through endpoints update registry (#19420)
* fix: pass through endpoints update registry

* add test case, fix lint error and comment to avoid confusion

* fix pass through endpoints test case
2026-01-22 19:57:48 -08:00
Ishaan JaffandGitHub c23e4b87dc [Feat] New LiteLLM Policy engine - create policies to manage guardrails, conditions - permissions per Key, Team (#19612)
* init PolicyMatcher

* TestPolicyMatcherGetMatchingPolicies

* TestPolicyMatcherGetMatchingPolicies

* feat: init PolicyResolver

* init resolver types

* init policy from config

* inint PolicyValidator

* validate policy

* init Architecture Diagram

* test_add_guardrails_from_policy_engine

* init _init_policy_engine

* test updates

* test fixws

* new attachment config

* simplify types

* TestPolicyResolverInheritance

* fix policy resolver

* fix policies

* fix applied policy

* docs fix

* docs fix

* fix linting + QA checks

* fix linting + QA fixes

* test fixes
2026-01-22 19:49:53 -08:00
yuneng-jiang f78fc4e0fe Fix org all proxy model case 2026-01-22 15:32:10 -08:00
Sameer KankuteandGitHub c78c878822 Merge pull request #19558 from BerriAI/litellm_gemini_vertexai_mapping
Add custom vertex ai mapping to the output
2026-01-22 19:44:32 +05:30
Sameer Kankute 991fee056f Fix batch tests 2026-01-22 19:23:32 +05:30
Sameer KankuteandGitHub ad1edd38d5 Merge branch 'main' into litellm_staging_01_21_2026 2026-01-22 17:56:40 +05:30
Emerson GomesandGitHub a3f7f5858b Fix date overflow/division by zero in proxy utils (#19527)
* Fix date overflow/division by zero in proxy utils

* Fix projected spend calculation

* Strengthen projected spend tests
2026-01-21 21:09:57 -08:00
davida-psandGitHub 7777aeb695 fixing prompt-security's guardrail implementation (#19374)
* Consolidated change

* fix(prompt_security): update message processing to persist sanitized files and filter for API calls

* fix per krrishdholakia suggestion
2026-01-21 20:09:40 -08:00
0e738a5027 fix(mcp): forward static_headers to MCP servers (#19341) (#19366)
Forward static_headers from /mcp-rest/test/* routes into the MCP client so headers are present during session.initialize() and tool discovery.

Also add a shared merge_mcp_headers() helper to keep header precedence consistent and ensure OpenAPI-to-MCP generated tools include static_headers.

Tests:
- pytest tests/test_litellm/proxy/_experimental/mcp_server/test_rest_endpoints.py
- pytest tests/test_litellm/proxy/_experimental/mcp_server/test_mcp_server_manager.py -k register_openapi_tools_includes_static_headers

Fixes #19341

Co-authored-by: Krish Dholakia <krrishdholakia@gmail.com>
2026-01-21 19:30:55 -08:00
Ishaan JaffandGitHub d5e912322f [Fix] VertexAI Pass through - Ensure only anthropic betas are forwarded down to LLM API (#19542)
* fix ALLOWED_VERTEX_AI_PASSTHROUGH_HEADERS

* test_vertex_passthrough_forwards_anthropic_beta_header

* fix test_vertex_passthrough_forwards_anthropic_beta_header

* test_vertex_passthrough_does_not_forward_litellm_auth_token

* fix utils

* Using Anthropic Beta Features on Vertex AI

* test_forward_headers_from_request_x_pass_prefix
2026-01-21 19:12:04 -08:00
yuneng-jiangandGitHub 6b6785bc4f Merge pull request #19539 from BerriAI/litellm_models_scope
[Feature] Adding Optional scope Param to /models
2026-01-21 17:41:22 -08:00
yuneng-jiangandGitHub c6b157832b Merge pull request #19296 from BerriAI/litellm_esca_reissue
[Reissue: Fix] /user/new Privilege Escalation
2026-01-21 16:46:34 -08:00
yuneng-jiang 6723b30d03 Adding scope to /models 2026-01-21 16:40:31 -08:00