Microsoft.Network networkWatchers/connectionMonitors 2019-12-01

Template format

To create a Microsoft.Network/networkWatchers/connectionMonitors resource, add the following JSON to the resources section of your template.

{
  "name": "string",
  "type": "Microsoft.Network/networkWatchers/connectionMonitors",
  "apiVersion": "2019-12-01",
  "location": "string",
  "tags": {},
  "properties": {
    "source": {
      "resourceId": "string",
      "port": "integer"
    },
    "destination": {
      "resourceId": "string",
      "address": "string",
      "port": "integer"
    },
    "autoStart": "boolean",
    "monitoringIntervalInSeconds": "integer",
    "endpoints": [
      {
        "name": "string",
        "resourceId": "string",
        "address": "string",
        "filter": {
          "type": "Include",
          "items": [
            {
              "type": "AgentAddress",
              "address": "string"
            }
          ]
        }
      }
    ],
    "testConfigurations": [
      {
        "name": "string",
        "testFrequencySec": "integer",
        "protocol": "string",
        "preferredIPVersion": "string",
        "httpConfiguration": {
          "port": "integer",
          "method": "string",
          "path": "string",
          "requestHeaders": [
            {
              "name": "string",
              "value": "string"
            }
          ],
          "validStatusCodeRanges": [
            "string"
          ],
          "preferHTTPS": "boolean"
        },
        "tcpConfiguration": {
          "port": "integer",
          "disableTraceRoute": "boolean"
        },
        "icmpConfiguration": {
          "disableTraceRoute": "boolean"
        },
        "successThreshold": {
          "checksFailedPercent": "integer",
          "roundTripTimeMs": "integer"
        }
      }
    ],
    "testGroups": [
      {
        "name": "string",
        "disable": "boolean",
        "testConfigurations": [
          "string"
        ],
        "sources": [
          "string"
        ],
        "destinations": [
          "string"
        ]
      }
    ],
    "outputs": [
      {
        "type": "Workspace",
        "workspaceSettings": {
          "workspaceResourceId": "string"
        }
      }
    ],
    "notes": "string"
  }
}

Property values

The following tables describe the values you need to set in the schema.

Microsoft.Network/networkWatchers/connectionMonitors object

Name Type Required Value
name string Yes The name of the connection monitor.
type enum Yes connectionMonitors
-or-
Microsoft.Network/networkWatchers/connectionMonitors

See Set name and type for child resources.
apiVersion enum Yes 2019-12-01
location string No Connection monitor location.
tags object No Connection monitor tags.
properties object Yes Properties of the connection monitor. - ConnectionMonitorParameters object

ConnectionMonitorParameters object

Name Type Required Value
source object No Describes the source of connection monitor. - ConnectionMonitorSource object
destination object No Describes the destination of connection monitor. - ConnectionMonitorDestination object
autoStart boolean No Determines if the connection monitor will start automatically once created.
monitoringIntervalInSeconds integer No Monitoring interval in seconds.
endpoints array No List of connection monitor endpoints. - ConnectionMonitorEndpoint object
testConfigurations array No List of connection monitor test configurations. - ConnectionMonitorTestConfiguration object
testGroups array No List of connection monitor test groups. - ConnectionMonitorTestGroup object
outputs array No List of connection monitor outputs. - ConnectionMonitorOutput object
notes string No Optional notes to be associated with the connection monitor.

ConnectionMonitorSource object

Name Type Required Value
resourceId string Yes The ID of the resource used as the source by connection monitor.
port integer No The source port used by connection monitor.

ConnectionMonitorDestination object

Name Type Required Value
resourceId string No The ID of the resource used as the destination by connection monitor.
address string No Address of the connection monitor destination (IP or domain name).
port integer No The destination port used by connection monitor.

ConnectionMonitorEndpoint object

Name Type Required Value
name string Yes The name of the connection monitor endpoint.
resourceId string No Resource ID of the connection monitor endpoint.
address string No Address of the connection monitor endpoint (IP or domain name).
filter object No Filter for sub-items within the endpoint. - ConnectionMonitorEndpointFilter object

ConnectionMonitorTestConfiguration object

Name Type Required Value
name string Yes The name of the connection monitor test configuration.
testFrequencySec integer No The frequency of test evaluation, in seconds.
protocol enum Yes The protocol to use in test evaluation. - Tcp, Http, Icmp
preferredIPVersion enum No The preferred IP version to use in test evaluation. The connection monitor may choose to use a different version depending on other parameters. - IPv4 or IPv6
httpConfiguration object No The parameters used to perform test evaluation over HTTP. - ConnectionMonitorHttpConfiguration object
tcpConfiguration object No The parameters used to perform test evaluation over TCP. - ConnectionMonitorTcpConfiguration object
icmpConfiguration object No The parameters used to perform test evaluation over ICMP. - ConnectionMonitorIcmpConfiguration object
successThreshold object No The threshold for declaring a test successful. - ConnectionMonitorSuccessThreshold object

ConnectionMonitorTestGroup object

Name Type Required Value
name string Yes The name of the connection monitor test group.
disable boolean No Value indicating whether test group is disabled.
testConfigurations array Yes List of test configuration names. - string
sources array Yes List of source endpoint names. - string
destinations array Yes List of destination endpoint names. - string

ConnectionMonitorOutput object

Name Type Required Value
type enum No Connection monitor output destination type. Currently, only "Workspace" is supported. - Workspace
workspaceSettings object No Describes the settings for producing output into a log analytics workspace. - ConnectionMonitorWorkspaceSettings object

ConnectionMonitorEndpointFilter object

Name Type Required Value
type enum No The behavior of the endpoint filter. Currently only 'Include' is supported. - Include
items array No List of items in the filter. - ConnectionMonitorEndpointFilterItem object

ConnectionMonitorHttpConfiguration object

Name Type Required Value
port integer No The port to connect to.
method enum No The HTTP method to use. - Get or Post
path string No The path component of the URI. For instance, "/dir1/dir2".
requestHeaders array No The HTTP headers to transmit with the request. - HTTPHeader object
validStatusCodeRanges array No HTTP status codes to consider successful. For instance, "2xx,301-304,418". - string
preferHTTPS boolean No Value indicating whether HTTPS is preferred over HTTP in cases where the choice is not explicit.

ConnectionMonitorTcpConfiguration object

Name Type Required Value
port integer No The port to connect to.
disableTraceRoute boolean No Value indicating whether path evaluation with trace route should be disabled.

ConnectionMonitorIcmpConfiguration object

Name Type Required Value
disableTraceRoute boolean No Value indicating whether path evaluation with trace route should be disabled.

ConnectionMonitorSuccessThreshold object

Name Type Required Value
checksFailedPercent integer No The maximum percentage of failed checks permitted for a test to evaluate as successful.
roundTripTimeMs integer No The maximum round-trip time in milliseconds permitted for a test to evaluate as successful.

ConnectionMonitorWorkspaceSettings object

Name Type Required Value
workspaceResourceId string No Log analytics workspace resource ID.

ConnectionMonitorEndpointFilterItem object

Name Type Required Value
type enum No The type of item included in the filter. Currently only 'AgentAddress' is supported. - AgentAddress
address string No The address of the filter item.

HTTPHeader object

Name Type Required Value
name string No The name in HTTP header.
value string No The value in HTTP header.