Child pages
  • WHM API 1 Functions - get_autossl_problems_for_domain
Skip to end of metadata
Go to start of metadata

 

Description

This function returns the list of the latest Domain Control Validation (DCV) problems for a specific domain.

Examples


 JSON API
https://hostname.example.com:2087/cpsess##########/json-api/get_autossl_problems_for_domain?api.version=1&domain=example.com
 XML API
https://hostname.example.com:2087/cpsess##########/xml-api/get_autossl_problems_for_domain?api.version=1&domain=example.com
 Command Line
whmapi1 get_autossl_problems_for_domain domain=example.com


Notes:

  • You must URI-encode values.
  • For more information and additional output options, read our Guide to WHM API 1 documentation or run the whmapi1 --help command.
  • If you run CloudLinux™, you must use the full path of the whmapi1 command:

    /usr/local/cpanel/bin/whmapi1

 Output (JSON)
{  
   "metadata":{  
      "reason":"OK",
      "command":"get_autossl_problems_for_domain",
      "result":1,
      "version":1
   },
   "data":{  
      "problems_by_domain":[  
         {  
            "domain":"www.example.com",
            "log":"2017-09-07T03:51:01Z",
			"problem":""doesnotexist.example.com" does not resolve to any IPv4 addresses on the internet.",
            "time":"2017-08-12T21:02:56Z"
         }
      ]
   }
}
 Output (XML)
<result>
    <metadata>
        <version>1</version>
        <result>1</result>
        <reason>OK</reason>
        <command>get_autossl_problems_for_domain</command>
    </metadata>
	<data>
		<problems_by_domain>
			<domain>www.example.com</domain>
            <log>2017-09-07T03:51:01Z</log>
			<problem>"doesnotexist.example.com" does not resolve to any IPv4 addresses on the internet.</problem>
			<time>2017-08-12T21:02:56Z</time>
		</problems_by_domain>
	</data>
</result>


Note:

Use WHM's API Shell interface (WHM >> Home >> Development >> API Shell) to directly test WHM API calls.

Parameters

Parameter
Type
Description
Possible values
Example
domainstring

Required

The domain for which to poll the DCV status.

A valid domain name that the account owns.example.com

 

Returns

ReturnTypeDescriptionPossible valuesExample
problems_by_domain
array of hashesAn array of hashes that contain information about DCV problems for each domain.This array of hashes includes the domain , problem, and time returns. 

domain

string

The domain's name.

The function returns this value in the problems_by_domain array of hashes.

A valid domain on the server.www.example.com

log

string

The log file of the last run in the /var/cpanel/logs/autossl/ directory.

This function returns this value in the problems_by_domain array of hashes.

A time value, in ISO-8601 format.2017-09-07T03:51:01Z

problem

string

The human readable explanation of the DCV problem.

Note:

The system does  not  localize this return.

The function returns this value in the problems_by_domain array of hashes.

A valid string."doesnotexist.example.com” does not resolve to any IPv4 addresses on the internet.

time

string

The last run time of the AutoSSL system.

The function returns this value in the problems_by_domain array of hashes.

A time value, in ISO-8601 format.
2017-08-12T21:02:56Z