Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This article explains how to get SLA data for a specific issue using REST API.

Requirements

  • Get SLA data from Jira Issues in the Cloud.

  • Get the issue where SLA is broken.

  • Get the relevant date when the following:

    • SLA started

    • SLA paused

    • SLA resumed

    • SLA finished

REST API function

...

STEPS:

  1. Use the REST API function

...

  1. below for a specific issue and SLA.

Code Block
https://tts.snapbytesapps.com/api/issue-sla/{issueId}/sla/{slaId}

...

  1. Choose which data to retrieve based on the above Rest API

...

  1. call’s response:

  • Elapsed duration

  • Remaining duration

  • Overdue duration

  • Paused duration

  • Start date

  • Target date (deadline)

  • End date and etc

Code Block
{
  "issueId": "10091",
  "slaId": "38",
  "slaName": "Time to Response",
  "slaValueAsDurationString": "1h",
  "workingCalendarName": "7x24",
  "slaValueType": "SLA_VALUE",
  "slaStartType": {},
  "slaTargetType": {},
  "percentageThreshold": 80,
  "slaStatus": "STILL",
  "slaValue": 3600000,
  "startDate": 1647419947000,
  "endDate": null,
  "deadline": 1647423547000,
  "elapsedDuration": 235087,
  "remainingDuration": 3364913,
  "overdueDuration": 0,
  "pausedDuration": 0,
  "elapsedPercentage": 7,
  "isStarted": true,
  "isPaused": false,
  "isFinished": false,
  "inNonWorkingHours": false,
  "inNonWorkingDays": false,
  "lastStatusDate": 1647420182087,
  "calendarId": "7x24",
  "workingDuration": 235087,
  "slaValueForFixedDurations": null
}

...

Info

If SLA is met:
endDate will not equal to “null“ and the remaining duration will be greater than “0”.

If SLA is breached:
The remaining duration will be equal to “0”.

If SLA is in progress:
endDate will equal to “null“ and the remaining duration will be greater than “0”.

Info

This page is for the Cloud instance.