You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 17 Current »

You can use the Parasoft REST API to remotely create and update virtual assets, as well as create, update, and execute test assets, directly on the Parasoft server. This enables third-party integrations, custom programmatic interactions, and access via additional user interfaces such as Parasoft CTP.

Sections include:

Prerequisites

  • The SOAtest and Virtualize servers must be running.
  • "Server API Enabled" or "Service Enabled" license feature required for remote access. 
    • If you have both SOAtest and Virtualize enabled, you must have both the "Server API Enabled" and "Service Enabled" license features applied.

How do I start SOAtest Server

From the cli: soatestcli -startServer
From the UI: Click the Start Server button in the SOAtest Server view.

If the Start Server button is grayed out and the red Stop Server button is enabled, this means that the server is running.

Make Sure Your License Supports SOAtest Server

If you are using the combined SOAtest/Virtualize distribution, a Virtualize license is required to run SOAtest Server. In some instances, you may only have a license for SOAtest, for example if you are updating to a paid license from the Free License. Contact your Parasoft representative for additional information about licensing options.

About the REST API

The REST API enables you to perform core operations, without using the desktop GUI, as well as integrate with other applications or tools that part of your Dev/Test infrastructure.  You can create, update, and delete data sources, test suites, virtual assets, tools, environments, and so on. For details, see the API documentation by opening the following URL in a browser:

http://<host>:9080/soavirt/api 

Your tools may be deployed on different ports.

Returning Requests in GZIP Format

The REST API can return requests in GZIP format. This results in smaller payloads being sent over the wire, which decreases the amount of time it takes to read responses from the server.

To have requests returned in GZIP format, the client accessing the REST API just needs to set the following HTTP header:
Accept-Encoding: gzip

Connecting to the API Using the Java Client

You can use Parasoft's Java-based client to connect to the Parasoft SOAtest/Virtualize Server so that you can start developing applications using the API. 

  1. Add the build.parasoft.com Maven repository to your pom.xml:

    <repositories>
      <repository>
        <id>Parasoft</id>
        <url>http://build.parasoft.com/maven/</url>
      </repository>
    </repositories>

     

  2. Next, add the com.parasoft.api.rest.client dependency:

    <dependency>
      <groupId>com.parasoft.soavirt</groupId>
      <artifactId>com.parasoft.api.rest.client</artifactId>
      <version>9.10.6</version>  <!-- should match version of your SOAtest server -->
    </dependency>

    The class com.parasoft.api.rest.client.ParasoftApiRestClient enables you to connect to the Parasoft SOAtest Server and invoke various operations, such as viewing and manipulating .tst files.

Refer to the API documentation for information on the resources available through the API. 

  • No labels