this is my code:
params = {
"zipFile":"123456.zip",
"projectName" : "test"
}
dispatch = r.post("http://biqatest.baidu.com/dispatch/project/upload",files = params)
As you can see,it's a post request.
but the reponse is:
405
>Request method 'GET' not supported
It's so strange,why?
file = {'file': open('yourzipfile.zip', 'rb')}
data = {'projectName': 'test'}
dispatch = r.post("http://biqatest.baidu.com/dispatch/project/upload",files=file, data=data)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.