cPanel Server Information
Variables
Return server's configuration settings
This function retrieves the configuration settings for the cPanel & WHM server on which an account exists. This is useful, for example, to verify which applications and functionality are available on the account.
get/Variables/get_server_information
Query parameters
name'default_theme' | 'email_filter_storage_directory' | 'allow_park_subdomain_on_hostname' | 'allow_remote_domains' | 'allow_unregistered_domains' | 'apache_port' | 'apache_ssl_port' | 'api_shell' | 'awstats_browser_update' | 'awstats_reverse_dns' | 'cpanel_root_directory' | 'database_prefix_required' | 'display_cpanel_doclinks' | 'dnsadmin_app' | 'empty_trash_days' | 'enable_file_protect' | 'file_upload_maximum_bytes' | 'file_upload_must_leave_bytes' | 'file_usage' | 'ftp_server' | 'htaccess_check_recurse' | 'invite_sub' | 'ipv6_listen' | 'local_nameserver_type' | 'logout_redirect_url' | 'mailbox_storage_format' | 'mail_server' | 'minimum_password_strength' | 'minimum_password_strength_mysql' | 'mysql_host' | 'mysql_version' | 'php_maximum_execution_time' | 'php_post_maximum_size' | 'php_system_default_version' | 'php_upload_maximum_filesize' | 'php_loader' | 'php_open_basedir_home' | 'phpmyadmin_disable_search_info_schema' | 'docroots_in_public_html_only' | 'require_ssl' | 'allow_reset_password' | 'allow_reset_password_for_subaccounts' | 'disable_analog' | 'skip_apache_clients_optimizer' | 'disable_awstats' | 'skip_mailbox_warnings_check' | 'disable_boxtrapper' | 'skip_bandwidth_limit_check' | 'disable_mailman' | 'disable_roundcube' | 'disable_spamassassin' | 'disable_spambox' | 'disable_webalizer' | 'ssl_default_key_type' | 'use_information_schema' | 'use_mail_for_mailman_url' | 'is_mod_userdir_enabled' | 'version'
The server configuration settings to return.
<details> <summary>Click to view information about the available server configuration settings.</summary>- default_theme - The cPanel interface's default theme.
- email_filter_storage_directory - The location of the Exim email filter storage directory.
- allow_park_subdomain_on_hostname - Whether the system allows users to park subdomains of the server's hostname.
- allow_remote_domains - Whether the system allows users to create addon domains or aliases that resolve to other servers.
- allow_unregistered_domains - Whether the system allows users to add domains they didn't register with a domain name registrar.
- apache_port - The IP address or IP address with a firewall port number that Apache® uses to listen for requests and serve web pages over an unsecured connection.
- apache_ssl_port - The port or IP address that Apache uses to listen for requests and serve web pages over a secure connection.
- api_shell - Whether the user can access cPanel's API Shell interface (cPanel >> Home >> Advanced >> API Shell).
- awstats_browser_update - Whether the user can update their AWStats software.
- awstats_reverse_dns - Whether the AWStats statistical analysis software interprets visitors' domain names as IP addresses.
- cpanel_root_directory - The cPanel root directory.
- database_prefix_required - Whether the account requires database prefixing.
- display_cpanel_doclinks - Whether the system displays links to cPanel feature documentation in the cPanel interface.
- dnsadmin_app - The application that processes DNS management requests.
- empty_trash_days - The minimum age of files that the system will automatically purge from .trash folders in user home directories.
- enable_file_protect - Whether EasyApache 4's FileProtect option is enabled.
- file_upload_maximum_bytes - The maximum file size, in megabytes (MB), that a user can upload to a server.
- file_upload_must_leave_bytes - The minimum filesystem quota that the system requires after a file uploads to a server.
- file_usage - Whether file usage information displays in the cPanel Home interface's statistics bar.
- ftp_server - The FTP server.
- htaccess_check_recurse - The maximum number of directories deep to look for .htaccess files when you change the PHP handler.
- invite_sub - Whether cPanel account users can send invitations to new Subaccount users via cPanel's User Manager interface (cPanel >> Home >> Preferences >> User Manager).
- ipv6_listen - Whether the cpsrvd daemon and other cPanel & WHM services listen on IPv6.
- local_nameserver_type - The DNS nameserver's type.
- logout_redirect_url - The logout redirection URL.
- mailbox_storage_format - The mailbox storage format for new accounts.
- mail_server - The mailserver type.
- minimum_password_strength - The minimum strength for cPanel account passwords.
- minimum_password_strength_mysql - The minimum strength for MySQL® or MariaDB® passwords.
- mysql_host - The MySQL or MariaDB hostname or IP address.
- mysql_version - The MySQL or MariaDB version.
- php_maximum_execution_time - The number of seconds that a PHP script can run before the system terminates it.
- php_post_maximum_size - The maximum size, in megabytes (MB), of a POST request.
- php_system_default_version - The system's default version of PHP.
- php_upload_maximum_filesize - The maximum file size, in megabytes (MB), that a PHP script may upload.
- php_loader - The PHP loaders through which the system executes internal PHP scripts.
- php_open_basedir_home - Whether PHP open_basedir protection is enabled on the server.
- phpmyadmin_disable_search_info_schema - Whether the user can search for the phpMyAdmin information schema.
- docroots_in_public_html_only - Whether the system restricts users from creating addon domains and subdomains outside of their public_html directory.
- require_ssl - Whether the system requires passwords and other sensitive information use SSL encryption.
- allow_reset_password - Whether cPanel's Reset Password feature is enabled for the account.
- allow_reset_password_for_subaccounts - Whether cPanel's Reset Password feature is enabled for subaccounts on the account.
- disable_analog - Whether users can access the Analog Stats interface (cPanel >> Home >> Metrics >> Analog Stats).
- skip_apache_clients_optimizer - Whether the Apache Client Optimizer is enabled.
- disable_awstats - Whether the AWStats software is enabled.
- skip_mailbox_warnings_check - Whether mailbox usage warnings are enabled.
- disable_boxtrapper - Whether BoxTrapper is enabled.
- skip_bandwidth_limit_check - Whether the system automatically suspends HTTP service for accounts that exceed their bandwidth limit.
- disable_mailman - Whether Mailman mailing lists are enabled.
- disable_roundcube - Whether Roundcube webmail is enabled.
- disable_spamassassin - Whether the Apache SpamAssassin™ spam filter is enabled.
- disable_spambox - Whether Apache SpamAssassin's spam box feature is enabled.
- disable_webalizer - Whether the Webalizer statistics program is enabled.
- ssl_default_key_type - The default SSL/TLS encryption algorithm used by the system.
- use_information_schema - Whether the system uses the MySQL® INFORMATION_SCHEMA view. This view includes disk usage by all MySQL tables in the disk usage totals.
- use_mail_for_mailman_url - Whether the system prefixes Mailman URLs with the mail prefix. For example, http://mail.domain.com/mailman.
- is_mod_userdir_enabled - Whether the Apache mod_userdir Tweak is enabled.
- version - The system's Linux® kernel version.
Note:
- If you don't use this parameter, this function returns all of the server's configuration settings.
- To retrieve multiple variables, increment this parameter. For example, name-1=variable, name-2=variable, name-3=variable.
Response
HTTP Request was successful.
Example response
{
"apiversion": 3,
"func": "get_server_information",
"module": "Variables",
"result": {
"data": {
"allow_remote_domains": 1,
"allow_reset_password": 1,
"allow_reset_password_for_subaccounts": 1,
"allow_unregistered_domains": 1,
"apache_port": "192.0.2.0:80",
"apache_ssl_port": "192.0.2.0:443",
"cpanel_root_directory": "/usr/local/cpanel",
"database_prefix_required": 1,
"default_theme": "jupiter",
"docroots_in_public_html_only": 1,
"email_filter_storage_directory": "/etc/vfilters",
"empty_trash_days": "disabled",
"enable_file_protect": 1,
"file_upload_must_leave_bytes": 5,
"ftp_server": "disabled",
"htaccess_check_recurse": 2,
"invite_sub": 1,
"is_mod_userdir_enabled": 1,
"local_nameserver_type": "powerdns",
"logout_redirect_url": "https://cpanel.net",
"mail_server": "dovecot",
"mailbox_storage_format": "maildir",
"minimum_password_strength": 65,
"minimum_password_strength_mysql": 65,
"mysql_version": "5.7",
"php_loader": "ioncube",
"php_maximum_execution_time": 90,
"php_post_maximum_size": 55,
"php_system_default_version": "ea-php73",
"php_upload_maximum_filesize": 50,
"require_ssl": 1,
"skip_mailbox_warnings_check": 1,
"ssl_default_key_type": "rsa-2048",
"use_information_schema": 1,
"version": "3.4"
},
"status": 1
}
}