/AutomatedBrowser

A Swift package for interacting with selenium and undetected-chromedriver through python by using PythonKit.

Primary LanguageSwiftGNU General Public License v3.0GPL-3.0

AutomatedBrowser

A Swift package for interacting with selenium and undetected-chromedriver (a selenium chromedriver) through python by using PythonKit.

Target is macOS/Linux where you can install python, Chrome, and the required python dependencies.

How to use

pip install selenium undetected-chromedriver

# Run example
cd Example
swift run
import AutomatedBrowser

// Regular Chrome
let browser = try! AutomatedBrowser(headless: false)
// Undetected Chrome
let browser = try! AutomatedBrowser(headless: false, undetected: true)

// Do some stuff
browser.load("https://example.org")
print(browser.pageSource)
browser.quit()

Contact

mahdi.jp