A Python CLI tool that checks SSL certificates for any domain. View certificate details, expiry dates, and security status.
This tutorial requires an APIVerve API key. Sign up free - no credit card required.
- Check SSL certificates for any domain
- See issuer and subject details
- View validity dates
- Certificate key size
- Serial number information
- Interactive mode or command-line arguments
-
Clone this repository
git clone https://github.com/apiverve/ssl-checker-python-tutorial.git cd ssl-checker-python-tutorial -
Install dependencies
pip install -r requirements.txt
-
Add your API key
Open
checker.pyand replace the API key:API_KEY = 'your-api-key-here'
-
Run the checker
Interactive mode:
python checker.py
Command line mode:
python checker.py google.com
$ python checker.py ebay.com
==================================================
SSL Certificate Check: ebay.com
==================================================
β
Certificate Found
π Certificate Details:
----------------------------------------------
Subject: ebay.com
Issuer: Sectigo Public Server Authentication CA OV R36
Valid From: Jul 28 00:00:00 2025 GMT
Valid To: Jul 28 23:59:59 2026 GMT
Key Size: 2048 bits
Serial: 99F408949A6416EDC3B8F5EC77B2EBE5
==================================================ssl-checker-python-tutorial/
βββ checker.py # Main Python script
βββ requirements.txt # Dependencies (requests)
βββ screenshot.jpg # Preview image
βββ LICENSE # MIT license
βββ .gitignore # Git ignore rules
βββ README.md # This file
- User provides a domain name
- Script cleans and validates the input
- API checks the SSL certificate
- Script calculates days until expiry
- Results displayed with status indicators
response = requests.get(
'https://api.apiverve.com/v1/sslchecker',
params={'domain': domain},
headers={'x-api-key': API_KEY}
)Endpoint: GET https://api.apiverve.com/v1/sslchecker
Query Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
domain |
string | Yes | Domain to check (e.g., "google.com") |
Example Response:
{
"status": "ok",
"error": null,
"data": {
"subject": {
"C": "US",
"ST": "California",
"O": "eBay, Inc.",
"CN": "ebay.com"
},
"issuer": {
"C": "GB",
"O": "Sectigo Limited",
"CN": "Sectigo Public Server Authentication CA OV R36"
},
"valid_from": "Jul 28 00:00:00 2025 GMT",
"valid_to": "Jul 28 23:59:59 2026 GMT",
"serialNumber": "99F408949A6416EDC3B8F5EC77B2EBE5",
"bits": 2048,
"domain": "ebay.com"
}
}- DevOps monitoring - Check certificate expiry dates
- Security audits - Verify SSL configuration
- Website maintenance - Prevent expired certificate downtime
- Compliance checking - Ensure proper SSL setup
- Domain management - Monitor multiple domains
- Add email alerts for expiring certificates
- Monitor multiple domains from a list
- Save results to CSV/JSON
- Build a web dashboard
- Integrate with Slack/Discord notifications
- Add scheduling with cron
Explore more APIs at APIVerve:
- DNS Lookup - Check DNS records
- WHOIS Lookup - Domain registration info
- Website Screenshot - Capture website screenshots
This tutorial works with the free APIVerve plan. Some APIs may have:
- Locked fields: Premium response fields return
nullon free plans - Ignored parameters: Some optional parameters require a paid plan
The API response includes a premium object when limitations apply. Upgrade anytime to unlock all features.
MIT - see LICENSE
- Get API Key - Sign up free
- APIVerve Marketplace - Browse 300+ APIs
- SSL Checker API - API details
