Azure Log Analytics
Azure Log Analytics API reference
COMMUNITYBEARER0 INSTALLS
OpenAPI Specificationv3.0
{
"swagger": "2.0",
"schemes": [
"https"
],
"host": "management.azure.com",
"info": {
"description": "Azure Log Analytics API reference",
"title": "Azure Log Analytics",
"version": "2019-08-01-preview",
"x-apisguru-categories": [
"cloud"
],
"x-logo": {
"url": "https://api.apis.guru/v2/cache/logo/https_assets.onestore.ms_cdnfiles_onestorerolling-1606-01000_shell_v3_images_logo_microsoft.png"
},
"x-origin": [
{
"format": "swagger",
"url": "https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/operationalinsights/resource-manager/Microsoft.OperationalInsights/preview/2019-08-01-preview/Clusters.json",
"version": "2.0"
}
],
"x-providerName": "azure.com",
"x-serviceName": "operationalinsights-Clusters",
"x-tags": [
"Azure",
"Microsoft"
]
},
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"securityDefinitions": {
"azure_auth": {
"authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
"description": "Azure Active Directory OAuth2 Flow",
"flow": "implicit",
"scopes": {
"user_impersonation": "impersonate your user account"
},
"type": "oauth2"
}
},
"security": [
{
"azure_auth": [
"user_impersonation"
]
}
],
"parameters": {
"ApiVersionParameter": {
"description": "Client Api Version.",
"in": "query",
"name": "api-version",
"required": true,
"type": "string"
},
"ResourceGroupNameParameter": {
"description": "The name of the resource group to get. The name is case insensitive.",
"in": "path",
"maxLength": 90,
"minLength": 1,
"name": "resourceGroupName",
"pattern": "^[-\\w\\._\\(\\)]+$",
"required": true,
"type": "string",
"x-ms-parameter-location": "method"
},
"SubscriptionIdParameter": {
"description": "Gets subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.",
"in": "path",
"name": "subscriptionId",
"required": true,
"type": "string"
}
},
"paths": {
"/subscriptions/{subscriptionId}/providers/Microsoft.OperationalInsights/clusters": {
"get": {
"description": "Gets the Log Analytics clusters in a subscription.",
"operationId": "Clusters_List",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"200": {
"description": "OK response definition.",
"schema": {
"$ref": "#/definitions/ClusterListResult"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"tags": [
"Clusters"
],
"x-ms-examples": {
"ClustersSubscriptionList": {
"parameters": {
"api-version": "2019-08-01-preview",
"subscriptionId": "00000000-0000-0000-0000-00000000000"
},
"responses": {
"200": {
"body": [
{
"id": "/subscriptions/594038b5-1093-476e-a366-482775671c11/resourcegroups/calbot-rg/providers/microsoft.operationalinsights/clusters/testresourcelock",
"identity": {
"principalId": "356d057d-cba5-44dd-8a30-b2e547bc416b",
"tenantId": "72f988bf-86f1-41af-91ab-2d7cd011db47",
"type": "SystemAssigned"
},
"location": "eastus",
"name": "TestResourceLock",
"properties": {
"clusterId": "5b02755b-5bf4-430c-9487-45502a2a7e62",
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429",
"provisioningState": "Succeeded"
},
"type": "Microsoft.OperationalInsights/clusters"
}
]
}
}
}
},
"x-ms-pageable": {
"nextLinkName": "nextLink"
}
}
},
"/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/clusters": {
"get": {
"description": "Gets Log Analytics clusters in a resource group.",
"operationId": "Clusters_ListByResourceGroup",
"parameters": [
{
"$ref": "#/parameters/ResourceGroupNameParameter"
},
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"200": {
"description": "OK response definition.",
"schema": {
"$ref": "#/definitions/ClusterListResult"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"tags": [
"Clusters"
],
"x-ms-examples": {
"ClustersGet": {
"parameters": {
"api-version": "2019-08-01-preview",
"resourceGroupName": "oiautorest6685",
"subscriptionId": "00000000-0000-0000-0000-00000000000"
},
"responses": {
"200": {
"body": [
{
"id": "/subscriptions/594038b5-1093-476e-a366-482775671c11/resourcegroups/calbot-rg/providers/microsoft.operationalinsights/clusters/testresourcelock",
"identity": {
"principalId": "356d057d-cba5-44dd-8a30-b2e547bc416b",
"tenantId": "72f988bf-86f1-41af-91ab-2d7cd011db47",
"type": "SystemAssigned"
},
"location": "eastus",
"name": "TestResourceLock",
"properties": {
"clusterId": "5b02755b-5bf4-430c-9487-45502a2a7e62",
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429",
"provisioningState": "Succeeded"
},
"type": "Microsoft.OperationalInsights/clusters"
}
]
}
}
}
},
"x-ms-pageable": {
"nextLinkName": "nextLink"
}
}
},
"/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/clusters/{clusterName}": {
"delete": {
"description": "Deletes a cluster instance.",
"operationId": "Clusters_Delete",
"parameters": [
{
"description": "The resource group name of the Log Analytics cluster.",
"in": "path",
"name": "resourceGroupName",
"required": true,
"type": "string"
},
{
"description": "Name of the Log Analytics Cluster.",
"in": "path",
"name": "clusterName",
"required": true,
"type": "string"
},
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"200": {
"description": "OK response definition."
},
"204": {
"description": "NoContent response definition."
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"tags": [
"Clusters"
],
"x-ms-examples": {
"ClustersDelete": {
"parameters": {
"api-version": "2019-08-01-preview",
"clusterName": "oiautorest6685",
"resourceGroupName": "oiautorest6685",
"subscriptionId": "00000000-0000-0000-0000-00000000000"
},
"responses": {
"200": {},
"204": {}
}
}
}
},
"get": {
"description": "Gets a Log Analytics cluster instance.",
"operationId": "Clusters_Get",
"parameters": [
{
"description": "The resource group name of the Log Analytics cluster.",
"in": "path",
"name": "resourceGroupName",
"required": true,
"type": "string"
},
{
"description": "Name of the Log Analytics Cluster.",
"in": "path",
"name": "clusterName",
"required": true,
"type": "string"
},
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"200": {
"description": "OK response definition.",
"schema": {
"$ref": "#/definitions/Cluster"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"tags": [
"Clusters"
],
"x-ms-examples": {
"ClustersGet": {
"parameters": {
"api-version": "2019-08-01-preview",
"clusterName": "oiautorest6685",
"resourceGroupName": "oiautorest6685",
"subscriptionId": "00000000-0000-0000-0000-00000000000"
},
"responses": {
"200": {
"body": [
{
"id": "/subscriptions/594038b5-1093-476e-a366-482775671c11/resourcegroups/calbot-rg/providers/microsoft.operationalinsights/clusters/testresourcelock",
"identity": {
"principalId": "356d057d-cba5-44dd-8a30-b2e547bc416b",
"tenantId": "72f988bf-86f1-41af-91ab-2d7cd011db47",
"type": "SystemAssigned"
},
"location": "eastus",
"name": "TestResourceLock",
"properties": {
"clusterId": "5b02755b-5bf4-430c-9487-45502a2a7e62",
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429",
"provisioningState": "Succeeded"
},
"type": "Microsoft.OperationalInsights/clusters"
},
{
"id": "/subscriptions/594038b5-1093-476e-a366-482775671c11/resourcegroups/mms-eus/providers/microsoft.operationalinsights/clusters/southukws",
"identity": {
"principalId": "356d057d-cba5-44dd-8a30-b2e547bc416b",
"tenantId": "72f988bf-86f1-41af-91ab-2d7cd011db47",
"type": "SystemAssigned"
},
"location": "East US",
"name": "SouthUKWS",
"properties": {
"clusterId": "5b02755b-5bf4-430c-9487-45502a2a7e62",
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429",
"provisioningState": "Succeeded"
},
"type": "Microsoft.OperationalInsights/clusters"
}
]
}
}
}
}
},
"patch": {
"description": "Updates a Log Analytics cluster.",
"operationId": "Clusters_Update",
"parameters": [
{
"description": "The resource group name of the cluster.",
"in": "path",
"name": "resourceGroupName",
"required": true,
"type": "string"
},
{
"description": "The name of the cluster.",
"in": "path",
"maxLength": 63,
"minLength": 4,
"name": "clusterName",
"pattern": "^[A-Za-z0-9][A-Za-z0-9-]+[A-Za-z0-9]$",
"required": true,
"type": "string"
},
{
"description": "The parameters required to patch a Log Analytics cluster.",
"in": "body",
"name": "parameters",
"required": true,
"schema": {
"$ref": "#/definitions/ClusterPatch"
}
},
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"200": {
"description": "The existing cluster was successfully updated. Check provisioningStatus to see detailed status.",
"schema": {
"$ref": "#/definitions/Cluster"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"tags": [
"Clusters"
],
"x-ms-examples": {
"ClustersPatch": {
"parameters": {
"api-version": "2019-08-01-preview",
"clusterName": "oiautorest6685",
"parameters": {
"properties": {
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429"
},
"tags": {
"tag1": "val1"
}
},
"resourceGroupName": "oiautorest6685",
"subscriptionId": "00000000-0000-0000-0000-00000000000"
},
"responses": {
"200": {
"body": {
"location": "australiasoutheast",
"properties": {
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429"
},
"tags": {
"tag1": "val1"
}
}
}
}
}
}
},
"put": {
"description": "Create or update a Log Analytics cluster.",
"operationId": "Clusters_CreateOrUpdate",
"parameters": [
{
"description": "The resource group name of the Log Analytics cluster.",
"in": "path",
"name": "resourceGroupName",
"required": true,
"type": "string"
},
{
"description": "The name of the Log Analytics cluster.",
"in": "path",
"maxLength": 63,
"minLength": 4,
"name": "clusterName",
"pattern": "^[A-Za-z0-9][A-Za-z0-9-]+[A-Za-z0-9]$",
"required": true,
"type": "string"
},
{
"description": "The parameters required to create or update a Log Analytics cluster.",
"in": "body",
"name": "parameters",
"required": true,
"schema": {
"$ref": "#/definitions/Cluster"
}
},
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"200": {
"description": "OK response definition.",
"schema": {
"$ref": "#/definitions/Cluster"
}
},
"201": {
"description": "Created response definition.",
"schema": {
"$ref": "#/definitions/Cluster"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"tags": [
"Clusters"
],
"x-ms-examples": {
"ClustersCreate": {
"parameters": {
"api-version": "2019-08-01-preview",
"clusterName": "oiautorest6685",
"parameters": {
"location": "australiasoutheast",
"properties": {
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429"
},
"tags": {
"tag1": "val1"
}
},
"resourceGroupName": "oiautorest6685",
"subscriptionId": "00000000-0000-0000-0000-00000000000"
},
"responses": {
"200": {
"body": {
"id": "/subscriptions/00000000-0000-0000-0000-000000000005/resourcegroups/oiautorest6685/providers/microsoft.operationalinsights/clusters/aztest2170",
"identity": {
"principalId": "356d057d-cba5-44dd-8a30-b2e547bc416b",
"tenantId": "72f988bf-86f1-41af-91ab-2d7cd011db47",
"type": "SystemAssigned"
},
"location": "australiasoutheast",
"name": "AzTest2170",
"properties": {
"clusterId": "bc089d7b-485c-4aff-a71e-c00f362d8d2f",
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429",
"provisioningState": "Creating"
},
"tags": {
"tag1": "val1"
},
"type": "Microsoft.OperationalInsights/clusters"
}
},
"201": {
"body": {
"id": "/subscriptions/00000000-0000-0000-0000-000000000005/resourcegroups/oiautorest6685/providers/microsoft.operationalinsights/clusters/aztest2170",
"identity": {
"principalId": "356d057d-cba5-44dd-8a30-b2e547bc416b",
"tenantId": "72f988bf-86f1-41af-91ab-2d7cd011db47",
"type": "SystemAssigned"
},
"location": "australiasoutheast",
"name": "AzTest2170",
"properties": {
"clusterId": "bc089d7b-485c-4aff-a71e-c00f362d8d2f",
"encryptionKeyUri": "https://aztest2170.vault.azure.net/certificates/aztest2170cert/654ft6c4e63845cbb50fd6fg51540429",
"provisioningState": "Creating"
},
"tags": {
"tag1": "val1"
},
"type": "Microsoft.OperationalInsights/clusters"
}
}
}
}
},
"x-ms-long-running-operation": true
}
}
},
"definitions": {
"Cluster": {
"allOf": [
{
"$ref": "#/definitions/Resource"
}
],
"description": "The top level Log Analytics cluster resource container.",
"properties": {
"identity": {
"$ref": "#/definitions/Identity",
"description": "The identity of the resource."
},
"properties": {
"$ref": "#/definitions/ClusterProperties",
"description": "Log Analytics cluster properties.",
"x-ms-client-flatten": true
}
},
"x-ms-azure-resource": true
},
"ClusterListResult": {
"description": "The list clusters operation response.",
"properties": {
"nextLink": {
"description": "The link used to get the next page of recommendations.",
"type": "string"
},
"value": {
"description": "A list of Log Analytics clusters.",
"items": {
"$ref": "#/definitions/Cluster"
},
"type": "array"
}
}
},
"ClusterPatch": {
"description": "The top level Log Analytics cluster resource container.",
"properties": {
"properties": {
"$ref": "#/definitions/ClusterPatchProperties",
"description": "Log Analytics cluster properties.",
"x-ms-client-flatten": true
},
"tags": {
"additionalProperties": {
"type": "string"
},
"description": "Resource tags",
"type": "object"
}
},
"x-ms-azure-resource": true
},
"ClusterPatchProperties": {
"description": "Log Analytics cluster patch properties.",
"properties": {
"encryptionKeyUri": {
"description": "The Key Vault key or certificate path associated with the Log Analytics cluster.",
"type": "string"
}
}
},
"ClusterProperties": {
"description": "Cluster properties.",
"properties": {
"clusterId": {
"description": "The ID associated with the cluster.",
"readOnly": true,
"type": "string"
},
"encryptionKeyUri": {
"description": "The Key Vault key or certificate path associated with the Log Analytics cluster.",
"type": "string"
},
"nextLink": {
"description": "The link used to get the next page of recommendations.",
"type": "string"
},
"provisioningState": {
"description": "The provisioning state of the cluster.",
"enum": [
"Creating",
"Succeeded",
"Failed",
"Canceled",
"Deleting",
"ProvisioningAccount"
],
"readOnly": true,
"type": "string",
"x-ms-enum": {
"modelAsString": true,
"name": "EntityStatus"
}
}
}
},
"ErrorDetails": {
"description": "The details of the error.",
"properties": {
"code": {
"description": "Error code.",
"readOnly": true,
"type": "string"
},
"message": {
"description": "Error message indicating why the operation failed.",
"readOnly": true,
"type": "string"
},
"target": {
"description": "The target of the particular error.",
"readOnly": true,
"type": "string"
}
}
},
"ErrorResponse": {
"description": "Error response indicates that the service is not able to process the incoming request. The reason is provided in the error message.",
"properties": {
"error": {
"$ref": "#/definitions/ErrorDetails",
"description": "The details of the error."
}
},
"type": "object"
},
"Identity": {
"description": "Identity for the resource.",
"properties": {
"principalId": {
"description": "The principal ID of resource identity.",
"readOnly": true,
"type": "string"
},
"tenantId": {
"description": "The tenant ID of resource.",
"readOnly": true,
"type": "string"
},
"type": {
"description": "The identity type.",
"enum": [
"SystemAssigned",
"None"
],
"type": "string",
"x-ms-enum": {
"modelAsString": false,
"name": "IdentityType"
}
}
},
"required": [
"type"
]
},
"Resource": {
"description": "The resource definition.",
"properties": {
"id": {
"description": "Resource Id",
"readOnly": true,
"type": "string"
},
"location": {
"description": "Resource location",
"type": "string"
},
"name": {
"description": "Resource name",
"readOnly": true,
"type": "string"
},
"tags": {
"additionalProperties": {
"type": "string"
},
"description": "Resource tags",
"type": "object"
},
"type": {
"description": "Resource type",
"readOnly": true,
"type": "string"
}
},
"x-ms-azure-resource": true
}
}
}