'Jmeter HTTP Request sample and SkipToken
I am using HTTP request sampler for API performance testing. My APIs might return a response containing the skiptoken If response contains the skiptoken, I need to call the API again using the skip token and capture the performance metrics. I required calling the API until there are no skiptoken available in the response. Please let me know how I can implement this in JMeter
Solution 1:[1]
You can add a Post-Processor, for example JSON Extractor, which will extract the skpitoken into a JMeter Variable from the API response.
If the variable is defined you can add If Controller and send another request to the API with the variable from the previous step.
Something like this:
Solution 2:[2]
You have to use any of the Post processor according to your API response content. e.g, Json extractor, Regex extractor, Boundary based extractor, whichever suits well.
Then you need to use While Controller instead of If controller. The While controller it will keep executing the API inside it, until the last skiptoken gets retrieved/ not found - refer the screenshot
If you use If controller - It will execute only once and proceed with other APIs
Since, I don't know the exact response body structure - you can use Regex to fetch the value, something like the below
"@odata.nextLink":"([^ ]+)"
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 |
| Solution 2 |



