Logo
15_Days_of_Postman_-_for_testers_IvanKo API Documentation

Monitors

Number of APIs: 6


1. Create a monitor

POST {{baseUrl}}/monitors

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

Frequency Cron Pattern
Every 5 minutes \\\\\\\*/5 \\\\\\\* \\\\\\\* \\\\\\\* \\\\\\\*
Every 30 minutes \\\\\\\*/30 \\\\\\\* \\\\\\\* \\\\\\\* \\\\\\\*
Every Hour 0 \\\\\\\*/1 \\\\\\\* \\\\\\\* \\\\\\\*
Every 6 Hours 0 \\\\\\\*/6 \\\\\\\* \\\\\\\* \\\\\\\*
Every day at 5pm 0 17 \\\\\\\* \\\\\\\* \\\\\\\*
Every Monday at 12pm 0 12 \\\\\\\* \\\\\\\* MON
Every weekday (Monday - Friday) at 6am 0 6 \\\\\\\* \\\\\\\* MON-FRI

Note:

You cannot create monitors for collections added to an API definition.



2. Run a monitor

POST {{baseUrl}}/monitors/{{monitorId}}/run

Runs a monitor and returns its run results.



3. Delete a monitor

DELETE {{baseUrl}}/monitors/{{monitorId}}

Deletes a monitor.



4. Get all monitors

GET {{baseUrl}}/monitors

Gets all monitors.



5. Get a monitor

GET {{baseUrl}}/monitors/{{monitorId}}

Gets information about a monitor.



6. Update a monitor

PUT {{baseUrl}}/monitors/{{monitorId}}

Updates 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.

Cron patterns

Frequency Cron Pattern
Every 5 minutes \\\*/5 \\\* \\\* \\\* \\\*
Every 30 minutes \\\*/30 \\\* \\\* \\\* \\\*
Every Hour 0 \\\*/1 \\\* \\\* \\\*
Every 6 Hours 0 \\\*/6 \\\* \\\* \\\*
Every day at 5pm 0 17 \\\* \\\* \\\*
Every Monday at 12pm 0 12 \\\* \\\* MON
Every weekday (Monday - Friday) at 6am 0 6 \\\* \\\* MON-FRI



ENDPOINTS