Our documentation is getting an overhaul! We would like your input! Click here to take a look at the beta launch of our new documentation site! Only cPanel & WHM version 82 documentation exists on our beta at this time. 84 will be added to the new site soon! Leave your feedback here: https://go.cpanel.net/docsfeedback
WHM API 1 Functions - install_rpm_plugin - Developer Documentation - cPanel Documentation
Child pages
  • WHM API 1 Functions - install_rpm_plugin
Skip to end of metadata
Go to start of metadata

Description

This function starts a plugin installation. The installation runs as a background process.

Examples


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


Notes:

  • Unless otherwise noted, 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)
{  
   "data":{
		 "log_entry":"2017-01-01T19:39:27Z_plugin_name",
		 "pid":"1234",
   },
   "metadata":{  
      "result":1,
      "version":1,
      "command":"install_rpm_plugin",
      "reason":"OK"
   }
}
 Output (XML)
<result>
	<data>
      <log_entry>2017-01-01T19:39:27Z_plugin_name</log_entry>
	  <pid>1234</pid>
    </data>
	<metadata>
		<version>1</version>
		<reason>OK</reason>
		<result>1</result>
		<command>install_rpm_plugin</command>
	</metadata>
	<data/>
</result>


Note:

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

Parameters

ParameterTypeDescriptionPossible valuesExample
namestring

Required

The name of a plugin RPM to install.

A valid plugin RPM name.plugin name

Returns

ReturnTypeDescriptionPossible valuesExample
log_entrystring

The name of the plugin log entry for this installation, which includes a timestamp.

A valid plugin RPM name.
2017-01-01T19:39:27Z_plugin_name
pidstringThe ID of the process that will install the RPM.