You can run your postman collection in Jenkins, with step:
1. Create new project.
Select new item > Enter an item name “Postman Example” > Choose Freestyle project > Click OK.
2. Setting Build Environment.
Select Configure > Choose Build Environment tab > Check Provide Node & npm bin/folder to Path
3. Setting Build.
Choose Execute Windows batch command > Enter the newman command to execute your postman collection. In this example, I run JSON file in my local computer.
If you want to run postman public collection, you can change the command to be “newman run your_public_link”
4. Setting Post-build Actions according to your needs, then click Save.
If you want notify your teammate with the result of your collection execution, you can choose E-mail Notification and fill the recipients.
5. Click Build Now and see result in Console Output.
Here is the test result:
If you have problems with the appearance of the report or the report format is not nice, you can update the Content Security Policy in Jenkins with command: System.setProperty(“hudson.model.DirectoryBrowserSupport.CSP”, “default-src ‘self’; style-src ‘self’ ‘unsafe-inline’;”)
Thanks for reading.