Moogsoft Docs

getReassignedSituationsPerUserStats

A GET request that returns the number of Situations reassigned by a user within a given time range.

Back to Stats API.

Request arguments

Endpoint getReassignedSituationsPerUserStats takes the following request arguments.

Response

Endpoint getReassignedSituationsPerUserStats returns the following response:

Successful requests return a JSON object containing the following:

Name

Type

Description

target

String

"Reassigned Situations (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: Number of Situations reassigned by the user.

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

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

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

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

Examples

The following examples demonstrate typical use of endpoint getReassignedSituationsPerUserStats:

Request example

A cURL request to return the number of Situations reassigned by user 5 from 11pm on Sunday, 14th October until 5am on Monday, 15th October 2018:

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

Response example

A successful response returns the number of Situations reassigned by the user Dave each hour during the time range:

[{
        "datapoints":[
                [2.0,1539558000000],
                [3.0,1539561600000],
                [0.0,1539565200000],
                [1.0,1539568800000],
                [0.0,1539572400000],
                [3.0,1539576000000],
        ],
        "target":"Reassigned Situations (Dave Danton)"
}]