30日間の無料評価版をお試しいただけます。

Versions Compared

Key

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

...

Expand
titleADDUSER

The following code will call the Yellowfin web service to create a user:

Code Block
AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

person.setUserId("test@yellowfin.com.au");
person.setPassword("test");
person.setFirstName("Simple");
person.setLastName("Simon");
person.setInitial("S");
person.setSalutationCode("MR");
person.setRoleCode("YFADMIN");
person.setEmailAddress("test@yellowfin.com.au");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("ADDUSER");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

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

This code will return SUCCESS in rs.getStatusCode(), otherwise it will return an error message explaining why the user creation process failed.

This function will create a user in Yellowfin. The details in the AdministrationPerson object will be used in the user creation process.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices ieg. e admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "ADDUSER"

 

Web services function

setFunction()

Person

AdministrationPerson

The AdministrationPerson object holding all of the new user's details for the user creation process

setPerson()

These are the parameters that you need to set in the AdministrationPerson object:

AdministrationPerson Element

Data Type

Description

Setting Code

UserId

String

User ID of the new user. This can be the user ID or the email address, depending on the Logon ID method

setUserId()

Password

String

Password of the new user

setPassword()

FirstName

String

First name of of the new user

setFirstName()

LastName

String

Last name of of the new user

setLastName()

Initial

String

Middle name of the new user

setInitial()

SalutationCode

String

Title of the new user. Possible values include:

  • DR
  • MISS
  • MR
  • MRS
  • MS

setSalutationCode()

RoleCode

String

Yellowfin role. The specified role here can be the Org Reference Code (YFADMIN) or the name of the role (Yellowfin Administrator)

setRoleCode()

EmailAddress

String

Email address of the new user

setEmailAddress()

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

Expand
titleDELUSER / DELETEUSER

The following code will call the Yellowfin web service to create a user:

Code Block
AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

person.setUserId("test@yellowfin.com.au");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("DELUSER");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

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

This code will return SUCCESS in rs.getStatusCode(), otherwise it will return an error message explaining why the user creation process failed.

Retrieving & Validating User Information

Once a user has been created, the user's details can be retrieved using a web service call. The User ID field in the AdministrationPerson object is used to identify the user. As a result, a populated AdministrationPerson object will be returned. For security reasons, passwords will not be returned and will be NULL. User information can also be validated against the application in this section.

Expand
titleGETUSER

The following code will call the Yellowfin web service to retrieve a user's details:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

Person.setUserId("testuser@yellowfin.com.au");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("GETUSER");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

This code will return an AdministrationPerson object with the user's details and SUCCESS in the rs.getStatusCode(), otherwise it will return an error message explaining why the process failed.

Expand
titleGETUSERBYIP

The following code will call the Yellowfin web service to retrieve a user's details via their internal IpId:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

Person.setIpId(5);

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("GETUSERBYIP");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

This code will return an AdministrationPerson object with the user's details and SUCCESS in the rs.getStatusCode(), otherwise it will return an error message explaining why the process failed.

...

titleGETUSERFROMSEARCH

Expand
titleVALIDATEUSER

The following code will call the Yellowfin web service to validate a user:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

person.setUserId("admin@yellowfin.com.au");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setFunction("VALIDATEUSER");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

This code will return an AdministrationPerson object of the particular user if successful; otherwise it will return an error message explaining why the user validation process failed.

Expand
titleVALIDATEPASSWORD

The following code will call the Yellowfin web service to validate a user's password:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

person.setUserId("testuser@yellowfin.com.au");
person.setPassword("test");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("VALIDATEPASSWORD");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

This code will check if the password is expired and will return FAILURE in the rs.getStatusCode() if it is not, otherwise it will return SUCCESS.

Manipulating User Information

A user's details can be modified at a later time using a web service call. The User ID field in the AdministrationPerson object is used to identify the user, so this cannot be changed. The rest of the fields within an AdministrationPerson object are populated with the new changes. For security reasons, the user's password cannot be changed with this web service call, but with a separate CHANGEPASSWORD function (below).

...

titleUPDATEUSER

...

This function will delete a user from Yellowfin. The details in the AdministrationPerson object will be used in the user deletion process.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices eg. admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "DELUSER" or "DELETEUSER"

 

Web services function

setFunction()

Person

AdministrationPerson

The AdministrationPerson object holding all of the user's details for the user creation process

setPerson()

These are the parameters that you need to set in the AdministrationPerson object:

AdministrationPerson Element

Data Type

Description

Setting Code

UserId

String

User ID of the Yellowfin user. This can be the user ID or the email address, depending on the Logon ID method

setUserId()

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

Retrieving & Validating User Information

Once a user has been created, the user's details can be retrieved using a web service call. The User ID field in the AdministrationPerson object is used to identify the user. As a result, a populated AdministrationPerson object will be returned. For security reasons, passwords will not be returned and will be NULL. User information can also be validated against the application in this section.

Expand
titleGETUSER

The following code will call the Yellowfin web service to retrieve a user's details:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

Person.setUserId("testuser@yellowfin.com.au");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("GETUSER");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

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

This code will return an AdministrationPerson object with the user's details and SUCCESS in the rs.getStatusCode(), otherwise it will return an error message explaining why the process failed.

This function will retrieve the details of a particular user in Yellowfin. The details in the AdministrationPerson object will be used in the retrieval process.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices eg. admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "GETUSER"

 

Web services function

setFunction()

Person

AdministrationPerson

The AdministrationPerson object holding the Yellowfin user's User ID for the retrieval process

setPerson()

These are the parameters that you need to set in the AdministrationPerson object:

AdministrationPerson Element

Data Type

Description

Setting Code

UserId

String

User ID of the Yellowfin user. This can be the user ID or the email address, depending on the Logon ID method

setUserId()

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

Person

AdministrationPerson

The AdministrationPerson object holding all of the returned user's details

getPerson()

Expand
titleGETUSERBYIP

The following code will call the Yellowfin web service to retrieve a user's details via their internal IpId:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

Person.setIpId(5);

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("GETUSERBYIP");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

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

This code will return an AdministrationPerson object with the user's details and SUCCESS in the rs.getStatusCode(), otherwise it will return an error message explaining why the process failed.

This function will retrieve the details of a particular user in Yellowfin by looking up their IP ID. The details in the AdministrationPerson object will be used in the retrieval process.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices eg. admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "GETUSERBYIP"

 

Web services function

setFunction()

Person

AdministrationPerson

The AdministrationPerson object holding the Yellowfin user's User ID for the retrieval process

setPerson()

These are the parameters that you need to set in the AdministrationPerson object:

AdministrationPerson Element

Data Type

Description

Setting Code

IpId|Integer|IP ID of the Yellowfin User|setIprId()|

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

Person

AdministrationPerson

The AdministrationPerson object holding all of the returned user's details

getPerson()

Expand
titleGETUSERFROMSEARCH

This function will retrieve users from Yellowfin based on a specific search string. This string is compared against the user's first name, last name, and email address.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices i.e admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "GETUSERSFROMSEARCH"

 

String

Web services function

setFunction()

Parameters

Array (String)

Search string to match against Yellowfin users' first names, last names, and email address

setParameters()

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

People

Array (AdministrationPerson)

An array of AdministrationPerson objects. These objects hold the returned users' details that match the search string

getPeople()

Expand
titleVALIDATEUSER

The following code will call the Yellowfin web service to validate a user:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

person.setUserId("admin@yellowfin.com.au");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setFunction("VALIDATEUSER");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

This code will return an AdministrationPerson object of the particular user if successful; otherwise it will return an error message explaining why the user validation process failed.

This function will validate a specified Yellowfin user, checking if the user currently exists within the application. The details in the AdministrationPerson object will be used in the user validation process.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices eg. admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "VALIDATEUSER"

 

Web services function

setFunction()

Person

AdministrationPerson

The AdministrationPerson object holding the Yellowfin user's User ID for the retrieval process

setPerson()

These are the parameters that you need to set in the AdministrationPerson object:

AdministrationPerson Element

Data Type

Description

Setting Code

UserId

String

User ID of the Yellowfin user. This can be the user ID or the email address, depending on the Logon ID method

setUserId()

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

Person

AdministrationPerson

The AdministrationPerson object holding all of the returned user's details

getPerson()

Expand
titleVALIDATEPASSWORD

The following code will call the Yellowfin web service to validate a user's password:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

person.setUserId("testuser@yellowfin.com.au");
person.setPassword("test");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("VALIDATEPASSWORD");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

This code will check if the password is expired and will return FAILURE in the rs.getStatusCode() if it is not, otherwise it will return SUCCESS.

This function will validate a Yellowfin user's password. The details in the AdministrationPerson object will be used in the password validation process.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices eg. admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "VALIDATEUSER"

 

Web services function

setFunction()

Person

AdministrationPerson

The AdministrationPerson object holding the Yellowfin user's User ID for the retrieval process

setPerson()

These are the parameters that you need to set in the AdministrationPerson object:

AdministrationPerson Element

Data Type

Description

Setting Code

UserId

String

User ID of the Yellowfin user. This can be the user ID or the email address, depending on the Logon ID method

setUserId()

Password

String

Password of the Yellowfin user

setPassword()

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

Manipulating User Information

A user's details can be modified at a later time using a web service call. The User ID field in the AdministrationPerson object is used to identify the user, so this cannot be changed. The rest of the fields within an AdministrationPerson object are populated with the new changes. For security reasons, the user's password cannot be changed with this web service call, but with a separate CHANGEPASSWORD function (below).

Expand
titleUPDATEUSER

The following code will call the Yellowfin web service to edit a user's details:

Code Block

AdministrationServiceRequest rsr = new AdminstrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

person.setUserId("testuser");
person.setFirstName("John");
person.setLastName("Doe");
person.setInitial("F");
person.setSalutationCode("MR");
person.setRoleCode("YFADMIN");
person.setEmailAddress("testuser@yellowfin.com.au")

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("UPDATEUSER");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);

This code will return an AdministrationPerson object with the user's details and SUCCESS in the rs.getStatusCode(), otherwise it will return an error message explaining why the process failed.

This function will update a specified Yellowfin user's details. The details in the AdministrationPerson object will be used in the update process.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices eg. admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "UPDATEUSER"

 

Web services function

setFunction()

Person

AdministrationPerson

The AdministrationPerson object holding the Yellowfin user's User ID for the retrieval process

setPerson()

These are the parameters that you can set in the AdministrationPerson object:

AdministrationPerson Element

Data Type

Description

Retrieval Code

UserId

String

User ID of the Yellowfin user. This can be the user ID or the email address, depending on the Logon ID method

setUserId()

Password

String

Password of the Yellowfin user

setPassword()

FirstName

String

First name of of the Yellowfin user

setFirstName()

LastName

String

Last name of of the Yellowfin user

setLastName()

Initial

String

Middle name of the Yellowfin user

setInitial()

SalutationCode

String

Title of the Yellowfin user. Possible values include:

  • DR
  • MISS
  • MR
  • MRS
  • MS

setSalutationCode()

RoleCode

String

Yellowfin role. The specified role here can be the Org Reference Code (YFADMIN) or the name of the role (Yellowfin Administrator)

setRoleCode()

EmailAddress

String

Email address of the Yellowfin user

setEmailAddress()

LanguageCode

String

Two letter code for the preferred language

setLanguageCode()

IpId

Integer

Internal Yellowfin IP ID

setIpId()

TimeZoneCode

String

The TimeZoneCode of the Yellowfin user. See appendix for valid values.

setTimeZoneCode()

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

Person

AdministrationPerson

The AdministrationPerson object holding all of the updated user's details

getPerson()

Expand
titleCHANGEPASSWORD

The following code will call the Yellowfin web service and change the password for the specified Yellowfin user:

Code Block

AdministrationServiceRequest rsr = new 

...

AdministrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson

...

(

...

);

person.

...

setUserId("

...

test@yellowfin.com.au");
person.

...

setPassword("

...

testtest");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("

...

CHANGEPASSWORD");
rsr.setPerson(person

...

);

rs = AdministrationService.remoteAdministrationCall(rsr);

The code will return SUCCESS in rs.getStatusCode(), otherwise it will return an error explaining why the process failed.

This function will change a specified Yellowfin user's password.

Request Element

Data Type

Description

Setting Code

LoginId

String

Login ID of the account used to connect to Yellowfin webservices eg. admin@yellowfin.com.au

setLoginId()

Password

String

Password of the account used to connect to Yellowfin webservices

setPassword()

OrgId

Integer

Primary Organization ID within Yellowfin. Always set this to 1.

setOrgId()

Function = "CHANGEPASSWORD"

 

Web services function

setFunction()

Person

AdministrationPerson

The AdministrationPerson object holding the Yellowfin user's User ID for the retrieval process

setPerson()

These are the parameters that you need to set in the AdministrationPerson object:

AdministrationPerson Element

Data Type

Description

Retrieval Code

UserId

String

User ID of the Yellowfin user. This can be the user ID or the email address, depending on the Logon ID method

setUserId()

Password

String

New password of the Yellowfin user

setPassword()

The response returned will contain these parameters:

Response Element

Data Type

Description

Retrieval Code

StatusCode

String

Status of the web service call. Possible values include:

  • SUCCESS
  • FAILURE

getStatusCode()

This code will return an AdministrationPerson object with the user's details and SUCCESS in the rs.getStatusCode(), otherwise it will return an error message explaining why the process failed.

Expand
titleCHANGEPASSWORD

The following code will call the Yellowfin web service and change the password for the specified Yellowfin user:

Code Block

AdministrationServiceRequest rsr = new AdministrationServiceRequest();
AdministrationServiceResponse rs = null;
AdministrationPerson person = new AdministrationPerson();

person.setUserId("test@yellowfin.com.au");
person.setPassword("testtest");

rsr.setLoginId(this.username);
rsr.setPassword(this.password);
rsr.setOrgId(new Integer(1));
rsr.setFunction("CHANGEPASSWORD");
rsr.setPerson(person);

rs = AdministrationService.remoteAdministrationCall(rsr);
The code will return SUCCESS in rs.getStatusCode(), otherwise it will return an error explaining why the process failed.

Retrieving Objects Belonging to a User

...