Condividi tramite


ApplicationInsightsComponentResource.PutAnalyticsItem Method

Definition

Adds or Updates a specific Analytics Item within an Application Insights component.

  • Request Path: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/microsoft.insights/components/{resourceName}/{scopePath}/item
  • Operation Id: AnalyticsItems_Put
  • Default Api Version: 2015-05-01
public virtual Azure.Response<Azure.ResourceManager.ApplicationInsights.Models.ApplicationInsightsComponentAnalyticsItem> PutAnalyticsItem (Azure.ResourceManager.ApplicationInsights.Models.ItemScopePath scopePath, Azure.ResourceManager.ApplicationInsights.Models.ApplicationInsightsComponentAnalyticsItem itemProperties, bool? overrideItem = default, System.Threading.CancellationToken cancellationToken = default);
abstract member PutAnalyticsItem : Azure.ResourceManager.ApplicationInsights.Models.ItemScopePath * Azure.ResourceManager.ApplicationInsights.Models.ApplicationInsightsComponentAnalyticsItem * Nullable<bool> * System.Threading.CancellationToken -> Azure.Response<Azure.ResourceManager.ApplicationInsights.Models.ApplicationInsightsComponentAnalyticsItem>
override this.PutAnalyticsItem : Azure.ResourceManager.ApplicationInsights.Models.ItemScopePath * Azure.ResourceManager.ApplicationInsights.Models.ApplicationInsightsComponentAnalyticsItem * Nullable<bool> * System.Threading.CancellationToken -> Azure.Response<Azure.ResourceManager.ApplicationInsights.Models.ApplicationInsightsComponentAnalyticsItem>
Public Overridable Function PutAnalyticsItem (scopePath As ItemScopePath, itemProperties As ApplicationInsightsComponentAnalyticsItem, Optional overrideItem As Nullable(Of Boolean) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Response(Of ApplicationInsightsComponentAnalyticsItem)

Parameters

scopePath
ItemScopePath

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.

itemProperties
ApplicationInsightsComponentAnalyticsItem

Properties that need to be specified to create a new item and add it to an Application Insights component.

overrideItem
Nullable<Boolean>

Flag indicating whether or not to force save an item. This allows overriding an item if it already exists.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

itemProperties is null.

Applies to