Skip to content

Step reference

This is the reference for the steps of a multi-step service. A service has 1 to 10 steps, run in order. Every step has a name (1 to 100 characters), a type and its request; everything else is optional.

Type What the step does Its request
http An HTTP or HTTPS request. method (GET, POST, PUT, PATCH, DELETE, HEAD or OPTIONS; GET by default), url (http:// or https://, up to 2,048 characters), headers, cookies, body and body_type (json, form, multipart, xml, text, graphql or binary_parameter), http_version (1.1, 2 or 2_fallback).
grpc A gRPC call, or the standard health check. host, port, service, method, metadata, message, health_check.
websocket Opens a WebSocket, sends a message and reads the answer. url (ws:// or wss://), headers, message (up to 64 KiB), close_after_first_answer (on by default).
tcp Connects to a port, optionally sends a payload. host, port, payload (up to 64 KiB).
udp Sends a datagram and waits for a reply. host, port, payload.
icmp Pings a host. host, count (1 to 10, 3 by default).
dns Looks a name up. name, record_type (A, AAAA, CNAME, MX, NS, TXT, SOA, CAA, SRV or PTR; A by default), resolver (the system’s when empty).
tls Completes a TLS handshake and reads the certificate. host, port (443 by default), sni.
smtp Talks to a mail server without sending mail. host, port, tls_mode (starttls, implicit or none). It never sends MAIL, RCPT or DATA.
wait Pauses the run. seconds (1 to 300).

A host that is a link-local or cloud metadata address (such as 169.254.169.254) is refused, and so is an IPv4 address written other than as four dotted numbers: write it as a.b.c.d. A destination must also be one your collectors are allowed to reach (see Parameters and a server’s services.allow).

Option Meaning
timeout_seconds The step’s own time limit, 5 to 120 seconds (10 by default).
follow_redirects http: up to 10 redirects (10 by default; 0 turns it off).
tls_verify Whether the certificate must be trusted (on by default).
proxy http: a proxy URL.
cookie_jar shared (the default: the run’s steps share cookies, never headers) or isolated.
response_check http: whether the response is judged at all (on by default).
response_type json or xml: the body must be well-formed, which a JSON or XML assertion needs.

A step’s auth is one of none, basic, digest, ntlm, bearer (a token), aws_sigv4, or, on an smtp step, a login. Every field is write-only. Write a value as a parameter reference such as {{param.api_token}}: a literal credential is refused, so a secret is never stored on WatchTower15.

A step has up to 20 assertions; the step passes when all of them do. An assertion has a target, an operator, an optional select (where to look) and a value.

Target Reads Operators
status the HTTP status is, is_not, in, matches, not_matches
response_time the step’s time in milliseconds less_than
header a header (name in select) contains, not_contains, is, is_not, matches, not_matches, exists, not_exists, lt, lte, gt, gte
body the whole body contains, not_contains, is, is_not, matches, not_matches
jsonpath a JSON value (path in select) the header comparisons (numeric ones included), plus any_contains and every_contains for a list
xpath an XML value (path in select) the same
json_schema the body against a JSON Schema valid
body_hash the body’s hash md5, sha1, sha256
freshness a timestamp in the body within_seconds
tls the certificate days_left_gt, issuer_is, hostname_matches
dns the answer answer_contains, answer_count
tcp the connection connect_time_lt
udp the reply round_trip_lt
icmp the ping round_trip_lt, packet_loss_lte

How values compare is as described under Response assertions: numbers compare as numbers, text compares exactly and case-sensitively, and a pattern is RE2. The body is read up to 1 MiB, and the assertions run on your collectors: the body never leaves them. A run records for each assertion whether it passed, why not, and the value it saw when that value is a number, true, false or null; for text, only its length.

A step has up to 10 extractions. An extraction reads a value from the answer into a name (letters, digits and underscores, starting with a letter, up to 64 characters) that every later step writes as {{name}}.

Field Meaning
from status, header, body, cookie or response_time.
parse full (the whole value), regex, jsonpath or xpath.
expression The pattern or path for regex, jsonpath and xpath, up to 1,024 characters.
filter The header or cookie name.

An extraction whose value is not found fails its step. A run records whether each extraction found its value, never the value.

  • {{param.name}} — a parameter, read on the collector.
  • {{var.name}} — a variable, generated for each run: numeric, alphabetic or alphanumeric (a length of 1 to 64), uuid, run_uuid, service_uuid, timestamp or date (with an offset and a format). A service has at most 10.
  • {{name}} — a value an earlier step extracted.

A reference may stand in a URL, a header value, a body, a path or an assertion’s value. One that names nothing is refused at save.

Field Values
on_success continue (the default) or exit_passed: the run ends passed, and the later steps do not run.
on_failure.then stop (the default) or continue.
on_failure.critical Whether a failure of this step fails the run (on by default). A non-critical failure is recorded and the run goes on.

A cleanup step is an ordinary step that follows a failure with then: continue: it runs after an earlier failure too, so a journey that creates something can delete it again.

repeat.mode Meaning
none Run the step once (the default).
retry Run it again up to count more times (1 to 5), interval_ms apart (0 to 60,000), until it passes.
poll_until Run it every interval_seconds (1 to 300) until it passes, for at most budget_seconds (1 to 300).

The whole run must still finish inside the service’s run budget.

What Limit
Steps in a service 1 to 10
Assertions in a step 20
Extractions in a step 10
Variables in a service 10
Parameters in a service 20
Run budget 5 to 300 seconds
Fast retry 0 to 3 more tries, up to 60 seconds apart
A step’s timeout 5 to 120 seconds
Headers or cookies in a step 50
A header or cookie value 4,096 characters

A service is one service on your price list whatever its steps: see Billing.