One of my favorite sessions this year at Oracle OpenWorld was the Oracle University Mini Lesson – PeopleSoft Enterprise and Web Services, session S783.

They went through the history and capabilities of web services, but I was primarily interested in the capabilities of PeopleTools 8.4x. My biggest take-away was the WSDL capabilities of Component Interface.

SOAPTOCI is a standards-compliant SOAP wrapper for Component Interface.

The promise of Component Interface has always been that you can programmatically enter data into PeopleSoft and it would execute all of the validations and business logic in real-time, including workflow transactions. The biggest disadvantage has been that even minor PeopleTools upgrades force you to upgrade your API libraries. SOAPTOCI addresses this concern, and makes Component Interface accessible to web service orchestration tools like the BPEL Process Manager.

In PeopleTools 8.4x, SOAPTOCI is actually pretty well documented in PeopleBooks. Check out your PeopleSoft Component Interfaces PeopleBook under the “Using WSDL Binding for Component Interface”.

I won’t go into the setup of SOAPTOCI, so check out the instructions in PeopleBooks. It will take you through setting up the SOAPTOCI synchronous transaction on the node of your choice.

Once you do get the SOAPTOCI message set up, you’re ready to start executing Component Interfaces. Let's get started.

First, fire up SendMaster (under $PS_HOME/sendmaster). If you've never used it, SendMaster is a developer tool that lets you post and get from a web server. You can enter the URL, HTTP headers, and XML message, and it has a window to show you the web server response.

The Server URL should be constructed like this: http://<servername.domain>:<port>/PSIGW/HttpListeningConnector.

HTTP headers should be:
MessageName:SOAPTOCI
MessageType:Sync
From:SOURCENODE
Content-Type:text/xml
SOAPAction:#SOAPTOCI#SOURCENODE
You’ll need to change SOURCENODE to be the node that you configured the SOAPTOCI transaction on.

Now I selected the Location Component Interface for this example. If you’re not running PeopleSoft Financials, feel free to choose any Component Interface that you like. You might want to open the LOCATION component interface in Application Designer as you work thorough this example so that you can see how the different XML tags map to the different Component Interface properties and methods.

Set the Input file like this:
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Header>
<Security_Request>
<Username>LC005360</Username>
<Password>secretpassword</Password>
</Security_Request>
</SOAP-ENV:Header>
<SOAP-ENV:Body>
<Find__CompIntfc__LOCATION>
<SETID>SHARE</SETID>
<LOCATION>2</LOCATION>
</Find__CompIntfc__LOCATION>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

Notice the <Security_Request> tag. This is where you enter the PeopleSoft Application Username and Password. Keep in mind that this user will need to have security to the component interface. This is set up on the Permission list under the Component Interface tab.

Now let’s discuss the <Find__CompIntfc__LOCATION> tag. This directs SOAPTOCI to load the LOCATION component interface, and execute the Find method on the data contained within this node. That data in this example is <SETID> and <LOCATION>.

So what does this do, exactly? Well, it would be like the user navigating to the LOCATION component, entering SHARE for the SETID and the number 2 for location, and clicking search. The user would be presented with all locations that begin with the number 2 for a location.

Executing this in SendMaster generates the following XML in the Output Information window:
<?xml version="1.0"?>
<SOAP-ENV:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:SOAP-ENC="http://schemas.xmlsoaporg/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoaporg/soap/envelope/"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Header/>
<SOAP-ENV:Body>
<Find__CompIntfc__LOCATIONResponse xmlns="http://psfttemp.org">
<LOCATION><SETID>SHARE</SETID><LOCATION>2000</LOCATION></LOCATION>
<LOCATION><SETID>SHARE</SETID><LOCATION>2001</LOCATION></LOCATION>
<LOCATION><SETID>SHARE</SETID><LOCATION>2002</LOCATION></LOCATION>
<LOCATION><SETID>SHARE</SETID><LOCATION>2003</LOCATION></LOCATION>
<LOCATION><SETID>SHARE</SETID><LOCATION>2004</LOCATION></LOCATION>
</Find__CompIntfc__LOCATIONResponse></SOAP-ENV:Body></SOAP-ENV:Envelope>

So, you get what you’d expect if you did the equivalent transaction on-line, except you get it in an XML format.

One more example – let’s actually create a new location through SOAPTOCI. Switch the Find__CompIntfc__LOCATION> tag to <Create__CompIntfc__LOCATION>, change the <LOCATION> value to a new location, and add a < DESCR> tag with a valid location description. You’ll notice that in Application Designer, DESCR is actually a child of LOCATION_TBL, so you’ll need to have a parent LOCATION_TBL before DESCR. Your file should resemble the following:

<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAP-ENV:Header>
<Security_Request>
<Username>LC005360</Username>
<Password>secretpassword</Password>
</Security_Request>
</SOAP-ENV:Header>
<SOAP-ENV:Body>
<Create__CompIntfc__LOCATION>
<SETID>SHARE</SETID>
<LOCATION>ABC</LOCATION>
<LOCATION_TBL>
< DESCR>ABCDEFG</DESCR>
</LOCATION_TBL>
</Create__CompIntfc__LOCATION>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

After posting, the Output Information should resemble the following:
<?xml version="1.0"?>

<SOAP-ENV:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoaporg/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoaporg/soap/envelope/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:Header/>

<SOAP-ENV:Body><Create__CompIntfc__LOCATIONResponse xmlns="http://psfttemp.org"><notification>1</notification>

<Detail/></Create__CompIntfc__LOCATIONResponse></SOAP-ENV:Body></SOAP-ENV:Envelope>



Notice the notification tag shows a 1. In the PeopleSoft world, 1 is a successful return code.

Now check, the database. You’ll find your new location there.
SQL> select
2 SETID,LOCATION,EFFDT,DESCR
3 FROM PS_LOCATION_TBL
4 where location = 'ABC';

SETID LOCATION EFFDT DESCR
----- ---------- --------- ------------------------------
SHARE ABC 30-SEP-05 ABCDEFG

Well, I hope that gets you started. You can also update information and get information through SOAPTOCI from just about any component interface. Best of luck!
Written by :
 
Trackback(0)
Comments (8)Add Comment
0
Comment from Tommy Tran
written by Tommy Tran, July 25, 2006
Hi,

I've setup my WebService in PeopleSoft. I can see that the message is good to go since I can make the call from the SendMaster Application. However, I was wondering if you have a sample application where I can consume the message from a Java client.



TIA,

t
Brent Martin
...
written by Brent Martin, July 25, 2006
I sure don't. I thought I saw an example in either PeopleBooks or on Customer Connection, though.
0
Technical Analyst
written by Sachin Deshmukh, May 28, 2007
I did write a java client to consume the peoplesoft webservice for country. From the wsdl provided by peoplesoft, we created a the java framework using Axis2.1. A java client was then created to consume the peoplesoft webservice.
0
changing response from soap to ci
written by Jerry van Beers, February 28, 2008
Upon adding new data into some record through a soap, EXT_ORG_TBL, a new EXT_ORG_ID is generated. Is it possible to send this new id in the response to the message?
Brent Martin
RE: changing response from soap to ci
written by Brent Martin, March 11, 2008
That's an interesting question. If I was coding a VBA or Java app that accessed the CI directly I'd just check the value of EXT_ORG_ID after the save method was executed. But I'm not sure if you can control the response method so that that value is passed back to the calling application and you obviously can't invoke the CI with an Update method because you won't know the key values to use.

Without further research I don't know how you could do it and I don't think it's possible. But I could be wrong... If you have support it might be worth opening a case with GSC and see what they say. I've had pretty good luck with their component interface people.
0
Update thru Web services
written by Devanand, April 09, 2008
Hi,
I am trying to update the Job record of PS HR thru web services. I am able to retrieve the information. But I am not able to save/ add additional record to the same. Help me.
I am not sure the usage of "Update__CompIntfc__CI_JOB_DATA" method.
0
mr
written by Nihar , November 30, 2010
I wan to secure my web service by id address also, so that it will check the id address from my setup by ip address page and if it found then only it will successfully login otherwise, it should give exception. Could you please tell how I will do this in CI based web service?
kjps
...
written by kjps, September 18, 2011
Hi

I an new to PS webservice and looking for help, my requirement is as follows:

1) Need to consume an API from a third party application into PS HCM
2) I am on 9.1, 8.50
3) I need to consume this webservice into PS to send out data from PS to this application.
4) The data that needs to be sent from PS to this application does not reside in 1 component. The data may be stored in several components.
5) We need an asynch message.
6) Since the data resides in several components, maybe I would need to use an AE to to fetch data from various tables and stage into a staging table and then invoke the webservice to send data to the third party application.

Can you please help and suggest, please help asap.Really urgent

Write comment

security code
Write the displayed characters


busy

Last Updated on Monday, 22 January 2007 07:15.