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>
This commit is contained in:
parent
fb83af224a
commit
e7e364eb0d
1 changed files with 5 additions and 0 deletions
|
|
@ -544,11 +544,16 @@ async def get_task_status(task_id: str) -> TaskStatusResponse:
|
||||||
@router.post(
|
@router.post(
|
||||||
"/upload/{flow_id}",
|
"/upload/{flow_id}",
|
||||||
status_code=HTTPStatus.CREATED,
|
status_code=HTTPStatus.CREATED,
|
||||||
|
deprecated=True,
|
||||||
)
|
)
|
||||||
async def create_upload_file(
|
async def create_upload_file(
|
||||||
file: UploadFile,
|
file: UploadFile,
|
||||||
flow_id: UUID,
|
flow_id: UUID,
|
||||||
) -> UploadFileResponse:
|
) -> UploadFileResponse:
|
||||||
|
"""Upload a file for a specific flow (Deprecated).
|
||||||
|
|
||||||
|
This endpoint is deprecated and will be removed in a future version.
|
||||||
|
"""
|
||||||
try:
|
try:
|
||||||
flow_id_str = str(flow_id)
|
flow_id_str = str(flow_id)
|
||||||
file_path = save_uploaded_file(file, folder_name=flow_id_str)
|
file_path = save_uploaded_file(file, folder_name=flow_id_str)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue