Cosmin
Cosmin

Reputation: 2404

Send both parameters and Body data with JMeter HTTP request

I need to send POST requests to an API server for which I need to send the following information: Server:

Methods:

Parameters:

Headers:

Body data: {

}

The thing is that I can't send them both, both the parameters for the API server and the body data, and one with the other doesn't work.

As a workaround to make it happen, I used in my HTTP Request for the path the url with parameters, like this:

Server name or IP: exampleapiserver.com

Path: /method1?apikey=apiserverkey&env=test

and in the body data I've put the actual body data.

Can this be achieved in a different way, not to be forced to use the parameters in the URL so that I can send the body data too?

Upvotes: 7

Views: 9914

Answers (1)

UBIK LOAD PACK
UBIK LOAD PACK

Reputation: 34556

The way you did it is ok. As of jmeter 2.13 there is no other way to do it.

Upvotes: 4

Related Questions