To enable Application Insights during local debugging, we need to install the Application Insights NuGet library in the TextEvaluation project, and add the same instrumentation key to the local configuration. To do so, execute the following steps:
- In Visual Studio, open the TextEvaluation project.
- Click on Tools -> NuGet Package Manager -> Package Manager Console.
- Run the following command:
Install-Package Microsoft.ApplicationInsights -Pre
- In the local.settings.json file, add the following new setting:
"APPINSIGHTS_INSTRUMENTATIONKEY": "<YourInstrumentationKey>"
- Now when you run the Function App locally in Visual Studio, your development machine will appear in the server list in Application Insights ...