You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> - Access to the source code of a [function app](../../azure-functions/functions-how-to-use-azure-function-app-settings.md) in Azure Functions.
17
-
> - Developer expertise capable of authoring custom code for [TrackAvailability()](/dotnet/api/microsoft.applicationinsights.telemetryclient.trackavailability), tailored to your specific business needs
16
+
> - Access to the source code of a [function app](../../azure-functions/functions-how-to-use-azure-function-app-settings.md) in Azure Functions
17
+
> - Developer expertise capable of authoring [custom code](#basic-code-sample) for [TrackAvailability()](/dotnet/api/microsoft.applicationinsights.telemetryclient.trackavailability), tailored to your specific business needs
18
18
19
19
> [!NOTE]
20
-
> - TrackAvailability() requires that you have made a developer investment in custom code.
21
-
> -[Standard tests](availability-standard-tests.md) should always be used if possible as they require little investment and have few prerequisites.
20
+
> -[TrackAvailability()](/dotnet/api/microsoft.applicationinsights.telemetryclient.trackavailability) requires that you make a developer investment in custom code.
21
+
> -[Standard tests](availability-standard-tests.md)**should always be used if possible** as they require little investment, no maintenance, and have few prerequisites.
22
22
23
23
## Check availability
24
24
@@ -43,6 +43,25 @@ You can use Log Analytics to view your availability results, dependencies, and m
43
43
44
44
:::image type="content" source="media/availability-azure-functions/dependencies.png" alt-text="Screenshot that shows the New Query tab with dependencies limited to 50." lightbox="media/availability-azure-functions/dependencies.png":::
45
45
46
+
## Basic code sample
47
+
48
+
The following example demonstrates a web availability test that requires a simple URL ping using the `getStringAsync()` method.
For advanced scenarios where the business logic must be adjusted to access the URL, such as obtaining tokens, setting parameters, and other test cases, custom code is necessary.
0 commit comments