Page History
This section includes some additional web services that you can use.
Testing Functions
The following web services can be used for testing or other basic functions:
Anchor | ||||
---|---|---|---|---|
|
Expand | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
This function is used to perform a test call to check if the Yellowfin server is active. It simply returns a Success message if you are able to talk to the server, otherwise a Failure message is returned.
Request ParametersThe following parameters should be passed with this request:
Request ExampleBelow is a SOAP XML example for this request:
Response ParametersThe returned response will contain these parameters:
Response ExampleThe service will return the below response, according to our SOAP example:
InstructionsSee below for step-by-step instructions on how to perform this call, using a Java example:
Complete ExampleBelow is a full example of this web service call. To use it for yourself, carry out the following the steps:
|
Anchor | ||
---|---|---|
|
...
|
Expand | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
This is another web service that can be used to test whether the Yellowfin server is active or not. It simply attempts to talk to the server and returns either a Success or Failure response. Request ParametersThe following parameters should be passed with this request:
Request ExampleBelow is a SOAP XML example for this request:
Response ParametersThe returned response will contain these parameters:
Response ExampleThe service will return the below response, according to our SOAP example:
InstructionsSee below for step-by-step instructions on how to perform this call, using a Java example:
Complete Complete ExampleBelow is a full example of this web service call. To use it for yourself, carry out the following the steps:
|
SQL Query Functions
Anchor | ||||
---|---|---|---|---|
|
Category: User object retrieval
GETIDFORUUID
Error: soap e,g differs from description (doesnt pass content type in Parameters)
Expand | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||
This function fetches the internal ID of Yellowfin content by passing the UUID. The type of content that it can be used for includes, Views, Reports, Dashboards, and Data Transformation. Request ParametersThe following parameters should be passed with this request: | ||||||||||||||||||||||
Request Element | Data Type | Description | ||||||||||||||||||||
LoginId | String | An administrator account to connect to the Yellowfin web services. This can either 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 "GETIDFORUUID". | ||||||||||||||||||||
Parameters | String[] | Array of string values. The first string must contain the UUID, and the second should specify the type of content. The following content types are supported:
|
Expand | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
|
Request Parameters
The following parameters should be passed with this request:
Request Element | Data Type | Description |
---|---|---|
LoginId | String | An administrator account to connect to the Yellowfin web services. This can either 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 "METADATASQLQUERY". |
Query | String | The SQL query that you want to perform on the Yellowfin database. |
Parameters | String[] | Use this to pass the Yellowfin database password. Only the first element of the array is required (which you can set as the password). However, if this requirement has been disabled (as mentioned in the steps above, then this parameter will not be required. |
Request Example
Below is a SOAP XML example for this request:
Code Block | ||
---|---|---|
| ||
<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>METADATASQLQUERY</function>
<query>SELECT * FROM person</query>
</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:
|
QueryResults | ReportRow | Array of the result set rows if SELECT was the request query. |
Response Example
The service will return the below response, according to our SOAP example:
Code Block | ||
---|---|---|
| ||
<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>
<queryResults>
<dataValue>5</dataValue>
<dataValue>Administrator</dataValue>
<dataValue>System</dataValue>
<dataValue/>
<dataValue/>
<dataValue xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
<dataValue>ATMN SSTM</dataValue>
<dataValue/>
<dataValue>System Administrator</dataValue>
<dataValue>System Administrator</dataValue>
<dataValue>EN</dataValue>
<dataValue>PRIVATE</dataValue>
<dataValue>4</dataValue>
<dataValue>EMAIL</dataValue>
<dataValue xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
<dataValue xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
<dataValue xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
<dataValue>AUSTRALIA/SYDNEY</dataValue>
<dataValue xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
<dataValue xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
<dataValue xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
<dataValue>ACTIVE</dataValue>
</queryResults>
<sessionId>804451ca30ad4a3065e4b67a9293440c</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 | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||||||
|
Request Example
Below is a SOAP XML example for this request:
Code Block | |||||||
---|---|---|---|---|---|---|---|
| |||||||
<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>
|
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 | ||||||
---|---|---|---|---|---|---|
| ||||||
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
<S:Body>
|
Complete Example
Below is a full example of this web service call. To use it for yourself, carry out the following the steps:
- Copy the code and save it as ws_metadatasqlquery.jsp.
- Put the file in the root folder: Yellowfin/appserver/webapps/ROOT.
- Adjust the host, port, and admin user details according to your environment.
- Run http://<host>:<port>/ws_metadatasqlquery.jsp from your Internet browser.
Code Block | ||||
---|---|---|---|---|
| ||||
<% <messages>Successfully Authenticated User: admin@yellowfin.com.au</messages> <messages>Web Service Request Complete</messages> /* <sessionId>b79bbf6c3f4c24d957db9ca2c3838710</sessionId> ws_metadatasqlquery.jsp <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 | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||||||||||
Code Block | ||||||||||||||||||
| ||||||||||||||||||
Define the request for this function, which includes logging in as the admin user and specifying the web service call to perform:
Pass the UUID and type of the Yellowfin content whose ID is required.
Initialize the Administration web service. Click here to learn how to do this. Add the following code to retrieve the response. If successful, display the entity ID (that is the ID of the content). Code Block | | |||||||||||||||||
|
Complete Example
Below is a full example of this web service call. To use it for yourself, carry out the following the steps:
- Copy the code and save it as ws_idforuuid.jsp.
- Put the file in the root folder: Yellowfin/appserver/webapps/ROOT.
- Adjust the host, port, and admin user details according to your environment.
- Run http://<host>:<port>/ws_idforuuid.jsp from your Internet browser.
<% for (ReportRow rr: rows){ String[] str = rr.getDataValue(); out.write("<br>"); /* ws_idforuuid.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");for (String s: str) // provide your Yellowfin web services admin account rsr.setPassword("test"); out.write("<br>" + s); // set to the password of the account above rsr.setOrgId(1); rsr.setFunction("GETIDFORUUID"); rsr.setParameters(new String[]{"fb6416c4-441e-42b3-a442-e7426f25f6b4","VIEW"}); AdministrationServiceResponse rs = adminService.remoteAdministrationCall(rsr); if ("SUCCESS".equals(rs.getStatusCode()) ) { out.write("<br>Success"); out.write("<br>ID: " + rs.getEntityId()); } } else { out.write("<br>Failure"); out.write(" Code: " + rs.getErrorCode()); } %> |
|