Knowledge Base Article

Home Page > Knowledge Base > Rapise

Home Page > Knowledge Base > Rapise > Rapise Web

Home Page > Knowledge Base > Spira Platform

Home Page > Knowledge Base > Spira Platform > SpiraTeam

Home Page > Knowledge Base > Spira Platform > SpiraTest

Article Accessing the Spira v4.2 REST API to get test cases in a release

by Adam S on Wednesday, June 10, 2015

This article describes the process and provides an example for accessing the Spira v4.2 REST API to get a filtered list of test cases in a release.

In this example we use the Rapise REST testing capability to access the Spira v4.2 REST API.

The first thing to do is open up the Spira v4.2 REST API documentation and then navigate to the POST method for the Release-TestCases resource. The GET method would allow us to let a simple list of all the test cases in the release, but when we want a filtered list, we need the POST version:

Now we can create a new Rapise REST service and enter this URL and associated parameters:


You can see that we've parameterized all of the querystring variables. We have also entered a valid user login and API key as credentials. If you click the SEND button it will display a green success message:

Now we need to specify that we want the data back as JSON (JavaScript Object Notation) rather than HTML or XML and also we'll specify (in JSON format) the filter. We shall filter the sample project's test cases by "Name" contains the phrase "book":


When you execute this test you'll get back the data in JSON format:

The full test in Rapise looks like:


The full Rapise sample web service test project is attached to this article.

Attachments
Article Info
Last Updated: 6/10/2015
Article ID: KB158
# Views: 2157
Tags
Powered by KronoDesk v1.1.0.15 | © Copyright Inflectra Corporation 2011-2016 | Licensed to Inflectra Corporation.