Interact with Issues

You are viewing an old version (v. 3) of this page.
The latest version is v. 6, last edited on Jun 19, 2011 (view differences | )
<< View previous version | view page history | view next version >>
TOC

Since QuickBuild 4.0, you can retrieve issues via RESTful APIs. The base URI for changes RESTful APIs is:

/rest/{tracker}

Here, tracker is the type of your issue tracker, in QuickBuild, includes:

  • Jira - /rest/jira
  • Trac - /rest/trac
  • Bugzilla - /rest/bugzilla

below, we will use $baseURI to represent the URI: /rest/{tracker}.

List all supported APIs

URI Response Type Params
$baseURI/help text/html  

Get the data version of changes

URI Response Type Params
$baseURI/version text/plain  

Retrieve the latest builds

URI Response Type Params
$baseURI/builds/{configuration} text/xml
  • configuration - PATH_PARAM
    Specify the configuration. By default, specify configuration id here, if you want to specify a configuration path, you need add prefix PATH:, for example, PATH:root/My/DEV
  • key - QUERY_PARAM
    The issue key. If specified, the builds related to this issue will return.
  • count - QUERY_PARAM
    Specify at most how many records you want. If not specified, all records found will return.

Query all builds
Below example shows how to retrieve the latest 50 builds related to a configuration:

http://quickbuild:8810/rest/jira/5/builds?count=50

or 

http://quickbuild:8810/rest/jira/PATH:root/My Test/builds?count=50

the response looks like:

<list>
  <build>
    <id>321</id>
    <version>1.0.15</version>
    <status>SUCCESSFUL</status>
    <beginDate class="sql-timestamp">2011-06-10T17:11:35.662000000+08:00</beginDate>
    <duration>3409</duration>
    <scheduled>false</scheduled>
    <requester>Administrator</requester>
    <deleted>false</deleted>
  </build>

  ... ...
</list>

The build element here is just a simple fragment of the build object, if you want more detailed information about build, you need retrieve the builds via /rest/builds API, see [Interact with Builds].

*Query builds related to an issue*

http://quickbuild:8810/rest/jira/5/builds?key=QB-123

here, query param *key* is the issue key which you want to find.

h3. Retrieve the changes of an issue
||URI||Response Type||Params||
|$baseURI/changes/\{configuration}/\{key}|_text/xml_|* *configuration* - PATH_PARAM 
Specify the configuration. By default, specify configuration id here, if you want to specify a configuration path, you need add prefix PATH:, for example, PATH:root/My/DEV
* *key* - PATH_PARAM 
The issue key you want to search.
* *count* - QUERY_PARAM 
Specify at most how many records you want. If not specified, all records found will return.|

http://quickbuild:8810/rest/jira/changes/5/TST-123

or

http://quickbuild:8810/rest/jira/changes/PATH:root/My Dev/TST-123


Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.