YouTrack Standalone 2019.3 Help

Create New Work Item

POST /rest/issue/{issue}/timetracking/workitem

Create a new work item for a particular issue.

POST /rest/issue/{issue}/timetracking/workitem

Parameters:

Name

Type

Description

issue

issue id

Issue id to which the work item is added

In the request code, provide the following parameters for a new work item (a work item is designated with <workItem> tag):

  1. <date> — date of the new work item in Unix Epoch time format

  2. <duration> — duration of the new work item, in minutes

  3. <description> — activity description

  4. <worktype> — work item type

The time part of the <date> parameter is replaced with the timestamp for midnight in the time zone of the current user.

For a sample code please see below.

Sample

Request

POST https://example.com/youtrack/rest/issue/HBR-63/timetracking/workitem Cookie: $Version=0; JSESSIONID=i3p6eke3gf1o1s3zqdlz31ozf; $Path=/; jetbrains.charisma.main.security.PRINCIPAL=NDgxMzQ5NGQxMzdlMTYzMWJiYTMwMWQ1YWNhYjZlN2JiN2FhNzRjZTExODVkNDU2NTY1ZWY1MWQ3Mzc2NzdiMjpyb290; $Path=/ <workItem> <date>1353316956611</date> <duration>240</duration> <description>first work item</description> <worktype> <name>Development</name> </worktype> </workItem>

Response

HTTP/1.1 201 Created Vary: Accept-Encoding Location: https://example.com/youtrack/rest/issue/HBR-63/timetracking/workitem/101-1 Content-Type: application/xml; charset=UTF-8 Cache-Control: no-cache, no-store, no-transform, must-revalidate Content-Length: 0
Last modified: 16 March 2020