In the paw, first configure the request for the login page. Then, in the second request, you can define the response body of the first request: we can use the regular expression filter on the raw response of another request.
create custom dynamic value:

then use the code below to set a custom dynamic value.
function evaluate(context){
var re = /<h2>([^<]+)<\/h2>/;
var request = context.getRequestByName('Login page')
var lastExchange = request.getLastExchange()
var body = lastExchange.responseBody
var m = re.exec(body)
return m[1]
};
Hide result