Search code examples
pythonseleniumserverclient

Feasible? Form automation webapp with selenium - [server side]


Tldr: Is it feasible to create a web tool/app that relies on server side Selenium automation.

Created a local script that automates form filling for car insurance quote websites and returns the cost to insure. Ie fill one form and it auto fills every other providers quote form and returns quotes.

But now I want to extend that functionality to others via some sort of webapp [flask/Django?] that handles a clients requests server side by fetching that information and returning it to the client based on their inputs.

What I’m struggling with is Selenium is limited to 5 web drivers (locally) I believe, and is resource intensive, so to me that means at most you can handle 5 website requests at once?


Solution

  • The short answer is YES.

    The idea to solve the problem is as follows:

    1. Create a web app which can fetch user's inputs and return something back to user. Just like the most common website.
    2. Create a service in the web app. The service can handle what you wanted using Selenium, such as, filling form of car insurance and getting the cost to insure.
    3. Create a webpage or API in the web app. The webpage/API calls the service mentioned above. When user use the webpage/API, Selenium will automate to do something.

    So, it's done.