Wiremock
Run wiremock with a docker container
docker run -it --rm \
-p 8081:8080 \
--name wiremock \
wiremock/wiremock:2.32.0
Serve data
Serve JSON data for a GET
request http://localhost:8081/sample-get
:
curl -X POST \
--data '{ "request": { "url": "/sample-get", "method": "GET" }, "response": { "status": 200, "headers": { "Content-Type": "application/json" }, "jsonBody": [{ "prop": "value"}, { "prop": "value-2"}] }}' \
http://localhost:8081/__admin/mappings/new