Return available RPM packages

This function lists a key's available RPMs. For more information, read our rpm.versions system documentation.

SecurityBasicAuth
Request
query Parameters
section
required
string

The RPM's section.

Example: section=rpm_groups
key
string

The RPM's key. If you do not specify a value, the function returns all RPM categories.

Example: key=3rdparty
Responses
200

HTTP Request was successful.

Response Schema: application/json
object or object

The RPM section and its associated RPMs.

Note:

  • This function uses the RPM section's name and RPM key's name for each return value.
  • If you specify the key parameter, this function returns only the called RPM key.
  • If you do not specify the key parameter, the function returns all RPM keys in the called section parameter.
object
get/get_rpm_version_data
Request samples
whmapi1 --output=jsonpretty \
  get_rpm_version_data \
  section='rpm_groups'
Response samples
application/json
{
  • "data": {
    • "3rdparty": [
      • "cpanel-pcre",
      • "cpanel-pixman",
      • "cpanel-analog"
      ]
    },
  • "metadata": {
    • "command": "get_rpm_version_data",
    • "reason": "OK",
    • "result": 1,
    • "version": 1
    }
}