Microsoft Azure App Service API poller template
Use this SAM API poller template to monitor Microsoft Azure App Services performance and statistics counters, including connection and request (2xx, 3xx, 4xx, 5xx) statistics for a specific Azure app.
Prerequisites
- Provide values for the following parameters:
- ${SUBSCRIPTION_ID}: Your Azure subscription ID. For example,
6a4208fe-5200-417e-9365-99781c6133c3
- ${USERGROUP_ID}: A resource group ID
- ${APP_NAME}: The App Service name
- Configure OAuth 2.0 Azure credentials with the following scope:
https://management.azure.com/.default
For credential tips, see API poller authorization and also Find Microsoft Azure credentials.
Notes
- Default thresholds are not set for this template.
- For reference, see Supported metrics with Azure Monitor (© 2020 Microsoft Corp., available at docs.microsoft.com, obtained on November 10, 2020).
- Here is an API request example:
https://management.azure.com/subscriptions/${SUBSCRIPTION_ID}/resourceGroups/${USERGROUP_ID}/providers/Microsoft.Web/sites/${APP_NAME}/providers/microsoft.insights/metrics?interval=PT1H&metricnames=BytesSent,Http2xx,Http3xx,Http401,Http403,Http404,Http406,Http4xx,Http5xx,Requests,BytesReceived,AverageMemoryWorkingSet,AverageResponseTime&aggregation=Average,Total&api-version=2018-01-01
Available metrics
Average number of bytes sent
The average number of bytes sent for the given app.
Unit: Bytes
Total number of 2xx requests
The number of requests resulting in an HTTP status code >= 200 but < 300 for the app.
Unit: Count
Total number of 3xx requests
The number of requests resulting in an HTTP status code >= 300 but < 400 for the app.
Unit: Count
Total number of 401 requests
The number of requests resulting in HTTP 401 status code for the app.
Unit: Count
Total number of 403 requests
The number of requests resulting in HTTP 403 status code for the app.
Unit: Count
Total number of 404 requests
The number of requests resulting in HTTP 404 status code for the app.
Unit: Count
Total number of 406 requests
The number of requests resulting in HTTP 406 status code for the app.
Unit: Count
Total number of 4xx requests
The number of requests resulting in an HTTP status code >= 400 but < 500 for the app.
Unit: Count
Total number of 5xx requests
The number of requests resulting in an HTTP status code >= 500 but < 600 for the app.
Unit: Count
Total number of requests served by the app
The number of all requests, regardless of the resulting HTTP status code for the app.
Unit: Count
Average number of bytes received
The average number of bytes received for the app.
Unit: Bytes
Average memory used
The average amount of memory, in MiBs, used by the app.
Unit: MiBs
Average response time
The average time taken for the app to serve requests in milliseconds (ms).
Unit: ms