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

Error rendering macro 'rw-search'

null

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Objects belonging to a user in a Primary or Client Organization can be retrieved and manipulated by using the web service calls categorized under this section. The information that is retrieved related to the object's metadata (that is the name, description, ID, etc. of reports and dashboards), and not the actual contents. To get actual data of a report (such as its HTML, or PDF), use Yellowfin's Report web services.

 

Report Objects

The following web service calls are related to obtaining or managing user's Yellowfin reports.

...

Expand
titleLOADTABREPORTS

This call is used to load metadata of dashboard tab reports accessible for a specific user. The user is to be specified through the AdministrationPerson object. You can provide a dashboard tab ID via the AdministrationReportGroup object to get report details of a specific tab.

 

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 "LOADTABREPORTS".

PersonAdministrationPersonObject containing details of the user. See table below.
OrgRefStringAn optional parameter to specify a client organization reference ID to search for the dashboard tab within it, instead of the default organization.
ReportGroupAdministrationReportGroupThis parameter is used to specify a dashboard tab whose report details are to be retrieved. See table below.

 

Anchor
loadtabreportap
loadtabreportap

These are the main parameters that you must set in the AdministrationPerson object for this web service call:

AdministrationPerson Element

Data Type

Description

UserId

String

To identify the user for whom to retrieve the dashboard. This could be the user ID or email address, depending on the Logon ID method.

 

Anchor
loadtabreprg
loadtabreprg

These are the main parameters that you must set in the AdministrationReportGroup object for this web service call:

AdministrationReportGroup Element

Data Type

Description

ReportGroupId

Integer

The ID of the dashboard tab.

 

 

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
ReportGroups

AdministrationReportGroup[]

 This array object contains dashboard reports’ metadata. This will contain only one item.

 

 

Instructions

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

Expand
titleStep-by-step instructions
  • Start with a basic request for this function, which includes logging in as the admin user and specifying the web service call to perform:

    Code Block
    languagejava
    AdministrationServiceRequest rsr = new AdministrationServiceRequest();
    
    rsr.setLoginId("admin@yellowfin.com.au");
    rsr.setPassword("test");
    rsr.setOrgId(1);
    
    rsr.setFunction("LOADTABREPORTS");
  • You may even identify a specific client organization:

    Code Block
    languagejava
    rsr.setOrgRef("org1");



  • Specify the user for whom to retrieve the report:

    Code Block
    languagejava
    AdministrationPerson ap = new AdministrationPerson();
    ap.setUserId("admin@yellowfin.com.au");
    
    rsr.setPerson(ap);
  • You may provide a dashboard tab or sub tab ID:

    Code Block
    languagejava
    AdministrationReportGroup rg = new AdministrationReportGroup();
    rg.setReportGroupId(61210);  // existing dashboard Id.
     
    rsr.setReportGroup(rg);



  • Once the request is configured, perform the call:

    Code Block
    languagejava
    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
    

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

 

  • The response will contain these parameters: StatusCode and ReportGroups. (See the Response Parameter section above for details on these.)

  • To retrieve the report details, use the following line:

    Code Block
    languagejava
    AdministrationReport[] reports = response.getReportGroups[0].getGroupReports();

 

 

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_ loadtabreports.jsp.
  2. Put the file in the root folder: Yellowfin/appserver/webapps/ROOT.
  3. Adjust the host, port, and admin user according to your environment.
  4. Run http://<host>:<port>/ws_ loadtabreports.jsp from your Internet browser.

 

Code Block
languagexml
themeEclipse
<%        	
/*          	ws_loadtabreports.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 the password of the above account
rsr.setOrgId(1);
rsr.setFunction("LOADTABREPORTS");
 
rsr.setOrgRef("org1");
 
AdministrationPerson ap = new AdministrationPerson();
ap.setUserId("test.user@yellowfin.com.au");    	
 
rsr.setPerson(ap);
 
AdministrationReportGroup rg = new AdministrationReportGroup();
rg.setReportGroupId(61210);
 
rsr.setReportGroup(rg);
 
AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
if ("SUCCESS".equals(rs.getStatusCode()) ) {
              	
              	AdministrationReportGroup[] tabs = rs.getReportGroups();
              	
              	if (tabs != null)
              	for (AdministrationReportGroup tab: tabs){
                                	out.write("<br>Tab Name: " + tab.getReportGroupName());
                                	out.write(tab.getGroupReports().length);
                                	AdministrationReport[] reports = tab.getGroupReports();
                                	for (AdministrationReport r: reports){
                                                  	out.write("<br><br>Report Name: " + r.getReportName());
                                                  	out.write("<br>Report Id: " + r.getReportId());
                                	}
              	}
              	
} else {
              	out.write("Failure");
              	out.write(" Code: " + rs.getErrorCode());
}
%>




 

 


 

Anchor
deletetab
deletetab

Expand
titleDELETETAB

Use this web service to delete a user dashboard tab or sub tab. The dashboard tab/sub tab must be specified by providing either the ID number or UUID. Use the AdministrationPerson object to specify the user.

 

 

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 "DELETETAB".

PersonAdministrationPersonObject containing details of the user whose dashboard tab is to be deleted. See table below.
OrgRefStringAn optional parameter to specify a client organization reference ID to search for the dashboard tab within it, instead of the default organization.
DashboardTabIdIntegerProvide the dashboard tab ID of the tab to be deleted. Or use the parameter below.
ParametersString[]Use this parameter to pass the UUID of the dashboard tab that is to be deleted, instead of using the parameter above.

 

Anchor
deltabap
deltabap

These are the main parameters that you must set in the AdministrationPerson object for this web service call:

AdministrationPerson Element

Data Type

Description

UserId

String

To identify the user whose dashboard tab is to be deleted. This could be the user ID or email address, depending on the Logon ID method.

 

 

Request Example

Below is a SOAP XML example for this request:

Code Block
languagexml
<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>DELETETAB</function>
            <person>
                <userId>admin@yellowfin.com.au</userId>              
            </person>
            <dashboardTabId>61243</dashboardTabId>
         </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:

Code Block
languagexml
<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>df716bf8bf6d71bd586da445e02b348e</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:

Expand
titleStep-by-step instructions
  • Start with a basic request for this function, which includes logging in as the admin user and specifying the web service call to perform:

    Code Block
    languagejava
    AdministrationServiceRequest rsr = new AdministrationServiceRequest();
    
    rsr.setLoginId("admin@yellowfin.com.au");
    rsr.setPassword("test");
    rsr.setOrgId(1);
    
    rsr.setFunction("DELETETAB");
  • You may even identify a specific client organization:

    Code Block
    languagejava
    rsr.setOrgRef("org1");



  • Specify the user for whom to retrieve the report:

    Code Block
    languagejava
    AdministrationPerson ap = new AdministrationPerson();
    ap.setUserId("admin@yellowfin.com.au");
    
    rsr.setPerson(ap);
  • You may either provide a dashboard tab or sub tab ID:

    Code Block
    languagejava
    rsr.setDashboardTabId(71081);



  • Or pass the dashboard tab or sub tab UUID:

    Code Block
    languagejava
    rsr.setParameters(new String[] {"0ac13905-aa14-4887-9718-44c29b11311b"});



  • Once the request is configured, perform the call:

    Code Block
    languagejava
    AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);
    

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

 

  • The response will contain StatusCode parameter.

 

 

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_ deletedashboard.jsp.
  2. Put the file in the root folder: Yellowfin/appserver/webapps/ROOT.
  3. Adjust the host, port, and admin user according to your environment.
  4. Run http://<host>:<port>/ws_ deletedashboard.jsp from your Internet browser.

 

Code Block
languagejava
themeEclipse
<%            
/*              ws_deletedashboard.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 above account
rsr.setOrgId(1);

rsr.setFunction("DELETETAB");
rsr.setOrgRef("org1");
AdministrationPerson ap = new AdministrationPerson();
ap.setUserId("admin@yellowfin.com.au");  			
rsr.setPerson(ap);

// pass the dashboard tab/subtab Id:
//rsr.setDashboardTabtId(71081);

// or dashboard tab/subtab UUID:
rsr.setParameters(new String[] {"0ac13905-aa14-4887-9718-44c29b11311b"});


AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr);

if ("SUCCESS".equals(rs.getStatusCode()) ) {
	out.write("<br>Dashboard tab has been deleted.");
} else {
		out.write("Failure");
		out.write(" Code: " + rs.getErrorCode());
}
%>

 


 

...