Skip to content

[Docs] Add missing MCP per-user token env vars to config_settings#25471

Merged
yuneng-berri merged 1 commit intomainfrom
litellm_doc_mcp_per_user_token_env_vars
Apr 10, 2026
Merged

[Docs] Add missing MCP per-user token env vars to config_settings#25471
yuneng-berri merged 1 commit intomainfrom
litellm_doc_mcp_per_user_token_env_vars

Conversation

@yuneng-berri
Copy link
Copy Markdown
Collaborator

Summary

MCP_PER_USER_TOKEN_DEFAULT_TTL and MCP_PER_USER_TOKEN_EXPIRY_BUFFER_SECONDS were introduced in #25441 but not added to the environment variables reference doc, causing test_env_keys.py to fail on all PRs branched from main after that merge.

Changes

Added both env vars to the environment variables - Reference table in docs/my-website/docs/proxy/config_settings.md, grouped with the existing MCP OAuth entries.

Testing

Ran poetry run python ./tests/documentation_tests/test_env_keys.py locally — passes.

Type

📖 Documentation

MCP_PER_USER_TOKEN_DEFAULT_TTL and MCP_PER_USER_TOKEN_EXPIRY_BUFFER_SECONDS
were added in #25441 but not documented, causing test_env_keys.py to fail.
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 10, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
litellm Ready Ready Preview, Comment Apr 10, 2026 4:06am

Request Review

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented Apr 10, 2026

Greptile Summary

This PR adds two missing environment variables (MCP_PER_USER_TOKEN_DEFAULT_TTL and MCP_PER_USER_TOKEN_EXPIRY_BUFFER_SECONDS) to the proxy config settings reference docs, fixing a test_env_keys.py regression introduced when they were implemented in #25441 without a corresponding docs entry. The documented defaults (43200 and 60) accurately match the values in litellm/constants.py.

Confidence Score: 5/5

Safe to merge — documentation-only fix with accurate defaults, unblocks CI on dependent PRs.

The change is two documentation lines with values verified against the source constants. No logic, security, or schema concerns.

No files require special attention.

Important Files Changed

Filename Overview
docs/my-website/docs/proxy/config_settings.md Added two MCP per-user token env var entries with correct defaults, grouped logically with existing MCP OAuth settings.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[MCP Per-User OAuth Token Request] --> B{expires_in present?}
    B -- Yes --> C[TTL = expires_in - MCP_PER_USER_TOKEN_EXPIRY_BUFFER_SECONDS\ndefault buffer: 60s]
    B -- No --> D[TTL = MCP_PER_USER_TOKEN_DEFAULT_TTL\ndefault: 43200s / 12 hours]
    C --> E[Store token in Redis with computed TTL]
    D --> E
Loading

Reviews (1): Last reviewed commit: "[Docs] Add missing MCP per-user token en..." | Re-trigger Greptile

@codspeed-hq
Copy link
Copy Markdown
Contributor

codspeed-hq Bot commented Apr 10, 2026

Merging this PR will not alter performance

✅ 16 untouched benchmarks


Comparing litellm_doc_mcp_per_user_token_env_vars (ce0b57b) with main (aa0fa10)

Open in CodSpeed

@ishaan-berri ishaan-berri self-requested a review April 10, 2026 04:10
@yuneng-berri yuneng-berri merged commit 42e5583 into main Apr 10, 2026
94 of 105 checks passed
@yuneng-berri yuneng-berri deleted the litellm_doc_mcp_per_user_token_env_vars branch April 10, 2026 04:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants