Postman Mock Servers (Request Forwarding)

Iā€™ve just started using Mock servers with Postman. I was wondering if they also support request forwarding or do we just have ā€œstandardā€ request + response set up only?

I couldnā€™t find any information regarding request forwarding in the documentation for mock servers or by searching about it online.

Hi @docking-module-mete7 :wave:
If itā€™s about handling responses based on requests, you can use x-mock-response-name, Iā€™ll leave a part of the documentation that talks a little more about it:

I hope it helped you :slightly_smiling_face:

1 Like

@cmnazario Hi Cris, thank you for responding! Unfortunately, thatā€™s not quite what I am looking for. I wanted to know if it is possible to configure the Mock server so that we have the option to forward the request to another server (potentially a mocked one) and then return the response back. So, if there was a way to configure one of the requests to be forwarded rather than return the saved example body, that would be awesome.

@docking-module-mete7 hi you could add a pre-request to check if the request is ā€˜somethingā€™ and change pm.request.url to be someother mock url instead of the one you using

1 Like