- Python 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| .gitattributes | ||
| LenovoWarranty.py | ||
| LenovoWarrantyOne.py | ||
| LICENSE | ||
| README.md | ||
| template.csv | ||
Lenovo Warranty Checker
Description
This project consists of two scripts, LenovoWarrantyOne.py and LenovoWarranty.py, designed to interact with Lenovo's API to retrieve product and warranty information based on serial numbers. The LenovoWarrantyOne.py script processes a single serial number provided as a command-line argument, while LenovoWarranty.py processes multiple serial numbers from a CSV file and updates the CSV with the retrieved information.
Requirements
- Python 3.x
requestslibrary
You can install the requests library using pip:
pip install requests
Files
1. LenovoWarrantyOne.py
This script fetches and displays product and warranty information for a single Lenovo product based on its serial number.
python LenovoWarrantyOne.py <serial_number>
2. LenovoWarranty.py
This script processes a CSV file of Lenovo serial numbers, fetches the corresponding product and warranty information, and updates the CSV file with this information.
python LenovoWarranty.py <csv_file_path>
template.csv
This file has a template structure that LenovoWarranty.py expects.
Contributing
We welcome contributions to this project! If you have suggestions for improvements, new features, or bug fixes, please follow the steps below:
-
Fork the Repository:
- Click on the "Fork" button at the top of this repository page to create a copy of the repository in your GitHub account.
-
Clone Your Fork:
- Clone your forked repository to your local machine.
-
Create a Branch:
- Create a new branch for your changes:
git checkout -b feature/your-feature-name
- Create a new branch for your changes:
-
Make Your Changes:
- Modify the code and add your improvements or new features.
-
Commit Your Changes:
- Commit your changes with a descriptive commit message:
git commit -m "Description of your changes"
- Commit your changes with a descriptive commit message:
-
Push to Your Fork:
- Push your changes to your forked repository:
git push origin feature/your-feature-name
- Push your changes to your forked repository:
-
Create a Pull Request:
- Go to the original repository and click on the "Pull Requests" tab.
- Click on the "New Pull Request" button and select your branch from the dropdown menu.
- Provide a descriptive title and detailed description of your changes.
- Click on the "Create Pull Request" button.
We will review your pull request and provide feedback or merge it into the main branch. Thank you for your contributions!