cPanelLicensing Perl Module

Last modified: July 27, 2022


Overview

The cPanelLicensing Perl module runs Manage2 API functions. Use the cPanelLicensing Perl module to manage customer licenses from the command line or through the Manage2 user interface.

Important:

You must run this module on a *nix-based system.

Requirements

To install this module, the following features must be available on the server:

  • Perl 5.6.2 or higher.
  • OpenSSL and its development libraries.

In addition, one of the following following Perl modules must exist on the server:

  • XML::Simple
  • JSON::Syck
  • YAML::Syck
  • YAML
  • JSON
  • JSON::XS

Download the module

To download the cPanelLicensing Perl module, click the cPanel License Management API SDK link in the Automation menu on the Manage2 Dashboard interface.

Basic use

When a script uses this module, the script must create an instance of the module with the following parameters:

  • user — The account username.
  • pass — The account password.

For example, the following code creates the initial instance of the cPanelLicensing Perl module:

1
2
3
4
5
use cPanelLicensing;
my $licenseManager =  cPanelLicensing->new(
     user => '$USERNAME',
     pass => '$PASSWORD'
);

Additional Documentation