PluginBench
Skill
Official
Pass
Audit score 90

appinsights-instrumentation

microsoft/azure-skills

Instrument webapps with Azure Application Insights: SDK setup, telemetry patterns, and configuration references.

What is appinsights-instrumentation?

appinsights-instrumentation provides guidance and reference material for adding Azure Application Insights telemetry to web applications. It covers SDK setup, auto-instrumentation (for ASP.NET Core on Azure App Service), manual instrumentation via Bicep or Azure CLI, and platform-specific code patterns for ASP.NET Core, Node.js, and Python. It does not modify project files directly—use azure-prepare for that.

  • Guides SDK setup for Azure Application Insights across ASP.NET Core, Node.js, and Python
  • Recommends auto-instrumentation for C# ASP.NET Core apps hosted on Azure App Service
  • Provides Bicep template examples and Azure CLI scripts for creating App Insights resources
  • References OpenTelemetry Distro and Exporter SDKs for Python, TypeScript, and Java
  • Covers Container Apps observability patterns
  • Helps identify the correct instrumentation approach based on language, framework, and hosting environment

How to install appinsights-instrumentation

npx skills add https://github.com/microsoft/azure-skills --skill appinsights-instrumentation
Prerequisites
  • App must be an ASP.NET Core or Node.js app hosted in Azure (primary support)
  • Python apps are also supported for manual instrumentation
  • Knowledge of where the app is hosted (App Service, Container App, etc.)
  • Existing Azure subscription to create Application Insights resource
  • Bicep templates or Azure CLI access for resource provisioning
Claude Code
Cursor
Windsurf
Cline

How to use appinsights-instrumentation

  1. 1.Install the skill: npx skills add https://github.com/microsoft/azure-skills --skill appinsights-instrumentation
  2. 2.Ask the agent how to instrument your app or about App Insights SDK setup
  3. 3.Confirm your app's language, framework, and Azure hosting environment when prompted
  4. 4.Follow auto-instrumentation guidance if using C# ASP.NET Core on Azure App Service
  5. 5.For other stacks, use the Bicep example or Azure CLI script to create the App Insights resource
  6. 6.Apply the language-specific code changes from the ASP.NET Core, Node.js, or Python guides
  7. 7.Reference SDK quick-reference docs for OpenTelemetry Distro or Exporter as needed
  8. 8.Use azure-prepare instead if you want the agent to directly modify your project files

Use cases

Good for
  • Understanding how to instrument an ASP.NET Core app with Application Insights
  • Setting up manual telemetry for a Node.js app hosted in Azure
  • Creating an App Insights resource using Bicep or Azure CLI
  • Learning OpenTelemetry SDK options for Python or TypeScript apps
  • Getting observability guidance for Azure Container Apps
Who it's for
  • Developers building ASP.NET Core apps hosted on Azure
  • Node.js developers deploying to Azure App Service or Container Apps
  • Python developers integrating Azure Monitor telemetry
  • Teams evaluating APM options on Azure
  • Coding agents (e.g., azure-prepare) needing reference material during instrumentation

appinsights-instrumentation FAQ

Does this skill modify my project files?

No. It provides guidance and reference material only. To have the agent make actual changes to your project, use azure-prepare instead.

Which languages and frameworks are supported?

ASP.NET Core, Node.js, and Python are covered. ASP.NET Core on Azure App Service also supports auto-instrumentation.

Can I use this for apps not hosted on Azure?

The skill is scoped to apps hosted in Azure. Hosting environment (App Service, Container App, etc.) affects which instrumentation approach is recommended.

What SDK options are available?

The skill references the Azure Monitor OpenTelemetry Distro (Python, TypeScript) and OpenTelemetry Exporter (Python, Java).

When should I use azure-prepare instead of this skill?

Use azure-prepare when you want to add or modify App Insights components in your project. This skill is for learning and reference only.

Full instructions (SKILL.md)

Source of truth, from microsoft/azure-skills.


name: appinsights-instrumentation description: "Guidance for instrumenting webapps with Azure Application Insights. Provides telemetry patterns, SDK setup, and configuration references. WHEN: how to instrument app, App Insights SDK, telemetry patterns, what is App Insights, Application Insights guidance, instrumentation examples, APM best practices." license: MIT metadata: author: Microsoft version: "1.1.2"

AppInsights Instrumentation Guide

This skill provides guidance and reference material for instrumenting webapps with Azure Application Insights.

⛔ ADDING COMPONENTS?

If the user wants to add App Insights to their app, invoke azure-prepare instead. This skill provides reference material—azure-prepare orchestrates the actual changes.

When to Use This Skill

  • User asks how to instrument (guidance, patterns, examples)
  • User needs SDK setup instructions
  • azure-prepare invokes this skill during research phase
  • User wants to understand App Insights concepts

When to Use azure-prepare Instead

  • User says "add telemetry to my app"
  • User says "add App Insights"
  • User wants to modify their project
  • Any request to change/add components

Prerequisites

The app in the workspace must be one of these kinds

  • An ASP.NET Core app hosted in Azure
  • A Node.js app hosted in Azure

Guidelines

Collect context information

Find out the (programming language, application framework, hosting) tuple of the application the user is trying to add telemetry support in. This determines how the application can be instrumented. Read the source code to make an educated guess. Confirm with the user on anything you don't know. You must always ask the user where the application is hosted (e.g. on a personal computer, in an Azure App Service as code, in an Azure App Service as container, in an Azure Container App, etc.).

Prefer auto-instrument if possible

If the app is a C# ASP.NET Core app hosted in Azure App Service, use AUTO guide to help user auto-instrument the app.

Manually instrument

Manually instrument the app by creating the AppInsights resource and update the app's code.

Create AppInsights resource

Use one of the following options that fits the environment.

  • Add AppInsights to existing Bicep template. See examples/appinsights.bicep for what to add. This is the best option if there are existing Bicep template files in the workspace.
  • Use Azure CLI. See scripts/appinsights.ps1 for what Azure CLI command to execute to create the App Insights resource.

No matter which option you choose, recommend the user to create the App Insights resource in a meaningful resource group that makes managing resources easier. A good candidate will be the same resource group that contains the resources for the hosted app in Azure.

Modify application code

  • If the app is an ASP.NET Core app, see ASPNETCORE guide for how to modify the C# code.
  • If the app is a Node.js app, see NODEJS guide for how to modify the JavaScript/TypeScript code.
  • If the app is a Python app, see PYTHON guide for how to modify the Python code.

SDK Quick References

Platform-Specific Guides