'JMeter gives me bad request once I run the thread

it seems to be jmeter doesn't see the parameter required even I wrote them. I tried a lot of versions and still the samee. It works fine using postman (curl)



Solution 1:[1]

Most probably it's not JMeter who "gives" you bad request, it's the system under test tells you that request is malformed via HTTP Status Code 400

There is only one version which will "work" but we cannot tell you which one unless you're willing to share the "working" request details from curl and/or postman.

If you can run the request successfully using curl or Postman you can:

  1. Create a test plan from Curl command

  2. Record curl command execution via JMeter's HTTP(S) Test Script Recorder by running your curl request via JMeter's proxy:

    curl -k -x http://localhost:8888 your-request-parameters http://your-server-endpoint
    
  3. Record Postman request execution via JMeter's HTTP(S) Test Script Recorder

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Dmitri T