Selenium brave automation: How do you scroll down a js script generated page and save the HAR file?

Chromium based browser’s HAR log et download utility is very useful and accessing it via Selenium automation makes it even better, but a search on:

“import” ChromeOptions setBinary HAR

would give you only 3 useless results
Automating Chromium through Selenium takes:

  1. downloading the latest “” (or whichever you need corresponding to the chromium-based browser you will be automating)
  2. System.set(ting)Property(“”, “<local path to wherever you have the §1>”)
  3. downloading the corresponding chromium-based browser binaries specified for webdriver in §1
  4. ChromeOptions ChrmOps = new ChromeOptions().set(ting)Binary(“<local path to wherever you have the §3>”);

which basically becomes and just 4 lines of set up code:

System.setProperty(“”, “<local path to wherever you have the §1>”);
ChromeOptions ChrmOps = new ChromeOptions();
ChrmOps.setBinary(“<local path to wherever you have the §3>”);
WebDriver WbDrvr = new ChromeDriver(ChrmOps);

Use for example that page:“Mehrwert” OR “Surplus Value”) AND (“Petty” OR “Ricardo” OR “Smith” OR “Marx” OR “Sraffa”)

How would you then set the networking logs, scroll down the js generated page and save the HAR file using automation?

Any suggestions, books, links, … as to how you could achieve such a feast?


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.