Skip to main content

getMTTAPerUserStats

A GET request that returns the mean time it takes a user to acknowledge a Situation within a given time range.

Back to Stats API.

Request arguments

Endpoint getMTTAPerUserStats takes the following request arguments.

Response

Endpoint getMTTAPerUserStats returns the following response:

Successful requests return a JSON object containing the following:

Name

Type

Description

target

String

"Mean Time to Acknowledge (MTTA) (full name)"

datapoints

Number Array

An array of data points. Each data point is an array in the format [data point, timestamp]:

  1. Data point:MTTA (seconds) for that bucket.

  • Less than 1 week: Returns the number of MTTA each hour in the time period.

  • 1 week to 1 month: Returns the number of MTTA each day in the time period.

  • 1 month to 1 year: Returns the number of MTTA each week in the time period.

  • More than 1 year: Returns the number of MTTA each month in the time period.

Examples

The following examples demonstrate typical use of endpoint getMTTAPerUserStats:

Request example

A cURL request for the MTTA for user 5 from 6.34am until 2.35pm on Tuesday, 25th September 2018:

curl -G -u graze:graze -k -v "https://localhost/graze/v1/getMTTAPerUserStats" --data-urlencode 'users=[5]' --data-urlencode 'from=1537857295' --data-urlencode 'to=1537886111' --data-urlencode 'aggregation=none'

Response example

A successful response returns the MTTA each hour for the user Robert:

[{
        "datapoints": [
                [221,1537857295000],
                [960,1537860895000], 
                [901,1537864495000], 
                [1196,1537868095000], 
                [671,1537871695000], 
                [1241,1537875295000], 
                [556,1537878895000]
        ],
        "target": "Mean Time to Acknowledge (MTTA)(Robert Richards)"
}]