Single Issue Expanded
Overview
GET /rest/issue/expanded
This endpoint is used to retrieve a single issue expanded report as text (CSV or JSON).
Required Permissions
All Users with Timepiece access can retrieve the details of the issue with the specified key.
Request
Basic Request
GET <service_url>/rest/issue/expanded?issueKey=<issueKey>&calendar=<calendar>&outputType=<outputType>
Full Request
GET <service_url>/rest/issue/expanded?issueKey=<issueKey>&trimHistoryStartDate=<trimHistoryStartDate>&trimHistoryEndDate=<trimHistoryEndDate>&calendar=<calendar>&dayLength=<dayLength>&viewFormat=<viewFormat>&outputType=<outputType>
Parameters
Parameter | Description | Required | Value Samples |
|---|---|---|---|
columnsBy | Defines the column structure of the report. Possible options are:
statusDurationExpanded is the default value and it will be used if this parameter is not provided. | No |
|
issueKey | Key of the issue that report will be generated for. | Yes | ABC-1 |
outputType | The output format of the report. Possible options are:
If not provided, "json" will be used. |
| |
historyFields | The IDs of fields (separated by commas) on JIRA Issues that will be used for Any Field reports. For details about Any Field report types please see: TiS Cloud - Report Types Both system and custom fields are supported. For more information see TiS Cloud - Field Names for REST Reports | only when columnsBy = anyfielddurationexpanded | assignee, customfield_10020, customfield_10007, description, duedate, fixVersions |
trimHistoryStartDate | The start date of history trim for issues. When provided, only activities in each issue's history after the given date will be processed for the report. Must be provided in "yyyy-MM-dd" or "yyyy-MM-dd hh:mm" format. If time parameter is not provided, default time "00:00" will be used | 2017-07-01 00:00 | |
trimHistoryEndDate | The end date of history trim for issues. When provided, only activities in each issue's history before the given date will be processed for the report. Must be provided in "yyyy-MM-dd" or "yyyy-MM-dd hh:mm" format. If time parameter is not provided, default time "00:00" will be used | 2017-08-31 23:59 | |
calendar | The calendar that report durations will be calculated based on. Possible options are:
Tip: You can get the IDs of calendars using the Calendars endpoint. | Yes |
|
dayLength |
|
| |
viewFormat | The format of duration data in the report. Possible options are:
If not provided, "minutes" will be used. |
| |
emptyValueToken | The token to use for empty values in the report (for example when an issue has never visited a status) Selecting a custom token might make it easier for the requesting system to process the data. Possible options are:
|
| |
csvFieldSeparator | The character to separate CSV values. Possible options are:
|
| |
decimalSeparator | The character to use as a decimal separator for decimal values in CSV format. Possible options are:
|
| |
valueQuotationMark | The character to quote values in CSV format. Possible options are:
|
|
Example Requests
GET https://tis.obss.io/rest/issue/expanded?issueKey=XYZ-34&calendar=normalHours
GET https://tis.obss.io/rest/issue/expanded?issueKey=ABC-3&calendar=normalHours&dayLength=24HourDays&viewFormat=minutes&outputType=csv
GET https://tis.obss.io/rest/issue/expanded?issueKey=QWERTY-45&trimHistoryStartDate=2017-09-01 00:00&trimHistoryEndDate=2017-10-31 00:00&calendar=1&dayLength=businessDays&viewFormat=minutes&outputType=csv
Response
Response Structure
The response will be in the format specified by the outputType parameter, either CSV or JSON, containing the requested issue expanded report data.
Example Response Body (JSON)
{
"dateTimeFormat": "dd/MMM/yy h:mm a",
"dateFormat": "dd/MMM/yy",
"timeZone": "Europe/Istanbul",
"locale": "en-US",
"viewFormat": "hours",
"isComposite": false,
"columnsBy": "Status Duration Expanded",
"calendar": {
"allWorkingDaysHaveEqualLengths": true,
"calendarSuccessfullyLoaded": true,
"clientKey": null,
"dailyWorkingHours": 24.0,
"holidays": [],
"id": null,
"is7x24Calendar": true,
"isDefault": null,
"name": "normalHours",
"timeZone": "UTC",
"workingTimes": [
{
"end": 86400000,
"start": 0,
"weekday": "SUNDAY"
},
{
"end": 86400000,
"start": 0,
"weekday": "MONDAY"
},
{
"end": 86400000,
"start": 0,
"weekday": "TUESDAY"
},
{
"end": 86400000,
"start": 0,
"weekday": "WEDNESDAY"
},
{
"end": 86400000,
"start": 0,
"weekday": "THURSDAY"
},
{
"end": 86400000,
"start": 0,
"weekday": "FRIDAY"
},
{
"end": 86400000,
"start": 0,
"weekday": "SATURDAY"
}
]
},
"dayLength": "24HourDays",
"query": " issuekey = 'htp-2'",
"reportDate": "08/Aug/22 1:34 PM",
"version": "2.4.0.692",
"includedStatuses": [
{
"id": "5",
"name": "Resolved",
"statusCategory": {
"id": "3",
"name": "Done",
"key": "done",
"colorName": "green"
},
"scope": null,
"deleted": false
},
{
"id": "6",
"name": "Closed",
"statusCategory": {
"id": "3",
"name": "Done",
"key": "done",
"colorName": "green"
},
"scope": null,
"deleted": false
}
],
"excludedStatuses": [],
"deletedStatuses": [],
"isAggregationType": false,
"isOverall": false,
"isAverage": false,
"isSum": false,
"isMedian": false,
"isStddev": false,
"drawAllChart": true,
"table": {
"header": {
"headerColumns": [
{
"id": "issuekey",
"value": "Key"
},
{
"id": "summary",
"value": "Summary"
}
],
"groupByColumns": [],
"fieldColumns": [],
"valueColumns": [
{
"id": "5",
"value": "Resolved",
"isConsolidated": false
},
{
"id": "6",
"value": "Closed",
"isConsolidated": false
}
]
},
"body": {
"rows": [
{
"headerColumns": [
{
"id": "issuekey",
"value": "HTP-2"
},
{
"id": "summary",
"value": "Issue with 1 history"
}
],
"groupByColumns": [],
"fieldColumns": [],
"expanded": {
"stats": {
"visitCounts": [
{
"statusId": "5",
"value": 1
},
{
"statusId": "6",
"value": 1
}
],
"firstValues": [
{
"statusId": "5",
"value": 180000
},
{
"statusId": "6",
"value": 82085633949
}
],
"lastValues": [
{
"statusId": "5",
"value": 180000
},
{
"statusId": "6",
"value": 82085633949
}
],
"minValues": [
{
"statusId": "5",
"value": 180000
},
{
"statusId": "6",
"value": 82085633949
}
],
"maxValues": [
{
"statusId": "5",
"value": 180000
},
{
"statusId": "6",
"value": 82085633949
}
],
"averageValues": [
{
"statusId": "5",
"value": 180000
},
{
"statusId": "6",
"value": 82085633949
}
],
"totalValues": [
{
"statusId": "5",
"value": 180000
},
{
"statusId": "6",
"value": 82085633949
}
],
"uniqueDates": [
{
"uniqueDate": "01/Jan/20 11:58 AM",
"statusId": "5",
"rawDate": 1577869080000
},
{
"uniqueDate": "01/Jan/20 12:01 PM",
"statusId": "6",
"rawDate": 1577869260000
}
]
},
"rows": [
{
"uniqueDate": "01/Jan/20 11:58 AM",
"statusId": "5",
"value": 180000
},
{
"uniqueDate": "01/Jan/20 12:01 PM",
"statusId": "6",
"value": 82085633949
}
]
}
}
]
}
}
}
Example Response Body (CSV)
"Date","Transitioned to","Resolved","Closed"
"01/Jan/20 11:58 AM","Resolved","0.05","-"
"01/Jan/20 12:01 PM","Closed","-","22801.5766013889"
Response Codes
200 OK: Returns a single issue expanded report as text (CSV or JSON).
400 Bad Request: When one or more of the required parameters are missing or one or more of the supplied parameter values are invalid.