Like what you see? Have a play with our trial version.

Error rendering macro 'rw-search'

null

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 9 Current »

The following web services can be used to configure Yellowfin.


This function updates the system configuration settings in Yellowfin. This works by changing the setting details directly in the Configuration table in Yellowfin’s database, however only the general system settings are affected, not any custom settings. Yellowfin determines these by checking the ConfigTypeCode column for the value “SYSTEM”. Therefore, this mainly effects the default organization.

Once the database table has been updated, you will need to restart Yellowfin for these changes to take effect.  


Request Parameters

The following parameters should be passed with this request:

Request Element

Data Type

Description

LoginId

String

An admin account to connect to Yellowfin web services. This can be the user ID or the email address, depending on the Logon ID method.

This account must have the “web services” role enabled, and must belong to the default (i.e. primary) org.

Password

String

Password of the above account.

OrgId

Integer

Default (i.e. primary) organization ID within Yellowfin. Always set this to 1.

Function

String

Web service function. Set this to "SAVECONFIGURATION".

ParametersString[]Array of strings. This parameter is used to pass the configuration settings. The first string should be the content for configCode, and the second is for configData of Configuration table.
ClientAdministrationClientOrgThis optional parameter is used to specify a particular client organization whose configurations are to be updated. However, if one is not specified, then the configuration settings will be applied to the default org. It must be noted, however, that the majority of the configuration settings are global and cannot be set up for a particular client.

 

Below are the mandatory parameters that you need to set in the AdministrationClientOrg object to create a new user:

ParameterData TypeDescription

ClientReferenceId

String

The unique ID used to identify a client.



Request Example

Below is a SOAP XML example for this request:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <web:remoteAdministrationCall>
         <arg0>
          <loginId>admin@yellowfin.com.au</loginId>
            <password>test</password>
            <orgId>1</orgId>
            <function>SAVECONFIGURATION</function>
            <parameters>Simple_Authentication</parameters>
            <parameters>true</parameters>      
         </arg0>
      </web:remoteAdministrationCall>
   </soapenv:Body>
</soapenv:Envelope>

 

 

Response Parameters

The returned response will contain these parameters:

Response Element

Data Type

Description

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

 

Response Example

The service will return the below response, according to our SOAP example:

<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
   <S:Body>
      <ns2:remoteAdministrationCallResponse xmlns:ns2="http://webservices.web.mi.hof.com/">
         <return>
            <errorCode>0</errorCode>
            <messages>Successfully Authenticated User: admin@yellowfin.com.au</messages>
            <messages>Web Service Request Complete</messages>
            <sessionId>15359eb5b3d7d2c63c6f43affe5f3b45</sessionId>
            <statusCode>SUCCESS</statusCode>
         </return>
      </ns2:remoteAdministrationCallResponse>
   </S:Body>
</S:Envelope>

 

 

Instructions

See below for step-by-step instructions on how to perform this call, using a Java example:

  • Define the request for this function, which includes logging in as the admin user and specifying the web service call to perform:

    AdministrationServiceRequest rsr = new AdministrationServiceRequest();
     
    rsr.setLoginId("admin@yellowfin.com.au");      	
    rsr.setPassword("test");  
    rsr.setOrgId(1);
    rsr.setFunction("SAVECONFIGURATION");
  • Pass the configuration setting to be updated in the Parameters object. The code example below sets Yellowfin's authentication method to Simple.

    rsr.setParameters(new String[]{"SIMPLE_AUTHENTICATION","TRUE"});
  • Once the request is configured, perform the call:

    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);

    Initialize the Administration web service. Click here to learn how to do this. 

 

  • Add the following code to retrieve the response. The response will contain the StatusCode. (See details in the Response Parameters table above.)

    if ("SUCCESS".equals(rs.getStatusCode()) ) {
                  	out.write("<br>Success");
                  	}
                  	else {
                  	out.write("<br>Failure");
                  	out.write(" Code: " + rs.getErrorCode());
                  	}     

 

 

Complete Example

Below is a full example of this web service call. To use it for yourself, carry out the following the steps:

  1. Copy the code and save it as ws_saveconfiguration.jsp.
  2. Put the file in the root folder: Yellowfin/appserver/webapps/ROOT.
  3. Adjust the host, port, and admin user details according to your environment.
  4. Run http://<host>:<port>/ws_saveconfiguration.jsp from your Internet browser.

 

<%        	
/*          	ws_SAVECONFIGURATION.jsp                     	*/
%>
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %>
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%
 
/*          	
	This example sets Yellowfin authentication method to Simple.
    That means, once Yellowfin has been restarted, the
    LOGINUSERNOPASSWORD call can be used to log users into Yellowfin with no password provided.
*/
 
AdministrationServiceService s_adm = new AdministrationServiceServiceLocator("localhost",8080, "/services/AdministrationService", false);    	// adjust host and port number
AdministrationServiceSoapBindingStub adminService = (AdministrationServiceSoapBindingStub) s_adm.getAdministrationService();
AdministrationServiceRequest rsr = new AdministrationServiceRequest();
 
rsr.setLoginId("admin@yellowfin.com.au");      	// provide your Yellowfin webservices admin account
rsr.setPassword("test");                        // set to the password of the account above
rsr.setOrgId(1);
rsr.setFunction("SAVECONFIGURATION");
 
rsr.setParameters(new String[]{"SIMPLE_AUTHENTICATION","TRUE"});
AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
 
if ("SUCCESS".equals(rs.getStatusCode()) ) {
              	out.write("<br>Success");
              	}
              	else {
              	out.write("<br>Failure");
              	out.write(" Code: " + rs.getErrorCode());
              	}             	
%>

 


 

This function updates the custom configuration settings in Yellowfin. The custom parameters are those that can be applied to a client organization. This works by changing the details directly in the Configuration table in Yellowfin’s database. Yellowfin determines which settings to change by checking the ConfigTypeCode column for the value “CUSTOM”.

Once the database table has been updated, you will need to restart Yellowfin for these changes to take affect. 


Request Parameters

The following parameters should be passed with this request:

Request Element

Data Type

Description

LoginId

String

An admin account to connect to Yellowfin web services. This can be the user ID or the email address, depending on the Logon ID method.

This account must have the “web services” role enabled, and must belong to the default (i.e. primary) org.

Password

String

Password of the above account.

OrgId

Integer

Default (i.e. primary) organization ID within Yellowfin. Always set this to 1.

Function

String

Web service function. Set this to " SAVECUSTOMPARAMETER".

ParametersString[]Array of strings. Set the first string to the value of configCode, and the second to that of the configData column of the Configuration table.
ClientAdministrationClientOrgThis optional parameter is used to specify a particular client organization whose configurations are to be updated. However, if one is not specified, then the configuration settings will be applied to the default org.

 

Below are the mandatory parameters that you need to set in the AdministrationClientOrg object to create a new user:

ParameterData TypeDescription

ClientReferenceId

String

The unique ID used to identify a client organization.



Request Example

Below is a SOAP XML example for this request:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:web="http://webservices.web.mi.hof.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <web:remoteAdministrationCall>
         <arg0>
          <loginId>admin@yellowfin.com.au</loginId>
            <password>test</password>
            <orgId>1</orgId>
            <function>SAVECUSTOMPARAMETER</function>
            <parameters>Simple_Authentication</parameters>
            <parameters>true</parameters>      
         </arg0>
      </web:remoteAdministrationCall>
   </soapenv:Body>
</soapenv:Envelope>

 

 

Response Parameters

The returned response will contain these parameters:

Response Element

Data Type

Description

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

 

Response Example

The service will return the below response, according to our SOAP example:

<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
   <S:Body>
      <ns2:remoteAdministrationCallResponse xmlns:ns2="http://webservices.web.mi.hof.com/">
         <return>
            <errorCode>0</errorCode>
            <messages>Successfully Authenticated User: admin@yellowfin.com.au</messages>
            <messages>Web Service Request Complete</messages>
            <sessionId>471080457c1359cbf09c29cd348f97d1</sessionId>
            <statusCode>SUCCESS</statusCode>
         </return>
      </ns2:remoteAdministrationCallResponse>
   </S:Body>
</S:Envelope>

 

 

Instructions

See below for step-by-step instructions on how to perform this call, using a Java example:

  • Define the request for this function, which includes logging in as the admin user and specifying the web service call to perform:

    AdministrationServiceRequest rsr = new AdministrationServiceRequest();
     
    rsr.setLoginId("admin@yellowfin.com.au"); 
    rsr.setPassword("test");   
    rsr.setOrgId(1);
    rsr.setFunction("SAVECUSTOMPARAMETER"); 
  • Pass the configuration setting to be updated in the Parameters object. The code example below sets Yellowfin's authentication method to 'Simple'.

    rsr.setParameters(new String[]{"SIMPLE_AUTHENTICATION","TRUE"});
  • Once the request is configured, perform the call:

    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);

    Initialize the Administration web service. Click here to learn how to do this. 

 

  • Add the following code to retrieve the response. The response will contain the StatusCode. (See details in the Response Parameters table above.)

    if ("SUCCESS".equals(rs.getStatusCode()) ) {
                  	out.write("<br>Success");
                  	}
                  	else {
                  	out.write("<br>Failure");
                  	out.write(" Code: " + rs.getErrorCode());
                  	}     

 

 

Complete Example

Below is a full example of this web service call. To use it for yourself, carry out the following the steps:

  1. Copy the code and save it as ws_savecustomparameter.jsp.
  2. Put the file in the root folder: Yellowfin/appserver/webapps/ROOT.
  3. Adjust the host, port, and admin user details according to your environment.
  4. Run http://<host>:<port>/ws_savecustomparameter.jsp from your Internet browser.

 

<%        	
/*          	ws_savecustomparameter.jsp                       */
%>
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %>
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%
 
/*          	
	This example set Yellowfin authentication method to Simple.
    That means, once Yellowfin has been restarted,
    LOGINUSERNOPASSWORD call can be used to log users into Yellowfin with no password provided.
*/
 
AdministrationServiceService s_adm = new AdministrationServiceServiceLocator("localhost",8080, "/services/AdministrationService", false);    // adjust host and port number
AdministrationServiceSoapBindingStub adminService = (AdministrationServiceSoapBindingStub) s_adm.getAdministrationService();
AdministrationServiceRequest rsr = new AdministrationServiceRequest();
 
rsr.setLoginId("admin@yellowfin.com.au");      	// provide your Yellowfin web services admin account
rsr.setPassword("test");                        // change to the password of the account above
rsr.setOrgId(1);
rsr.setFunction("SAVECUSTOMPARAMETER");
 
rsr.setParameters(new String[]{"SIMPLE_AUTHENTICATION","TRUE"});
AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
 
if ("SUCCESS".equals(rs.getStatusCode()) ) {
              	out.write("<br>Success");
              	}
              	else {
              	out.write("<br>Failure");
              	out.write(" Code: " + rs.getErrorCode());
              	}             	
%>

 


 

This web service retrieves the current system configuration details of Yellowfin. This is done by specifying a ConfigCode element; the system then fetches the values saved in that element’s corresponding ConfigData column of the Configuration table in Yellowfin’s database. Note that only system (and not custom) parameters are loaded, as Yellowfin checks for values that contain “SYSTEM” in the ConfigTypeCode column.

For instance, using this you can verify if simple authentication is enabled, that allows users to log in without a password.


Request Parameters

The following parameters should be passed with this request:

Request Element

Data Type

Description

LoginId

String

An admin account to connect to Yellowfin web services. This can be the user ID or the email address, depending on the Logon ID method.

This account must have the “web services” role enabled, and must belong to the default (i.e. primary) org.

Password

String

Password of the above account.

OrgId

Integer

Default (i.e. primary) organization ID within Yellowfin. Always set this to 1.

Function

String

Web service function. Set this to "LOADCONFIGURATION".

ParametersString[]Array of strings. This is used to pass the value of the ConfigCode element.
ClientAdministrationClientOrgThis optional parameter is used to specify a particular client organization whose configurations are to be updated. However, if one is not specified, then the configuration settings will be applied to the default org.

 

Below are the mandatory parameters that you need to set in the AdministrationClientOrg object to create a new user:

ParameterData TypeDescription

ClientReferenceId

String

The unique ID used to identify a client organization.


 

Response Parameters

The returned response will contain these parameters:

Response Element

Data Type

Description

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

BinaryData

String

Contains the configData value of the specified Configuration.configCode element (from Yellowfin's Configuration database). Null will be returned if no such ConfigCode is found in the Configuration table.

 

Instructions

See below for step-by-step instructions on how to perform this call, using a Java example:

  • Define the request for this function, which includes logging in as the admin user and specifying the web service call to perform:

    AdministrationServiceRequest rsr = new AdministrationServiceRequest();
     
    rsr.setLoginId("admin@yellowfin.com.au"); 
    rsr.setPassword("test");   
    rsr.setOrgId(1);
    rsr.setFunction("LOADCONFIGURATION"); 
  • Pass the configuration setting to be updated in the Parameters object. The code example below sets Yellowfin's authentication method to 'Simple'.

    rsr.setParameters(new String[]{"SIMPLE_AUTHENTICATION"});
  • Once the request is configured, perform the call:

    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);

    Initialize the Administration web service. Click here to learn how to do this. 

 

  • Add the following code to retrieve the response. (See the response that is returned in the Response Parameters table above.)

    if ("SUCCESS".equals(rs.getStatusCode()) ) {
                  	out.write("<br>Success");
    				String data = rs.getBinaryData();
                  	out.write("<br>ConfigData: " + data);
                  	}
    else {
                  	out.write("<br>Failure");
                  	out.write(" Code: " + rs.getErrorCode());
    }       

 

 

Complete Example

Below is a full example of this web service call. To use it for yourself, carry out the following the steps:

  1. Copy the code and save it as ws_loadconfiguration.jsp.
  2. Put the file in the root folder: Yellowfin/appserver/webapps/ROOT.
  3. Adjust the host, port, and admin user details according to your environment.
  4. Run http://<host>:<port>/ws_loadconfiguration.jsp from your Internet browser.

 

<%        	
/*          	ws_loadconfiguration.jsp                   	*/
%>
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %>
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>
<%
AdministrationServiceService s_adm = new AdministrationServiceServiceLocator("localhost",8080, "/services/AdministrationService", false);    	// adjust host and port number
AdministrationServiceSoapBindingStub adminService = (AdministrationServiceSoapBindingStub) s_adm.getAdministrationService();
AdministrationServiceRequest rsr = new AdministrationServiceRequest();
 
rsr.setLoginId("admin@yellowfin.com.au");      	// provide your Yellowfin webservices admin account
rsr.setPassword("test");                                                    	// change to be the password of the account above
rsr.setOrgId(1);
rsr.setFunction("LOADCONFIGURATION");
 
rsr.setParameters(new String[]{"SIMPLE_AUTHENTICATION"});
AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
 
if ("SUCCESS".equals(rs.getStatusCode()) ) {
              	out.write("<br>Success");
String data = rs.getBinaryData();
              	out.write("<br>ConfigData: " + data);
              	}
else {
              	out.write("<br>Failure");
              	out.write(" Code: " + rs.getErrorCode());
}             	
%>

 


 

This web service retrieves the custom configuration details of Yellowfin. This is done by specifying a ConfigCode element; the system then fetches the values saved in that element’s corresponding ConfigData column of the Configuration table in Yellowfin’s database. Only custom parameters are loaded, as Yellowfin checks for values that contain “CUSTOM” in the ConfigTypeCode column.

For instance, using this you can verify if simple authentication is enabled, that allows users to log in without a password.


Request Parameters

The following parameters should be passed with this request:

Request Element

Data Type

Description

LoginId

String

An admin account to connect to Yellowfin web services. This can be the user ID or the email address, depending on the Logon ID method.

This account must have the “web services” role enabled, and must belong to the default (i.e. primary) org.

Password

String

Password of the above account.

OrgId

Integer

Default (i.e. primary) organization ID within Yellowfin. Always set this to 1.

Function

String

Web service function. Set this to " LOADCUSTOMPARAMETER".

ParametersString[]Array of strings. This is used to pass the value of the ConfigCode element.
ClientAdministrationClientOrgThis optional parameter is used to specify a particular client organization whose configurations are to be updated. However, if one is not specified, then the configuration settings will be applied to the default org.

 

Below are the mandatory parameters that you need to set in the AdministrationClientOrg object to create a new user:

ParameterData TypeDescription

ClientReferenceId

String

The unique ID used to identify a client organization.


 

Response Parameters

The returned response will contain these parameters:

Response Element

Data Type

Description

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

BinaryData

String

Contains the configData value of the specified Configuration.configCode element (from Yellowfin's Configuration database). Null will be returned if no such ConfigCode is found in the Configuration table.

 

Instructions

See below for step-by-step instructions on how to perform this call, using a Java example:

  • Define the request for this function, which includes logging in as the admin user and specifying the web service call to perform:

    AdministrationServiceRequest rsr = new AdministrationServiceRequest();
     
    rsr.setLoginId("admin@yellowfin.com.au"); 
    rsr.setPassword("test");   
    rsr.setOrgId(1);
    rsr.setFunction("LOADCONFIGURATION"); 
  • Pass the configuration setting to be updated in the Parameters object. The code example below sets Yellowfin's authentication method to 'Simple'.

    rsr.setParameters(new String[]{"SIMPLE_AUTHENTICATION"});
  • Once the request is configured, perform the call:

    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);

    Initialize the Administration web service. Click here to learn how to do this. 

 

  • Add the following code to retrieve the response. (See the response that is returned in the Response Parameters table above.)

    if ("SUCCESS".equals(rs.getStatusCode()) ) {
                  	out.write("<br>Success");
    				String data = rs.getBinaryData();
                  	out.write("<br>ConfigData: " + data);
                  	}
    else {
                  	out.write("<br>Failure");
                  	out.write(" Code: " + rs.getErrorCode());
    }   

 

 

Complete Example

Below is a full example of this web service call. To use it for yourself, carry out the following the steps:

  1. Copy the code and save it as ws_loadcustomparameter.jsp.
  2. Put the file in the root folder: Yellowfin/appserver/webapps/ROOT.
  3. Adjust the host, port, and admin user details according to your environment.
  4. Run http://<host>:<port>/ws_loadcustomparameter.jsp from your Internet browser.

 

/*          	ws_loadcustomparameter.jsp                     	*/
%>
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
<%@ page import="com.hof.util.*, java.util.*, java.text.*" %>
<%@ page import="com.hof.web.form.*" %>
<%@ page import="com.hof.mi.web.service.*" %>

<%
AdministrationServiceService s_adm = new AdministrationServiceServiceLocator("localhost",8080, "/services/AdministrationService", false);    	// adjust host and port number
AdministrationServiceSoapBindingStub adminService = (AdministrationServiceSoapBindingStub) s_adm.getAdministrationService();
AdministrationServiceRequest rsr = new AdministrationServiceRequest();
 
rsr.setLoginId("admin@yellowfin.com.au");      	// provide your Yellowfin web services admin account
rsr.setPassword("test");                        // set to the password of the account above
rsr.setOrgId(1);
rsr.setFunction("LOADCUSTOMPARAMETER");
 
rsr.setParameters(new String[]{"SIMPLE_AUTHENTICATION"});
AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
 
if ("SUCCESS".equals(rs.getStatusCode()) ) {
              	out.write("<br>Success");
String data = rs.getBinaryData();
              	out.write("<br>ConfigData: " + data);
              	}
else {
              	out.write("<br>Failure");
              	out.write(" Code: " + rs.getErrorCode());
}             	
%>

 


 

  • No labels