Skip to content

视频上传

https://chat-go.jwzhd.com/open-apis/v1/video/upload?token=xxxxxxxxxx

POST

curl --location 'https://chat-go.jwzhd.com/open-apis/v1/video/upload?token=xxxxxxxxxx' \
--form 'video=@"D:\\video\\aaa\\bbb.mp4"'
Content-Type: "multipart/form-data;"
字段类型是否必填说明
videofile视频内容,仅限单个视频,上传视频大小不超过 20MB
字段类型说明
codeint响应代码
msgstring响应信息,包括异常信息
dataObject返回数据
{
"code": 1,
"data": {
"videoKey": "xxxxxxxxxxxx"
},
"msg": "success"
}
import requests
url = "https://chat-go.jwzhd.com/open-apis/v1/video/upload?token=xxxxxx"
files=[
('video',open('6bca4389875743205502a57bb90fcad0.mp4','rb'))
]
response = requests.request("POST", url, files=files)
print(response.text)