Skip to content

About

Scraper developed with Azure Functions and Twilio for the management and tracking of information related to vehicles and license registration

Resources

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

GestorAutoLicencias

An automated web scraper leveraging Azure Functions and Twilio to streamline the management and tracking of vehicle-related information and driver's license registrations.

Build Status License: MIT Twitter Follow


🚀 Features

  • Automated Scraping: Efficiently extracts data related to vehicle information and driver's license appointments using Selenium and Undetected Chromedriver.
  • Azure Functions Integration: Runs seamlessly as an Azure Function for scalability and cost-effectiveness.
  • Twilio Notifications: Sends SMS notifications for important events like newly available test slots.
  • Configurable Preferences: Easily customize search parameters (dates, centers, etc.) via config.ini.
  • Intelligent Session Management: Handles license information changes and restarts failed browser sessions.
  • Captcha Handling: Attempts to solve captchas (with Buster Chrome extension support).
  • Firewall Bypass Attempts: Includes delays and refresh strategies.
  • Error Logging: Reports errors for monitoring.

⚙️ Tech Stack

  • Python
  • Selenium
  • Undetected Chromedriver
  • Azure Functions
  • Twilio
  • ConfigParser
  • requests

🛠️ Installation

  1. Clone the repository:

    git clone [https://github.com/vectorc0de/car-license-scraper.git](https://github.com/vectorc0de/car-license-scraper.git)
    cd car-license-scraper
  2. Install dependencies:

    pip install -r requirements.txt
    pip install undetected-chromedriver
  3. Configure config.ini:

    • Update Twilio phone_number in [twilio].
    • Configure preferences in [preferences]:
      • licence: Your driving license number.
      • booking: Your booking reference number.
      • current_test_date, current_test_centre, current_test_error: Current test info.
      • disabled_dates: Dates to exclude (e.g., ['2025-05-25', '2025-05-26']).
      • centre: Preferred test centers (e.g., ['Test Centre 1', 'Another Centre']).
      • before_date, after_date: Date range for earlier tests (e.g., 2025-06-01).
      • auto_book_test: yes to enable auto-booking (use with caution!).
      • formatted_current_test_date: Current test date in YYYY-MM-DD format.
  4. Set up Azure Function (if deploying to Azure):

    • Create an Azure Function App.
    • Deploy the Python code.
    • Configure environment variables (Twilio SID, Auth Token).
    • Ensure chromedriver is accessible.

🚀 Usage

  • Running locally:

    python your_scraper_script_name.py

    (Replace your_scraper_script_name.py).

  • Running as Azure Function:

    • Deployed function will execute based on triggers.
    • Monitor Azure Function logs.

⚠️ Important Notes

  • Ethical Scraping: Use responsibly, respect robots.txt and terms of service.
  • Website Changes: May break the scraper; updates might be needed.
  • Captcha Limitations: Solving not guaranteed; manual intervention might be required.
  • Auto Booking (Caution): Use auto_book_test carefully!
  • Driver Executable: Ensure chromedriver in the chromedriver directory is compatible

About

Scraper developed with Azure Functions and Twilio for the management and tracking of information related to vehicles and license registration

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages