Skip to content

Latest commit

 

History

History
32 lines (20 loc) · 1 KB

asawebserver.rst

File metadata and controls

32 lines (20 loc) · 1 KB

Running Hoverfly as a webserver

Please carefully read through webserver alongside this tutorial to gain a high-level understanding of what we are about to cover.

Below is a complete example how to capture data with Hoverfly running as a proxy, and how to save it in a simulation file.

asawebserver.sh

Now we can use Hoverfly as a webserver in Simulate mode.

asawebserver.sh

Hoverfly returned a response to our request while running as a webserver, not as a proxy.

Notice that we issued a cURL command to http://localhost:8500/a/b instead of http://echo.jsontest.com/a/b. This is because when running as a webserver, Hoverfly strips the domain from the endpoint URL in the simulation.

This is explained in more detail in the webserver section.

Note

Hoverfly starts in Simulate mode by default.