We have to run a script where we have to change the value for one of the field name on webpage, as a part of POST parameters section we are only having a single line e.g.
{"type":"EXP","name":"ValueName02","description":"DescName01","exportPassword":"Test@12340","criteria":{"version":1,"page":1,"resultsPerPage":1000}
(which was recorded during the recording of user path)
In the above line is there any way(s) so that we can update the value of only field at each iteration so that can make a unique request with each iteration.
Thanks in Advance.
You can create a variable in the variable manager of type current date, name it something like 'timeMillis', the format will be milliseconds from the format list, you can then just modify your payload to be...
{"type":"EXP","name":"ValueName${timeMillis}","description":"DescName01","exportPassword":"Test@12340","criteria":{"version":1,"page":1,"resultsPerPage":1000}
Why don’t you just put a timestamp in? Current date in milliseconds
@Neil W thanks for your response, could you please assist me more on how to pass the value of TimeStamp in the request as we are unable to pass any variable_name (which usually starts with $ sign) in the request.
If we are passing any variable using ${Var_name} it will just taking this as the value and the same is getting passed in the request.
Thanks in advance.
Thanks @Neil W,
I have made the changes as suggested by you but I am still getting the response code as 400 for the request, have attached the request and response for your reference.
Thanks in advance.
no attachments made it
added the attachment.