- Created by Documentation, last modified on Apr 09, 2018
Use WHM API to Call cPanel API & UAPI
disable_authentication_provider
disable_failing_authentication_providers
enable_authentication_provider
get_available_authentication_providers
get_provider_client_configurations
get_provider_configuration_fields
get_provider_display_configurations
get_users_authn_linked_accounts
set_provider_client_configurations
set_provider_display_configurations
twofactorauth_generate_tfa_config
twofactorauth_get_user_configs
cpgreylist_is_server_netblock_trusted
cpgreylist_list_entries_for_common_mail_provider
cpgreylist_load_common_mail_providers_config
cpgreylist_save_common_mail_providers_config
cpgreylist_trust_entries_for_common_mail_provider
cpgreylist_untrust_entries_for_common_mail_provider
create_cpgreylist_trusted_host
delete_cpgreylist_trusted_host
Description
This function retrieves the server's custom style. You can set the custom style through WHM's Customization interface (Home >> cPanel >> Customization) or with WHM API 1's
save_style
function.
Notes:
- In cPanel & WHM version 58 to 11.48, WHM's Customization interface (Home >> cPanel >> Customization) was the Branding interface (Home >> cPanel >> Branding).
- In cPanel & WHM version 11.48 and earlier, WHM's Branding interface (Home >> cPanel >> Branding) was the Customize Paper Lantern interface (Home >> cPanel >> Customize Paper Lantern).
Examples
https://hostname.example.com:2087/cpsess##########/json-api/load_style?api.version=1
https://hostname.example.com:2087/cpsess##########/xml-api/load_style?api.version=1
whmapi1 load_style
Notes:
- 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. - We introduced this functionality in cPanel & WHM version 11.52.0.8.
{ "metadata":{ "result":1, "reason":"Ok", "version":1, "command":"load_style" }, "data":{ "help_url":"http://example.com/help/", "favicon":"favicon.ico", "company_name":"Example Company", "branding_dir":"/var/cpanel/customizations/brand", "documentation_url":"http://example.com/documentation/", "webmail_logo":"webmail.png", "company_logo":"logo.png" } }
<result> <data> <favicon>/var/cpanel/customizations/brand</favicon> <company_name>Example Company</company_name> <branding_dir/var/cpanel/customizations/brand</branding_dir> <webmail_logo>webmail.png</webmail_logo> <company_logo>logo.png</company_logo> <documentation_url>http://example.com/documentation/</documentation_url> <help_url>http://example.com/help/</help_url> </data> <metadata> <version>1</version> <reason>Ok</reason> <result>1</result> <command>load_style</command> </metadata> </result>
Note:
Parameters
This function does not accept parameters.
Returns
Return | Type | Description | Possible values | Example |
---|---|---|---|---|
company_name | string | The company name. |
| Example Corporation |
help_url | string | The reseller's help system URL. |
| http://example.com/help/ |
documentation_url | string | The reseller's documentation URL. |
| http://example.com/documentation/ |
style_dir | string | The style information's location. |
| /var/cpanel/customizations/brand |
company_logo | string | The filename for the logo that displays in the cPanel interface. |
| logo.png |
webmail_logo | string | The filename for the logo that displays in the Webmail interface. Note: We added this return in cPanel & WHM version 60. |
| webmail.png |
favicon | string | The favicon file's name. |
| favicon.png |
Function information
API Version:
Available in:
WHM 11.44+
Methods:
GET, POST
Required Parameters:
(none)
Return Formats:
About WHM API 1
WHM API 1 performs functions and accesses data in WHM.
Notes:
- Some functions and parameters may require that the you authenticate as the
root
user. - You must use the appropriate WHM ports (
2086
or2087
) to call WHM API functions.
Find a function
Related functions
-
Page:WHM API 1 Functions - load_style — This function retrieves the server's custom style.
-
Page:WHM API 1 Functions - save_style — This function saves the server's custom style.
-
Page:WHM API 1 Functions - remove_logo — This function removes an existing logo or favicon.
-
Page:WHM API 1 Functions - list_styles — This function lists the server's cPanel styles.
-
Page:WHM API 1 Functions - set_default — This function sets the default cPanel style.