...
Note |
---|
Work Log Attribute (WLA) functionality (see Work Log Attributes (WLA)) is currently not supported via the JIRA REST API! |
Please have a look at the following example (use the JIRA REST API browser to test: https://developer.atlassian.com/display/DOCS/Using+the+REST+API+Browser):
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
{ "update": { "comment": [ { "add": { "body": "." } } ] }, "fields": { "customfield_10100":"nocharge==on||noChargeInfo==why this should not be charged||timeSpentCorrected==5h||adjustEstimate==new||newEstimate==5w||activity==3||startDate==Sep 29, 2014 9:34 AM||startTime==5:05 PM||endTime==5:07 PM||comment==my worklog description||issueKey==ABCD-239||logWorkOption==summary||timeLogged==6h||activateLogwork==true||", "assignee": { "name": "bob" }, "resolution": { "name": "Fixed" } }, "transition": { "id": "5" } } |
...
Info |
---|
Custom field ID for the ictime "Log work" field will be different for your JIRA installation, as well as time & date formats might be. |
Parameter | Description | Remarks | ||
---|---|---|---|---|
"comment" | JIRA comment | Mandatory.
| ||
"activity" | ID of the activity type in ictime | Optional, only if you use the feature. | ||
"timeLogged" | Result (time logged). Expects the format defined in JIRA. | Required if logWorkOption is "summary" | ||
"startTime" | Start time for your work log. Expects the format defined in JIRA. | Required if logWorkOption is "fromTo" | ||
"endTime" | End time for your work log. Expects the format defined in JIRA. | Required if logWorkOption is "fromTo" | ||
"startDate" | Date. Expects the format defined in JIRA. | Mandatory. | ||
"logWorkOption" |
| One of both option must be selected. Depending on the option selected, you need to set "timeLogged" or "startTime" and "endTime". | ||
"nocharge" | "on" if this entry should not be charged | Optional, only if you use the feature. | ||
"noChargeInfo" | Optional information if a work log should not be charged ("nocharge" is "on"). | Optional, only if you use the feature. | ||
"timeSpentCorrected" | The corrected amount of time (to be charged instead of the time resulting from "timeLogged" (or "startTime" and "endTime"). The other values are still required. | Optional, only if you use the feature. | ||
"adjustEstimate" | JIRA options to handle an existing extimate.
| Default is "auto". | ||
"newEstimate" | If "adjustEstimate" is "new". Expects the format defined in JIRA. |
"adjustmentAmount" | If "adjustEstimate" is "manual". Expects the format defined in JIRA. |
"issueKey" | Issue key. | Mandatory. |
"activateLogwork" | required, since 5.7.7.0 | must be set to true since version 5.7.7.0, NOT required starting frm 5.8.3.15 |
JIRA and ictime error handling is available, you should get meaningful error responses.