Simple API mock using nc (or netcat)
- nc (or netcat)
- Create your
responsefile under directory that same with request path For example you want to create mock for GET /healthz Create fileresponseunderresponses/GET/healthz/folderresponsesis mandatory - Write you response HTTP inside your
responsefile For example to send simple 200 OK you can do thisHTTP/1.1 200 OK Content-type: text/html OK - Run your script
./wailea.sh - Access from port
1080curl localhost:1080/healthz -v