Requestdiff – Send two HTTP requests and visualize any differences
1–10 of 36 posts
Re: Requestdiff – Send two HTTP requests and visualize any differences
#2Two questions:
1) What's the diff logic? At first glance, it looks like JSON is reformatted (maybe canonicalized in some way) and then a line-by-line diff is applied. Is there more to it? Since the tool seems JSON-aware, I was surprised to see an added trailing comma up as a difference.
2) Do you have plans to expand the kind of HTTP requests users can make? It would be nice to use different verbs, headers, and request bodies. Runscope has a similar tool[0] built in that I believe (haven't tried it yet) allows a bit more flexibility, but it would be nice to have a standalone tool available.
[0] http://blog.runscope.com/posts/comparing-http-requests-using...
Re: Requestdiff – Send two HTTP requests and visualize any differences
#3Re: Requestdiff – Send two HTTP requests and visualize any differences
#4This would be useful behind a firewall. Is the source available?
Re: Requestdiff – Send two HTTP requests and visualize any differences
#5https://blog.twitter.com/2015/diffy-testing-services-without...
Re: Requestdiff – Send two HTTP requests and visualize any differences
#6diff https://httpbin.org/get) https://httpbin.org/get?show_env=1)
Re: Requestdiff – Send two HTTP requests and visualize any differences
#7Seems like a useful tool; thanks for sharing it! Two questions: 1) What's the diff logic? At first glance, it looks like JSON is reformatted (maybe canonicalized in some way) and then a line-by-line diff is applied. Is there more to it? Since the tool seems JSON-aware, I was surprised to see an added trailing comma up as a difference. 2) Do you have plans to expand the kind of HTTP requests users can make? It would b…
1) the diff is really simple, line by line and text based. I'm just using this really awesome library to do it: https://github.com/kpdecker/jsdiff The JSON is just being pretty printed to be able to do a text diff in a meaningful way.
2) Yes, I do, and thanks for the suggestions! But I just wanted to go with the minimal version first and see if people found it useful.
I didn't know about Runscope's diffing feature. Btw, I'm using a HTTPBin for the sample requests, which is a Runscope project as far as I know :)
Re: Requestdiff – Send two HTTP requests and visualize any differences
#8(1) Terminal based
(2) Supported other types of HTTP requests
(3) Supported request body
(4) Allowed editing request headers
(5) Wasn't so easily exploitable to be used as a proxy or a DDoS relay (server-side bummer):
http://requestdiff.com/proxy?url1=https://www.amazon.com&url...
Re: Requestdiff – Send two HTTP requests and visualize any differences
#9For people wanting to have a CLI tool instead, John Graham-Cumming's httpdiff might be worth looking at. https://github.com/jgrahamc/httpdiff
Re: Requestdiff – Send two HTTP requests and visualize any differences
#10For command-line junkies: diff https://httpbin.org/get ) https://httpbin.org/get?show_env=1 )
diff -u https://httpbin.org/get) https://httpbin.org/get?show_env=1) | colordiff