CertWatch is currently in Beta. We'd love your feedback!
cURL
curl --request POST \ --url https://api.example.com/certificates
Add a new certificate to monitor
curl -X POST https://api.certwatch.app/v1/certificates \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "domain": "example.com", "name": "Main Website", "port": 443, "alertThresholds": [30, 14, 7, 3, 1] }'
domain
name
port
alertThresholds
{ "domain": "example.com" }
{ "domain": "api.example.com", "name": "Production API", "port": 8443, "alertThresholds": [14, 7, 1] }
{ "data": { "id": "cert_abc123", "domain": "example.com", "name": "Main Website", "status": "valid", "daysUntilExpiry": 89, "expiresAt": "2025-04-08T15:00:00Z", "issuedAt": "2025-01-08T15:00:00Z", "issuer": "Let's Encrypt", "subject": "example.com", "port": 443, "alertThresholds": [30, 14, 7, 3, 1], "createdAt": "2025-01-08T12:00:00Z", "updatedAt": "2025-01-08T12:00:00Z" }, "meta": { "requestId": "req_xyz789" } }
{ "error": { "code": "invalid_domain", "message": "The domain format is invalid" } }
{ "error": { "code": "duplicate_domain", "message": "This domain is already being monitored" } }
{ "error": { "code": "certificate_not_found", "message": "Could not retrieve SSL certificate from this domain" } }
{ "error": { "code": "certificate_limit_reached", "message": "You have reached your certificate limit. Upgrade your plan to add more." } }
{ "error": { "code": "invalid_api_key", "message": "The provided API key is invalid" } }