From e7e364eb0dfd65b5ca07f0ba49f411599d912eb8 Mon Sep 17 00:00:00 2001 From: Jordan Frazier <122494242+jordanrfrazier@users.noreply.github.com> Date: Tue, 19 Nov 2024 12:05:23 -0800 Subject: [PATCH] chore: add deprecation flag on base upload flow route (#4717) * add deprecation flag on base upload flow route * add deprecation flag on base upload flow route * [autofix.ci] apply automated fixes --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> --- src/backend/base/langflow/api/v1/endpoints.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/backend/base/langflow/api/v1/endpoints.py b/src/backend/base/langflow/api/v1/endpoints.py index 000618fb6..3514d23aa 100644 --- a/src/backend/base/langflow/api/v1/endpoints.py +++ b/src/backend/base/langflow/api/v1/endpoints.py @@ -544,11 +544,16 @@ async def get_task_status(task_id: str) -> TaskStatusResponse: @router.post( "/upload/{flow_id}", status_code=HTTPStatus.CREATED, + deprecated=True, ) async def create_upload_file( file: UploadFile, flow_id: UUID, ) -> UploadFileResponse: + """Upload a file for a specific flow (Deprecated). + + This endpoint is deprecated and will be removed in a future version. + """ try: flow_id_str = str(flow_id) file_path = save_uploaded_file(file, folder_name=flow_id_str)