I have a curl command that works
curl -F "file=@vid.mp4" https://servername/api/upload
I am not sure how to translate it into loadtest:
I have tried:
loadtest -n 1 -c 1 -m POST -p vid.mp4 https://servername/api/upload
or
loadtest -n 1 -c 1 -m POST -p vid.mp4 -T "multipart/form-data" https://servername/api/upload
But it results in an error.
INFO 400: 1 errors
From curl's man:
-F
For HTTP protocol family, this lets curl emulate a filled-in form in which a user has pressed the submit button.
This causes curl to POST data using the Content-Type multipart/form-data according to RFC 2388.
Example: send an image to an HTTP server, where 'profile' is the name of the form-field to which
the file portrait.jpg will be the input:
curl -F profile=@portrait.jpg https://example.com/upload.cgi
Hello,
I have a curl command that works
curl -F "file=@vid.mp4" https://servername/api/upload
I am not sure how to translate it into loadtest: I have tried:
But it results in an error.
INFO 400: 1 errors
From curl's man: