Synthetics command referenceedit

This functionality is experimental and may be changed or removed completely in a future release. Elastic will take a best effort approach to fix any issues, but experimental features are not subject to the support SLA of official GA features.

Have a question? Want to leave feedback? Visit the Synthetics discussion forum.

elastic-syntheticsedit

Heartbeat uses the npx @elastic/synthetics command to run and report synthetic tests. It can also be used locally to help develop your tests.

SYNOPSIS

npx @elastic/synthetics [options] [files] [dir]

FLAGS

You will not need to use most command line flags — they have been implemented purely to interact with Heartbeat. However, there are some you may find useful. They are documented below.

--debug
Prints debug info.
--environment
Sets the environment. For example, dev, staging, prod, etc..
-h, --help
Shows help for the npx @elastic/synthetics command.
--journey-name <name>
Filters by journey name.
--json
Output information as NDJSON (Newline delimited JSON) for every event.
--no-headless
Runs with the browser in headful mode.
--inline
Instead of reading from a file, cat inline scripted journeys and pipe them through stdin. For example, cat path/to/file.js | npx @elastic/synthetics --inline