This repository provides a Python Selenium automation script to bulk-create help desk tickets in the Hayes gethelphss system based on data from an Excel file. It is designed to streamline repetitive ticket creation for devices like projectors, desktops / laptops, ensuring consistency and saving time for IT staff. Automate creation of several tickets without API, since an API wasn't available.
-
Reads device and tag data from an Excel spreadsheet
-
Automates browser actions to:
-
Log in via Google Login (without SSO/Chrome profile - Manual Selection -> Select
Use Chrome without an account) -
Navigate the multi-step ticket creation UI (e.g. Technology → Devices → Projectors / Speakers)
-
Fill out all required ticket fields, including dynamic summary and description
-
Assign tickets to a specific user and submitter
-
Submits tickets reliably, handling form validation and overlays
-
Python 3.8+
Google Chrome installed
ChromeDriver matching your Chrome version (in your System Variables' PATH)
Selenium, pandas, python-dotenv, openpyxl installed in your environment (pip installed via requirements.txt below)
pip install selenium pandas openpyxl python-dotenvgit clone https://github.com/your-org/hayes-ticket-automation.git
cd hayes-ticket-automationDo NOT use your existing Chrome user profile for automation.
Create a .env file in your project root:
USER_EMAIL=your.email@domain.com
PASSWORD=your_google_password
-
Do not use USERNAME as a variable name; it conflicts with system variables.
-
Make sure
.envis in your.gitignoreto keep credentials private.
-
Place your device/tag Excel file in the information/ directory.
-
The file should have at least these columns: Projector Name, Tag.
Example:
| Device Name | Tag |
|---|---|
| BUR-RM01-PROJ | 769452 |
| BUR-RM02-PROJ | 769453 |
python -m venv venv
# On Windows:
venv\Scripts\activate
# On Mac/Linux:
source venv/bin/activatepip install -r requirements.txtpython main.py-
The script will launch Chrome, log in via SSO, and begin creating tickets as specified in your Excel file.
-
Progress and any errors will be printed to the console.
-
Ticket Fields: Edit the script to adjust summary, description, or other fields as needed.
-
Selectors: If the UI changes, update XPaths or IDs in the script for robustness.
-
Rate Limiting: Adjust time.sleep() values if you encounter rate-limiting or want to throttle submissions.
-
Element Not Found/Clickable:
-
Ensure ChromeDriver matches your Chrome version.
-
Check that all form fields are being filled as required.
-
Use screenshots (the script can save them) to debug UI state.
-
-
SSO Issues:
- Credentials in .env must be accurate and complete.
- Fork this repository
- Create a new branch (git checkout -b feature-branch)
- Make your changes and add tests if applicable
- Commit and push (git commit -am 'Add new feature')
- Open a Pull Request
- Never commit
.envor credentials to the repository. Ensure.envis in of.gitignore. - Select
Use Chrome without an accountfor automation to avoid interfering with personal browsing.
This project is licensed under the MIT License.
- Inspired by real-world IT automation needs for K-8 device management / ticket handling.
- Uses Selenium, pandas, and python-dotenv for robust, maintainable automation.
For issues, open a GitHub issue or contact the repository maintainer. Contributions and improvements are welcome!