Get Available Work Items of Issue
GET /rest/issue/{issue}/timetracking/workitem/
Get the list of available work items for a particular issue.
GET /rest/issue/{issue}/timetracking/workitem/
Name | Type | Description |
---|---|---|
issue | issue id | Issue ID of an issue for which you'd like to get a list of all available work items. |
For each work item in response code, you will get the following parameters:
Also, for each work item we provide unique URL to access this work item (as 'URL'
attribute
for the <workItem> parameter). See the section below for samples.
Samples
Sample 1
GET http://localhost:8081/rest/issue/HBR-63/timetracking/workitem
Cookie: $Version=0; JSESSIONID=i3p6eke3gf1o1s3zqdlz31ozf; $Path=/; jetbrains.charisma.main.security.PRINCIPAL=NDgxMzQ5NGQxMzdlMTYzMWJiYTMwMWQ1YWNhYjZlN2JiN2FhNzRjZTExODVkNDU2NTY1ZWY1MWQ3Mzc2NzdiMjpyb290; $Path=/
HTTP/1.1 200 OK
Vary: Accept-Encoding
Content-Type: application/xml; charset=UTF-8
Cache-Control: no-cache, no-store, no-transform, must-revalidate
Content-Length: 78
Server: Jetty(8.1.7.v20120910)
<?xml version="1.0" encoding="UTF-8" standalone="yes"?><workItems></workItems>
Sample 2
GET http://localhost:8081/rest/issue/HBR-63/timetracking/workitem
Cookie: $Version=0; JSESSIONID=i3p6eke3gf1o1s3zqdlz31ozf; $Path=/; jetbrains.charisma.main.security.PRINCIPAL=NDgxMzQ5NGQxMzdlMTYzMWJiYTMwMWQ1YWNhYjZlN2JiN2FhNzRjZTExODVkNDU2NTY1ZWY1MWQ3Mzc2NzdiMjpyb290; $Path=/
HTTP/1.1 200 OK
Vary: Accept-Encoding
Content-Type: application/xml; charset=UTF-8
Cache-Control: no-cache, no-store, no-transform, must-revalidate
Content-Length: 727
Server: Jetty(8.1.7.v20120910)
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<workItems>
<workItem url="https://example.com/youtrack/rest/issue/HBR-63/timetracking/workitem/101-1">
<id>101-1</id>
<date>1353316956611</date>
<duration>240</duration>
<description>first work item</description>
<author login="root" url="https://example.com/youtrack/rest/admin/user/root"/>
</workItem>
<workItem url="https://example.com/youtrack/rest/issue/HBR-63/timetracking/workitem/101-2">
<id>101-2</id>
<date>1352894400000</date>
<duration>480</duration>
<description>second work item</description>
<author login="root" url="https://example.com/youtrack/rest/admin/user/root"/>
</workItem>
</workItems>
Sample 3
GET http://localhost:8081/rest/issue/HBR-63/timetracking/workitem
Cookie: $Version=0; JSESSIONID=i3p6eke3gf1o1s3zqdlz31ozf; $Path=/; jetbrains.charisma.main.security.PRINCIPAL=NDgxMzQ5NGQxMzdlMTYzMWJiYTMwMWQ1YWNhYjZlN2JiN2FhNzRjZTExODVkNDU2NTY1ZWY1MWQ3Mzc2NzdiMjpyb290; $Path=/
HTTP/1.1 200 OK
Vary: Accept-Encoding
Content-Type: application/xml; charset=UTF-8
Cache-Control: no-cache, no-store, no-transform, must-revalidate
Content-Length: 409
Server: Jetty(8.1.7.v20120910)
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<workItems>
<workItem url="https://example.com/youtrack/rest/issue/HBR-63/timetracking/workitem/101-1">
<id>101-1</id>
<date>1353316956611</date>
<duration>230</duration>
<description>first work item edited</description>
<author login="root" url="https://example.com/youtrack/rest/admin/user/root"/>
</workItem>
</workItems>
Last modified: 2 February 2017