TrackStudio Enterprise 3.5
Using Java SOAP

The following topic describes how to interact with TrackStudio from a Java application using TrackStudio SOAP API.

To develop a client application which uses TrackStudio SOAP API:

  1. Enable TrackStudio SOAP API
  2. Start TrackStudio Enterprise
  3. Implement client application. In order to work with SOAP API you should first perform authentication. For this, you need to:
  • Create a DevPack class instance
DevPack dp = new DevPack("http://localhost:8888/TrackStudio");
  • Call the authenticate method
String sessionId = dp.getUserService().authenticate("root","root");

The session ID received as the result of authentication can be used to call other methods. 

The code presented below shows the example of the simplest Java client:

import gran.trackstudio.DevPack;

public class ATest {
    public static void main(String[] args) throws Exception {
        DevPack dp = new DevPack("http://localhost:8888/TrackStudio");
        String sessionId = dp.getUserService()
           .authenticate("root","root");
        System.out.println("Session ID is:"+sessionId);
    }
}
  1. Compile the client application
javac -classpath tssoapclient.jar;axis.jar;jaxrpc.jar Test.java
  1. Run the client application
C:\>java -classpath tssoapclient.jar;axis.jar;jaxrpc.jar;
commons-logging.jar;commons-discovery.jar;saaj.jar;. Test
Session ID is:297e234cfbf9889500fbf989ee890012