Child pages
  • Guide to Standardized Hooks - Whostmgr Functions
Skip to end of metadata
Go to start of metadata


Introduction

The Whostmgr category's events occur during WHM functions.

Accounts::change_package


This event triggers whenever an account's hosting plan (package) changes, or whenever a hosting plan is edited.

Available Stages:

  • pre — Hook action code runs before the change.
  • post — Hook actions code runs after the change.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
cur_pkgstring

The hosting plan's (package's) current name.

A valid hosting plan name.oldpackagename
new_pkgstring

The new hosting plan's (package's) name.

A valid hosting plan name.

newpackagename
userstringThe user for whom the package will change.A valid username on the server.username
ParameterTypeDescriptionPossible valuesExample
cur_pkgstring

The hosting plan's (package's) current name.

A valid hosting plan name.oldpackagename
new_pkgstring

The new hosting plan's (package's) name.

A valid hosting plan name.

newpackagename
userstringThe user for whom the package changed.A valid username on the server.username


Accounts::Create


This event triggers whenever the system creates an account.

Available Stages:

  • pre — Hook action code runs before the system creates the account.
  • post — Hook actions code runs after the system creates the account.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

This event returns the WHM API 1  createacct function's input parameters and values .

 

Accounts::Modify


This event triggers whenever the system modifies an account.

Available Stages:

  • pre — Hook action code runs before the change.
  • post — Hook actions code runs after the change.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

This event returns the WHM API 1  modifyacct function's input parameters and values .


Accounts::Remove


This event triggers whenever the system deletes an account.

Available Stages:

  • pre — Hook action code runs before the system deletes the account.
  • post — Hook actions code runs after the system deletes the account.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

This event returns the WHM API 1  removeacct function's input parameters and values.

 

Accounts::set_shell


This event triggers whenever the system modifies an account's shell.

Available Stages:

  • pre — Hook action code runs before the system modifies the shell.
  • post — Hook actions code runs after the system modifies the shell.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
new_shellstringThe new shell setting.
  • noshell
  • nologin
  • false
  • shutdown
  • sync
noshell
current_shellstringThe current shell setting.
  • noshell
  • nologin
  • false
  • shutdown
  • sync
nologin
userstringThe account for which shell settings will change.A valid username on the server.username
ParameterTypeDescriptionPossible valuesExample
new_shellstringThe new shell setting.
  • noshell
  • nologin
  • false
  • shutdown
  • sync
noshell
current_shellstringThe previous shell setting.
  • noshell
  • nologin
  • false
  • shutdown
  • sync
nologin
userstringThe account for which shell settings changed.A valid username on the server.username
rawoutstringAdditonal raw output from the event.A string value.raw output


Accounts::suspendacct


Note:

This event is only available in cPanel & WHM version 11.46. 

This event triggers whenever the system suspends an account.

Available Stages:

  • pre — Hook action code runs before the system suspends the account.
  • post — Hook actions code runs after the system suspends the account.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
userstringThe account to suspend.A valid username on the server.

username

reasonstringThe reason for suspension, if one exists.A string value.Nonpayment
disallowunbooleanWhether resellers can unsuspend the account.
  • 1 — Resellers cannot unsuspend the account.
  • 0 — Resellers can unsuspend the account.
1
ParameterTypeDescriptionPossible valuesExample
userstringThe suspended account.A valid username on the server.username
reasonstringThe reason for suspension, if one exists.A string value.Nonpayment
disallowunbooleanWhether resellers can unsuspend the account.
  • 1 — Resellers cannot unsuspend the account.
  • 0 — Resellers can unsuspend the account.
1
rawoutstringThe event's raw output.A string value.raw output


Accounts::unsuspendacct


Note:

This event is only available in cPanel & WHM version 11.46. 

This event triggers whenever the system unsuspends an account.

Available Stages:

  • pre — Hook action code runs before the system unsuspends the account.
  • post — Hook actions code runs after the system unsuspends the account.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
userstringThe account to unsuspend.A valid username on the server.

username

ParameterTypeDescriptionPossible valuesExample
userstringThe unsuspended account.A valid username on the server.username
rawoutstringThe event's raw output.A string value.raw output

AutoSSL::installssl


 

Note:

This event is only available in cPanel & WHM version 72 or later.

This event triggers when the AutoSSL service installs or changes an SSL certificate.

Note:

This hook does not listen for uninstallation events.


Available Stages:

  • pre — Hook action allows for pre-installation validation and actions.
  • post — Hook action allows for post-installation validation and actions.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
web_vhost_namestring

Required

The vhost's name.

A valid vhost name.example.com
certificate_pemstring

Required

The certificate's in PEM format.

A valid SSL certificate in PEM format.
 Click to view...
-----BEGIN CERTIFICATE-----\r\n 
MIIEEzCCAvugAwIBAgIJALF/jFpw6p1bMA0GCSqGSIb3DQEBBQUAMIGfMRYwFAYD\r\n 
VQQDEw10ZXN0c2ltb24uY29tMRYwFAYDVQQLEw1Eb2N1bWVudGF0aW9uMQswCQYD\r\n 
VQQGEwJVUzEoMCYGCSqGSIb3DQEJARYZbGF1cmVuY2Uuc2ltb25AY3BhbmVsLm5l\r\n 
dDEUMBIGA1UEChMLY1BhbmVsIEluYy4xDjAMBgNVBAgTBVRleGFzMRAwDgYDVQQH\r\n 
EwdIb3VzdG9uMB4XDTEzMDUxNzE2MTMwN1oXDTE0MDUxNzE2MTMwN1owgZ8xFjAU\r\n 
BgNVBAMTDXRlc3RzaW1vbi5jb20xFjAUBgNVBAsTDURvY3VtZW50YXRpb24xCzAJ\r\n 
BgNVBAYTAlVTMSgwJgYJKoZIhvcNAQkBFhlsYXVyZW5jZS5zaW1vbkBjcGFuZWwu\r\n 
bmV0MRQwEgYDVQQKEwtjUGFuZWwgSW5jLjEOMAwGA1UECBMFVGV4YXMxEDAOBgNV\r\n 
BAcTB0hvdXN0b24wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDRO0AP\r\n 
N5XtjDqkEyJ6ctfYqUtt9yUXyRuCETFjW6opNLSmZSHeF6L2aZka646lhj02CFyl\r\n 
kzsNSxysN66tY+WZcTmvgPisJdQFpFvjroJZgDjYRV0QqokKdRy/5BU0+tHXoYpj\r\n 
9JOQlbvEWxiGR3R80sL1ma4AfSE6Gv8M/PULTadan51eHaikXqjOXdPJQKuWP3g9\r\n 
FnIuf38WRYwzGrre88qsZrpsMrADX5dotHWgqAf7Tap6xfA4CUAgQo9tldariuVi\r\n 
Bz+sRJ/Sjgxnhw1HYWGttBuBZFhMpdHpPnTJ7DIFMd/FN5gG/tah30SapWpo35Ux\r\n 
3BpJcdUjtazy82K5AgMBAAGjUDBOMB0GA1UdDgQWBBQAlv7/tALOYb7zAXbYG2+9\r\n 
AMI3xjAfBgNVHSMEGDAWgBQAlv7/tALOYb7zAXbYG2+9AMI3xjAMBgNVHRMEBTAD\r\n 
AQH/MA0GCSqGSIb3DQEBBQUAA4IBAQCxzpe71Hc7Es0dqIN7bhIFYIIgcr6wxM6a\r\n 
a9d+QG+QPH0x0KAqV8EgUbZysvyxEF0bPxW3ZAr1Is1wk80PMuU3bToFFVbFFIIr\r\n 
HRNfKLGvxiMXnZA1c6L4N0lowvXHgZxTTUXtDFLXyrcwrLsvUErEV7rbizuxqfPw\r\n 
caRtXn4uc+t6HYuW7yWesBauCWnJNiKbjN/F+uCTurN3QMAeWf3ZJtsfkAgk8dyq\r\n 
R/83a3kDtSPrpt+jX+qdjKEpRtQ5Qpm6XT2gCOQPgnfiUtOCH419pp922P/AAGc+\r\n 
ZUhYoWcRWKw/y6gI7Ru++9+8+wkadL9EbKMZxhVwD5qVm4ZlWK2a\r\n
                    
-----END CERTIFICATE-----%0
key_pemstring

Required

The certificate's key in PEM format.

A valid private key in PEM format.
 Click to view...

 -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eZfOLhsfDN1AoGBAKQTUEINsj+75psgbAr6 ELGgItJ9yPBLVRr+cUzEpx9LDWVvjMihpP4NX1gq8EOPWT+ewLHVmmsjCyV6xw8J XXF8e2xif3in0m3D/wCzE7u2T06rKM3B017hKnrZmGoHnrqPU2osM4sOUpshWX6d v1Q4EF1+fbK3YCW+VpCBsB9NAoGAQo+uhNLODee56iKkzpjXWCsFTq6ar3hD5F3P 63buKdNwhd2GlSPhXFbf+7M5GWW6BZk6rMvv7EOAVice2uvyFm8/4/1WbmF8R+T7 LX1rPLO5p/m701QpvP11TabiwqRkqtSEQhSRF0AKTojSW/yyHCZFAawUhV/Z9EKi HmKb97kCgYAyzmFc2it0HqnsOnRybop603nqMtWGTQO4cxa93HUDpYajuK2K3Dfr xUj6lG3z/oKJGGE2JqgZ6LBAhNJtJWJu2ox3pKGE63QjLJnVwb8y1NFYpe/crbLe PuBwIR0L7drXxfv7O5btY7h6QI2d1/UIAQPAWbxLoTM+ndQ/uPEdfA== -----END RSA PRIVATE KEY-----

cab_pemstring

The certificate's CA bundle in PEM format.

If you do not use this parameter, the system will automatically determine the appropriate CA bundle file to use.

A valid CA bundle in PEM format.
 Click to view...
-----BEGIN CERTIFICATE-----\r\n
MIIB+jCCAWMCAgGjMA0GCSqGSIb3DQEBBAUAMEUxCzAJBgNVBAYTAlVTMRgwFgYD\r\n
VQQKEw9HVEUgQ29ycG9yYXRpb24xHDAaBgNVBAMTE0dURSBDeWJlclRydXN0IFJv\r\n
b3QwHhcNOTYwMjIzMjMwMTAwWhcNMDYwMjIzMjM1OTAwWjBFMQswCQYDVQQGEwJV\r\n
UzEYMBYGA1UEChMPR1RFIENvcnBvcmF0aW9uMRwwGgYDVQQDExNHVEUgQ3liZXJU\r\n
cnVzdCBSb290MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC45k+625h8cXyv\r\n
RLfTD0bZZOWTwUKOx7pJjTUteueLveUFMVnGsS8KDPufpz+iCWaEVh43KRuH6X4M\r\n
ypqfpX/1FZSj1aJGgthoTNE3FQZor734sLPwKfWVWgkWYXcKIiXUT0Wqx73llt/5\r\n
1KiOQswkwB6RJ0q1bQaAYznEol44AwIDAQABMA0GCSqGSIb3DQEBBAUAA4GBABKz\r\n
dcZfHeFhVYAA1IFLezEPI2PnPfMD+fQ2qLvZ46WXTeorKeDWanOB5sCJo9Px4KWl\r\n
IjeaY8JIILTbcuPI9tl8vrGvU9oUtCG41tWW4/5ODFlitppK+ULdjG+BqXH/9Apy\r\n
bW1EDp3zdHSo1TRJ6V6e6bR64eVaH4QwnNOfpSXY\r\n
-----END CERTIFICATE-----
ReturnTypeDescriptionPossible valuesExample
rawoutstring

The function's raw output.

A valid string in HTML format.
 Click to view...

Certificate verification passed<br /> <br />
           The Certificate for the domain example.com was installed on the IP 192.168.0.20.
           </html><br><b>Finished SSL Install Process for example.com     
          (www.example.com).</b>

status

Boolean

Whether the function was successful.

  • 1 — Success.
  • 0 — Failure.
1

Domain::park


This event triggers whenever a user creates a domain alias (parks a domain).

Available Stages:

  • pre — Hook action code runs before the change.
  • post — Hook actions code runs after the change.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
target_domainstring

The domain name for which to create an alias.

A valid domain name.oldpackagename
new_domainstring

The domain name to which the alias will point.

A valid domain name.

newpackagename
userstringThe user who will create the alias.A valid username on the server.username
ParameterTypeDescriptionPossible valuesExample
target_domainstring

The domain name for which to create an alias.

A valid domain name.oldpackagename
new_domainstring

The domain name to which the alias will point.

A valid domain name.

newpackagename
userstringThe user who will create the alias.A valid username on the server.username

Lang::PHP::ini_set_content


Notes:

  • This event is only available in cPanel & WHM version 56 or later.
  • When you hook this event, you must also hook UAPI's LangPHP::php_ini_set_user_content function to ensure consistent behavior.

 

This event triggers when an administrator uploads a new complete php.ini file.

Available Stages:

  • pre — Hook action code runs before the change.
  • post — Hook actions code runs after the change.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

This event returns the WHM API 1 php_ini_set_content function's input parameters and values.

Lang::PHP::ini_set_directives


Notes:

This event triggers when an administrator changes the directives in the php.ini file.

Available Stages:

  • pre — Hook action code runs before the system changes the directives.
  • post — Hook actions code runs after the system changes the directives.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

This event returns the WHM API 1 php_ini_set_directives  function's input parameters and values.

Lang::PHP::set_handler


Note:

This event is only available in cPanel & WHM version 56 or later.

This event triggers when an administrator changes the handler that serves the PHP files for any version of PHP.

Available Stages:

  • pre — Hook action code runs before the system changes the handler.
  • post — Hook actions code runs after the system changes the handler.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

This event returns the WHM API 1 php_set_handler  function's input parameters and values.

Lang::PHP::set_system_default_version


Note:

This event is only available in cPanel & WHM version 56 or later.

 

This event triggers when an administrator changes the system default PHP version.

Available Stages:

  • pre — Hook action code runs before the system changes the default PHP version.
  • post — Hook actions code runs after the system changes the default PHP version.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

This event returns the WHM API 1 php_set_system_default_version  function's input parameters and values.

Lang::PHP::set_vhost_versions


Notes:

  • This event is only available in cPanel & WHM version 56 or later.
  • When you hook this event, you must also hook UAPI's LangPHP::php_set_vhost_versions function to ensure consistent behavior.

This event triggers when an administrator changes the PHP version for a specific virtual host.

Available Stages:

  • pre — Hook action code runs before the system changes the virtual host's PHP version.
  • post — Hook actions code runs after the system changes the virtual host's PHP version.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

This event returns the WHM API 1 php_set_vhost_versions  function's input parameters and values.

RemoteMySQL::activate_profile


Note:

This event is only available in cPanel & WHM version 62 or later.

This event triggers whenever the system activates a Remote MySQL® profile.

Available Stages:

  • pre — Hook action code runs before the system activates the remote profile.
  • post — Hook actions code runs after the system activates the remote profile.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Input parameters

Note:

The chosen stage determines the event's input. Select the appropriate tab to view input parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
profile_namestringThe Remote MySQL profile's name.A valid profile name on the server.

notlocalhost

ParameterTypeDescriptionPossible valuesExample
profile_namestringThe Remote MySQL profile's name.A valid profile name on the server.

notlocalhost

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

N/A

ParameterTypeDescriptionPossible valuesExample
resultBoolean

The Remote MySQL profile's name.

  • 1 — The function succeeded.

  • 0 — The function failed.

notlocalhost


ParkAdmin::park


This event triggers whenever the system parks a domain.

Available Stages:

  • pre — Hook action code runs before the system parks the domain.
  • post — Hook actions code runs after the system parks the domain.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
userstringThe cPanel account that owns the domains.A valid username on the server.

username

target_domainstringThe domain on which to park the new_domain domain.A valid domain.example.com
new_domainstringThe domain to park on the target_domain domain.A valid domain.parkeddomain.com
ParameterTypeDescriptionPossible valuesExample
userstringThe cPanel account that owns the domains.A valid username on the server.

username

target_domainstringThe domain on which the system parked the new_domain domain.A valid domain.example.com
new_domainstringThe domain that the system parked on the target_domain domain.A valid domain.parkeddomain.com


ParkAdmin::unpark


This event triggers whenever the system unparks a domain.

Available Stages:

  • pre — Hook action code runs before the system unparks the domain.
  • post — Hook actions code runs after the system unparks the domain.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
userstringThe cPanel account that owns the domains.A valid username on the server.

username

parent_domainstringThe domain on which the domain is parked.A valid domain.example.com
domainstringThe domain to unpark.A valid domain.parkeddomain.com
ParameterTypeDescriptionPossible valuesExample
userstringThe cPanel account that owns the domains.A valid username on the server.

username

parent_domainstringThe domain on which the domain was parked.A valid domain.example.com
domainstringThe unparked domain.A valid domain.parkeddomain.com

 

Packages::verify_input_data


 

This event triggers when an account package is added or modified.

Available Stages:

  • pre — Hook action allows for package field input checks and rejects the creation or modification of the package if values do not match desired criteria.
  • post — N/A

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
bwlimit string

The hosting plan's maximum bandwidth use.

This parameter defaults to unlimited.

  • A positive integer between one and 999,999 that represents the maximum bandwidth use, in Megabytes (MB).
  • 0unlimited, or null — The account has unlimited bandwidth.

unlimited

cgiBoolean

Whether CGI access is enabled for the account.

This parameter defaults to 1.

  • 1 — Enabled.
  • 0 — Disabled.

y

ip

string

Whether the account has a dedicated IP address.

This parameter defaults to n.

  • y — The account has a dedicated IP address.
  • n — The account does not have a dedicated IP address.

n

maxsubstringThe hosting plan's maximum number of subdomains.
  • unlimited
  • An integer that represents a number of subdomains.
unlimited

maxpop

string

The hosting plan's maximum number of email accounts.

This parameter defaults to unlimited.

  • A positive integer between one and 999,999.
  • 0unlimited, or null — The account has unlimited email accounts.
unlimited
maxlststringThe hosting plan's maximum number of mailing lists.
  • unlimited
  • An integer that represents a number of mailing lists.
unlimited
cpmodstring

The hosting plan's cPanel theme.

This parameter defaults to the server's default cPanel theme.

  • paper_lantern
  • A valid theme on the server.
paper_lantern
languagestring

The hosting plan's default locale.

This value defaults to the server's default locale.

A two-letter ISO-3166 code.en
featureliststringThe hosting plan's feature list.

If you do not use this parameter, the function assigns the default feature list to the hosting plan's accounts.

A valid feature list name on the server.default
maxftpstringThe hosting plan's maximum number of FTP accounts.

This parameter defaults to unlimited.

  • A positive integer between one and 999,999.
  • 0unlimited, or null — The account has unlimited FTP accounts.
unlimited
max_emails_per_hourstring

The maximum number of emails that the account can send in one hour.

This parameter defaults to unlimited.

Note:

This parameter is only available in cPanel & WHM version 11.32 or later.

  • A positive integer
  • 0 or unlimited — The account can send an unlimited number of emails.
unlimited.
maxaddonstring

The hosting plan's maximum number of addon domains.

This parameter defaults to unlimited.

  • A positive integer between one and 999,999.
  • 0unlimited, or null — The account has unlimited addon domains.
0
maxsqlstring

The hosting plan's maximum number of each available type of SQL database.

For example, if you set this value to 5 and the system administrator allows MySQL® and PostgreSQL® databases, users can create up to five MySQL databases and up to five PostgreSQL databases.

This parameter defaults to unlimited.

  • A positive integer between one and 999,999.
  • 0unlimited, or null — The account has unlimited databases.
unlimited
hasshellBoolean 

Whether the account has shell access.

This parameter defaults to 0.

  • 1 — The account has shell access.
  • 0 — No shell access.
n
editstring

Whether the users wishes to modify or add an existing package extension.

 

  • yes — The user wishes to modify an existing package extension.
  • no — The user wishes to add an existing package extension.


Note:

The edit parameter is part of the API call and not included in the package. The system displays yes when a user modifies an existing package extension and no when they wish to add one.

yes
max_defer_fail_percentagesinteger

The percentage of failed or deferred email messages that the account can send per hour before outgoing mail is rate-limited.

Note:

This parameter is only available in cPanel & WHM version 11.32 or later.

  • A positive integer.
  • 0 or unlimited — The account can send an unlimited number of failed or deferred messages.
unlimited
quotaintegerThe hosting plan's disk space quota.

This parameter defaults to 0 (unlimited).

  • A positive integer between one and 999,999 that represents the maximum disk space that the account may use, in Megabytes (MB).
  • 0 — The hosting plan's disk space is unlimited.
unlimited
maxparkstring

The hosting plan's maximum number of parked domains (aliases).

This parameter defaults to unlimited.

  • A positive integer between one and 999,999.
  • 0unlimited, or null — The account has unlimited parked domains.
0
namestringThe hosting plan name.An existing hosting plan name on the server.lvebishes
_package_extensions
string

The hosting plan's package extensions.

If you do not provide a value, the hosting plan will not include package extensions.

Note:

This parameter is only available in cPanel & WHM version 11.40 or later.

A space-delimited list of one or more package extensions on the server.

Notes:

  • You can also include the extension's variables in your function call, in key=value format. Consult the extension's documentation for a list of possible variables.
  •  Extension names and variables are case-sensitive.
extension1 extension2 extension3

digestauth

stringWhether to enable Digest Authentication for the account.
    • y — Enable.
    • n — Disable.
n

N/A

SSL::installssl


 

Note:

This event is only available in cPanel & WHM version 72 or later.

This event triggers when a system administrator manually installs or changes an SSL certificate via WHM interfaces or WHM API 1 functions.

Note:

This hook does not listen for SSL certificate uninstallation or AutoSSL events.


Available Stages:

  • pre — Hook action allows for pre-installation validation and actions.
  • post — Hook action allows for post-installation validation and actions.

Action Code Runs As:

root

Blocking Attribute:

Escalate Privileges Attribute:

N/A

Output parameters

Note:

The chosen stage determines the event's output. Select the appropriate tab to view output parameters for that stage. 

ParameterTypeDescriptionPossible valuesExample
domainstring

Required

The domain's name.

A valid domain name.example.com
crtstring

Required

The certificate's text.

A valid SSL certificate.
 Click to view...
-----BEGIN CERTIFICATE-----\r\n 
MIIEEzCCAvugAwIBAgIJALF/jFpw6p1bMA0GCSqGSIb3DQEBBQUAMIGfMRYwFAYD\r\n 
VQQDEw10ZXN0c2ltb24uY29tMRYwFAYDVQQLEw1Eb2N1bWVudGF0aW9uMQswCQYD\r\n 
VQQGEwJVUzEoMCYGCSqGSIb3DQEJARYZbGF1cmVuY2Uuc2ltb25AY3BhbmVsLm5l\r\n 
dDEUMBIGA1UEChMLY1BhbmVsIEluYy4xDjAMBgNVBAgTBVRleGFzMRAwDgYDVQQH\r\n 
EwdIb3VzdG9uMB4XDTEzMDUxNzE2MTMwN1oXDTE0MDUxNzE2MTMwN1owgZ8xFjAU\r\n 
BgNVBAMTDXRlc3RzaW1vbi5jb20xFjAUBgNVBAsTDURvY3VtZW50YXRpb24xCzAJ\r\n 
BgNVBAYTAlVTMSgwJgYJKoZIhvcNAQkBFhlsYXVyZW5jZS5zaW1vbkBjcGFuZWwu\r\n 
bmV0MRQwEgYDVQQKEwtjUGFuZWwgSW5jLjEOMAwGA1UECBMFVGV4YXMxEDAOBgNV\r\n 
BAcTB0hvdXN0b24wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDRO0AP\r\n 
N5XtjDqkEyJ6ctfYqUtt9yUXyRuCETFjW6opNLSmZSHeF6L2aZka646lhj02CFyl\r\n 
kzsNSxysN66tY+WZcTmvgPisJdQFpFvjroJZgDjYRV0QqokKdRy/5BU0+tHXoYpj\r\n 
9JOQlbvEWxiGR3R80sL1ma4AfSE6Gv8M/PULTadan51eHaikXqjOXdPJQKuWP3g9\r\n 
FnIuf38WRYwzGrre88qsZrpsMrADX5dotHWgqAf7Tap6xfA4CUAgQo9tldariuVi\r\n 
Bz+sRJ/Sjgxnhw1HYWGttBuBZFhMpdHpPnTJ7DIFMd/FN5gG/tah30SapWpo35Ux\r\n 
3BpJcdUjtazy82K5AgMBAAGjUDBOMB0GA1UdDgQWBBQAlv7/tALOYb7zAXbYG2+9\r\n 
AMI3xjAfBgNVHSMEGDAWgBQAlv7/tALOYb7zAXbYG2+9AMI3xjAMBgNVHRMEBTAD\r\n 
AQH/MA0GCSqGSIb3DQEBBQUAA4IBAQCxzpe71Hc7Es0dqIN7bhIFYIIgcr6wxM6a\r\n 
a9d+QG+QPH0x0KAqV8EgUbZysvyxEF0bPxW3ZAr1Is1wk80PMuU3bToFFVbFFIIr\r\n 
HRNfKLGvxiMXnZA1c6L4N0lowvXHgZxTTUXtDFLXyrcwrLsvUErEV7rbizuxqfPw\r\n 
caRtXn4uc+t6HYuW7yWesBauCWnJNiKbjN/F+uCTurN3QMAeWf3ZJtsfkAgk8dyq\r\n 
R/83a3kDtSPrpt+jX+qdjKEpRtQ5Qpm6XT2gCOQPgnfiUtOCH419pp922P/AAGc+\r\n 
ZUhYoWcRWKw/y6gI7Ru++9+8+wkadL9EbKMZxhVwD5qVm4ZlWK2a\r\n
                    
-----END CERTIFICATE-----%0
keystring

Required

The certificate's key.

A valid private key.
 Click to view...

 -----BEGIN RSA PRIVATE KEY----- MIIEpAIBAAKCAQEA4AVM6J4Qg3DIFWr/eJ5GRmIATYsJIepKbrDy70sq+udcO8R8 xxak0oMZ/9mUdp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XF8e2xif3in0m3D/wCzE7u2T06rKM3B017hKnrZmGoHnrqPU2osM4sOUpshWX6d v1Q4EF1+fbK3YCW+VpCBsB9NAoGAQo+uhNLODee56iKkzpjXWCsFTq6ar3hD5F3P 63buKdNwhd2GlSPhXFbf+7M5GWW6BZk6rMvv7EOAVice2uvyFm8/4/1WbmF8R+T7 LX1rPLO5p/m701QpvP11TabiwqRkqtSEQhSRF0AKTojSW/yyHCZFAawUhV/Z9EKi HmKb97kCgYAyzmFc2it0HqnsOnRybop603nqMtWGTQO4cxa93HUDpYajuK2K3Dfr xUj6lG3z/oKJGGE2JqgZ6LBAhNJtJWJu2ox3pKGE63QjLJnVwb8y1NFYpe/crbLe PuBwIR0L7drXxfv7O5btY7h6QI2d1/UIAQPAWbxLoTM+ndQ/uPEdfA== -----END RSA PRIVATE KEY-----

cabstring

The certificate's CA bundle.

If you do not use this parameter, the system will automatically determine the appropriate CA bundle file to use.

A valid CA bundle.
 Click to view...
-----BEGIN CERTIFICATE-----\r\n
MIIB+jCCAWMCAgGjMA0GCSqGSIb3DQEBBAUAMEUxCzAJBgNVBAYTAlVTMRgwFgYD\r\n
VQQKEw9HVEUgQ29ycG9yYXRpb24xHDAaBgNVBAMTE0dURSBDeWJlclRydXN0IFJv\r\n
b3QwHhcNOTYwMjIzMjMwMTAwWhcNMDYwMjIzMjM1OTAwWjBFMQswCQYDVQQGEwJV\r\n
UzEYMBYGA1UEChMPR1RFIENvcnBvcmF0aW9uMRwwGgYDVQQDExNHVEUgQ3liZXJU\r\n
cnVzdCBSb290MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC45k+625h8cXyv\r\n
RLfTD0bZZOWTwUKOx7pJjTUteueLveUFMVnGsS8KDPufpz+iCWaEVh43KRuH6X4M\r\n
ypqfpX/1FZSj1aJGgthoTNE3FQZor734sLPwKfWVWgkWYXcKIiXUT0Wqx73llt/5\r\n
1KiOQswkwB6RJ0q1bQaAYznEol44AwIDAQABMA0GCSqGSIb3DQEBBAUAA4GBABKz\r\n
dcZfHeFhVYAA1IFLezEPI2PnPfMD+fQ2qLvZ46WXTeorKeDWanOB5sCJo9Px4KWl\r\n
IjeaY8JIILTbcuPI9tl8vrGvU9oUtCG41tWW4/5ODFlitppK+ULdjG+BqXH/9Apy\r\n
bW1EDp3zdHSo1TRJ6V6e6bR64eVaH4QwnNOfpSXY\r\n
-----END CERTIFICATE-----
ipstring

The IP address of the certificate's domain.

This parameter defaults to the local IP address for the domain.

 

A valid IP address.192.168.0.20
enable_sni_for_mailBoolean

Whether SNI for mail is enabled.

Note:

We added this parameter in cPanel & WHM version 11.48.

This parameter defaults to 0.


  • 1 — Enabled.
  • 0 — Disabled.
1
ReturnTypeDescriptionPossible valuesExample
rawoutstring

The function's raw output.

A valid string in HTML format.
 Click to view...

Certificate verification passed<br /> <br />
           The Certificate for the domain example.com was installed on the IP 192.168.0.20.
           </html><br><b>Finished SSL Install Process for example.com     
          (www.example.com).</b>

status

Boolean

Whether the function was successful.

  • 1 — Success.
  • 0 — Failure.
1