Template example for creating an app service, document db and an application insights. A few properties are injected into the app insights as the instrumentation key and the document DB connection strings.
This template has been built targetting .net core, so the variable name is the same default one app insights for .net core is using. Also the AspNetCore environment variable is how you define what is your environment as Development, Staging or Production.