Skip to content

A monitor runs a folder, or the whole collection, on a schedule with an environment, through the runner, and tells you when it fails. It runs in one of two places, both yours: the Dockito desktop app on your computer, or CI with dockito run. Dockito’s servers never send a request, so your keys stay on your machine or in your CI’s secrets.

In the desktop app, open the API doc and choose ⏱ Monitors at the top of the requests, then New monitor:

  • Run: the whole collection, or a folder.
  • Environment: its values and secrets come from this computer, as when you send a request.
  • When: every 5, 10, 15 or 30 minutes; hourly at a minute past the hour; daily at a time; or weekdays (Monday to Friday) at a time. Times are your computer’s.
  • Notify me when a run fails: a notification in words, such as “Bookings API · 2 of 14 failed: Create booking: expected 201, got 500”, and one more when it passes again. Click it to open that run.

Each monitor shows its last run, its pass rate over the last 20 runs, and when it runs next, with Run now, Pause, Edit and Delete. Open one to see its runs, with the results of each as the runner shows them, Failed to see only what failed, and Copy for AI.

When it runs:

  • While Dockito is open, its window closed too: it carries on in the menu bar. Quitting Dockito stops monitors.
  • Open Dockito at login (at the bottom of Monitors) starts it when you log in, so monitors carry on after a restart.
  • If your Mac was asleep, or Dockito was closed, when a run was due, the monitor runs once shortly after it wakes or opens, not once for every run it missed.
  • A run never changes your values: what scripts set is dropped when it ends.

Kept on this computer, not in the doc. A monitor is yours: it doesn’t run on your teammates’ computers, and it isn’t in the doc’s History. Each monitor keeps its last 20 runs here (200 in all), results only.

To monitor from a server that’s always on, run the collection in CI. dockito monitor init writes a GitHub Actions workflow:

Terminal window
dockito monitor init <doc> - --env Staging --every 1h
dockito monitor init <doc> Bookings --env Production --every weekdays --at 07:30

It writes .github/workflows/dockito-monitor.yml and lists the repository secrets to set (gh secret set NAME):

  • DOCKITO_TOKEN: a token from Settings › Tokens that can view the doc.
  • Each secret of the collection and the environment, and each value with nothing shared, named as dockito run reads them: {{bookingsToken}} is BOOKINGS_TOKEN. CI has no keychain, so they come from the environment.

--every takes 5m, 10m, 15m, 20m, 30m, 1h (the default), 2h, 3h, 4h, 6h, 12h, daily or weekdays; --at sets the time for daily and weekdays, in UTC. --cron takes any GitHub schedule instead. A failed test, script or request fails the job, and GitHub emails whoever watches the repository; the JUnit results are kept with the run.

The workflow it writes looks like this:

name: "Dockito monitor: Bookings API"
on:
schedule:
- cron: "0 * * * *"
workflow_dispatch:
permissions:
contents: read
jobs:
monitor:
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/setup-node@v4
with:
node-version: 22
- run: npm install -g dockito
- name: "Run Bookings API (the whole collection)"
run: |
dockito run '<doc>' '-' --env 'Staging' --reporter junit > dockito-results.xml
env:
DOCKITO_TOKEN: ${{ secrets.DOCKITO_TOKEN }}
BOOKINGS_TOKEN: ${{ secrets.BOOKINGS_TOKEN }}
- if: always()
uses: actions/upload-artifact@v4
with:
name: dockito-results
path: dockito-results.xml

dockito run works wherever Node runs. Give it a token and the secrets as environment variables, and read its exit code (1 when anything failed). With cron, keep them in a file only you can read rather than in the crontab:

Terminal window
# ~/.bookings-monitor.env (chmod 600):
# export DOCKITO_TOKEN=…
# export BOOKINGS_TOKEN=…
# crontab: every 15 minutes, results kept as JUnit
*/15 * * * * . "$HOME/.bookings-monitor.env" && dockito run <doc> - --env Staging --reporter junit > "$HOME/bookings-monitor.xml"

--reporter json prints the whole run instead, for your own alerting.