1. Packages
  2. Routeros Provider
  3. API Docs
  4. ToolNetwatch
routeros 1.81.2 published on Tuesday, Apr 15, 2025 by terraform-routeros

routeros.ToolNetwatch

Explore with Pulumi AI

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as routeros from "@pulumi/routeros";

const test = new routeros.ToolNetwatch("test", {
    host: "8.8.8.8",
    interval: "30s",
    thrMax: "400ms",
    type: "icmp",
    upScript: ":log info \"Ping to 8.8.8.8 successful\"",
});
Copy
import pulumi
import pulumi_routeros as routeros

test = routeros.ToolNetwatch("test",
    host="8.8.8.8",
    interval="30s",
    thr_max="400ms",
    type="icmp",
    up_script=":log info \"Ping to 8.8.8.8 successful\"")
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/routeros/routeros"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := routeros.NewToolNetwatch(ctx, "test", &routeros.ToolNetwatchArgs{
			Host:     pulumi.String("8.8.8.8"),
			Interval: pulumi.String("30s"),
			ThrMax:   pulumi.String("400ms"),
			Type:     pulumi.String("icmp"),
			UpScript: pulumi.String(":log info \"Ping to 8.8.8.8 successful\""),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Routeros = Pulumi.Routeros;

return await Deployment.RunAsync(() => 
{
    var test = new Routeros.ToolNetwatch("test", new()
    {
        Host = "8.8.8.8",
        Interval = "30s",
        ThrMax = "400ms",
        Type = "icmp",
        UpScript = ":log info \"Ping to 8.8.8.8 successful\"",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.routeros.ToolNetwatch;
import com.pulumi.routeros.ToolNetwatchArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var test = new ToolNetwatch("test", ToolNetwatchArgs.builder()
            .host("8.8.8.8")
            .interval("30s")
            .thrMax("400ms")
            .type("icmp")
            .upScript(":log info \"Ping to 8.8.8.8 successful\"")
            .build());

    }
}
Copy
resources:
  test:
    type: routeros:ToolNetwatch
    properties:
      host: 8.8.8.8
      interval: 30s
      thrMax: 400ms
      type: icmp
      upScript: :log info "Ping to 8.8.8.8 successful"
Copy

Create ToolNetwatch Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new ToolNetwatch(name: string, args: ToolNetwatchArgs, opts?: CustomResourceOptions);
@overload
def ToolNetwatch(resource_name: str,
                 args: ToolNetwatchArgs,
                 opts: Optional[ResourceOptions] = None)

@overload
def ToolNetwatch(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 host: Optional[str] = None,
                 port: Optional[float] = None,
                 src_address: Optional[str] = None,
                 accept_icmp_time_exceeded: Optional[bool] = None,
                 comment: Optional[str] = None,
                 disabled: Optional[bool] = None,
                 dns_server: Optional[str] = None,
                 down_script: Optional[str] = None,
                 ___path_: Optional[str] = None,
                 http_code_max: Optional[float] = None,
                 http_code_min: Optional[float] = None,
                 start_delay: Optional[str] = None,
                 name: Optional[str] = None,
                 packet_count: Optional[float] = None,
                 packet_interval: Optional[str] = None,
                 packet_size: Optional[float] = None,
                 ___id_: Optional[float] = None,
                 ___skip_: Optional[str] = None,
                 record_type: Optional[str] = None,
                 interval: Optional[str] = None,
                 startup_delay: Optional[str] = None,
                 test_script: Optional[str] = None,
                 thr_avg: Optional[str] = None,
                 thr_http_time: Optional[str] = None,
                 thr_jitter: Optional[str] = None,
                 thr_loss_count: Optional[float] = None,
                 thr_loss_percent: Optional[float] = None,
                 thr_max: Optional[str] = None,
                 thr_stdev: Optional[str] = None,
                 thr_tcp_conn_time: Optional[str] = None,
                 timeout: Optional[str] = None,
                 tool_netwatch_id: Optional[str] = None,
                 ttl: Optional[float] = None,
                 type: Optional[str] = None,
                 up_script: Optional[str] = None)
func NewToolNetwatch(ctx *Context, name string, args ToolNetwatchArgs, opts ...ResourceOption) (*ToolNetwatch, error)
public ToolNetwatch(string name, ToolNetwatchArgs args, CustomResourceOptions? opts = null)
public ToolNetwatch(String name, ToolNetwatchArgs args)
public ToolNetwatch(String name, ToolNetwatchArgs args, CustomResourceOptions options)
type: routeros:ToolNetwatch
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. ToolNetwatchArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. ToolNetwatchArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. ToolNetwatchArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. ToolNetwatchArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. ToolNetwatchArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

ToolNetwatch Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The ToolNetwatch resource accepts the following input properties:

Host This property is required. string
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
AcceptIcmpTimeExceeded bool
If the ICMP time exceeded message should be considered a valid response.
Comment string
Disabled bool
DnsServer string
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
DownScript string
Script to execute on the event of probe state change OK -> fail.
HttpCodeMax double
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
HttpCodeMin double
OK/fail criteria for HTTP response code.
Interval string
The time interval between probe tests.
Name string
Task name.
PacketCount double
Total count of ICMP packets to send out within a single test.
PacketInterval string
The time between ICMP-request packet send.
PacketSize double
The total size of the IP ICMP packet.
Port double
TCP port (for both tcp-conn and http-get probes)
RecordType string
Record type that will be used for DNS probe.
SrcAddress string
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
StartDelay string
Time to wait before starting probe (on add, enable, or system start).
StartupDelay string
Time to wait until starting Netwatch probe after system startup.
TestScript string
Script to execute at the end of every probe test.
ThrAvg string
Fail threshold for rtt-avg.
ThrHttpTime string
Fail threshold for http-resp-time.
ThrJitter string
Fail threshold for rtt-jitter.
ThrLossCount double
Fail threshold for loss-count.
ThrLossPercent double
Fail threshold for loss-percent.
ThrMax string
Fail threshold for rtt-max (a value above thr-max is a probe fail).
ThrStdev string
Fail threshold for rtt-stdev.
ThrTcpConnTime string
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
Timeout string
Max time limit to wait for a response.
ToolNetwatchId string
Ttl double
Manually set time to live value for ICMP packet.
Type string
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
UpScript string
Script to execute on the event of probe state change fail -> OK.
___id_ double
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ string
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ string
A set of transformations for field names. This is an internal service field, setting a value is not required.
Host This property is required. string
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
AcceptIcmpTimeExceeded bool
If the ICMP time exceeded message should be considered a valid response.
Comment string
Disabled bool
DnsServer string
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
DownScript string
Script to execute on the event of probe state change OK -> fail.
HttpCodeMax float64
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
HttpCodeMin float64
OK/fail criteria for HTTP response code.
Interval string
The time interval between probe tests.
Name string
Task name.
PacketCount float64
Total count of ICMP packets to send out within a single test.
PacketInterval string
The time between ICMP-request packet send.
PacketSize float64
The total size of the IP ICMP packet.
Port float64
TCP port (for both tcp-conn and http-get probes)
RecordType string
Record type that will be used for DNS probe.
SrcAddress string
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
StartDelay string
Time to wait before starting probe (on add, enable, or system start).
StartupDelay string
Time to wait until starting Netwatch probe after system startup.
TestScript string
Script to execute at the end of every probe test.
ThrAvg string
Fail threshold for rtt-avg.
ThrHttpTime string
Fail threshold for http-resp-time.
ThrJitter string
Fail threshold for rtt-jitter.
ThrLossCount float64
Fail threshold for loss-count.
ThrLossPercent float64
Fail threshold for loss-percent.
ThrMax string
Fail threshold for rtt-max (a value above thr-max is a probe fail).
ThrStdev string
Fail threshold for rtt-stdev.
ThrTcpConnTime string
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
Timeout string
Max time limit to wait for a response.
ToolNetwatchId string
Ttl float64
Manually set time to live value for ICMP packet.
Type string
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
UpScript string
Script to execute on the event of probe state change fail -> OK.
___id_ float64
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ string
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ string
A set of transformations for field names. This is an internal service field, setting a value is not required.
host This property is required. String
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
___id_ Double
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ String
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ String
A set of transformations for field names. This is an internal service field, setting a value is not required.
acceptIcmpTimeExceeded Boolean
If the ICMP time exceeded message should be considered a valid response.
comment String
disabled Boolean
dnsServer String
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
downScript String
Script to execute on the event of probe state change OK -> fail.
httpCodeMax Double
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
httpCodeMin Double
OK/fail criteria for HTTP response code.
interval String
The time interval between probe tests.
name String
Task name.
packetCount Double
Total count of ICMP packets to send out within a single test.
packetInterval String
The time between ICMP-request packet send.
packetSize Double
The total size of the IP ICMP packet.
port Double
TCP port (for both tcp-conn and http-get probes)
recordType String
Record type that will be used for DNS probe.
srcAddress String
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
startDelay String
Time to wait before starting probe (on add, enable, or system start).
startupDelay String
Time to wait until starting Netwatch probe after system startup.
testScript String
Script to execute at the end of every probe test.
thrAvg String
Fail threshold for rtt-avg.
thrHttpTime String
Fail threshold for http-resp-time.
thrJitter String
Fail threshold for rtt-jitter.
thrLossCount Double
Fail threshold for loss-count.
thrLossPercent Double
Fail threshold for loss-percent.
thrMax String
Fail threshold for rtt-max (a value above thr-max is a probe fail).
thrStdev String
Fail threshold for rtt-stdev.
thrTcpConnTime String
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
timeout String
Max time limit to wait for a response.
toolNetwatchId String
ttl Double
Manually set time to live value for ICMP packet.
type String
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
upScript String
Script to execute on the event of probe state change fail -> OK.
host This property is required. string
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
___id_ number
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ string
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ string
A set of transformations for field names. This is an internal service field, setting a value is not required.
acceptIcmpTimeExceeded boolean
If the ICMP time exceeded message should be considered a valid response.
comment string
disabled boolean
dnsServer string
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
downScript string
Script to execute on the event of probe state change OK -> fail.
httpCodeMax number
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
httpCodeMin number
OK/fail criteria for HTTP response code.
interval string
The time interval between probe tests.
name string
Task name.
packetCount number
Total count of ICMP packets to send out within a single test.
packetInterval string
The time between ICMP-request packet send.
packetSize number
The total size of the IP ICMP packet.
port number
TCP port (for both tcp-conn and http-get probes)
recordType string
Record type that will be used for DNS probe.
srcAddress string
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
startDelay string
Time to wait before starting probe (on add, enable, or system start).
startupDelay string
Time to wait until starting Netwatch probe after system startup.
testScript string
Script to execute at the end of every probe test.
thrAvg string
Fail threshold for rtt-avg.
thrHttpTime string
Fail threshold for http-resp-time.
thrJitter string
Fail threshold for rtt-jitter.
thrLossCount number
Fail threshold for loss-count.
thrLossPercent number
Fail threshold for loss-percent.
thrMax string
Fail threshold for rtt-max (a value above thr-max is a probe fail).
thrStdev string
Fail threshold for rtt-stdev.
thrTcpConnTime string
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
timeout string
Max time limit to wait for a response.
toolNetwatchId string
ttl number
Manually set time to live value for ICMP packet.
type string
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
upScript string
Script to execute on the event of probe state change fail -> OK.
host This property is required. str
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
___id_ float
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ str
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ str
A set of transformations for field names. This is an internal service field, setting a value is not required.
accept_icmp_time_exceeded bool
If the ICMP time exceeded message should be considered a valid response.
comment str
disabled bool
dns_server str
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
down_script str
Script to execute on the event of probe state change OK -> fail.
http_code_max float
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
http_code_min float
OK/fail criteria for HTTP response code.
interval str
The time interval between probe tests.
name str
Task name.
packet_count float
Total count of ICMP packets to send out within a single test.
packet_interval str
The time between ICMP-request packet send.
packet_size float
The total size of the IP ICMP packet.
port float
TCP port (for both tcp-conn and http-get probes)
record_type str
Record type that will be used for DNS probe.
src_address str
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
start_delay str
Time to wait before starting probe (on add, enable, or system start).
startup_delay str
Time to wait until starting Netwatch probe after system startup.
test_script str
Script to execute at the end of every probe test.
thr_avg str
Fail threshold for rtt-avg.
thr_http_time str
Fail threshold for http-resp-time.
thr_jitter str
Fail threshold for rtt-jitter.
thr_loss_count float
Fail threshold for loss-count.
thr_loss_percent float
Fail threshold for loss-percent.
thr_max str
Fail threshold for rtt-max (a value above thr-max is a probe fail).
thr_stdev str
Fail threshold for rtt-stdev.
thr_tcp_conn_time str
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
timeout str
Max time limit to wait for a response.
tool_netwatch_id str
ttl float
Manually set time to live value for ICMP packet.
type str
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
up_script str
Script to execute on the event of probe state change fail -> OK.
host This property is required. String
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
___id_ Number
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ String
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ String
A set of transformations for field names. This is an internal service field, setting a value is not required.
acceptIcmpTimeExceeded Boolean
If the ICMP time exceeded message should be considered a valid response.
comment String
disabled Boolean
dnsServer String
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
downScript String
Script to execute on the event of probe state change OK -> fail.
httpCodeMax Number
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
httpCodeMin Number
OK/fail criteria for HTTP response code.
interval String
The time interval between probe tests.
name String
Task name.
packetCount Number
Total count of ICMP packets to send out within a single test.
packetInterval String
The time between ICMP-request packet send.
packetSize Number
The total size of the IP ICMP packet.
port Number
TCP port (for both tcp-conn and http-get probes)
recordType String
Record type that will be used for DNS probe.
srcAddress String
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
startDelay String
Time to wait before starting probe (on add, enable, or system start).
startupDelay String
Time to wait until starting Netwatch probe after system startup.
testScript String
Script to execute at the end of every probe test.
thrAvg String
Fail threshold for rtt-avg.
thrHttpTime String
Fail threshold for http-resp-time.
thrJitter String
Fail threshold for rtt-jitter.
thrLossCount Number
Fail threshold for loss-count.
thrLossPercent Number
Fail threshold for loss-percent.
thrMax String
Fail threshold for rtt-max (a value above thr-max is a probe fail).
thrStdev String
Fail threshold for rtt-stdev.
thrTcpConnTime String
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
timeout String
Max time limit to wait for a response.
toolNetwatchId String
ttl Number
Manually set time to live value for ICMP packet.
type String
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
upScript String
Script to execute on the event of probe state change fail -> OK.

Outputs

All input properties are implicitly available as output properties. Additionally, the ToolNetwatch resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing ToolNetwatch Resource

Get an existing ToolNetwatch resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: ToolNetwatchState, opts?: CustomResourceOptions): ToolNetwatch
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        ___id_: Optional[float] = None,
        ___path_: Optional[str] = None,
        ___skip_: Optional[str] = None,
        accept_icmp_time_exceeded: Optional[bool] = None,
        comment: Optional[str] = None,
        disabled: Optional[bool] = None,
        dns_server: Optional[str] = None,
        down_script: Optional[str] = None,
        host: Optional[str] = None,
        http_code_max: Optional[float] = None,
        http_code_min: Optional[float] = None,
        interval: Optional[str] = None,
        name: Optional[str] = None,
        packet_count: Optional[float] = None,
        packet_interval: Optional[str] = None,
        packet_size: Optional[float] = None,
        port: Optional[float] = None,
        record_type: Optional[str] = None,
        src_address: Optional[str] = None,
        start_delay: Optional[str] = None,
        startup_delay: Optional[str] = None,
        test_script: Optional[str] = None,
        thr_avg: Optional[str] = None,
        thr_http_time: Optional[str] = None,
        thr_jitter: Optional[str] = None,
        thr_loss_count: Optional[float] = None,
        thr_loss_percent: Optional[float] = None,
        thr_max: Optional[str] = None,
        thr_stdev: Optional[str] = None,
        thr_tcp_conn_time: Optional[str] = None,
        timeout: Optional[str] = None,
        tool_netwatch_id: Optional[str] = None,
        ttl: Optional[float] = None,
        type: Optional[str] = None,
        up_script: Optional[str] = None) -> ToolNetwatch
func GetToolNetwatch(ctx *Context, name string, id IDInput, state *ToolNetwatchState, opts ...ResourceOption) (*ToolNetwatch, error)
public static ToolNetwatch Get(string name, Input<string> id, ToolNetwatchState? state, CustomResourceOptions? opts = null)
public static ToolNetwatch get(String name, Output<String> id, ToolNetwatchState state, CustomResourceOptions options)
resources:  _:    type: routeros:ToolNetwatch    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
AcceptIcmpTimeExceeded bool
If the ICMP time exceeded message should be considered a valid response.
Comment string
Disabled bool
DnsServer string
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
DownScript string
Script to execute on the event of probe state change OK -> fail.
Host string
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
HttpCodeMax double
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
HttpCodeMin double
OK/fail criteria for HTTP response code.
Interval string
The time interval between probe tests.
Name string
Task name.
PacketCount double
Total count of ICMP packets to send out within a single test.
PacketInterval string
The time between ICMP-request packet send.
PacketSize double
The total size of the IP ICMP packet.
Port double
TCP port (for both tcp-conn and http-get probes)
RecordType string
Record type that will be used for DNS probe.
SrcAddress string
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
StartDelay string
Time to wait before starting probe (on add, enable, or system start).
StartupDelay string
Time to wait until starting Netwatch probe after system startup.
TestScript string
Script to execute at the end of every probe test.
ThrAvg string
Fail threshold for rtt-avg.
ThrHttpTime string
Fail threshold for http-resp-time.
ThrJitter string
Fail threshold for rtt-jitter.
ThrLossCount double
Fail threshold for loss-count.
ThrLossPercent double
Fail threshold for loss-percent.
ThrMax string
Fail threshold for rtt-max (a value above thr-max is a probe fail).
ThrStdev string
Fail threshold for rtt-stdev.
ThrTcpConnTime string
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
Timeout string
Max time limit to wait for a response.
ToolNetwatchId string
Ttl double
Manually set time to live value for ICMP packet.
Type string
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
UpScript string
Script to execute on the event of probe state change fail -> OK.
___id_ double
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ string
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ string
A set of transformations for field names. This is an internal service field, setting a value is not required.
AcceptIcmpTimeExceeded bool
If the ICMP time exceeded message should be considered a valid response.
Comment string
Disabled bool
DnsServer string
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
DownScript string
Script to execute on the event of probe state change OK -> fail.
Host string
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
HttpCodeMax float64
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
HttpCodeMin float64
OK/fail criteria for HTTP response code.
Interval string
The time interval between probe tests.
Name string
Task name.
PacketCount float64
Total count of ICMP packets to send out within a single test.
PacketInterval string
The time between ICMP-request packet send.
PacketSize float64
The total size of the IP ICMP packet.
Port float64
TCP port (for both tcp-conn and http-get probes)
RecordType string
Record type that will be used for DNS probe.
SrcAddress string
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
StartDelay string
Time to wait before starting probe (on add, enable, or system start).
StartupDelay string
Time to wait until starting Netwatch probe after system startup.
TestScript string
Script to execute at the end of every probe test.
ThrAvg string
Fail threshold for rtt-avg.
ThrHttpTime string
Fail threshold for http-resp-time.
ThrJitter string
Fail threshold for rtt-jitter.
ThrLossCount float64
Fail threshold for loss-count.
ThrLossPercent float64
Fail threshold for loss-percent.
ThrMax string
Fail threshold for rtt-max (a value above thr-max is a probe fail).
ThrStdev string
Fail threshold for rtt-stdev.
ThrTcpConnTime string
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
Timeout string
Max time limit to wait for a response.
ToolNetwatchId string
Ttl float64
Manually set time to live value for ICMP packet.
Type string
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
UpScript string
Script to execute on the event of probe state change fail -> OK.
___id_ float64
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ string
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ string
A set of transformations for field names. This is an internal service field, setting a value is not required.
___id_ Double
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ String
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ String
A set of transformations for field names. This is an internal service field, setting a value is not required.
acceptIcmpTimeExceeded Boolean
If the ICMP time exceeded message should be considered a valid response.
comment String
disabled Boolean
dnsServer String
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
downScript String
Script to execute on the event of probe state change OK -> fail.
host String
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
httpCodeMax Double
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
httpCodeMin Double
OK/fail criteria for HTTP response code.
interval String
The time interval between probe tests.
name String
Task name.
packetCount Double
Total count of ICMP packets to send out within a single test.
packetInterval String
The time between ICMP-request packet send.
packetSize Double
The total size of the IP ICMP packet.
port Double
TCP port (for both tcp-conn and http-get probes)
recordType String
Record type that will be used for DNS probe.
srcAddress String
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
startDelay String
Time to wait before starting probe (on add, enable, or system start).
startupDelay String
Time to wait until starting Netwatch probe after system startup.
testScript String
Script to execute at the end of every probe test.
thrAvg String
Fail threshold for rtt-avg.
thrHttpTime String
Fail threshold for http-resp-time.
thrJitter String
Fail threshold for rtt-jitter.
thrLossCount Double
Fail threshold for loss-count.
thrLossPercent Double
Fail threshold for loss-percent.
thrMax String
Fail threshold for rtt-max (a value above thr-max is a probe fail).
thrStdev String
Fail threshold for rtt-stdev.
thrTcpConnTime String
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
timeout String
Max time limit to wait for a response.
toolNetwatchId String
ttl Double
Manually set time to live value for ICMP packet.
type String
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
upScript String
Script to execute on the event of probe state change fail -> OK.
___id_ number
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ string
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ string
A set of transformations for field names. This is an internal service field, setting a value is not required.
acceptIcmpTimeExceeded boolean
If the ICMP time exceeded message should be considered a valid response.
comment string
disabled boolean
dnsServer string
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
downScript string
Script to execute on the event of probe state change OK -> fail.
host string
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
httpCodeMax number
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
httpCodeMin number
OK/fail criteria for HTTP response code.
interval string
The time interval between probe tests.
name string
Task name.
packetCount number
Total count of ICMP packets to send out within a single test.
packetInterval string
The time between ICMP-request packet send.
packetSize number
The total size of the IP ICMP packet.
port number
TCP port (for both tcp-conn and http-get probes)
recordType string
Record type that will be used for DNS probe.
srcAddress string
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
startDelay string
Time to wait before starting probe (on add, enable, or system start).
startupDelay string
Time to wait until starting Netwatch probe after system startup.
testScript string
Script to execute at the end of every probe test.
thrAvg string
Fail threshold for rtt-avg.
thrHttpTime string
Fail threshold for http-resp-time.
thrJitter string
Fail threshold for rtt-jitter.
thrLossCount number
Fail threshold for loss-count.
thrLossPercent number
Fail threshold for loss-percent.
thrMax string
Fail threshold for rtt-max (a value above thr-max is a probe fail).
thrStdev string
Fail threshold for rtt-stdev.
thrTcpConnTime string
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
timeout string
Max time limit to wait for a response.
toolNetwatchId string
ttl number
Manually set time to live value for ICMP packet.
type string
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
upScript string
Script to execute on the event of probe state change fail -> OK.
___id_ float
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ str
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ str
A set of transformations for field names. This is an internal service field, setting a value is not required.
accept_icmp_time_exceeded bool
If the ICMP time exceeded message should be considered a valid response.
comment str
disabled bool
dns_server str
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
down_script str
Script to execute on the event of probe state change OK -> fail.
host str
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
http_code_max float
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
http_code_min float
OK/fail criteria for HTTP response code.
interval str
The time interval between probe tests.
name str
Task name.
packet_count float
Total count of ICMP packets to send out within a single test.
packet_interval str
The time between ICMP-request packet send.
packet_size float
The total size of the IP ICMP packet.
port float
TCP port (for both tcp-conn and http-get probes)
record_type str
Record type that will be used for DNS probe.
src_address str
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
start_delay str
Time to wait before starting probe (on add, enable, or system start).
startup_delay str
Time to wait until starting Netwatch probe after system startup.
test_script str
Script to execute at the end of every probe test.
thr_avg str
Fail threshold for rtt-avg.
thr_http_time str
Fail threshold for http-resp-time.
thr_jitter str
Fail threshold for rtt-jitter.
thr_loss_count float
Fail threshold for loss-count.
thr_loss_percent float
Fail threshold for loss-percent.
thr_max str
Fail threshold for rtt-max (a value above thr-max is a probe fail).
thr_stdev str
Fail threshold for rtt-stdev.
thr_tcp_conn_time str
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
timeout str
Max time limit to wait for a response.
tool_netwatch_id str
ttl float
Manually set time to live value for ICMP packet.
type str
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
up_script str
Script to execute on the event of probe state change fail -> OK.
___id_ Number
Resource ID type (.id / name). This is an internal service field, setting a value is not required.
___path_ String
Resource path for CRUD operations. This is an internal service field, setting a value is not required.
___skip_ String
A set of transformations for field names. This is an internal service field, setting a value is not required.
acceptIcmpTimeExceeded Boolean
If the ICMP time exceeded message should be considered a valid response.
comment String
disabled Boolean
dnsServer String
The DNS server that the probe should send its requests to, if not specified it will use the value from /ip dns.
downScript String
Script to execute on the event of probe state change OK -> fail.
host String
The IP address of the server to be probed. Formats: * ipv4 * ipv4@vrf * ipv6 * ipv6@vrf * ipv6-linklocal%interface
httpCodeMax Number
Response in the range [http-code-min , http-code-max] is a probe pass/OK; outside - a probe fail. See mozilla-http-status or rfc7231.
httpCodeMin Number
OK/fail criteria for HTTP response code.
interval String
The time interval between probe tests.
name String
Task name.
packetCount Number
Total count of ICMP packets to send out within a single test.
packetInterval String
The time between ICMP-request packet send.
packetSize Number
The total size of the IP ICMP packet.
port Number
TCP port (for both tcp-conn and http-get probes)
recordType String
Record type that will be used for DNS probe.
srcAddress String
Source IP address which the Netwatch will try to use in order to reach the host. If address is not present, then the host will be considered as down.
startDelay String
Time to wait before starting probe (on add, enable, or system start).
startupDelay String
Time to wait until starting Netwatch probe after system startup.
testScript String
Script to execute at the end of every probe test.
thrAvg String
Fail threshold for rtt-avg.
thrHttpTime String
Fail threshold for http-resp-time.
thrJitter String
Fail threshold for rtt-jitter.
thrLossCount Number
Fail threshold for loss-count.
thrLossPercent Number
Fail threshold for loss-percent.
thrMax String
Fail threshold for rtt-max (a value above thr-max is a probe fail).
thrStdev String
Fail threshold for rtt-stdev.
thrTcpConnTime String
Fail threshold for tcp-connect-time, the configuration uses microseconds, if the time unit is not specified (s/m/h), log and status pages display the same value in milliseconds.
timeout String
Max time limit to wait for a response.
toolNetwatchId String
ttl Number
Manually set time to live value for ICMP packet.
type String
Type of the probe: * icmp - (ping-style) series of ICMP request-response with statistics * tcp-conn - test TCP connection (3-way handshake) to a server specified by IP and port * http-get - do an HTTP Get request and test for a range of correct replies * simple - simplified ICMP probe, with fewer options than ICMP type, used for backward compatibility with the older Netwatch version
upScript String
Script to execute on the event of probe state change fail -> OK.

Import

#The ID can be found via API or the terminal

#The command for the terminal is -> :put [/tool/netwatch get [print show-ids]]

$ pulumi import routeros:index/toolNetwatch:ToolNetwatch test *3
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
routeros terraform-routeros/terraform-provider-routeros
License
Notes
This Pulumi package is based on the routeros Terraform Provider.