components
Creates, updates, deletes, gets or lists a components resource.
Overview
| Name | components |
| Type | Resource |
| Id | azure.application_insights.components |
Fields
The following fields are returned by SELECT queries:
- get_purge_status
- get
- list_by_resource_group
- list
| Name | Datatype | Description |
|---|---|---|
status | string | Status of the operation represented by the requested Id. Required. Known values are: "pending" and "completed". (pending, completed) |
| Name | Datatype | Description |
|---|---|---|
id | string | Azure resource Id. |
name | string | Azure resource name. |
AppId | string | Application Insights Unique ID for your Application. |
ApplicationId | string | The unique ID of your application. This field mirrors the 'Name' field and cannot be changed. |
Application_Type | string | Type of application being monitored. Required. Known values are: "web" and "other". (web, other) |
ConnectionString | string | Application Insights component connection string. |
CreationDate | string (date-time) | Creation Date for the Application Insights component, in ISO 8601 format. |
DisableIpMasking | boolean | Disable IP masking. |
DisableLocalAuth | boolean | Disable Non-AAD based Auth. |
Flow_Type | string | Used by the Application Insights system to determine what kind of flow this component was created by. This is to be set to 'Bluefield' when creating/updating a component via the REST API. "Bluefield" (Bluefield) |
ForceCustomerStorageForProfiler | boolean | Force users to create their own storage account for profiler and debugger. |
HockeyAppId | string | The unique application ID created when a new application is added to HockeyApp, used for communications with HockeyApp. |
HockeyAppToken | string | Token used to authenticate communications with between Application Insights and HockeyApp. |
ImmediatePurgeDataOn30Days | boolean | Purge data immediately after 30 days. |
IngestionMode | string | Indicates the flow of the ingestion. Known values are: "ApplicationInsights", "ApplicationInsightsWithDiagnosticSettings", and "LogAnalytics". (ApplicationInsights, ApplicationInsightsWithDiagnosticSettings, LogAnalytics) |
InstrumentationKey | string | Application Insights Instrumentation key. A read-only value that applications can use to identify the destination for all telemetry sent to Azure Application Insights. This value will be supplied upon construction of each new Application Insights component. |
LaMigrationDate | string (date-time) | The date which the component got migrated to LA, in ISO 8601 format. |
Name | string | Application name. |
PrivateLinkScopedResources | array | List of linked private link scope resources. |
Request_Source | string | Describes what tool created this Application Insights component. Customers using this API should set this to the default 'rest'. "rest" (rest) |
RetentionInDays | integer | Retention period in days. |
SamplingPercentage | number | Percentage of the data produced by the application being monitored that is being sampled for Application Insights telemetry. |
TenantId | string | Azure Tenant Id. |
WorkspaceResourceId | string | Resource Id of the log analytics workspace which the data will be ingested to. This property is required to create an application with this API version. Applications from older versions will not have this property. |
etag | string | Resource etag. |
kind | string | The kind of application that this component refers to, used to customize UI. This value is a freeform string, values should typically be one of the following: web, ios, other, store, java, phone. Required. |
location | string | Resource location. Required. |
provisioningState | string | Current state of this component: whether or not is has been provisioned within the resource group it is defined. Users cannot change this value but are able to read from it. Values will include Succeeded, Deploying, Canceled, and Failed. |
publicNetworkAccessForIngestion | string | The network access type for accessing Application Insights ingestion. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
publicNetworkAccessForQuery | string | The network access type for accessing Application Insights query. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
tags | object | Resource tags. |
type | string | Azure resource type. |
| Name | Datatype | Description |
|---|---|---|
id | string | Azure resource Id. |
name | string | Azure resource name. |
AppId | string | Application Insights Unique ID for your Application. |
ApplicationId | string | The unique ID of your application. This field mirrors the 'Name' field and cannot be changed. |
Application_Type | string | Type of application being monitored. Required. Known values are: "web" and "other". (web, other) |
ConnectionString | string | Application Insights component connection string. |
CreationDate | string (date-time) | Creation Date for the Application Insights component, in ISO 8601 format. |
DisableIpMasking | boolean | Disable IP masking. |
DisableLocalAuth | boolean | Disable Non-AAD based Auth. |
Flow_Type | string | Used by the Application Insights system to determine what kind of flow this component was created by. This is to be set to 'Bluefield' when creating/updating a component via the REST API. "Bluefield" (Bluefield) |
ForceCustomerStorageForProfiler | boolean | Force users to create their own storage account for profiler and debugger. |
HockeyAppId | string | The unique application ID created when a new application is added to HockeyApp, used for communications with HockeyApp. |
HockeyAppToken | string | Token used to authenticate communications with between Application Insights and HockeyApp. |
ImmediatePurgeDataOn30Days | boolean | Purge data immediately after 30 days. |
IngestionMode | string | Indicates the flow of the ingestion. Known values are: "ApplicationInsights", "ApplicationInsightsWithDiagnosticSettings", and "LogAnalytics". (ApplicationInsights, ApplicationInsightsWithDiagnosticSettings, LogAnalytics) |
InstrumentationKey | string | Application Insights Instrumentation key. A read-only value that applications can use to identify the destination for all telemetry sent to Azure Application Insights. This value will be supplied upon construction of each new Application Insights component. |
LaMigrationDate | string (date-time) | The date which the component got migrated to LA, in ISO 8601 format. |
Name | string | Application name. |
PrivateLinkScopedResources | array | List of linked private link scope resources. |
Request_Source | string | Describes what tool created this Application Insights component. Customers using this API should set this to the default 'rest'. "rest" (rest) |
RetentionInDays | integer | Retention period in days. |
SamplingPercentage | number | Percentage of the data produced by the application being monitored that is being sampled for Application Insights telemetry. |
TenantId | string | Azure Tenant Id. |
WorkspaceResourceId | string | Resource Id of the log analytics workspace which the data will be ingested to. This property is required to create an application with this API version. Applications from older versions will not have this property. |
etag | string | Resource etag. |
kind | string | The kind of application that this component refers to, used to customize UI. This value is a freeform string, values should typically be one of the following: web, ios, other, store, java, phone. Required. |
location | string | Resource location. Required. |
provisioningState | string | Current state of this component: whether or not is has been provisioned within the resource group it is defined. Users cannot change this value but are able to read from it. Values will include Succeeded, Deploying, Canceled, and Failed. |
publicNetworkAccessForIngestion | string | The network access type for accessing Application Insights ingestion. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
publicNetworkAccessForQuery | string | The network access type for accessing Application Insights query. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
tags | object | Resource tags. |
type | string | Azure resource type. |
| Name | Datatype | Description |
|---|---|---|
id | string | Azure resource Id. |
name | string | Azure resource name. |
AppId | string | Application Insights Unique ID for your Application. |
ApplicationId | string | The unique ID of your application. This field mirrors the 'Name' field and cannot be changed. |
Application_Type | string | Type of application being monitored. Required. Known values are: "web" and "other". (web, other) |
ConnectionString | string | Application Insights component connection string. |
CreationDate | string (date-time) | Creation Date for the Application Insights component, in ISO 8601 format. |
DisableIpMasking | boolean | Disable IP masking. |
DisableLocalAuth | boolean | Disable Non-AAD based Auth. |
Flow_Type | string | Used by the Application Insights system to determine what kind of flow this component was created by. This is to be set to 'Bluefield' when creating/updating a component via the REST API. "Bluefield" (Bluefield) |
ForceCustomerStorageForProfiler | boolean | Force users to create their own storage account for profiler and debugger. |
HockeyAppId | string | The unique application ID created when a new application is added to HockeyApp, used for communications with HockeyApp. |
HockeyAppToken | string | Token used to authenticate communications with between Application Insights and HockeyApp. |
ImmediatePurgeDataOn30Days | boolean | Purge data immediately after 30 days. |
IngestionMode | string | Indicates the flow of the ingestion. Known values are: "ApplicationInsights", "ApplicationInsightsWithDiagnosticSettings", and "LogAnalytics". (ApplicationInsights, ApplicationInsightsWithDiagnosticSettings, LogAnalytics) |
InstrumentationKey | string | Application Insights Instrumentation key. A read-only value that applications can use to identify the destination for all telemetry sent to Azure Application Insights. This value will be supplied upon construction of each new Application Insights component. |
LaMigrationDate | string (date-time) | The date which the component got migrated to LA, in ISO 8601 format. |
Name | string | Application name. |
PrivateLinkScopedResources | array | List of linked private link scope resources. |
Request_Source | string | Describes what tool created this Application Insights component. Customers using this API should set this to the default 'rest'. "rest" (rest) |
RetentionInDays | integer | Retention period in days. |
SamplingPercentage | number | Percentage of the data produced by the application being monitored that is being sampled for Application Insights telemetry. |
TenantId | string | Azure Tenant Id. |
WorkspaceResourceId | string | Resource Id of the log analytics workspace which the data will be ingested to. This property is required to create an application with this API version. Applications from older versions will not have this property. |
etag | string | Resource etag. |
kind | string | The kind of application that this component refers to, used to customize UI. This value is a freeform string, values should typically be one of the following: web, ios, other, store, java, phone. Required. |
location | string | Resource location. Required. |
provisioningState | string | Current state of this component: whether or not is has been provisioned within the resource group it is defined. Users cannot change this value but are able to read from it. Values will include Succeeded, Deploying, Canceled, and Failed. |
publicNetworkAccessForIngestion | string | The network access type for accessing Application Insights ingestion. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
publicNetworkAccessForQuery | string | The network access type for accessing Application Insights query. Known values are: "Enabled" and "Disabled". (Enabled, Disabled) |
tags | object | Resource tags. |
type | string | Azure resource type. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_purge_status | select | resource_group_name, resource_name, purge_id, subscription_id | Get status for an ongoing purge operation. | |
get | select | resource_group_name, resource_name, subscription_id | Returns an Application Insights component. | |
list_by_resource_group | select | resource_group_name, subscription_id | Gets a list of Application Insights components within a resource group. | |
list | select | subscription_id | Gets a list of all Application Insights components within a subscription. | |
create_or_update | insert | resource_group_name, resource_name, subscription_id, location, kind | Creates (or updates) an Application Insights component. Note: You cannot specify a different value for InstrumentationKey nor AppId in the Put operation. | |
update_tags | update | resource_group_name, resource_name, subscription_id | Updates an existing component's tags. To update other fields use the CreateOrUpdate method. | |
create_or_update | replace | resource_group_name, resource_name, subscription_id, location, kind | Creates (or updates) an Application Insights component. Note: You cannot specify a different value for InstrumentationKey nor AppId in the Put operation. | |
purge | delete | resource_group_name, resource_name, subscription_id | Purges data in an Application Insights component by a set of user-defined filters. In order to manage system resources, purge requests are throttled at 50 requests per hour. You should batch the execution of purge requests by sending a single command whose predicate includes all user identities that require purging. Use the in operator to specify multiple identities. You should run the query prior to using for a purge request to verify that the results are expected. Note: this operation is intended for Classic resources, for workspace-based Application Insights resource please run purge operation (directly on the workspace)(https://docs.microsoft.com/en-us/rest/api/loganalytics/workspace-purge/purge _) , scoped to specific resource id. | |
delete | delete | resource_group_name, resource_name, subscription_id | Deletes an Application Insights component. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
purge_id | string | In a purge status request, this is the Id of the operation the status of which is returned. Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
resource_name | string | The name of the Application Insights component resource. Required. |
subscription_id | string |
SELECT examples
- get_purge_status
- get
- list_by_resource_group
- list
Get status for an ongoing purge operation.
SELECT
status
FROM azure.application_insights.components
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND resource_name = '{{ resource_name }}' -- required
AND purge_id = '{{ purge_id }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Returns an Application Insights component.
SELECT
id,
name,
AppId,
ApplicationId,
Application_Type,
ConnectionString,
CreationDate,
DisableIpMasking,
DisableLocalAuth,
Flow_Type,
ForceCustomerStorageForProfiler,
HockeyAppId,
HockeyAppToken,
ImmediatePurgeDataOn30Days,
IngestionMode,
InstrumentationKey,
LaMigrationDate,
Name,
PrivateLinkScopedResources,
Request_Source,
RetentionInDays,
SamplingPercentage,
TenantId,
WorkspaceResourceId,
etag,
kind,
location,
provisioningState,
publicNetworkAccessForIngestion,
publicNetworkAccessForQuery,
tags,
type
FROM azure.application_insights.components
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND resource_name = '{{ resource_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Gets a list of Application Insights components within a resource group.
SELECT
id,
name,
AppId,
ApplicationId,
Application_Type,
ConnectionString,
CreationDate,
DisableIpMasking,
DisableLocalAuth,
Flow_Type,
ForceCustomerStorageForProfiler,
HockeyAppId,
HockeyAppToken,
ImmediatePurgeDataOn30Days,
IngestionMode,
InstrumentationKey,
LaMigrationDate,
Name,
PrivateLinkScopedResources,
Request_Source,
RetentionInDays,
SamplingPercentage,
TenantId,
WorkspaceResourceId,
etag,
kind,
location,
provisioningState,
publicNetworkAccessForIngestion,
publicNetworkAccessForQuery,
tags,
type
FROM azure.application_insights.components
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Gets a list of all Application Insights components within a subscription.
SELECT
id,
name,
AppId,
ApplicationId,
Application_Type,
ConnectionString,
CreationDate,
DisableIpMasking,
DisableLocalAuth,
Flow_Type,
ForceCustomerStorageForProfiler,
HockeyAppId,
HockeyAppToken,
ImmediatePurgeDataOn30Days,
IngestionMode,
InstrumentationKey,
LaMigrationDate,
Name,
PrivateLinkScopedResources,
Request_Source,
RetentionInDays,
SamplingPercentage,
TenantId,
WorkspaceResourceId,
etag,
kind,
location,
provisioningState,
publicNetworkAccessForIngestion,
publicNetworkAccessForQuery,
tags,
type
FROM azure.application_insights.components
WHERE subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create_or_update
- Manifest
Creates (or updates) an Application Insights component. Note: You cannot specify a different value for InstrumentationKey nor AppId in the Put operation.
INSERT INTO azure.application_insights.components (
location,
tags,
kind,
etag,
properties,
resource_group_name,
resource_name,
subscription_id
)
SELECT
'{{ location }}' /* required */,
'{{ tags }}',
'{{ kind }}' /* required */,
'{{ etag }}',
'{{ properties }}',
'{{ resource_group_name }}',
'{{ resource_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
etag,
kind,
location,
properties,
tags,
type
;
# Description fields are for documentation purposes
- name: components
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the components resource.
- name: resource_name
value: "{{ resource_name }}"
description: Required parameter for the components resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the components resource.
- name: location
value: "{{ location }}"
description: |
Resource location. Required.
- name: tags
value: "{{ tags }}"
description: |
Resource tags.
- name: kind
value: "{{ kind }}"
description: |
The kind of application that this component refers to, used to customize UI. This value is a freeform string, values should typically be one of the following: web, ios, other, store, java, phone. Required.
- name: etag
value: "{{ etag }}"
description: |
Resource etag.
- name: properties
description: |
Properties that define an Application Insights component resource.
value:
ApplicationId: "{{ ApplicationId }}"
AppId: "{{ AppId }}"
Name: "{{ Name }}"
Application_Type: "{{ Application_Type }}"
Flow_Type: "{{ Flow_Type }}"
Request_Source: "{{ Request_Source }}"
InstrumentationKey: "{{ InstrumentationKey }}"
CreationDate: "{{ CreationDate }}"
TenantId: "{{ TenantId }}"
HockeyAppId: "{{ HockeyAppId }}"
HockeyAppToken: "{{ HockeyAppToken }}"
provisioningState: "{{ provisioningState }}"
SamplingPercentage: {{ SamplingPercentage }}
ConnectionString: "{{ ConnectionString }}"
RetentionInDays: {{ RetentionInDays }}
DisableIpMasking: {{ DisableIpMasking }}
ImmediatePurgeDataOn30Days: {{ ImmediatePurgeDataOn30Days }}
WorkspaceResourceId: "{{ WorkspaceResourceId }}"
LaMigrationDate: "{{ LaMigrationDate }}"
PrivateLinkScopedResources:
- ResourceId: "{{ ResourceId }}"
ScopeId: "{{ ScopeId }}"
publicNetworkAccessForIngestion: "{{ publicNetworkAccessForIngestion }}"
publicNetworkAccessForQuery: "{{ publicNetworkAccessForQuery }}"
IngestionMode: "{{ IngestionMode }}"
DisableLocalAuth: {{ DisableLocalAuth }}
ForceCustomerStorageForProfiler: {{ ForceCustomerStorageForProfiler }}
UPDATE examples
- update_tags
Updates an existing component's tags. To update other fields use the CreateOrUpdate method.
UPDATE azure.application_insights.components
SET
tags = '{{ tags }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND resource_name = '{{ resource_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
etag,
kind,
location,
properties,
tags,
type;
REPLACE examples
- create_or_update
Creates (or updates) an Application Insights component. Note: You cannot specify a different value for InstrumentationKey nor AppId in the Put operation.
REPLACE azure.application_insights.components
SET
location = '{{ location }}',
tags = '{{ tags }}',
kind = '{{ kind }}',
etag = '{{ etag }}',
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND resource_name = '{{ resource_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
AND kind = '{{ kind }}' --required
RETURNING
id,
name,
etag,
kind,
location,
properties,
tags,
type;
DELETE examples
- purge
- delete
Purges data in an Application Insights component by a set of user-defined filters. In order to manage system resources, purge requests are throttled at 50 requests per hour. You should batch the execution of purge requests by sending a single command whose predicate includes all user identities that require purging. Use the in operator to specify multiple identities. You should run the query prior to using for a purge request to verify that the results are expected. Note: this operation is intended for Classic resources, for workspace-based Application Insights resource please run purge operation (directly on the workspace)(https://docs.microsoft.com/en-us/rest/api/loganalytics/workspace-purge/purge _) , scoped to specific resource id.
DELETE FROM azure.application_insights.components
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND resource_name = '{{ resource_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;
Deletes an Application Insights component.
DELETE FROM azure.application_insights.components
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND resource_name = '{{ resource_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;