fastapi上传文件之File,UploadFile

File类  上传单个文件

from fastapi import File
from typing import List


@app04.post('single_file')
async def single_file(file: bytes = File(...))
      return {'filesize': len(file)}

# 筛选多条简历 List[bytes] = File(...)

 

posted @ 2021-05-28 18:00  苦行僧冬*婷  阅读(1665)  评论(0)    收藏  举报