Search code examples
pythonseleniumselenium-webdrivergoogle-chrome-extension

How to chose country of VPN(zenmate) chrome extension with selenium python


I want to automate choosing country of zenmate VPN extension with selenium but I don't know how to access it

this is my code to add the extension:

from selenium import webdriver
from selenium.webdriver.chrome.options import Options

chrome_option = Options()
chrome_option.add_extension("vpn.crx")
driver1 = webdriver.Chrome(executable_path='chromedriver.exe',options=chrome_option)
driver1.get("https://www.google.com/")

Solution

  • You can use pyautogui. Make your mouse go to extension icon, click on it, go to search field, look up the country and click on it. Voila.