mirror of
https://github.com/tiennm99/litellm.git
synced 2026-07-15 22:22:12 +00:00
Add new /public/endpoints endpoint that returns which providers support each LiteLLM endpoint (e.g., chat_completions, embeddings). The endpoint reads from a local backup JSON file bundled with the package, caches the result in-process, and transforms the raw provider-centric data into an endpoint-centric response format. Changes: - Add litellm/provider_endpoints_support_backup.json (copy of root source file) - Add Pydantic response models (EndpointProvider, SupportedEndpoint, SupportedEndpointsResponse) - Add /public/endpoints route with transformation and caching logic - Add 16 comprehensive tests covering HTTP layer and transformation functions Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Testing for litellm/
This directory 1:1 maps the the litellm/ directory, and can only contain mocked tests.
The point of this is to:
- Increase test coverage of
litellm/ - Make it easy for contributors to add tests for the
litellm/package and easily run tests without needing LLM API keys.
File name conventions
litellm/proxy/test_caching_routes.pymaps tolitellm/proxy/caching_routes.pytest_<filename>.pymaps tolitellm/<filename>.py