From 294aa8628cac03b8540da345e91c156eb9363877 Mon Sep 17 00:00:00 2001 From: harish876 Date: Wed, 8 Apr 2026 00:55:52 +0000 Subject: [PATCH] fix: backwards compatibility for files endpoint --- .../proxy/openai_files_endpoints/files_endpoints.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/litellm/proxy/openai_files_endpoints/files_endpoints.py b/litellm/proxy/openai_files_endpoints/files_endpoints.py index 14e7da9560c..b37ed8bdb49 100644 --- a/litellm/proxy/openai_files_endpoints/files_endpoints.py +++ b/litellm/proxy/openai_files_endpoints/files_endpoints.py @@ -577,11 +577,6 @@ async def create_file( # noqa: PLR0915 dependencies=[Depends(user_api_key_auth)], tags=["files"], ) -# @router.get( -# "/files/{file_id:path}/content", -# dependencies=[Depends(user_api_key_auth)], -# tags=["files"], -# ) async def get_file_content( # noqa: PLR0915 request: Request, fastapi_response: Response, @@ -835,6 +830,11 @@ async def get_file_content( # noqa: PLR0915 dependencies=[Depends(user_api_key_auth)], tags=["files"], ) +@router.get( + "/files/{file_id:path}/content", + dependencies=[Depends(user_api_key_auth)], + tags=["files"], +) async def get_file_content_streaming( request: Request, fastapi_response: Response,