We have a new documentation site for cPanel & WHM! You can find our new documentation site at docs.cpanel.net.

We will continue to maintain our API documentation on this server.

Child pages
  • Guide to the LiveAPI System - The end() Method
Skip to end of metadata
Go to start of metadata



The end() method deconstructs the Cpanel::LiveAPI object and closes the connection to cPanel & WHM.

  • Only use this method once in any script or application.
  • Use this method after you have completed all of the actions that require a connection to cPanel & WHM.


  • For Perl applications, this method is required.
  • For PHP applications, this method is not required. We provide this method for backwards compatibility with LivePHP scripts. 


LiveAPI PHP Class

// Disconnect from cPanel - only do this once.

LiveAPI Perl Module

# Disconnect from cPanel - only do this once.


This method does not accept parameters.


This method does not return a value.