A lightweight proxy server with URL-based replacement.
go get github.com/pranavraja/replaceproxy
$GOPATH/bin is in your
replaceproxy [-repl url_prefix -with file_or_url]
Start a proxy server on
0.0.0.0:8080. Log each response to stdout, color-coded by status.
replaceproxy -repl http://google.com -with http://myotherserver.com/google.txt
Replace all requests under the google.com domain with the response from myotherserver.com/google.txt. Preserve headers and status code of the original response.
replaceproxy -repl http://myapi.com/user/1/feeds -with feeds.json
Replace requests to myapi.com/user/1/feeds with the canned response stored in feeds.json. Preserve headers and status code of the original response.