Child pages
  • WHM API 1 Functions - set_provider_display_configurations
Skip to end of metadata
Go to start of metadata

 

Description

This function sets the display configuration for the login button of an external authentication identity provider.

Examples


 JSON API
https://hostname.example.com:2087/cpsess##########/json-api/set_provider_display_configurations?api.version=1&provider_id=google&service_name=cpaneld&configurations=%7B"textcolor"%3A"FF9999"%7D
 XML API
https://hostname.example.com:2087/cpsess##########/xml-api/set_provider_display_configurations?api.version=1&provider_id=google&service_name=cpaneld&configurations=%7B"textcolor"%3A"FF9999"%7D
 Command Line
whmapi1 set_provider_display_configurations provider_id=google service_name=cpaneld configurations={\"textcolor\":\"FF9999\"}


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.
  • If you run CloudLinux™, you must use the full path of the whmapi1 command:

    /usr/local/cpanel/bin/whmapi1

 Output (JSON)
{
  "data": {},
  "metadata": {
    "reason": "OK",
    "version": 1,
    "result": 1,
    "command": "set_provider_display_configurations"
  }
}
 Output (XML)
<result>
    <metadata>
        <reason>OK</reason>
        <result>1</result>
        <version>1</version>
        <command>set_provider_display_configurations</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
service_namestring

Required

The cPanel & WHM service's name.

A valid service name:

    • cpaneld
    • whostmgrd
    • webmaild
cpaneld
provider_idstring

Required

The identity provider's key.

A valid identity provider's key.

cpanelid
configurationsJSON

Required

The display configuration.

A JSON-encoded key-value set that includes display configuration settings, such as:

  • display_name
  • label
  • icon
  • textcolor
  • icon_type
  • color
{"textcolor":"FF9999"}


Returns

This function only returns metadata.