Getting the certificate health of a site with our PHP SDK

Make sure you've read the getting started guide first. Once that's done, you should have our package & authentication ready to go.

Getting the certificate

If your site has its certificate health check enabled, you can get some information regarding the found certificate.

$certificate = $ohDear->site($siteId)->certificateHealth();

//alternatively you could do this
$certificate = $ohDear->certificateHealth($siteId);

Both methods above will return an OhDear\PhpSdk\Resources\CertificateHealth instance.

You can get the properties of a certificate

// An array containing some details about the certificate itself

// An array containing all the checks we performed on the certificate

// An array containing the names of all the issuers in the certificate chain.

The specific return values are described in the certificate health API endpoint.

Was this page helpful to you? Feel free to reach out via or on Twitter via @OhDearApp if you have any other questions. We'd love to help!