Skip to main content

web_tests

Creates, updates, deletes, gets or lists a web_tests resource.

Overview

Nameweb_tests
TypeResource
Idazure.application_insights.web_tests

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringAzure resource Id.
namestringAzure resource name.
ConfigurationobjectAn XML configuration specification for a WebTest.
DescriptionstringUser defined description for this WebTest.
EnabledbooleanIs the test actively being monitored.
FrequencyintegerInterval in seconds between test runs for this WebTest. Default value is 300.
KindstringThe kind of web test this is, valid choices are ping, multistep and standard. Required. Known values are: "ping", "multistep", and "standard". (ping, multistep, standard)
LocationsarrayA list of where to physically run the tests from to give global coverage for accessibility of your application. Required.
NamestringUser defined name if this WebTest. Required.
RequestobjectThe collection of request properties.
RetryEnabledbooleanAllow for retries should this WebTest fail.
SyntheticMonitorIdstringUnique ID of this WebTest. This is typically the same value as the Name field. Required.
TimeoutintegerSeconds until this WebTest will timeout and fail. Default value is 30.
ValidationRulesobjectThe collection of validation rule properties.
kindstringThe kind of WebTest that this web test watches. Choices are ping, multistep and standard. Known values are: "ping", "multistep", and "standard". (ping, multistep, standard)
locationstringResource location. Required.
provisioningStatestringCurrent state of this component, whether or not is has been provisioned within the resource group it is defined. Users cannot change this value but are able to read from it. Values will include Succeeded, Deploying, Canceled, and Failed.
tagsobjectResource tags.
typestringAzure resource type.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, web_test_name, subscription_idGet a specific Application Insights web test definition.
list_by_componentselectcomponent_name, resource_group_name, subscription_idGet all Application Insights web tests defined for the specified component.
list_by_resource_groupselectresource_group_name, subscription_idGet all Application Insights web tests defined for the specified resource group.
listselectsubscription_idGet all Application Insights web test definitions for the specified subscription.
create_or_updateinsertresource_group_name, web_test_name, subscription_id, locationCreates or updates an Application Insights web test definition.
update_tagsupdateresource_group_name, web_test_name, subscription_idUpdates the tags associated with an Application Insights web test.
create_or_updatereplaceresource_group_name, web_test_name, subscription_id, locationCreates or updates an Application Insights web test definition.
deletedeleteresource_group_name, web_test_name, subscription_idDeletes an Application Insights web test.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
component_namestringThe name of the Application Insights component resource. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
subscription_idstring
web_test_namestringThe name of the Application Insights WebTest resource. Required.

SELECT examples

Get a specific Application Insights web test definition.

SELECT
id,
name,
Configuration,
Description,
Enabled,
Frequency,
Kind,
Locations,
Name,
Request,
RetryEnabled,
SyntheticMonitorId,
Timeout,
ValidationRules,
kind,
location,
provisioningState,
tags,
type
FROM azure.application_insights.web_tests
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND web_test_name = '{{ web_test_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Creates or updates an Application Insights web test definition.

INSERT INTO azure.application_insights.web_tests (
location,
tags,
kind,
properties,
resource_group_name,
web_test_name,
subscription_id
)
SELECT
'{{ location }}' /* required */,
'{{ tags }}',
'{{ kind }}',
'{{ properties }}',
'{{ resource_group_name }}',
'{{ web_test_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
kind,
location,
properties,
tags,
type
;

UPDATE examples

Updates the tags associated with an Application Insights web test.

UPDATE azure.application_insights.web_tests
SET
tags = '{{ tags }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND web_test_name = '{{ web_test_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
kind,
location,
properties,
tags,
type;

REPLACE examples

Creates or updates an Application Insights web test definition.

REPLACE azure.application_insights.web_tests
SET
location = '{{ location }}',
tags = '{{ tags }}',
kind = '{{ kind }}',
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND web_test_name = '{{ web_test_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
RETURNING
id,
name,
kind,
location,
properties,
tags,
type;

DELETE examples

Deletes an Application Insights web test.

DELETE FROM azure.application_insights.web_tests
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND web_test_name = '{{ web_test_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;