addSSLHost — Adding an SSL host

The addSSLHost method adds or edits a hostname for which to conduct an SSL check.

Although the addSSLHost method supports editing an existing hostname, we recommend that you use a dedicated method editSSLHost.

The API endpoint is:

https://api.sitelock.com/v1/partner

Request format

  • SiteLockOnlineRequest: This element is used to delineate the full API request.

    • authentication: The partner’s username, password, and branding

      • username: The partner’s API username

      • password: The partner’s API password

      • partner: (Optional) The brand name to use in messaging

    • addSSLHost: The method name

      • site_id: The ID of the site for which to conduct an SSL check

      • domain: The hostname for which to conduct an SSL check

        Enter only the hostname (for example, www.example.com). Adding the HTTP protocol indicator (for example, https://www.example.com) is unnecessary and will cause the scan to fail.

Example request

<SiteLockOnlineRequest>
    <authentication>
        <user>Username</user>
        <password>Password</password>
    </authentication>
    <addSSLHost>
        <site_id>10900</site_id>
        <domain>www.example.com</domain>
    </addSSLHost>
</SiteLockOnlineRequest>
xml

Response format

  • SiteLockOnlineResponse: This element is used to delineate the full API response.

    • addSSLHost: The method name

      • sslhost: The hostname details

        • id: [attribute] - An internal SiteLock host ID, can safely be ignored

        • domain: [attribute] - The hostname that was added for an SSL check

        • action: [attribute] - The action that was perfomed

Example response

<SiteLockOnlineResponse>
    <addSSLHost>
        <sslhost id="523998" domain="www.example.com" action="created" />
    </addSSLHost>
</SiteLockOnlineResponse>
xml