Retrieving SSO Service Preferences
Use the get-prefs operation to retrieve preferences of the SSO service.
Request Packet
A request XML packet retrieving SSO service preferences includes the get-prefs operation node:
<packet version="1.5.2.0">
<sso>
<get-prefs/>
</sso>
</packet>
The get-prefs node is required. Data type: none.
Response Packet Structure
The get-prefs node of the output XML packet is presented by type SSOGetPrefsOutput (sso.xsd
) and structured as follows:
- The result node is required. It wraps the response retrieved from the server. Data type: resultType (
common.xsd
). - The status node is required. It specifies the execution status of the operation. Data type: string. Allowed values: ok | error.
- The errcode node is optional. Is returns the error code if the operation fails. Data type: integer.
- The errtext node is optional. It returns the error message if the operation fails. Data type: string.
- The prefs node is required. Data type: SSOPrefs (
sso.xsd
). It specifies SSO service preferences and has the following graphical presentation:If it is present, the following nodes are required:
- The idp-url node specifies URL of an IdP if Plesk is registered in the IdP. Data type: base64.
- The enabled node defines if SSO service is enabled. Data type: boolean.
- The application-id node stores Plesk application ID (created by the IdP) if Plesk is registered in the IdP. Data type: string.
Samples
This request packet retrieves SSO service preferences.
<packet version="1.5.1.0">
<sso>
<get-prefs/>
</sso>
</packet>
Response:
<packet version="1.5.1.0">
<sso>
<get-prefs>
<result>
<status>ok</status>
<prefs>
<idp-url>aHR0cHM6Ly9zc28uZXhhbXBsZS5jb206MTExNDMv</idp-url>
<enabled>true</enabled>
<application-id>ac688844-2d14-46a1-8b6a-93cfa</application-id>
</prefs>
</result>
</get-prefs>
</sso>
</packet>
If the SSO service is disabled, the response from the server can look as follows:
<packet version="1.5.1.0">
<sso>
<get-prefs>
<result>
<status>ok</status>
<prefs>
<enabled>false</enabled>
</prefs>
</result>
</get-prefs>
</sso>
</packet>