次の方法で共有


Components - Create Or Update

Application Insights コンポーネントを作成 (または更新) します。 注: Put 操作で InstrumentationKey と AppId に別の値を指定することはできません。

PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/components/{resourceName}?api-version=2015-05-01

URI パラメーター

名前 / 必須 説明
resourceGroupName
path True

string

リソース グループの名前。 名前の大文字と小文字は区別されます。

resourceName
path True

string

Application Insights コンポーネント リソースの名前。

subscriptionId
path True

string

ターゲット サブスクリプションの ID。

api-version
query True

string

この操作に使用する API バージョン。

要求本文

名前 必須 説明
kind True

string

このコンポーネントが参照するアプリケーションの種類。UI のカスタマイズに使用されます。 この値はフリーフォーム文字列です。値は通常、web、ios、other、store、java、phone のいずれかである必要があります。

location True

string

リソースの場所

properties.Application_Type True

ApplicationType

監視対象のアプリケーションの種類。

properties.DisableIpMasking

boolean

IP マスクを無効にします。

properties.Flow_Type

FlowType

Application Insights システムによって、このコンポーネントが作成されたフローの種類を決定するために使用されます。 これは、REST API を使用してコンポーネントを作成または更新するときに、"Bluefield" に設定されます。

properties.HockeyAppId

string

HockeyApp との通信に使用される、新しいアプリケーションが HockeyApp に追加されたときに作成される一意のアプリケーション ID。

properties.ImmediatePurgeDataOn30Days

boolean

30 日後にデータを消去します。

properties.IngestionMode

IngestionMode

インジェストのフローを示します。

properties.Request_Source

RequestSource

この Application Insights コンポーネントを作成したツールについて説明します。 この API を使用しているお客様は、これを既定の 'rest' に設定する必要があります。

properties.RetentionInDays

integer

保有期間 (日数)。

properties.SamplingPercentage

number

Application Insights テレメトリ用にサンプリングされている、監視対象のアプリケーションによって生成されるデータの割合。

tags

object

リソース タグ

応答

名前 説明
200 OK

ApplicationInsightsComponent

Application Insights コンポーネントを作成または更新するときに要求が成功しました。 更新されたコンポーネントが返されます。

セキュリティ

azure_auth

Azure Active Directory OAuth2 フロー。

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

名前 説明
user_impersonation ユーザー アカウントの借用

ComponentCreate
ComponentUpdate

ComponentCreate

Sample Request

PUT https://management.azure.com/subscriptions/subid/resourceGroups/my-resource-group/providers/Microsoft.Insights/components/my-component?api-version=2015-05-01

{
  "location": "South Central US",
  "kind": "web",
  "properties": {
    "Application_Type": "web",
    "Flow_Type": "Bluefield",
    "Request_Source": "rest"
  }
}

Sample Response

{
  "id": "/subscriptions/subid/resourceGroups/my-resource-group/providers/Microsoft.Insights/components/my-component",
  "name": "my-component",
  "type": "Microsoft.Insights/components",
  "location": "South Central US",
  "tags": "",
  "kind": "web",
  "properties": {
    "ApplicationId": "my-component",
    "AppId": "887f4bfd-b5fd-40d7-9fc3-123456789abc",
    "Application_Type": "web",
    "Flow_Type": "Bluefield",
    "Request_Source": "rest",
    "InstrumentationKey": "bc095013-3cf2-45ac-ab47-123456789abc",
    "CreationDate": "2017-01-24T01:05:38.5934061+00:00",
    "TenantId": "f438d567-7177-4fe1-a5e3-123456789abc",
    "HockeyAppId": "",
    "HockeyAppToken": "",
    "provisioningState": "Succeeded",
    "SamplingPercentage": 100,
    "RetentionInDays": 90,
    "ConnectionString": "InstrumentationKey=bc095013-3cf2-45ac-ab47-123456789abc",
    "DisableIpMasking": false,
    "ImmediatePurgeDataOn30Days": false,
    "IngestionMode": "ApplicationInsights"
  }
}

ComponentUpdate

Sample Request

PUT https://management.azure.com/subscriptions/subid/resourceGroups/my-resource-group/providers/Microsoft.Insights/components/my-component?api-version=2015-05-01

{
  "location": "South Central US",
  "kind": "web",
  "tags": {
    "ApplicationGatewayType": "Internal-Only",
    "BillingEntity": "Self"
  }
}

Sample Response

{
  "id": "/subscriptions/subid/resourceGroups/my-resource-group/providers/Microsoft.Insights/components/my-component",
  "name": "my-component",
  "type": "Microsoft.Insights/components",
  "location": "South Central US",
  "tags": {
    "ApplicationGatewayType": "Internal-Only",
    "BillingEntity": "Self"
  },
  "kind": "web",
  "properties": {
    "ApplicationId": "my-component",
    "AppId": "887f4bfd-b5fd-40d7-9fc3-123456789abc",
    "Application_Type": "web",
    "Flow_Type": "Bluefield",
    "Request_Source": "rest",
    "InstrumentationKey": "bc095013-3cf2-45ac-ab47-123456789abc",
    "CreationDate": "2017-01-24T01:05:38.5934061+00:00",
    "TenantId": "f438d567-7177-4fe1-a5e3-123456789abc",
    "HockeyAppId": "",
    "HockeyAppToken": "",
    "provisioningState": "Succeeded",
    "SamplingPercentage": 100,
    "RetentionInDays": 90,
    "ConnectionString": "InstrumentationKey=bc095013-3cf2-45ac-ab47-123456789abc",
    "DisableIpMasking": false,
    "ImmediatePurgeDataOn30Days": false,
    "IngestionMode": "ApplicationInsights"
  }
}

定義

名前 説明
ApplicationInsightsComponent

Application Insights コンポーネント定義。

ApplicationType

監視対象のアプリケーションの種類。

FlowType

Application Insights システムによって、このコンポーネントが作成されたフローの種類を決定するために使用されます。 これは、REST API を使用してコンポーネントを作成または更新するときに、"Bluefield" に設定されます。

IngestionMode

インジェストのフローを示します。

PrivateLinkScopedResource

プライベート リンク スコープのリソース参照。

RequestSource

この Application Insights コンポーネントを作成したツールについて説明します。 この API を使用しているお客様は、これを既定の 'rest' に設定する必要があります。

ApplicationInsightsComponent

Application Insights コンポーネント定義。

名前 既定値 説明
id

string

Azure リソース ID

kind

string

このコンポーネントが参照するアプリケーションの種類。UI のカスタマイズに使用されます。 この値はフリーフォーム文字列です。値は通常、web、ios、other、store、java、phone のいずれかである必要があります。

location

string

リソースの場所

name

string

Azure リソース名

properties.AppId

string

Application Insights アプリケーションの一意の ID。

properties.ApplicationId

string

アプリケーションの一意の ID。 このフィールドは 'Name' フィールドを反映しており、変更できません。

properties.Application_Type

ApplicationType

web

監視対象のアプリケーションの種類。

properties.ConnectionString

string

Application Insights コンポーネントの接続文字列。

properties.CreationDate

string

Application Insights コンポーネントの作成日 (ISO 8601 形式)。

properties.DisableIpMasking

boolean

IP マスクを無効にします。

properties.Flow_Type

FlowType

Bluefield

Application Insights システムによって、このコンポーネントが作成されたフローの種類を決定するために使用されます。 これは、REST API を使用してコンポーネントを作成または更新するときに、"Bluefield" に設定されます。

properties.HockeyAppId

string

HockeyApp との通信に使用される、新しいアプリケーションが HockeyApp に追加されたときに作成される一意のアプリケーション ID。

properties.HockeyAppToken

string

Application Insights と HockeyApp の間の通信を認証するために使用されるトークン。

properties.ImmediatePurgeDataOn30Days

boolean

30 日後にデータを消去します。

properties.IngestionMode

IngestionMode

ApplicationInsights

インジェストのフローを示します。

properties.InstrumentationKey

string

Application Insights インストルメンテーション キー。 アプリケーションが Azure アプリケーション Insights に送信されるすべてのテレメトリの宛先を識別するために使用できる読み取り専用の値。 この値は、新しい Application Insights コンポーネントの構築時に指定されます。

properties.PrivateLinkScopedResources

PrivateLinkScopedResource[]

リンクされたプライベート リンク スコープ リソースの一覧。

properties.Request_Source

RequestSource

rest

この Application Insights コンポーネントを作成したツールについて説明します。 この API を使用しているお客様は、これを既定の 'rest' に設定する必要があります。

properties.RetentionInDays

integer

90

保有期間 (日数)。

properties.SamplingPercentage

number

Application Insights テレメトリ用にサンプリングされている、監視対象のアプリケーションによって生成されるデータの割合。

properties.TenantId

string

Azure テナント ID。

properties.provisioningState

string

このコンポーネントの現在の状態: が定義されているリソース グループ内にプロビジョニングされているかどうか。 ユーザーはこの値を変更できませんが、そこから読み取ることができます。 値には、Succeeded、Deploying、Canceled、Failed が含まれます。

tags

object

リソース タグ

type

string

Azure リソースタイプ

ApplicationType

監視対象のアプリケーションの種類。

名前 説明
other

string

web

string

FlowType

Application Insights システムによって、このコンポーネントが作成されたフローの種類を決定するために使用されます。 これは、REST API を使用してコンポーネントを作成または更新するときに、"Bluefield" に設定されます。

名前 説明
Bluefield

string

IngestionMode

インジェストのフローを示します。

名前 説明
ApplicationInsights

string

ApplicationInsightsWithDiagnosticSettings

string

LogAnalytics

string

PrivateLinkScopedResource

プライベート リンク スコープのリソース参照。

名前 説明
ResourceId

string

プライベート リンク スコープ リソースの完全なリソース ID。

ScopeId

string

プライベート リンク スコープの一意の識別子。

RequestSource

この Application Insights コンポーネントを作成したツールについて説明します。 この API を使用しているお客様は、これを既定の 'rest' に設定する必要があります。

名前 説明
rest

string