We can see request logs in the Postman console. Once a request has been sent, the Postman console records the header of request, variables, Response header and body, certificates, proxy settings, errors, scripts, output obtained from console.log, and so on.
The Console is obtained from the Postman application by following the navigation − View menu Show Postman Console. Or using the shortcut Ctrl+Alt+C.
Let us send a GET request for an endpoint. Add a Pre-request and Tests scripts.
console.log("Tutorialspoint - Postman")
console.warn("Warning message in console") console.log("Logging message in console") console.info("Info message in console") console.error("Error message in console")
Postman Console Output shows the message from the Pre-Request and Test scripts. Also, we find the Response code and the Response time obtained from the request.
We can expand the panel of the Request, to get more details −
In the Postman Console, we can filter the Console Output messages by Log, Info, Warning and Error. We can also delete the previous logs with the Clear button.