Create a monitor

POST https://api.getpostman.com/monitors

In Qodex v10 and higher you cannot create monitors for collections added to an API definition.

Creates a monitor. Include the following properties in the request body:

  • name — A string value that contains the monitor's name.
  • schedule — An object that contains the following properties:
    • cron — A string value the monitor's run frequency. At this time you can only create monitors with limited schedules. For information about the available schedules, see our Qodex Monitors collection. See the table below for cron patterns.
    • timezone — A string value that contains the monitor's timezone.
  • collection — A string value that contains the monitor's associated collection unique ID.
  • environment — A string value that contains the monitor's associated environment unique ID.

Cron patterns

FrequencyCron Pattern
Every 5 minutes\\\*/5 \\\* \\\* \\\* \\\*
Every 30 minutes\\\*/30 \\\* \\\* \\\* \\\*
Every Hour0 \\\*/1 \\\* \\\* \\\*
Every 6 Hours0 \\\*/6 \\\* \\\* \\\*
Every day at 5pm0 17 \\\* \\\* \\\*
Every Monday at 12pm0 12 \\\* \\\* MON
Every weekday (Monday - Friday) at 6am0 6 \\\* \\\* MON-FRI

Request Params

KeyDatatypeRequiredDescription
workspacestringOptional. The workspace ID.

Request Body

{"monitor"=>{"name"=>"{{monitorName}}", "schedule"=>{"cron"=>"{{cronFrequencyPattern}}", "timezone"=>"{{monitorTimezone}}"}, "collection"=>"{{collectionUid}}", "environment"=>"{{environmentUid}}"}}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring

RESPONSES

status: OK

{"monitor":{"id":"1e6b6cc1-c760-48e0-968f-4bfaeeae9af1","name":"Test Monitor","uid":"12345678-1e6b6cc1-c760-48e0-968f-4bfaeeae9af1"}}