Monitors are kept in sync with your collections in the Postman app at all times. This means that you can debug in the app locally, while your monitors are updated on our servers, seamlessly.
The best way to debug monitors is via the Postman console available on the monitors web view. Click on the failed monitor, and review the relevant logs under the Console Log tab. Check out some tips and tricks for debugging in the console.
When a monitor fails, a “Need help debugging?” popup will display on the Postman monitors web view. Whenever possible, these suggestions will include debugging tips that are specifically related to the error that occurred. For example, if the monitor failed because we were unable to contact the server, then the debugging tip will suggest ensuring that the server’s IP address is correct, and that it’s publicly available. Or, if the monitor failed because of a missing variable, then the debugging tip will suggest verifying the monitor is using the correct environment, and that the variable exists in the environment.
In addition to the above, here are some debugging tricks:
console.log(environment);to your request scripts and comparing the results across monitoring and local runs.
console.log(JSON.stringify(responseBody, null, 2)); console.log(JSON.stringify(responseHeaders, null, 2));
try - catchblock will also let the test and pre-request scripts in your collection run to completion, allowing you to see the entire picture.