{ "swagger": "2.0", "info": { "title": "ApplicationInsightsManagementClient", "description": "Azure Application Insights client for saved items.", "version": "2015-05-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": { "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/microsoft.insights/components/{resourceName}/{scopePath}": { "get": { "description": "Gets a list of Analytics Items defined within an Application Insights component.", "operationId": "AnalyticsItems_List", "parameters": [ { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "#/parameters/ResourceNameParameter" }, { "$ref": "#/parameters/ItemScopePathParameter" }, { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/ItemScopeParameter" }, { "$ref": "#/parameters/ItemTypeParameter" }, { "$ref": "#/parameters/IncludeContentParameter" } ], "responses": { "200": { "description": "A list containing 0 or more items associated with the Application Insights component.", "schema": { "type": "array", "items": { "$ref": "#/definitions/ApplicationInsightsComponentAnalyticsItem" } } } }, "x-ms-examples": { "AnalyticsItemList": { "$ref": "./examples/AnalyticsItemList.json" } } } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/microsoft.insights/components/{resourceName}/{scopePath}/item": { "get": { "description": "Gets a specific Analytics Items defined within an Application Insights component.", "operationId": "AnalyticsItems_Get", "parameters": [ { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "#/parameters/ResourceNameParameter" }, { "$ref": "#/parameters/ItemScopePathParameter" }, { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/ItemIdParameter" }, { "$ref": "#/parameters/ItemNameParameter" } ], "responses": { "200": { "description": "A single item associated with the Application Insights component.", "schema": { "$ref": "#/definitions/ApplicationInsightsComponentAnalyticsItem" } } }, "x-ms-examples": { "AnalyticsItemGet": { "$ref": "./examples/AnalyticsItemGet.json" } } }, "put": { "description": "Adds or Updates a specific Analytics Item within an Application Insights component.", "operationId": "AnalyticsItems_Put", "parameters": [ { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "#/parameters/ResourceNameParameter" }, { "$ref": "#/parameters/ItemScopePathParameter" }, { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/OverrideItemParameter" }, { "name": "itemProperties", "description": "Properties that need to be specified to create a new item and add it to an Application Insights component.", "in": "body", "required": true, "schema": { "$ref": "#/definitions/ApplicationInsightsComponentAnalyticsItem" } } ], "responses": { "200": { "description": "The new or updated item associated with the Application Insights component.", "schema": { "$ref": "#/definitions/ApplicationInsightsComponentAnalyticsItem" } } }, "x-ms-examples": { "AnalyticsItemPut": { "$ref": "./examples/AnalyticsItemPut.json" } } }, "delete": { "description": "Deletes a specific Analytics Items defined within an Application Insights component.", "operationId": "AnalyticsItems_Delete", "parameters": [ { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/ResourceGroupNameParameter" }, { "$ref": "#/parameters/ResourceNameParameter" }, { "$ref": "#/parameters/ItemScopePathParameter" }, { "$ref": "../../../../../common-types/resource-management/v1/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/ItemIdParameter" }, { "$ref": "#/parameters/ItemNameParameter" } ], "responses": { "200": { "description": "The item has been successfully removed from the Application Insights component" } }, "x-ms-examples": { "AnalyticsItemDelete": { "$ref": "./examples/AnalyticsItemDelete.json" } } } } }, "definitions": { "ApplicationInsightsComponentAnalyticsItem": { "description": "Properties that define an Analytics item that is associated to an Application Insights component.", "type": "object", "properties": { "Id": { "type": "string", "description": "Internally assigned unique id of the item definition." }, "Name": { "type": "string", "description": "The user-defined name of the item." }, "Content": { "type": "string", "description": "The content of this item" }, "Version": { "type": "string", "description": "This instance's version of the data model. This can change as new features are added.", "readOnly": true }, "Scope": { "description": "Enum indicating if this item definition is owned by a specific user or is shared between all users with access to the Application Insights component.", "type": "string", "enum": [ "shared", "user" ], "x-ms-enum": { "name": "ItemScope", "modelAsString": true } }, "Type": { "description": "Enum indicating the type of the Analytics item.", "type": "string", "enum": [ "none", "query", "recent", "function" ], "x-ms-enum": { "name": "ItemType", "modelAsString": true } }, "TimeCreated": { "type": "string", "description": "Date and time in UTC when this item was created.", "readOnly": true }, "TimeModified": { "type": "string", "description": "Date and time in UTC of the last modification that was made to this item.", "readOnly": true }, "Properties": { "$ref": "#/definitions/ApplicationInsightsComponentAnalyticsItemProperties" } } }, "ApplicationInsightsComponentAnalyticsItemProperties": { "type": "object", "properties": { "functionAlias": { "type": "string", "description": "A function alias, used when the type of the item is Function" } }, "description": "A set of properties that can be defined in the context of a specific item type. Each type may have its own properties." } }, "parameters": { "ResourceNameParameter": { "name": "resourceName", "in": "path", "required": true, "type": "string", "description": "The name of the Application Insights component resource.", "x-ms-parameter-location": "method" }, "ItemScopePathParameter": { "name": "scopePath", "in": "path", "required": true, "type": "string", "enum": [ "analyticsItems", "myanalyticsItems" ], "x-ms-enum": { "name": "ItemScopePath", "modelAsString": true }, "description": "Enum indicating if this item definition is owned by a specific user or is shared between all users with access to the Application Insights component.", "x-ms-parameter-location": "method" }, "ItemScopeParameter": { "name": "scope", "in": "query", "required": false, "type": "string", "default": "shared", "enum": [ "shared", "user" ], "x-ms-enum": { "name": "ItemScope", "modelAsString": true }, "description": "Enum indicating if this item definition is owned by a specific user or is shared between all users with access to the Application Insights component.", "x-ms-parameter-location": "method" }, "ItemTypeParameter": { "name": "type", "in": "query", "required": false, "type": "string", "default": "none", "enum": [ "none", "query", "function", "folder", "recent" ], "x-ms-enum": { "name": "ItemTypeParameter", "modelAsString": true }, "description": "Enum indicating the type of the Analytics item.", "x-ms-parameter-location": "method" }, "ItemIdParameter": { "name": "id", "in": "query", "required": false, "type": "string", "description": "The Id of a specific item defined in the Application Insights component", "x-ms-parameter-location": "method" }, "ItemNameParameter": { "name": "name", "in": "query", "required": false, "type": "string", "description": "The name of a specific item defined in the Application Insights component", "x-ms-parameter-location": "method" }, "IncludeContentParameter": { "name": "includeContent", "in": "query", "required": false, "type": "boolean", "description": "Flag indicating whether or not to return the content of each applicable item. If false, only return the item information.", "x-ms-parameter-location": "method" }, "OverrideItemParameter": { "name": "overrideItem", "in": "query", "required": false, "type": "boolean", "description": "Flag indicating whether or not to force save an item. This allows overriding an item if it already exists.", "x-ms-parameter-location": "method" } } }