0

I need to measure the response times of an API query to different combinations of payloads.

While exploring multiple API testing tools I came across Jmeter. Which provides a CSV Data Set configuration.

Jmeter Configuration Screenshot

But what I need is selecting a random name of columns from a csv and put those is a query.

{
  "query": ["rcol1":val1, "rcol2":val2 ... ]
}

Is this achievable ?

1 Answer 1

1

You can build your request payload dynamically using JSR223 PreProcessor and Groovy language.

See JsonBuilder class documentation and Parsing and producing JSON article for more details.

If you want a code snippet you will need to provide:

  1. First 2-3 lines of your CSV file
  2. The desired payload format showing how data from CSV should be organized
Sign up to request clarification or add additional context in comments.

1 Comment

Here's the required data from points 1 & 2. pastes.io/mz8dyhsfis

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.