Create monitor
monitor_createCreate a monitor that watches command, file, or log conditions and returns an ID to wait on until true. Ideal for long-running tasks like builds, deploys, or downloads.
Instructions
Create a background monitor that watches for a condition and settles when it becomes true. Evaluation happens inside the plugin, so never write your own sleep/poll loop. Returns a monitor id; pass it to monitor_wait to pause until the condition holds. Use this for anything long-running: cluster jobs, builds, deploys, downloads, servers coming up. Installed condition types: command, file, log.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Human-readable label, e.g. 'slurm job 12345'. | |
| poll | No | Override the probe schedule. Event-driven conditions (file, log) still react immediately via filesystem events; this tunes the periodic safety check behind them. | |
| condition | Yes | ||
| timeout_seconds | No | Monitor moves to state 'timeout' if unresolved after this long. Default 24h. |