Wouldn't it be easier to just put it in your existing monitoring system?
* https://github.com/matteocorti/check_ssl_cert
* https://www.monitoring-plugins.org/doc/man/check_http.html
* https://exchange.nagios.org/directory/Plugins/Network-Protoc...
Or with Prometheus: https://github.com/prometheus/blackbox_exporter
https endpoints will include the probe_ssl_earliest_cert_expiry metric, which is the expiration in UNIX epoch seconds. Use with the builtin time() function.