Skip to content

feat(ui): disclaim that the Update API Key modal only rotates api_key - #31805

Merged
ryan-crabbe-berri merged 3 commits into
litellm_internal_stagingfrom
litellm_api_key_modal_disclaimer
Jul 1, 2026
Merged

feat(ui): disclaim that the Update API Key modal only rotates api_key#31805
ryan-crabbe-berri merged 3 commits into
litellm_internal_stagingfrom
litellm_api_key_modal_disclaimer

Conversation

@ryan-crabbe-berri

Copy link
Copy Markdown
Contributor

Relevant issues

Follow-up to #28089

Linear ticket

Summary

The Update API Key modal added in #28089 always writes litellm_params.api_key, so it does not rotate the credential for models that authenticate a different way (Azure using azure_ad_token, Bedrock using AWS keys, Vertex using a service-account JSON). On those models the button is still shown, and pasting a new secret there writes a stray api_key that the provider ignores while the real credential is left unchanged. This adds a warning so users of those providers are not misled into thinking their secret was rotated

Broadening the modal to rotate the correct field per provider is the real fix and is left as a follow-up; this is just the honest interim disclaimer

Pre-Submission checklist

  • I have added meaningful tests
  • My PR passes all CI/CD checks (lint, format, unit tests)
  • My PR's scope is as isolated as possible; it only solves 1 specific problem
  • I have requested a Greptile review by commenting @greptileai and received a Confidence Score of at least 4/5 before requesting a maintainer review

Screenshots / Proof of Fix

Static antd warning Alert inside the modal. To see it: open the Admin UI at /ui/models-and-endpoints, open any DB model, click "Update API Key", and the warning renders above the New API Key field. No test added because it is a static informational element with no logic

Type

📖 Documentation

Changes

Adds a warning Alert to UpdateModelCredentialsModal noting that only api_key is rotated and that Azure AD token / AWS / Vertex JSON providers are not covered yet

An adversarial review of the credential-rotation work noted the modal always
writes litellm_params.api_key, so models that authenticate with an Azure AD
token, AWS credentials, or a Vertex service-account JSON are not rotated by it.
Adds a warning Alert to the modal so users are not misled into thinking those
secrets were rotated; broadening the modal to those providers is a follow-up
@greptile-apps

greptile-apps Bot commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR adds a static informational Alert to UpdateModelCredentialsModal to warn users that only litellm_params.api_key is written, leaving Azure AD token, AWS, and Vertex service-account JSON credentials unchanged.

  • Imports Alert from antd and places it between the existing description text and the form, giving non-api_key auth users an honest heads-up before submitting.
  • No logic is altered; the change is purely presentational and does not affect the PATCH call or any other component.

Confidence Score: 5/5

Safe to merge — only a static warning banner is added with no changes to logic, API calls, or data flow.

The change is a single informational UI element: an Ant Design Alert placed above the credential form. No logic, state, network calls, or component contracts are touched. The only minor tension is that the existing description text sounds more conclusive than the warning that immediately follows, but this is a cosmetic wording concern and does not affect functionality.

No files require special attention.

Important Files Changed

Filename Overview
ui/litellm-dashboard/src/components/update_model_credentials_modal.tsx Adds an Ant Design Alert warning above the API key field to notify users that Azure AD token, AWS, and Vertex service-account JSON auth are not covered by this rotation modal.

Reviews (1): Last reviewed commit: "feat(ui): disclaim that the Update API K..." | Re-trigger Greptile

…odal.tsx

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

codecov Bot commented Jul 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@ryan-crabbe-berri
ryan-crabbe-berri merged commit 3e0bd71 into litellm_internal_staging Jul 1, 2026
122 checks passed
@ryan-crabbe-berri
ryan-crabbe-berri deleted the litellm_api_key_modal_disclaimer branch July 1, 2026 17:25
duanhongyi pushed a commit to duanhongyi/litellm that referenced this pull request Jul 2, 2026
…BerriAI#31805)

* feat(ui): disclaim that the Update API Key modal only rotates api_key

An adversarial review of the credential-rotation work noted the modal always
writes litellm_params.api_key, so models that authenticate with an Azure AD
token, AWS credentials, or a Vertex service-account JSON are not rotated by it.
Adds a warning Alert to the modal so users are not misled into thinking those
secrets were rotated; broadening the modal to those providers is a follow-up

* Update ui/litellm-dashboard/src/components/update_model_credentials_modal.tsx

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

* style(ui): prettier-format the credential modal

---------

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