GroupBy Query Outputs

Information retrieved via a GroupBy query follows a simple format. A very simple example of this might look like this:

[
   {
      "version": "v1",
      "timestamp": "2024-02-20T13:00:00.000+02:00",
      "event": {
         "hw-fan-speed_max-Max": 9880
      }
   }
]

As you can see, the response is essentially a list of timestamps with associated events. Each event has three main fields:

  • version
  • timestamp
  • event

The version will always be "v1".

The timestamp shows when the event happened. The value will be formatted according to the ISO-8601 standard Keep in mind that GroupBy queries are always retrieving a period of data, such as "10 minutes". Thus, the timestamp represents the entire period and is not the actual data of the endpoint at that specific point in time. The timestamp simply shows when the period of the specific output event started.

Finally, the event list all the retrieved values and is the most complex field in the output. The example above just shows a simple query with only a single output. If you add multipe aggregations or postAggregations, you will get more outputs

If you have multiple aggregations, or if you add postAggregations, you can get an output with multiple events like this:

[
   {
      "version": "v1",
      "timestamp": "2024-02-20T13:00:00.000+02:00",
      "event": {
         "hw-fan-speed-Avg": 8771,
         "hw.fan.speed-Sum": 7578610,
         "count": 864
      }
   }
]

Keep in mind that the field names in the event output are based on how you configured them.

If you add dimensions to your query, your events will contain these attributes as well. This also means that you might have multiple entries for the same timestamp, each with their own unique attributes:

[
   {
      "version": "v1",
      "timestamp": "2024-02-20T13:00:00.000+02:00",
      "event": {
         "host.name": "Yosemite-2",
         "hw-fan-speed_max-Max": 9880
      }
   },
   {
      "version": "v1",
      "timestamp": "2024-02-20T13:00:00.000+02:00",
      "event": {
         "host.name": "Yosemite-3",
         "hw-fan-speed_max-Max": 8870
      }
   }
]