0

I would need a standalone server against which I can mock my REST endpoints. The requirements are: - needs to run standalone - needs to be able to respond with a specific response message based on the incoming request message

Would WireMock be the best tool for this type of mocking?

user1340582
  • 19,151
  • 35
  • 115
  • 171

1 Answers1

0

Yes, you can do it with WireMock as long as you know what the expected requests and responses should be. You will need to create several mappings (for each of the expected request/response pairs) and put a matcher for any unique element of each request so you can identify them apart.

In fact, with Wiremock 2.0 onwards, you can unmarshall the request into an object and perform all data manipulation / prepare the response dynamically from inside the class. I did it with Java.

Eugene A
  • 330
  • 4
  • 16