Thanks all.
I was able to make it work by removing the "Content-Type" header and adding
MIME type as an application/binary.


On Tue, Apr 23, 2024 at 12:43 AM Dmitri T <[email protected]> wrote:

> Nuwan Mudalige wrote:
> > Hi,
> >
> > I have a file upload API call which is working fine on Postman.
> >
> > While I am recording that Postman request by Jmeter it is throwing  "415
> > Unsupported Media Type" error.
> >
> > I manually built a Jmeter test following the Postman but still failed
> with
> > the same issue.
> >
> > Appreciate your expertise support to resolve this issue.
> >
> > Thank you!
> >
> > - Nuwan
> >
> HTTP Status 415
> <https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/415> means
> that you're using wrong HTTP request method
> <https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods>, i.e. GET
> instead of POST or something like this.
>
> Given your test works in Postman you can record it using JMeter's
> HTTP(S) Test Script Recorder, at least this way there will be no mess
> with methods, parameters, etc. If you're uploading a file make sure to
> copy the file to "bin" folder of your JMeter installation prior to
> upload. See How to Convert Your Postman API Tests to JMeter for Scaling
> <https://www.blazemeter.com/blog/convert-postman-api-tests> for more
> information.
>
> You might need to correlate
> <
> https://jmeter.apache.org/usermanual/jmeter_proxy_step_by_step.html#correlate-start>
>
> any dynamic parameters as well.
>
>
>

Reply via email to