Currently, I am dealing with a token that is being returned in the body of a web page.
WDS.browser.findElement(org.openqa.selenium.By.xpath("//*[contains(@name,'RequestVerificationToken')]")).getText();
This token is what I need to extract:
My goal is to pass this variable out of the selenium webdriver and share it across all threads.
Typically, when working with regular pages, I use a regular expression extractor as a post processor to set it to a variable for correlation. However, in this scenario, I am uncertain about the approach.
How can I transform this into a global variable in JS?