SubscriptionScopeMetricsRequestBodyParameters interface
Query parameters can also be specified in the body, specifying the same parameter in both the body and query parameters will result in an error.
Properties
| aggregation | The list of aggregation types (comma separated) to retrieve. |
| auto |
When set to true, if the timespan passed in is not supported by this metric, the API will return the result using the closest supported timespan. When set to false, an error is returned for invalid timespan parameters. Defaults to false. |
| filter | The $filter is used to reduce the set of metric data returned. |
| interval | The interval (i.e. timegrain) of the query in ISO 8601 duration format. Defaults to PT1M. Special case for 'FULL' value that returns single datapoint for entire time span requested. Examples: PT15M, PT1H, P1D, FULL |
| metric |
The names of the metrics (comma separated) to retrieve. |
| metric |
Metric namespace where the metrics you want reside. |
| order |
The aggregation to use for sorting results and the direction of the sort. Only one order can be specified. Examples: sum asc. |
| result |
Reduces the set of data collected. The syntax allowed depends on the operation. See the operation's description for details. |
| roll |
Dimension name(s) to rollup results by. For example if you only want to see metric values with a filter like 'City eq Seattle or City eq Tacoma' but don't want to see separate values for each city, you can specify 'RollUpBy=City' to see the results for Seattle and Tacoma rolled up into one timeseries. |
| timespan | The timespan of the query. It is a string with the following format 'startDateTime_ISO/endDateTime_ISO'. |
| top | The maximum number of records to retrieve. Valid only if $filter is specified. Defaults to 10. |
| validate |
When set to false, invalid filter parameter values will be ignored. When set to true, an error is returned for invalid filter parameters. Defaults to true. |
Property Details
aggregation
The list of aggregation types (comma separated) to retrieve.
aggregation?: string
Property Value
string
autoAdjustTimegrain
When set to true, if the timespan passed in is not supported by this metric, the API will return the result using the closest supported timespan. When set to false, an error is returned for invalid timespan parameters. Defaults to false.
autoAdjustTimegrain?: boolean
Property Value
boolean
filter
The $filter is used to reduce the set of metric data returned.
Example:
Metric contains metadata A, B and C.
- Return all time series of C where A = a1 and B = b1 or b2
$filter=A eq ‘a1’ and B eq ‘b1’ or B eq ‘b2’ and C eq ‘*’
- Invalid variant:
$filter=A eq ‘a1’ and B eq ‘b1’ and C eq ‘*’ or B = ‘b2’
This is invalid because the logical or operator cannot separate two different metadata names.
- Return all time series where A = a1, B = b1 and C = c1:
$filter=A eq ‘a1’ and B eq ‘b1’ and C eq ‘c1’
- Return all time series where A = a1
$filter=A eq ‘a1’ and B eq ‘’ and C eq ‘’.
filter?: string
Property Value
string
interval
The interval (i.e. timegrain) of the query in ISO 8601 duration format. Defaults to PT1M. Special case for 'FULL' value that returns single datapoint for entire time span requested. Examples: PT15M, PT1H, P1D, FULL
interval?: string
Property Value
string
metricNames
The names of the metrics (comma separated) to retrieve.
metricNames?: string
Property Value
string
metricNamespace
Metric namespace where the metrics you want reside.
metricNamespace?: string
Property Value
string
orderBy
The aggregation to use for sorting results and the direction of the sort. Only one order can be specified. Examples: sum asc.
orderBy?: string
Property Value
string
resultType
Reduces the set of data collected. The syntax allowed depends on the operation. See the operation's description for details.
resultType?: string
Property Value
string
rollUpBy
Dimension name(s) to rollup results by. For example if you only want to see metric values with a filter like 'City eq Seattle or City eq Tacoma' but don't want to see separate values for each city, you can specify 'RollUpBy=City' to see the results for Seattle and Tacoma rolled up into one timeseries.
rollUpBy?: string
Property Value
string
timespan
The timespan of the query. It is a string with the following format 'startDateTime_ISO/endDateTime_ISO'.
timespan?: string
Property Value
string
top
The maximum number of records to retrieve. Valid only if $filter is specified. Defaults to 10.
top?: number
Property Value
number
validateDimensions
When set to false, invalid filter parameter values will be ignored. When set to true, an error is returned for invalid filter parameters. Defaults to true.
validateDimensions?: boolean
Property Value
boolean