Triggering a monitor to run via a third-party

Is there a way to trigger a collection monitor to run (outside of its schedule) from a third-party service?

Specifically I want to run a monitor containing our API integration tests after every new deploy to our staging environment (but this would be generally useful outside of this use-case). For example, our deploy script could perform a CURL pointing at Postman somehow, to trigger the monitor to run after each deploy is complete.

Whilst I can see how to send monitor result data to third-party webhooks after a monitor has run, I can’t see how to trigger a monitor to run from outside Postman.

Thanks!

Hi @cadenzabox,

Yep, you can execute a monitor via the Postman API! See here for the endpoint: https://documenter.getpostman.com/view/631643/JsLs/#5b277ca0-7114-e04e-f1f5-246fbbd6d973

You can also use the postmanctl CLI like so:

$ postmanctl run monitor $MONITOR_UID

Hope that helps.

Best,

Kevin

1 Like

Thank you so much! This is exactly what we need. :grin:

How I didn’t find your API docs (when we use Postman to create API docs) I don’t quite know. :man_facepalming:

Cheers, Francis