Commit Graph
34849 Commits
Author SHA1 Message Date
Shivam RawatandGitHub cf331c4fc5 Merge pull request #23295 from BerriAI/revert-23287-docs_flow_builder
Revert "policy builder"
2026-03-10 15:39:10 -07:00
Shivam RawatandGitHub a71ba39b78 Revert "policy builder" 2026-03-10 15:38:59 -07:00
Cesar GarciaandGitHub 3bf91ed9fe Merge pull request #23258 from Chesars/docs/openai-tool-search
docs(responses): add tool_search & namespaces docs for gpt-5.4
2026-03-10 18:51:16 -03:00
Chesars e7a9c1e156 docs(responses): remove unused json import from tool search example 2026-03-10 18:41:54 -03:00
Ishaan JaffandGitHub 3b80b312a9 feat(ui): show tools per MCP server in chat panel (#23294)
- fix transport display: use handleTransport() instead of hardcoding HTTP/stdio based on server_url presence
- show available tools list when clicking into a server detail view
- preload tool counts per server card in parallel (one request per server, counts pop in independently)
- add skeleton loading indicator on each card while its tool count is fetching
- fix: pass server UUID (not name) to /mcp-rest/tools/list — name was always hitting access_denied
2026-03-10 14:40:28 -07:00
Ishaan JaffandGitHub 6faad2919a feat(chat-ui): add MCP OAuth2 value prop and server auth badges (#23291)
* feat(chat-ui): add MCP OAuth2 value prop and OAuth2 pill on server cards

- Add subtitle in chat empty state explaining MCP OAuth2 value prop with 'Open Apps' link
- Update MCPAppsPanel header copy to explain the flow more clearly
- Show OAuth2 pill badge on server cards where auth_type is oauth2

* fix(chat-ui): use AUTH_TYPE.OAUTH2 constant instead of hardcoded string
2026-03-10 14:37:32 -07:00
Cesar GarciaandGitHub 375b7665ad Merge pull request #23275 from Chesars/fix/add-gpt-5.3-model-entry
feat(openai): add missing supports_web_search to OpenAI models
2026-03-10 18:00:59 -03:00
Ishaan JaffandGitHub 8c12781487 feat(ui): OpenAPI MCP server support with popular API quick-picker (#23200)
* fix: guard prisma import in config_override_endpoints to fix proxy import without prisma

Top-level `from prisma.errors import RecordNotFoundError` was introduced in the
Hashicorp Vault feature PR and breaks `import litellm.proxy.proxy_server` when
prisma is not installed (e.g. plain `pip install litellm[proxy]` in CI).

Wraps the import in try/except ImportError so the module loads cleanly when
prisma is absent; the except branch aliases RecordNotFoundError to Exception,
which is safe because the code path that catches it only logs a debug message.

* fix: sync poetry.lock with pyproject.toml (litellm-proxy-extras 0.4.51 → 0.4.52)

poetry.lock was regenerated for 0.4.51 but pyproject.toml was subsequently
bumped to 0.4.52 without re-running poetry lock. This caused the
proxy_e2e_azure_batches_tests CI job to fail at the Install Dependencies step
('pyproject.toml changed significantly since poetry.lock was last generated'),
preventing all 3 tests in that job from running.

* Revert "fix: sync poetry.lock with pyproject.toml (litellm-proxy-extras 0.4.51 → 0.4.52)"

This reverts commit 249ec7c9c2.

* feat(ui): add OpenAPI MCP server support with popular API quick-picker

- New `openapi_registry.json` with 10 well-known APIs (GitHub, Atlassian, Figma, Google, Stripe, HubSpot, Notion, Slack, Shopify, Snowflake) — each with validated spec URLs and OAuth 2.0 endpoints
- Backend endpoint `GET /v1/mcp/registry.json` to serve the registry (reads fresh from disk)
- `OpenAPIQuickPicker` component: logo grid for popular APIs with letter fallback for broken images
- `OpenAPIFormSection` component: encapsulates picker + spec URL input as a clean unit
- When selecting a preset, spec URL and OAuth fields are pre-filled automatically
- Fixed `useTestMCPConnection`: for OpenAPI transport, tools load from the spec as soon as the URL is set — no auth type or OAuth token required
- Validated all spec URLs are reachable; removed Linear (GraphQL-only, no REST spec)

* feat(ui): add curated key tools preview for OpenAPI MCP servers

When selecting a popular API from the quick-picker, show the 8 most
useful MCP tools for that API in a collapsible preview card. First 4
are shown by default; clicking "expand" shows all 8 with descriptions
on hover.

- Added `key_tools` array (8 tools each) to all 10 APIs in openapi_registry.json
- New `KeyToolsPreview` component in OpenAPIFormSection with expand/collapse
- Extended `OpenAPIRegistryEntry` type with `key_tools?: OpenAPIKeyTool[]`

* fix(ui): move key tools preview inside Tool Configuration card

* fix(ui): pin suggested tools at top of tool list, fix TDZ crash, add per-section enable/disable

* fix: address greptile review - fix registry spec URLs, remove redundant dep, add error handling

* fix: restore enable/disable all buttons for non-preset MCP servers

* refactor: extract ToolRow component, move handlers to component body, fix key props

* fix: remove rewrites() from next.config.mjs (incompatible with output: export), fix OAuth field paths

* fix: enable/disable all operates on full tool set, not just filtered subset

* fix: cache openapi registry, make oauth optional, reset preset auto-select on new preset

* fix: use official Shopify API specs repo, move lru_cache error handling to caller

* fix: use Shopify 2023-10 REST spec, co-locate rest section header with tool rows

* fix: guard fuzzy-match against empty keywords, remove placeholder OAuth URLs for Shopify/Snowflake

* fix: lift useTestMCPConnection to parent to eliminate duplicate requests, clear keyTools on manual spec URL edit

* fix: clear stale OAuth fields when switching to non-OAuth preset, show expected tools on empty spec

* fix: gate registry fetch on modal visibility, use resetFields to clear OAuth fields
2026-03-10 13:59:52 -07:00
Ishaan JaffandGitHub 373e5e316b feat(mcp): BYOM — non-admin MCP server submission + admin review workflow (#23205)
* feat(mcp): add BYOM (Bring Your Own MCPs) submission + admin review workflow

Non-admins can now submit MCP servers for review via POST /v1/mcp/server/register.
Admins get a Submissions tab in the UI to approve or reject pending servers.
Approved servers enter the active runtime; rejected ones stay out with notes.

- DB: add approval_status, submitted_by, submitted_at, reviewed_at, review_notes
  to LiteLLM_MCPServerTable with migration
- Backend: new endpoints register, submissions, approve, reject
- reload_servers_from_database now only loads approval_status=active servers
- UI: Submissions tab with stat cards, card list, confirm dialogs; non-admin
  "Submit MCP Server" button wired to /register endpoint
- Fix get_mcp_submissions to filter by submitted_at IS NOT NULL (not submitted_by,
  which can be null for team-scoped keys without an associated user)

* feat(mcp): rename nav item to Team MCPs + add New badge

* fix(mcp): revert nav label, rename Submissions tab to Team MCPs + New badge

* feat(mcp): add MCP Standards — required fields config + CI-style checks on submissions

Adds a "Standards" tab (admin-only) to MCP Servers where admins define which
server fields are required for a submission to pass. Each submission card in
Team MCPs then shows a green ✓ or red ✗ for each required field, with a
summary "N/M checks" badge in the header — like GitHub CI status rows.

Also adds a `source_url` field (GitHub / Source URL) to the MCP server schema
so non-admins can link to the source repo when submitting a server.

- schema.prisma: add `source_url String?` to LiteLLM_MCPServerTable
- migration: 20260309000001_add_mcp_source_url
- _types.py: source_url on NewMCPServerRequest, UpdateMCPServerRequest, LiteLLM_MCPServerTable
- types.tsx: source_url on MCPServer interface
- create_mcp_server.tsx: GitHub/Source URL form field
- MCPStandardsSettings.tsx: new — toggle which fields are required (stored in general settings as mcp_required_fields)
- mcp_servers.tsx: Standards tab (admin-only)
- MCPSubmissionsTab.tsx: load required fields + CI-style check pills on each card

* refactor(mcp): move submission rules into Team MCPs tab, grouped free-form UI

Folds the Standards tab into Team MCPs. Submission Rules panel now lives at the
top of the Team MCPs tab — collapsible, shows active rules as chips when closed,
expands to a grouped checkbox editor (Documentation / Source / Connection /
Security). Removes the separate Standards tab from the nav.

MCPStandardsSettings.tsx is now constants-only (FIELD_GROUPS, MCP_REQUIRED_FIELD_DEFS,
SETTINGS_KEY) — the UI lives in MCPSubmissionsTab.

* feat(mcp): add mcp_required_fields to ConfigGeneralSettings + config/list endpoint

Registers mcp_required_fields as a proper general_settings field so the UI
can read/write it via /config/list and /config/field/update without the
"Invalid field" error. Also fixes a pre-existing pyright None-check issue
in _sync_ui_settings_to_general_settings.

* ui(mcp): GitHub-style PR checks panel on submission cards

* ui: rename Team MCPs -> Submitted Tools, Team Guardrails -> Submitted Guardrails

* address greptile review feedback (greploop iteration 1)

* fix: inline import, add approval workflow tests, rename Submitted MCPs

* fix(mcp): allow re-approval of rejected MCP server submissions

* fix(mcp): evict rejected servers from runtime; enforce mcp_required_fields on /register

* fix(mcp): sort submissions newest-first; force active status on admin-created servers

* fix(mcp): add missing mock in test, show Approve for rejected, clear submission metadata, drop spurious Content-Type

* fix(mcp/ui): show Reject for active servers; show submit form to non-admins with team-key note

* fix(mcp): conditional reload on reject; view-only admin for submissions; block admin from /register

* fix(mcp): match auth_type required-field validation to UI compliance check (reject 'none')

* fix(mcp): block view-only admin from /register; log settings failure; warn on active server reject

* fix(mcp): allow view-only admin to use /register; add _validate_mcp_required_fields tests

* fix(mcp): validate field names in mcp_required_fields; surface backend error in submit UI

* fix(mcp): fix falsy field check; add field-name validation; add take limit; document server-managed fields; close dialog on error
2026-03-10 13:58:59 -07:00
Cesar GarciaandGitHub 6a3b029066 Merge pull request #23271 from Chesars/docs/gpt54-reasoning-tools-limitation
docs(openai): document gpt-5.4 reasoning_effort + tools limitation
2026-03-10 17:57:31 -03:00
milan-berriGitHubgreptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
9100e16776 docs: pip venv upgrade workflow (#23290)
* docs: add pip/venv upgrade workflow guide

- Add comprehensive guide for upgrading LiteLLM proxy via pip
- Covers Prisma client regeneration and DB migration steps
- Includes verification commands and troubleshooting tips
- Links to existing Prisma migration troubleshooting doc

* docs: clarify Python version in prisma generate command

- Update example to show multiple Python versions (3.11, 3.12, 3.13)
- Make it clear LiteLLM supports multiple Python versions, not just 3.11

* docs: emphasize venv activation before running commands

- Add info box at top reminding users to activate venv
- Include venv activation step before starting proxy (both options)
- Add Windows activation command for cross-platform clarity
- Make it clear all commands assume activated venv

* docs: add pip_venv_upgrade to sidebar navigation

- Add new page to Troubleshooting section in sidebars.js
- Positioned after Performance/Latency category and before rollback
- Makes the upgrade guide discoverable through docs navigation

* docs: show explicit --schema flag in prisma migrate deploy

- Add explicit --schema path to Option B migration command
- Remove ambiguous instruction about running from litellm_proxy_extras
- Include path variable guidance for clarity
- Makes the command immediately runnable without directory navigation

* Update docs/my-website/docs/troubleshoot/pip_venv_upgrade.md

Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>

* Update docs/my-website/docs/troubleshoot/pip_venv_upgrade.md

Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>

* fix: close code block and add missing section in pip_venv_upgrade.md

* docs: define schema-path placeholder in verification section

---------

Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-03-10 13:53:54 -07:00
Chesars e88dc2e428 feat(openai): add supports_web_search to o4-mini models
Tested and confirmed both o4-mini and o4-mini-2025-04-16 support
web_search_preview via the Responses API.
2026-03-10 17:49:39 -03:00
Shivam RawatandGitHub 97c92cc84e Merge pull request #23287 from BerriAI/docs_flow_builder
policy builder
2026-03-10 13:44:18 -07:00
Shivam RawatGitHubgreptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
592232e835 Update docs/my-website/docs/proxy/guardrails/guardrail_pipeline_flow_builder.md
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-03-10 13:42:46 -07:00
Shivam RawatGitHubgreptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
f3844d8356 Update docs/my-website/docs/proxy/guardrails/guardrail_pipeline_flow_builder.md
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-03-10 13:42:36 -07:00
Chesars effaef3cfb fix: remove duplicate supports_web_search keys
7 models already had supports_web_search from upstream, causing
duplicate JSON keys. Re-serialized to remove duplicates.
2026-03-10 16:49:45 -03:00
Chesars 7a0c8af458 merge: resolve conflicts with upstream/main
Keep both: supports_web_search additions and upstream's
supports_none_reasoning_effort / supports_xhigh_reasoning_effort fields.
2026-03-10 16:42:28 -03:00
Chesars 6bc4cc8f0f feat(openai): add supports_web_search to OpenAI models with Responses API
Add `supports_web_search: true` to 31 OpenAI models that support the
`web_search_preview` tool via the Responses API. This enables the Router
to correctly include these deployments when requests use web search tools.

Models excluded (tested, confirmed unsupported):
- o1-pro (Tool 'web_search_preview' is not supported)
- gpt-audio / gpt-audio-mini (not supported)
- gpt-4.1-nano (not supported)
- codex-mini-latest (model not found)

Also removes the invalid `gpt-5.3` entry added in prior commit
(model name does not exist in OpenAI API; use gpt-5.3-chat-latest).
2026-03-10 16:28:50 -03:00
shivam fa330ed96b policy builder 2026-03-10 12:09:00 -07:00
Chesars af297dc082 fix(openai): clean up gpt-5.3 model entry fields
- Remove dead fields: supports_none_reasoning_effort, supports_xhigh_reasoning_effort
  (not referenced anywhere in the codebase)
- Remove supports_web_search (inconsistent with other base models)
- Add supports_service_tier (consistent with gpt-5, gpt-5.1, gpt-5.2)
2026-03-10 16:04:31 -03:00
ffc89e4ef6 fix(mcp): add AWS SigV4 auth for Bedrock AgentCore MCP servers (#22782)
* fix(mcp): add AWS SigV4 auth for Bedrock AgentCore MCP servers

Add aws_sigv4 auth type to MCP client via httpx.Auth subclass that
signs each request with SigV4 using botocore. Enables mcp_servers
config to connect to AgentCore-hosted MCP servers.

* docs(mcp): add AWS SigV4 auth documentation for Bedrock AgentCore

Add dedicated docs page for configuring MCP servers with AWS SigV4
authentication, update MCP overview with aws_sigv4 auth type and
config example, and link from Bedrock AgentCore provider docs.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix(mcp): address Greptile review — requires_request_body, full header signing, health check

- Add requires_request_body = True to MCPSigV4Auth so httpx buffers the
  request body before calling auth_flow (prevents empty body hash for
  streaming requests)
- Pass all request headers to AWSRequest for canonical SigV4 signing
  instead of only Content-Type
- Exclude aws_sigv4 from health check skip logic since it has its own
  credential fields (not authentication_token)
- Fix docs: mark aws_access_key_id/aws_secret_access_key as optional
  (falls back to boto3 credential chain)
- Add test for requires_request_body flag

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Krish Dholakia <krrishdholakia@gmail.com>
2026-03-10 11:11:20 -07:00
Ishaan JaffandGitHub 9543d785b5 fix(mcp): don't auto-detect M2M OAuth from field presence (#23187)
* fix(mcp): require explicit opt-in for OAuth2 M2M client_credentials flow

Auto-detecting M2M from client_id+secret+token_url presence broke existing
interactive OAuth setups (e.g. GitHub Enterprise). Add oauth2_flow field and
default has_client_credentials to False — M2M must be explicitly opted into
with oauth2_flow: client_credentials.

* test(mcp): add regression tests for oauth2_flow M2M opt-in behavior
2026-03-10 10:59:49 -07:00
mubashir1osmaniandGitHub 26febf11a7 Merge pull request #23202 from mubashir1osmani/fix/tag-usage-cost-panel-zero
fix: tag usage cost panel zero
2026-03-10 13:57:22 -04:00
mubashir1osmani 88d0f9d834 added comments 2026-03-10 13:56:15 -04:00
mubashir1osmaniandGitHub 6a59ec5ddf fix: anthropic prompt caching returns a string instead of an int
fix: anthropic prompt caching returns a string instead of an int
2026-03-10 13:51:17 -04:00
ryan-crabbeandGitHub 0a324663fb Merge pull request #23215 from BerriAI/litellm_migrate_user_buttons_tremor_to_antd
Migrate user management buttons from Tremor to Ant Design
2026-03-10 10:32:09 -07:00
yuneng-jiangandGitHub b02ecc7807 Merge pull request #23260 from milan-berri/feat/mcp-token-auth-support
feat(mcp): add token authentication support for MCP servers
2026-03-10 09:57:21 -07:00
Milan 4c9220bdec feat(mcp): add token authentication support for MCP servers
- Add 'token' to MCPAuth enum for custom token auth format
- Implement token auth in MCP client (_get_auth_headers)
- Add token auth support for OpenAPI-based MCP tools
- Add comprehensive unit tests to existing test_mcp_client.py
- Fixes issue where MCP servers expecting 'Authorization: token <value>' header could not connect
2026-03-10 18:33:08 +02:00
milan-berriandGitHub 336fb0cfeb fix(security): strip secret_fields from guardrail logging response (#23162)
When guardrails return the full data dict (e.g. guardrails_ai), the
guardrail response logged to spend logs and OTEL traces could contain
data["secret_fields"].raw_headers with plaintext Authorization headers.

This adds a pop("secret_fields") in the guardrail logging path,
matching the existing pattern used by Langfuse and Arize integrations.

Tested: Verified fix removes secret_fields/raw_headers/authorization
from both /spend/logs/ui responses and OTEL trace span attributes.
2026-03-10 08:58:18 -07:00
Harshit JainandGitHub 424a96580b Merge pull request #22627 from BerriAI/litellm_presidio_antropic_edge_case
fix: presidio edge case with antropic handle on pii token leak
2026-03-10 21:16:56 +05:30
Harshit JainandGitHub e1c2c36f67 Merge pull request #23259 from BerriAI/litellm_claude_missing_reqs
fix: claude code req traces on langfuse
2026-03-10 21:15:36 +05:30
Harshit JainandGitHub fdb0a46242 Merge pull request #23209 from BerriAI/litellm_silent_metrics
feat: record silent metrics
v1.82.1-silent-dev2
2026-03-10 21:14:09 +05:30
Harshit JainandGitHub a7e9bca103 Merge pull request #23214 from BerriAI/litellm_deployment_helm_chart
feat: add strategy to deployment for helmchart
2026-03-10 21:13:40 +05:30
Chesars 8c2c379cb5 fix(openai): add missing gpt-5.3 model entry
Fixes #23267 — plain `gpt-5.3` was missing from the model pricing
JSON, causing tool_choice (and other capability flags) to default
to unsupported. Copied fields from gpt-5.3-chat-latest.
2026-03-10 12:35:23 -03:00
Chesars d232d0de6c docs(openai): document gpt-5.4 reasoning_effort + tools limitation
Add tip boxes explaining that gpt-5.4 does not support reasoning_effort
with function tools in /v1/chat/completions, and that the responses
bridge (openai/responses/gpt-5.4) should be used instead.
2026-03-10 12:04:55 -03:00
Chesars 8fac04208d docs(responses): add tool_search bridge examples for chat completions
Add examples showing tool_search with namespaces via the chat
completions bridge (openai/responses/ prefix) for both SDK and proxy.
2026-03-10 10:27:40 -03:00
Harshit JainGitHubgreptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
17804edc78 Update litellm/utils.py
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-03-10 18:44:57 +05:30
Harshit JainGitHubgreptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
81bd62e8b0 Update litellm/utils.py
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
v1.82.1-dev
2026-03-10 18:39:40 +05:30
Harshit28j 558523fd75 fix: req changes by greptile 2026-03-10 18:33:17 +05:30
Harshit28j 8c3d6db482 fix: claude code req traces on langfuse 2026-03-10 18:21:42 +05:30
Chesars bec12db635 docs(responses): add tool_search & namespaces section for gpt-5.4
Add documentation for OpenAI's tool_search feature (Responses API)
with SDK and Proxy examples showing namespace-based deferred tool
loading. Closes #23206.
2026-03-10 09:50:08 -03:00
Sameer KankuteandGitHub a788b21092 Merge pull request #23243 from BerriAI/litellm_bedrock-completion-tokens-details
fix(bedrock): populate completion_tokens_details in Responses API
2026-03-10 18:19:28 +05:30
Sameer KankuteandGitHub cd80213f1c Merge pull request #23151 from BerriAI/litellm_preserve-reasoning-summary-for-responses-api
fix(openai): preserve reasoning_effort summary field for Responses API
2026-03-10 18:18:46 +05:30
Sameer KankuteandGitHub b3c4326845 Merge pull request #23131 from BerriAI/litellm_vertex_ai_extra_body_cache_fix
fix(vertex_ai): strip LiteLLM-internal keys from extra_body before merging to Gemini request
2026-03-10 18:17:29 +05:30
Sameer KankuteandGitHub 9bc7357e7c Merge pull request #23222 from BerriAI/litellm_oss_staging_02_18_2026
Litellm oss staging 02 18 2026
2026-03-10 17:46:06 +05:30
Sameer KankuteandGitHub b211b67cea Merge pull request #23164 from BerriAI/litellm_oss_staging_03_09_2026
oss staging 03/09/2026
2026-03-10 17:45:17 +05:30
Sameer KankuteandGitHub d0d1291c15 Merge pull request #22628 from BerriAI/litellm_oss_staging_03_02_2026
Litellm oss staging 03 02 2026
2026-03-10 17:40:31 +05:30
Sameer KankuteandGitHub 9bee76c30d Merge pull request #23253 from BerriAI/main
merge main
2026-03-10 17:25:01 +05:30
Sameer KankuteandGitHub 72fc2f77cf Merge pull request #23252 from BerriAI/main
merge main
2026-03-10 17:24:19 +05:30
Sameer KankuteandGitHub 3f17a63b81 Merge branch 'main' into litellm_oss_staging_03_02_2026 2026-03-10 17:19:37 +05:30