Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding MetricNamespacesAPI for version 2017-12-01-preview/Fix metrics_API.json format issue #3804

Merged
merged 14 commits into from
Sep 6, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"parameters": {
"resourceUri": "subscriptions/a252e87d-ec06-45b1-8901-57e613be91b0/resourceGroups/larrytest/providers/Microsoft.DocumentDB/databaseAccounts/larrytestdocdb",
"startTime": "2018-08-31T15:53:00Z",
"api-version": "2017-12-01-preview"
},
"responses": {
"200": {
"body": {
"value": [
{
"id": "/subscriptions/a252e87d-ec06-45b1-8901-57e613be91b0/resourceGroups/larrytest/providers/Microsoft.DocumentDB/databaseAccounts/larrytestdocdb/providers/microsoft.insights/metricNamespaces/Microsoft.DocumentDB-databaseAccounts",
"name": "Microsoft.DocumentDB-databaseAccounts",
"type": "Microsoft.Insights/metricNamespaces",
"properties": {
"metricNamespaceName": "Microsoft.DocumentDB/databaseAccounts"
}
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,166 @@
{
"swagger": "2.0",
"info": {
"title": "MonitorManagementClient",
"x-ms-code-generation-settings": {
"name": "MonitorManagementClient"
},
"version": "2017-12-01-preview"
},
"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/metricNamespaces": {
"get": {
"tags": [
"metricNamespaces"
],
"operationId": "MetricNamespaces_List",
"description": "Lists the metric namespaces for the resource.",
"parameters": [
{
"$ref": "#/parameters/ResourceUriParameter"
},
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/StartTimeParameter"
}
],
"responses": {
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
},
"200": {
"description": "Successful request to get the list of metric namespaces",
"schema": {
"$ref": "#/definitions/MetricNamespaceCollection"
}
}
},
"x-ms-pageable": {
"nextLinkName": null
},
"x-ms-examples": {
"Get Metric Namespaces without filter": { "$ref": "./examples/GetMetricNamespaces.json" }
}
}
}
},
"definitions": {
"MetricNamespaceName": {
"properties": {
"metricNamespaceName": {
"type": "string",
"description": "The metric namespace name."
}
},
"description": "The fully qualified metric namespace name."
},
"MetricNamespace": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "The ID of the metricNamespace."
},
"type": {
"type": "string",
"description": "The type of the namespace."
},
"name": {
"type": "string",
"description": "The name of the namespace."
},
"properties": {
"$ref": "#/definitions/MetricNamespaceName",
"description": "Properties which include the fully qualified namespace name."
}
},
"description": "Metric namespace class specifies the metadata for a metric namespace."
},
"MetricNamespaceCollection": {
"properties": {
"value": {
"type": "array",
"items": {
"$ref": "#/definitions/MetricNamespace"
},
"description": "The values for the metric namespaces."
}
},
"required": ["value"],
"description": "Represents collection of metric namespaces."
},
"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
},
"StartTimeParameter": {
"name": "startTime",
"in": "query",
"required": false,
"type": "string",
"description": "The ISO 8601 conform Date start time from which to query for metric namespaces.",
"x-ms-parameter-location": "method"
}
}
}
30 changes: 29 additions & 1 deletion specification/monitor/resource-manager/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,37 @@ These are the global settings for the MonitorClient API.
title: MonitorClient
description: Monitor Management Client
openapi-type: arm
tag: package-2018-03

tag: package-2018-09

```
### Tag: package-2018-09

These settings apply only when `--tag=package-2018-09` is specified on the command line.

``` yaml $(tag) == 'package-2018-09'
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/2018-03-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
- microsoft.insights/stable/2018-03-01/metricAlert_API.json
- microsoft.insights/stable/2018-04-16/scheduledQueryRule_API.json
- microsoft.insights/preview/2017-12-01-preview/metricNamespaces_API.json
```

### Tag: package-2018-03

These settings apply only when `--tag=package-2018-03` is specified on the command line.
Expand Down