How to get cookie information as JSON
Cookie cookie1 = driver.manage().getCookieNamed("1P_JAR");
Map jsonObject = cookie1.toJson();
System.out.println(jsonObject.toString());
Posted on December 13, 2019
By Shah Nawaz
Cookie cookie1 = driver.manage().getCookieNamed("1P_JAR");
Map jsonObject = cookie1.toJson();
System.out.println(jsonObject.toString());
We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it. Privacy Policy
Accept