From af0f44458d1e370da2868ef412e240d76b15fa84 Mon Sep 17 00:00:00 2001
From: LarryZhang19 <35974877+LarryZhang19@users.noreply.github.com>
Date: Tue, 6 Feb 2018 13:48:00 -0800
Subject: [PATCH 1/6] Adding 2018-01-01 version for metrics API
---
.../stable/2018-01-01/examples/GetMetric.json | 98 ++
.../examples/GetMetricDefinitions.json | 928 ++++++++++++++++++
.../examples/GetMetricMetadata.json | 59 ++
.../2018-01-01/metricDefinitions_API.json | 430 ++++++++
.../stable/2018-01-01/metrics_API.json | 429 ++++++++
.../monitor/resource-manager/readme.md | 25 +-
6 files changed, 1968 insertions(+), 1 deletion(-)
create mode 100644 specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetric.json
create mode 100644 specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricDefinitions.json
create mode 100644 specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricMetadata.json
create mode 100644 specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
create mode 100644 specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetric.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetric.json
new file mode 100644
index 000000000000..e794a13b203b
--- /dev/null
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetric.json
@@ -0,0 +1,98 @@
+{
+ "parameters": {
+ "resourceUri": "subscriptions/b324c52b-4073-4807-93af-e07d289c093e/resourceGroups/test/providers/Microsoft.Storage/storageAccounts/larryshoebox/blobServices/default",
+ "timespan": "2017-04-14T02:20:00Z/2017-04-14T04:20:00Z",
+ "metric": "BlobCapacity",
+ "metricnamespace": "Microsoft.Storage/storageAccounts/blobServices",
+ "$filter": "BlobType eq '*'",
+ "top": "3",
+ "orderby": "Average asc",
+ "aggregation": "Average,count",
+ "interval": "PT1M",
+ "api-version": "2018-01-01"
+ },
+ "responses": {
+ "200": {
+ "body": {
+ "cost": 0,
+ "timespan": "2017-04-14T02:20:00Z/2017-04-14T04:20:00Z",
+ "interval": "PT1M",
+ "namespace": "Microsoft.Storage/storageAccounts/blobServices",
+ "resourceregion": "eastus2",
+ "value": [
+ {
+ "id": "/subscriptions/b324c52b-4073-4807-93af-e07d289c093e/resourceGroups/test/providers/Microsoft.Storage/storageAccounts/larryshoebox/blobServices/default/providers/Microsoft.Insights/metrics/BlobCapacity",
+ "type": "Microsoft.Insights/metrics",
+ "name": {
+ "value": "BlobCapacity",
+ "localizedValue": "Blob Capacity"
+ },
+ "unit": "Bytes",
+ "timeseries": [
+ {
+ "metadatavalues": [
+ {
+ "name": {
+ "value": "blobtype",
+ "localizedValue": "blobtype"
+ },
+ "value": "PageBlob"
+ }
+ ],
+ "data": [
+ {
+ "timeStamp": "2017-04-14T02:20:00Z",
+ "count": 0.0
+ },
+ {
+ "timeStamp": "2017-04-14T02:21:00Z",
+ "count": 0.0
+ },
+ {
+ "timeStamp": "2017-04-14T02:22:00Z",
+ "count": 0.0
+ },
+ {
+ "timeStamp": "2017-04-14T02:23:00Z",
+ "count": 1.0,
+ "average": 0.0
+ }
+ ]
+ },
+ {
+ "metadatavalues": [
+ {
+ "name": {
+ "value": "blobtype",
+ "localizedValue": "blobtype"
+ },
+ "value": "BlockBlob"
+ }
+ ],
+ "data": [
+ {
+ "timeStamp": "2017-04-14T02:20:00Z",
+ "count": 0.0
+ },
+ {
+ "timeStamp": "2017-04-14T02:21:00Z",
+ "count": 0.0
+ },
+ {
+ "timeStamp": "2017-04-14T02:22:00Z",
+ "count": 0.0
+ },
+ {
+ "timeStamp": "2017-04-14T02:23:00Z",
+ "count": 1.0,
+ "average": 245.0
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricDefinitions.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricDefinitions.json
new file mode 100644
index 000000000000..5f49d369c758
--- /dev/null
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricDefinitions.json
@@ -0,0 +1,928 @@
+{
+ "parameters": {
+ "resourceUri": "subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricDefinitions",
+ "api-version": "2018-01-01",
+ "metricnamespace": "Microsoft.Web/sites"
+ },
+ "responses": {
+ "200": {
+ "body":
+ {
+ "value": [{
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/CpuTime",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "CpuTime",
+ "localizedValue": "CPU Time"
+ },
+ "isDimensionRequired": false,
+ "unit": "Seconds",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Requests",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Requests",
+ "localizedValue": "Requests"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/BytesReceived",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "BytesReceived",
+ "localizedValue": "Data In"
+ },
+ "isDimensionRequired": false,
+ "unit": "Bytes",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/BytesSent",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "BytesSent",
+ "localizedValue": "Data Out"
+ },
+ "isDimensionRequired": false,
+ "unit": "Bytes",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http101",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http101",
+ "localizedValue": "Http 101"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http2xx",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http2xx",
+ "localizedValue": "Http 2xx"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http3xx",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http3xx",
+ "localizedValue": "Http 3xx"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http401",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http401",
+ "localizedValue": "Http 401"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http403",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http403",
+ "localizedValue": "Http 403"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http404",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http404",
+ "localizedValue": "Http 404"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http406",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http406",
+ "localizedValue": "Http 406"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http4xx",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http4xx",
+ "localizedValue": "Http 4xx"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/Http5xx",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "Http5xx",
+ "localizedValue": "Http Server Errors"
+ },
+ "isDimensionRequired": false,
+ "unit": "Count",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/MemoryWorkingSet",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "MemoryWorkingSet",
+ "localizedValue": "Memory working set"
+ },
+ "isDimensionRequired": false,
+ "unit": "Bytes",
+ "primaryAggregationType": "Average",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/AverageMemoryWorkingSet",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "AverageMemoryWorkingSet",
+ "localizedValue": "Average memory working set"
+ },
+ "isDimensionRequired": false,
+ "unit": "Bytes",
+ "primaryAggregationType": "Average",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/AverageResponseTime",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "AverageResponseTime",
+ "localizedValue": "Average Response Time"
+ },
+ "isDimensionRequired": false,
+ "unit": "Seconds",
+ "primaryAggregationType": "Average",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }
+ ]
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricMetadata.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricMetadata.json
new file mode 100644
index 000000000000..10a07efc6362
--- /dev/null
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricMetadata.json
@@ -0,0 +1,59 @@
+{
+ "parameters": {
+ "timespan": "2017-04-14T02:20:00Z/2017-04-14T04:20:00Z",
+ "metric": "BlobCapacity",
+ "metricnamespace": "Microsoft.Storage/storageAccounts/blobServices",
+ "$filter": "BlobType eq '*'",
+ "top": "3",
+ "orderby": "Average asc",
+ "aggregation": "Average,count",
+ "interval": "PT1M",
+ "resulttype": "metadata",
+ "resourceUri": "subscriptions/b324c52b-4073-4807-93af-e07d289c093e/resourceGroups/test/providers/Microsoft.Storage/storageAccounts/larryshoebox/blobServices/default",
+ "api-version": "2018-01-01"
+ },
+ "responses": {
+ "200": {
+ "body": {
+ "timespan": "2017-04-14T02:20:00Z/2017-04-14T04:20:00Z",
+ "namespace": "Microsoft.Storage/storageAccounts/blobServices",
+ "resourceregion": "eastus2",
+ "value": [
+ {
+ "id": "/subscriptions/b324c52b-4073-4807-93af-e07d289c093e/resourceGroups/test/providers/Microsoft.Storage/storageAccounts/larryshoebox/blobServices/default/providers/Microsoft.Insights/metrics/BlobCapacity",
+ "type": "Microsoft.Insights/metrics",
+ "name": {
+ "value": "BlobCapacity",
+ "localizedValue": "Blob Capacity"
+ },
+ "unit": "Bytes",
+ "timeseries": [
+ {
+ "metadatavalues": [
+ {
+ "name": {
+ "value": "blobtype",
+ "localizedValue": "blobtype"
+ },
+ "value": "BlockBlob"
+ }
+ ]
+ },
+ {
+ "metadatavalues": [
+ {
+ "name": {
+ "value": "blobtype",
+ "localizedValue": "blobtype"
+ },
+ "value": "PageBlob"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
new file mode 100644
index 000000000000..f944a7273744
--- /dev/null
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
@@ -0,0 +1,430 @@
+{
+ "swagger": "2.0",
+ "info": {
+ "title": "MonitorManagementClient",
+ "x-ms-code-generation-settings": {
+ "name": "MonitorManagementClient"
+ },
+ "version": "2018-01-01"
+ },
+ "host": "management.azure.com",
+ "schemes": [
+ "https"
+ ],
+ "consumes": [
+ "application/json"
+ ],
+ "produces": [
+ "application/json"
+ ],
+ "security": [
+ {
+ "azure_auth": [
+ "user_impersonation"
+ ]
+ }
+ ],
+ "securityDefinitions": {
+ "azure_auth": {
+ "type": "oauth2",
+ "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
+ "flow": "implicit",
+ "description": "Azure Active Directory OAuth2 Flow",
+ "scopes": {
+ "user_impersonation": "impersonate your user account"
+ }
+ }
+ },
+ "paths": {
+ "/{resourceUri}/providers/microsoft.insights/metricDefinitions": {
+ "get": {
+ "tags": [
+ "MetricDefinitions"
+ ],
+ "operationId": "MetricDefinitions_List",
+ "description": "Lists the metric definitions for the resource.",
+ "parameters": [
+ {
+ "$ref": "#/parameters/ResourceUriParameter"
+ },
+ {
+ "$ref": "#/parameters/ApiVersionParameter"
+ },
+ {
+ "$ref": "#/parameters/MetricNamespaceParameter"
+ }
+ ],
+ "responses": {
+ "default": {
+ "description": "Error response describing why the operation failed.",
+ "schema": {
+ "$ref": "#/definitions/ErrorResponse"
+ }
+ },
+ "200": {
+ "description": "Successful request to get the list of metric definitions",
+ "schema": {
+ "$ref": "#/definitions/MetricDefinitionCollection"
+ },
+ "examples": {
+ "application/json": {
+ "value": [{
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/CpuTime",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "CpuTime",
+ "localizedValue": "CPU Time"
+ },
+ "isDimensionRequired": false,
+ "unit": "Seconds",
+ "primaryAggregationType": "Total",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/MemoryWorkingSet",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "MemoryWorkingSet",
+ "localizedValue": "Memory working set"
+ },
+ "isDimensionRequired": false,
+ "unit": "Bytes",
+ "primaryAggregationType": "Average",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }, {
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/AverageMemoryWorkingSet",
+ "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
+ "namespace": "Microsoft.Web/sites",
+ "name": {
+ "value": "AverageMemoryWorkingSet",
+ "localizedValue": "Average memory working set"
+ },
+ "isDimensionRequired": false,
+ "unit": "Bytes",
+ "primaryAggregationType": "Average",
+ "supportedAggregationTypes": [
+ "None",
+ "Average",
+ "Minimum",
+ "Maximum",
+ "Total",
+ "Count"
+ ],
+ "metricAvailabilities": [{
+ "timeGrain": "PT1M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT5M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT15M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT30M",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT1H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT6H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "PT12H",
+ "retention": "P93D"
+ },
+ {
+ "timeGrain": "P1D",
+ "retention": "P93D"
+ }
+ ],
+ "dimensions": [{
+ "value": "Instance",
+ "localizedValue": "Instance"
+ }
+ ]
+ }
+ ]
+ }
+ }
+ }
+ },
+ "x-ms-pageable": {
+ "nextLinkName": null
+ },
+ "x-ms-examples": {
+ "Get Metric Definitions without filter": { "$ref": "./examples/GetMetricDefinitions.json" }
+ }
+ }
+ }
+ },
+ "definitions": {
+ "LocalizableString": {
+ "required": [ "value" ],
+ "properties": {
+ "value": {
+ "type": "string",
+ "description": "the invariant value."
+ },
+ "localizedValue": {
+ "type": "string",
+ "description": "the locale specific value."
+ }
+ },
+ "description": "The localizable string class."
+ },
+ "MetricAvailability": {
+ "properties": {
+ "timeGrain": {
+ "type": "string",
+ "format": "duration",
+ "description": "the time grain specifies the aggregation interval for the metric. Expressed as a duration 'PT1M', 'P1D', etc."
+ },
+ "retention": {
+ "type": "string",
+ "format": "duration",
+ "description": "the retention period for the metric at the specified timegrain. Expressed as a duration 'PT1M', 'P1D', etc."
+ }
+ },
+ "description": "Metric availability specifies the time grain (aggregation interval or frequency) and the retention period for that time grain."
+ },
+ "Unit": {
+ "type": "string",
+ "description": "the unit of the metric.",
+ "enum": [
+ "Count",
+ "Bytes",
+ "Seconds",
+ "CountPerSecond",
+ "BytesPerSecond",
+ "Percent",
+ "MilliSeconds",
+ "ByteSeconds",
+ "Unspecified"
+ ],
+ "x-ms-enum": {
+ "name": "Unit",
+ "modelAsString": false
+ }
+ },
+ "AggregationType":
+ {
+ "type": "string",
+ "description": "the aggregation type of the metric.",
+ "enum": [
+ "None",
+ "Average",
+ "Count",
+ "Minimum",
+ "Maximum",
+ "Total"
+ ],
+ "x-ms-enum": {
+ "name": "AggregationType",
+ "modelAsString": false
+ }
+ },
+ "MetricDefinition": {
+ "properties": {
+ "isDimensionRequired": {
+ "type": "boolean",
+ "description": "Flag to indicate whether the dimension is required."
+ },
+ "resourceId": {
+ "type": "string",
+ "description": "the resource identifier of the resource that emitted the metric."
+ },
+ "namespace": {
+ "type": "string",
+ "description": "the namespace the metric blongs to."
+ },
+ "name": {
+ "$ref": "#/definitions/LocalizableString",
+ "description": "the name and the display name of the metric, i.e. it is a localizable string."
+ },
+ "unit": {
+ "$ref": "#/definitions/Unit",
+ "description": "the unit of the metric."
+ },
+ "primaryAggregationType": {
+ "$ref": "#/definitions/AggregationType",
+ "description": "the primary aggregation type value defining how to use the values for display.",
+ },
+ "supportedAggregationTypes": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/AggregationType"
+ },
+ "description": "the collection of what aggregation types are supported."
+ },
+ "metricAvailabilities": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/MetricAvailability"
+ },
+ "description": "the collection of what aggregation intervals are available to be queried."
+ },
+ "id": {
+ "type": "string",
+ "description": "the resource identifier of the metric definition."
+ },
+ "dimensions": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/LocalizableString"
+ },
+ "description": "the name and the display name of the dimension, i.e. it is a localizable string."
+ }
+ },
+ "description": "Metric definition class specifies the metadata for a metric."
+ },
+ "MetricDefinitionCollection": {
+ "properties": {
+ "value": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/MetricDefinition"
+ },
+ "description": "the values for the metric definitions."
+ }
+ },
+ "required": ["value"],
+ "description": "Represents collection of metric definitions."
+ },
+ "ErrorResponse": {
+ "description": "Describes the format of Error response.",
+ "type": "object",
+ "properties": {
+ "code": {
+ "description": "Error code",
+ "type": "string"
+ },
+ "message": {
+ "description": "Error message indicating why the operation failed.",
+ "type": "string"
+ }
+ }
+ }
+ },
+ "parameters": {
+ "ApiVersionParameter": {
+ "name": "api-version",
+ "in": "query",
+ "required": true,
+ "type": "string",
+ "description": "Client Api Version."
+ },
+ "ResourceUriParameter": {
+ "name": "resourceUri",
+ "in": "path",
+ "required": true,
+ "type": "string",
+ "description": "The identifier of the resource.",
+ "x-ms-parameter-location": "method",
+ "x-ms-skip-url-encoding": true
+ },
+ "MetricNamespaceParameter": {
+ "name": "metricnamespace",
+ "in": "query",
+ "required": false,
+ "type": "string",
+ "description": "Metric namespace to query metric definitions for."
+ }
+ }
+}
\ No newline at end of file
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
new file mode 100644
index 000000000000..d4e48cc00481
--- /dev/null
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
@@ -0,0 +1,429 @@
+{
+ "swagger": "2.0",
+ "info": {
+ "title": "MonitorManagementClient",
+ "x-ms-code-generation-settings": {
+ "name": "MonitorManagementClient"
+ },
+ "version": "2018-01-01"
+ },
+ "host": "management.azure.com",
+ "schemes": [
+ "https"
+ ],
+ "consumes": [
+ "application/json"
+ ],
+ "produces": [
+ "application/json"
+ ],
+ "security": [
+ {
+ "azure_auth": [
+ "user_impersonation"
+ ]
+ }
+ ],
+ "securityDefinitions": {
+ "azure_auth": {
+ "type": "oauth2",
+ "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
+ "flow": "implicit",
+ "description": "Azure Active Directory OAuth2 Flow",
+ "scopes": {
+ "user_impersonation": "impersonate your user account"
+ }
+ }
+ },
+ "paths": {
+ "/{resourceUri}/providers/microsoft.insights/metrics": {
+ "get": {
+ "tags": [
+ "Metrics"
+ ],
+ "operationId": "Metrics_List",
+ "description": "**Lists the metric values for a resource**.",
+ "parameters": [
+ {
+ "$ref": "#/parameters/ResourceUriParameter"
+ },
+ {
+ "$ref": "#/parameters/TimespanParameter"
+ },
+ {
+ "$ref": "#/parameters/IntervalParameter"
+ },
+ {
+ "$ref": "#/parameters/MetricParameter"
+ },
+ {
+ "$ref": "#/parameters/AggregationsParameter"
+ },
+ {
+ "$ref": "#/parameters/TopParameter"
+ },
+ {
+ "$ref": "#/parameters/OrderByParameter"
+ },
+ {
+ "name": "$filter",
+ "in": "query",
+ "type": "string",
+ "description": "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 ‘*’**.",
+ "required": false
+ },
+ {
+ "$ref": "#/parameters/ResultTypeParameter"
+ },
+ {
+ "$ref": "#/parameters/ApiVersionParameter"
+ },
+ {
+ "$ref": "#/parameters/MetricNamespaceParameter"
+ }
+ ],
+ "responses": {
+ "default": {
+ "description": "Error response describing why the operation failed.",
+ "schema": {
+ "$ref": "#/definitions/ErrorResponse"
+ }
+ },
+ "200": {
+ "description": "Successful request to get the list of metric values.",
+ "schema": {
+ "$ref": "#/definitions/Response"
+ },
+ "examples": {
+ "application/json": {
+ "cost": 0,
+ "timespan": "2017-08-10T21:44:34Z/2017-08-10T22:44:34Z",
+ "interval": "PT1M",
+ "namespace": "Microsoft.Storage/storageAccounts/blobServices",
+ "resourceregion": "eastus2",
+ "value": [{
+ "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/Microsoft.Insights/metrics/CpuTime",
+ "type": "Microsoft.Insights/metrics",
+ "name": {
+ "value": "CpuTime",
+ "localizedValue": "CPU Time"
+ },
+ "unit": "Seconds",
+ "timeseries": [{
+ "metadatavalues": [],
+ "data": [{
+ "timeStamp": "2017-08-10T21:44:00Z",
+ "total": 0.0
+ }, {
+ "timeStamp": "2017-08-10T21:45:00Z",
+ "total": 0.0
+ }, {
+ "timeStamp": "2017-08-10T21:46:00Z",
+ "total": 0.0
+ }, {
+ "timeStamp": "2017-08-10T21:47:00Z",
+ "total": 0.0
+ }, {
+ "timeStamp": "2017-08-10T21:48:00Z",
+ "total": 0.0
+ }, {
+ "timeStamp": "2017-08-10T21:49:00Z",
+ "total": 0.0
+ }, {
+ "timeStamp": "2017-08-10T21:50:00Z",
+ "total": 0.0
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ }
+ }
+ },
+ "x-ms-odata": "#/definitions/MetadataValue",
+ "x-ms-examples": {
+ "Get Metric for data": { "$ref": "./examples/GetMetric.json" },
+ "Get Metric for metadata": { "$ref": "./examples/GetMetricMetadata.json" }
+ }
+ }
+ }
+ },
+ "definitions": {
+ "LocalizableString": {
+ "required": [ "value" ],
+ "properties": {
+ "value": {
+ "type": "string",
+ "description": "the invariant value."
+ },
+ "localizedValue": {
+ "type": "string",
+ "description": "the locale specific value."
+ }
+ },
+ "description": "The localizable string class."
+ },
+ "Unit": {
+ "type": "string",
+ "description": "the unit of the metric.",
+ "enum": [
+ "Count",
+ "Bytes",
+ "Seconds",
+ "CountPerSecond",
+ "BytesPerSecond",
+ "Percent",
+ "MilliSeconds",
+ "ByteSeconds",
+ "Unspecified"
+ ],
+ "x-ms-enum": {
+ "name": "Unit",
+ "modelAsString": false
+ }
+ },
+ "MetricValue": {
+ "required": [ "timeStamp" ],
+ "properties": {
+ "timeStamp": {
+ "type": "string",
+ "format": "date-time",
+ "description": "the timestamp for the metric value in ISO 8601 format."
+ },
+ "average": {
+ "type": "number",
+ "format": "double",
+ "description": "the average value in the time range."
+ },
+ "minimum": {
+ "type": "number",
+ "format": "double",
+ "description": "the least value in the time range."
+ },
+ "maximum": {
+ "type": "number",
+ "format": "double",
+ "description": "the greatest value in the time range."
+ },
+ "total": {
+ "type": "number",
+ "format": "double",
+ "description": "the sum of all of the values in the time range."
+ },
+ "count": {
+ "type": "integer",
+ "format": "int64",
+ "description": "the number of samples in the time range. Can be used to determine the number of values that contributed to the average value."
+ }
+ },
+ "description": "Represents a metric value."
+ },
+ "MetadataValue": {
+ "properties": {
+ "name": {
+ "$ref": "#/definitions/LocalizableString",
+ "description": "the name of the metadata."
+ },
+ "value": {
+ "type": "string",
+ "description": "the value of the metadata."
+ }
+ },
+ "description": "Represents a metric metadata value."
+ },
+ "ErrorResponse": {
+ "description": "Describes the format of Error response.",
+ "type": "object",
+ "properties": {
+ "code": {
+ "description": "Error code",
+ "type": "string"
+ },
+ "message": {
+ "description": "Error message indicating why the operation failed.",
+ "type": "string"
+ }
+ }
+ },
+ "Response": {
+ "type": "object",
+ "properties": {
+ "cost": {
+ "type": "number",
+ "format": "int32",
+ "minimum": 0,
+ "description": "The integer value representing the cost of the query, for data case."
+ },
+ "timespan": {
+ "type": "string",
+ "description": "The timespan for which the data was retrieved. Its value consists of two datatimes concatenated, separated by '/'. This may be adjusted in the future and returned back from what was originally requested."
+ },
+ "interval": {
+ "type": "string",
+ "format": "duration",
+ "description": "The interval (window size) for which the metric data was returned in. This may be adjusted in the future and returned back from what was originally requested. This is not present if a metadata request was made."
+ },
+ "namespace": {
+ "type": "string",
+ "description": "The namespace of the metrics been queried"
+ },
+ "resourceregion": {
+ "type": "string",
+ "description": "The region of the resource been queried for metrics."
+ },
+ "value": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/Metric"
+ },
+ "description": "the value of the collection."
+ }
+ },
+ "required": [ "timespan", "value" ],
+ "description": "The response to a metrics query."
+ },
+ "Metric": {
+ "type": "object",
+ "properties": {
+ "id": {
+ "type": "string",
+ "description": "the metric Id."
+ },
+ "type": {
+ "type": "string",
+ "description": "the resource type of the metric resource."
+ },
+ "name": {
+ "$ref": "#/definitions/LocalizableString",
+ "description": "the name and the display name of the metric, i.e. it is localizable string."
+ },
+ "unit": {
+ "$ref": "#/definitions/Unit",
+ "description": "the unit of the metric."
+ },
+ "timeseries": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/TimeSeriesElement"
+ },
+ "description": "the time series returned when a data query is performed."
+ }
+ },
+ "required": [ "id", "type", "name", "unit", "timeseries" ],
+ "description": "The result data of a query."
+ },
+ "TimeSeriesElement": {
+ "type": "object",
+ "properties": {
+ "metadatavalues": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/MetadataValue"
+ },
+ "description": "the metadata values returned if $filter was specified in the call."
+ },
+ "data": {
+ "type": "array",
+ "items": {
+ "$ref": "#/definitions/MetricValue"
+ },
+ "description": "An array of data points representing the metric values. This is only returned if a result type of data is specified."
+ }
+ },
+ "description": "A time series result type. The discriminator value is always TimeSeries in this case."
+ }
+ },
+ "parameters": {
+ "ResourceUriParameter": {
+ "name": "resourceUri",
+ "in": "path",
+ "required": true,
+ "type": "string",
+ "description": "The identifier of the resource.",
+ "x-ms-parameter-location": "method",
+ "x-ms-skip-url-encoding": true
+ },
+ "TimespanParameter": {
+ "name": "timespan",
+ "in": "query",
+ "required": false,
+ "type": "string",
+ "description": "The timespan of the query. It is a string with the following format 'startDateTime_ISO/endDateTime_ISO'.",
+ "x-ms-parameter-location": "method"
+ },
+ "IntervalParameter": {
+ "name": "interval",
+ "in": "query",
+ "required": false,
+ "type": "string",
+ "format": "duration",
+ "description": "The interval (i.e. timegrain) of the query.",
+ "x-ms-parameter-location": "method"
+ },
+ "MetricParameter": {
+ "name": "metric",
+ "in": "query",
+ "required": false,
+ "type": "string",
+ "description": "The name of the metric to retrieve.",
+ "x-ms-parameter-location": "method"
+ },
+ "AggregationsParameter": {
+ "name": "aggregation",
+ "in": "query",
+ "required": false,
+ "type": "string",
+ "description": "The list of aggregation types (comma separated) to retrieve.",
+ "x-ms-parameter-location": "method"
+ },
+ "TopParameter": {
+ "name": "$top",
+ "in": "query",
+ "required": false,
+ "type": "number",
+ "format": "int32",
+ "description": "The maximum number of records to retrieve.\nValid only if $filter is specified.\nDefaults to 10.",
+ "x-ms-parameter-location": "method"
+ },
+ "OrderByParameter": {
+ "name": "$orderby",
+ "in": "query",
+ "required": false,
+ "type": "string",
+ "description": "The aggregation to use for sorting results and the direction of the sort.\nOnly one order can be specified.\nExamples: sum asc.",
+ "x-ms-parameter-location": "method"
+ },
+ "ResultTypeParameter": {
+ "name": "resultType",
+ "in": "query",
+ "type": "string",
+ "enum": [
+ "Data",
+ "Metadata"
+ ],
+ "x-ms-enum": {
+ "name": "ResultType",
+ "modelAsString": false
+ },
+ "description": "Reduces the set of data collected. The syntax allowed depends on the operation. See the operation's description for details.",
+ "x-ms-parameter-location": "method",
+ "required": false
+ },
+ "ApiVersionParameter": {
+ "name": "api-version",
+ "in": "query",
+ "required": true,
+ "type": "string",
+ "description": "Client Api Version."
+ },
+ "MetricNamespaceParameter": {
+ "name": "metricnamespace",
+ "in": "query",
+ "required": false,
+ "type": "string",
+ "description": "Metric namespace to query metric definitions for."
+ }
+ }
+}
\ No newline at end of file
diff --git a/specification/monitor/resource-manager/readme.md b/specification/monitor/resource-manager/readme.md
index 1588e4103c0b..e6338ec1b157 100644
--- a/specification/monitor/resource-manager/readme.md
+++ b/specification/monitor/resource-manager/readme.md
@@ -28,7 +28,30 @@ These are the global settings for the MonitorClient API.
title: MonitorClient
description: Monitor Management Client
openapi-type: arm
-tag: package-2017-09
+tag: package-2018-02
+```
+### Tag: package-2018-02
+
+These settings apply only when `--tag=package-2018-02` is specified on the command line.
+
+``` yaml $(tag) == 'package-2018-02'
+input-file:
+- microsoft.insights/stable/2015-04-01/autoscale_API.json
+- microsoft.insights/stable/2015-04-01/operations_API.json
+- microsoft.insights/stable/2016-03-01/alertRulesIncidents_API.json
+- microsoft.insights/stable/2016-03-01/alertRules_API.json
+- microsoft.insights/stable/2016-03-01/logProfiles_API.json
+- microsoft.insights/preview/2017-05-01-preview/diagnosticsSettings_API.json
+- microsoft.insights/preview/2017-05-01-preview/diagnosticsSettingsCategories_API.json
+- microsoft.insights/stable/2017-04-01/actionGroups_API.json
+- microsoft.insights/stable/2017-04-01/activityLogAlerts_API.json
+- microsoft.insights/stable/2015-04-01/activityLogs_API.json
+- microsoft.insights/stable/2015-04-01/eventCategories_API.json
+- microsoft.insights/stable/2015-04-01/tenantActivityLogs_API.json
+- microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
+- microsoft.insights/stable/2018-01-01/metrics_API.json
+- microsoft.insights/preview/2017-11-01-preview/baseline_API.json
+- microsoft.insights/preview/2017-11-01-preview/calculateBaseline_API.json
```
### Tag: package-2017-09
From fa60ee8a72205ccb78b877f85b6add99ec07ea07 Mon Sep 17 00:00:00 2001
From: LarryZhang19 <35974877+LarryZhang19@users.noreply.github.com>
Date: Tue, 6 Feb 2018 15:07:19 -0800
Subject: [PATCH 2/6] Fix extra comma at the end of line
---
.../stable/2018-01-01/metricDefinitions_API.json | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
index f944a7273744..4c9c2a1824a3 100644
--- a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
@@ -344,7 +344,7 @@
},
"primaryAggregationType": {
"$ref": "#/definitions/AggregationType",
- "description": "the primary aggregation type value defining how to use the values for display.",
+ "description": "the primary aggregation type value defining how to use the values for display."
},
"supportedAggregationTypes": {
"type": "array",
From 25392731dd0415e1e5700412428dd5a96a2d7813 Mon Sep 17 00:00:00 2001
From: LarryZhang19 <35974877+LarryZhang19@users.noreply.github.com>
Date: Wed, 7 Feb 2018 12:52:09 -0800
Subject: [PATCH 3/6] Fix PR comments 1
---
.../2018-01-01/metricDefinitions_API.json | 177 ------------------
.../stable/2018-01-01/metrics_API.json | 46 -----
.../monitor/resource-manager/readme.md | 8 +-
3 files changed, 4 insertions(+), 227 deletions(-)
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
index 4c9c2a1824a3..4ce7202cc364 100644
--- a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metricDefinitions_API.json
@@ -65,183 +65,6 @@
"description": "Successful request to get the list of metric definitions",
"schema": {
"$ref": "#/definitions/MetricDefinitionCollection"
- },
- "examples": {
- "application/json": {
- "value": [{
- "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/CpuTime",
- "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
- "namespace": "Microsoft.Web/sites",
- "name": {
- "value": "CpuTime",
- "localizedValue": "CPU Time"
- },
- "isDimensionRequired": false,
- "unit": "Seconds",
- "primaryAggregationType": "Total",
- "supportedAggregationTypes": [
- "None",
- "Average",
- "Minimum",
- "Maximum",
- "Total",
- "Count"
- ],
- "metricAvailabilities": [{
- "timeGrain": "PT1M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT5M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT15M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT30M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT1H",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT6H",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT12H",
- "retention": "P93D"
- },
- {
- "timeGrain": "P1D",
- "retention": "P93D"
- }
- ],
- "dimensions": [{
- "value": "Instance",
- "localizedValue": "Instance"
- }
- ]
- }, {
- "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/MemoryWorkingSet",
- "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
- "namespace": "Microsoft.Web/sites",
- "name": {
- "value": "MemoryWorkingSet",
- "localizedValue": "Memory working set"
- },
- "isDimensionRequired": false,
- "unit": "Bytes",
- "primaryAggregationType": "Average",
- "supportedAggregationTypes": [
- "None",
- "Average",
- "Minimum",
- "Maximum",
- "Total",
- "Count"
- ],
- "metricAvailabilities": [{
- "timeGrain": "PT1M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT5M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT15M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT30M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT1H",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT6H",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT12H",
- "retention": "P93D"
- },
- {
- "timeGrain": "P1D",
- "retention": "P93D"
- }
- ],
- "dimensions": [{
- "value": "Instance",
- "localizedValue": "Instance"
- }
- ]
- }, {
- "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/microsoft.insights/metricdefinitions/AverageMemoryWorkingSet",
- "resourceId": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest",
- "namespace": "Microsoft.Web/sites",
- "name": {
- "value": "AverageMemoryWorkingSet",
- "localizedValue": "Average memory working set"
- },
- "isDimensionRequired": false,
- "unit": "Bytes",
- "primaryAggregationType": "Average",
- "supportedAggregationTypes": [
- "None",
- "Average",
- "Minimum",
- "Maximum",
- "Total",
- "Count"
- ],
- "metricAvailabilities": [{
- "timeGrain": "PT1M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT5M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT15M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT30M",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT1H",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT6H",
- "retention": "P93D"
- },
- {
- "timeGrain": "PT12H",
- "retention": "P93D"
- },
- {
- "timeGrain": "P1D",
- "retention": "P93D"
- }
- ],
- "dimensions": [{
- "value": "Instance",
- "localizedValue": "Instance"
- }
- ]
- }
- ]
- }
}
}
},
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
index d4e48cc00481..1a96a1521136 100644
--- a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
@@ -93,52 +93,6 @@
"description": "Successful request to get the list of metric values.",
"schema": {
"$ref": "#/definitions/Response"
- },
- "examples": {
- "application/json": {
- "cost": 0,
- "timespan": "2017-08-10T21:44:34Z/2017-08-10T22:44:34Z",
- "interval": "PT1M",
- "namespace": "Microsoft.Storage/storageAccounts/blobServices",
- "resourceregion": "eastus2",
- "value": [{
- "id": "/subscriptions/07c0b09d-9f69-4e6e-8d05-f59f67299cb2/resourceGroups/Rac46PostSwapRG/providers/Microsoft.Web/sites/alertruleTest/providers/Microsoft.Insights/metrics/CpuTime",
- "type": "Microsoft.Insights/metrics",
- "name": {
- "value": "CpuTime",
- "localizedValue": "CPU Time"
- },
- "unit": "Seconds",
- "timeseries": [{
- "metadatavalues": [],
- "data": [{
- "timeStamp": "2017-08-10T21:44:00Z",
- "total": 0.0
- }, {
- "timeStamp": "2017-08-10T21:45:00Z",
- "total": 0.0
- }, {
- "timeStamp": "2017-08-10T21:46:00Z",
- "total": 0.0
- }, {
- "timeStamp": "2017-08-10T21:47:00Z",
- "total": 0.0
- }, {
- "timeStamp": "2017-08-10T21:48:00Z",
- "total": 0.0
- }, {
- "timeStamp": "2017-08-10T21:49:00Z",
- "total": 0.0
- }, {
- "timeStamp": "2017-08-10T21:50:00Z",
- "total": 0.0
- }
- ]
- }
- ]
- }
- ]
- }
}
}
},
diff --git a/specification/monitor/resource-manager/readme.md b/specification/monitor/resource-manager/readme.md
index e6338ec1b157..6d4659a7f64f 100644
--- a/specification/monitor/resource-manager/readme.md
+++ b/specification/monitor/resource-manager/readme.md
@@ -28,13 +28,13 @@ These are the global settings for the MonitorClient API.
title: MonitorClient
description: Monitor Management Client
openapi-type: arm
-tag: package-2018-02
+tag: package-2018-02-preview
```
-### Tag: package-2018-02
+### Tag: package-2018-02-preview
-These settings apply only when `--tag=package-2018-02` is specified on the command line.
+These settings apply only when `--tag=package-2018-02-preview` is specified on the command line.
-``` yaml $(tag) == 'package-2018-02'
+``` yaml $(tag) == 'package-2018-02-preview'
input-file:
- microsoft.insights/stable/2015-04-01/autoscale_API.json
- microsoft.insights/stable/2015-04-01/operations_API.json
From f6739fd0e07e3d040fc0b1f47f3297a7a4a69cba Mon Sep 17 00:00:00 2001
From: LarryZhang19 <35974877+LarryZhang19@users.noreply.github.com>
Date: Fri, 16 Feb 2018 15:50:41 -0800
Subject: [PATCH 4/6] Fixing top/orderby names, Please be reminded, there is no
code change, it's just a typo of the names.
---
.../microsoft.insights/stable/2018-01-01/metrics_API.json | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
index 1a96a1521136..acfc986094db 100644
--- a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/metrics_API.json
@@ -333,7 +333,7 @@
"x-ms-parameter-location": "method"
},
"TopParameter": {
- "name": "$top",
+ "name": "top",
"in": "query",
"required": false,
"type": "number",
@@ -342,7 +342,7 @@
"x-ms-parameter-location": "method"
},
"OrderByParameter": {
- "name": "$orderby",
+ "name": "orderby",
"in": "query",
"required": false,
"type": "string",
From 451731bb04757b86146a4da8c8451b1a95b20546 Mon Sep 17 00:00:00 2001
From: LarryZhang19 <35974877+LarryZhang19@users.noreply.github.com>
Date: Fri, 16 Feb 2018 17:32:07 -0800
Subject: [PATCH 5/6] Fix the sample to reflect the parameter
---
.../stable/2018-01-01/examples/GetMetric.json | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetric.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetric.json
index e794a13b203b..e4577210e0fa 100644
--- a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetric.json
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetric.json
@@ -5,7 +5,7 @@
"metric": "BlobCapacity",
"metricnamespace": "Microsoft.Storage/storageAccounts/blobServices",
"$filter": "BlobType eq '*'",
- "top": "3",
+ "top": 3,
"orderby": "Average asc",
"aggregation": "Average,count",
"interval": "PT1M",
From 8ddf699be2bc7bd7a429b97db29d4abb3f238cad Mon Sep 17 00:00:00 2001
From: LarryZhang19 <35974877+LarryZhang19@users.noreply.github.com>
Date: Fri, 16 Feb 2018 17:45:12 -0800
Subject: [PATCH 6/6] Fix meta data sample as well.
---
.../stable/2018-01-01/examples/GetMetricMetadata.json | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricMetadata.json b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricMetadata.json
index 10a07efc6362..eb929a0ee350 100644
--- a/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricMetadata.json
+++ b/specification/monitor/resource-manager/microsoft.insights/stable/2018-01-01/examples/GetMetricMetadata.json
@@ -4,7 +4,7 @@
"metric": "BlobCapacity",
"metricnamespace": "Microsoft.Storage/storageAccounts/blobServices",
"$filter": "BlobType eq '*'",
- "top": "3",
+ "top": 3,
"orderby": "Average asc",
"aggregation": "Average,count",
"interval": "PT1M",