1— The license was successfully looked up.
0— The license does not exist.
-1— The request failed due to an error.
http://manage2.cpanel.net/XMLlookup.cgi?ip=127.0.0.1in a web browser will produce XML output similar to the following:
Calling the function using the URL above will return XML data by default. To change the output format that will be returned, use either of the following URLs:<XMLlookup licenseid="000001" reason="OK" status="1" version="1"/>
XMLlookup.cgi. You can use this module to pass input variables to a Manage2 API function. You may need to edit the example below to suit your needs.
In this example,fetchLicenseId( ip=>$ip )
$ipis meant to stand for the IP address that corresponds to the license ID you wish to retrieve. For more information about using a Perl module to call API functions, visit our page here.
In this example,<?php include("cpl.inc.php"); $cpl = new cPanelLicensing("__USERNAME__","__PASSWORD__"); $lisc = $cpl->fetchLicenseId(array( "ip" => $ip ) ); ?>
$ipis meant to stand for the IP address that corresponds to the license ID you wish to retrieve. Remember:
__PASSWORD__are meant to represent the username and password for your Manage2 account. For more information about using a PHP class to call API functions, visit our page here.