I'm using JSoup to authenticate then connect to a website. Some URL have a JSON response (because part of the site is in AJAX). Can JSoup handle JSON response ?
Connection.Response doc = Jsoup.connect("...")
.data(...)
.cookie(...)
.header(...)
.method(Method.POST)
.execute();
String result = doc.body()
In my case body is "".
Is there JSoup like libraries for JSON ?
You can fetch JSON or other data format using this:
// JSON example
String json = Jsoup.connect(url).ignoreContentType(true).execute().body();