Sriraj
8 years agoContributor
Can i generate a random number without using a data source and have it passed in the rest request?
I need to generate random numbers which needs to be sent for a field call "ID" and there can be multiple occurrences of this field and thus i want to generate a random number for these tags where ever ID is present of a specified length .
Some thing like below is what i want to put where ever field ID is present.
"id": %STR(6,6,True,false,false,false),
"brand": "e-commerce",
"channel": "online",
I see that it does not work when i tried and i do not want to use Data Source . Any alternate options?
While i different options , i found a way to do this and is as below.
${=org.apache.commons.lang.RandomStringUtils.randomNumeric(5)}
Number 5 represents the length for the number.