你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

Components - Get

返回 Application Insights 组件。

GET 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 版本。

响应

名称 类型 说明
200 OK

ApplicationInsightsComponent

Application Insights 组件定义。

安全性

azure_auth

Azure Active Directory OAuth2 Flow。

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

Scopes

名称 说明
user_impersonation 模拟用户帐户

示例

ComponentGet

Sample Request

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

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"
  }
}

定义

名称 说明
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。 此字段反映“名称”字段,无法更改。

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 时创建的唯一应用程序 ID,用于与 HockeyApp 通信。

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