postmanpostman-mockspostman-mock-api-server

Postman Mock API Server - how to make it private after I already created the collection and made it public


As in the title. I have scoured the Postman documentation and went through different nooks and crannies in Postman desktop app but I am unable to make my mock api server private.

I have generated a Postman API Key and I am passing it with all the requests in mock api as x-api-key header but it doesn't change anything. I can still access the collection's endpoints by simply pasting the url in the browser.

When I was creating the mock api server, I choose public option to speed up the setup but now would like to make it private.


Solution

  • If the Mock has already be created as a Public Server, you can make it Private by editing the Mock from the Collection menu in the app.

    Once this has been changed to a Private Server, you should be able to call it only using the x-api-key token in the header.

    Postman

    More details can be found on the Postman Learning Center:

    https://learning.getpostman.com/docs/postman/mock-servers/setting-up-mock/#editing-mock-servers