Skip to content

Conversation

@yuneng-jiang
Copy link
Collaborator

@yuneng-jiang yuneng-jiang commented Nov 18, 2025

[Fix] Make /litellm_model_cost_map public

Relevant issues

There was no reason to keep /get/litellm_model_cost_map a proxy admin only route. All the data displayed is public information. I moved this route to /public/litellm_model_cost_map

Pre-Submission checklist

Please complete all items before asking a LiteLLM maintainer to review your PR

  • I have Added testing in the tests/litellm/ directory, Adding at least 1 test is a hard requirement - see details
  • I have added a screenshot of my new test passing locally
  • My PR passes all unit tests on make test-unit
  • My PR's scope is as isolated as possible, it only solves 1 specific problem

Type

🐛 Bug Fix
✅ Test

Changes

image image image image

@vercel
Copy link

vercel bot commented Nov 18, 2025

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

Project Deployment Preview Comments Updated (UTC)
litellm Ready Ready Preview Comment Dec 7, 2025 4:02am

"""
Return a mapping of model names to their litellm_provider and mode.
This is a public endpoint that provides the same structure as /get/litellm_model_cost_map
but without cost information, making it accessible to non-admin users.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a reason to hide the cost information?

My understanding of /get/litellm_model_cost_map is that it's just our publicly available cost info being returned, so why not just make it a public route?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cc: @ishaan-jaff am i missing something?

@yuneng-jiang yuneng-jiang changed the title [Fix] Expose new model provider map endpoint and use in add model workflow [Fix] Make /litellm_model_cost_map public Nov 22, 2025
@yuneng-jiang yuneng-jiang merged commit f9a4ba3 into main Dec 7, 2025
55 of 59 checks passed
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.

3 participants