getReoccurringSituationStats
A GET request that returns the percentage of reoccurring situations in the system over a given time range.
Back to Stats API.
Request arguments
Endpoint getReoccurringSituationStats
takes the following request arguments.
Response
Endpoint getReoccurringSituationStats
returns the following response:
Successful requests return a JSON object containing the following:
Name | Type | Description |
---|---|---|
| String | "Reoccurring Situations" |
| Number Array | An array of data points. Each data point is an array in the format [data point, timestamp]:
|
Examples
The following examples demonstrate typical use of endpoint getReoccurringSituationStats
:
Request example
A cURL request to retrieve the number of reoccurring Situations from 6pm on Sunday, September 10th 2017 until 6pm on Monday, September 10th 2018:
curl -G -u graze:graze -k -v "https://localhost/graze/v1/getReoccurringSituationStats" --data-urlencode 'from=1505066400' --data-urlencode 'to=1536602400'
Response example
A successful response returns that there were 186 reoccurring Situations during the year:
[{ "datapoints": [ [186.0, 1537980650126], ], "target": "Reoccurring situations" }]