Two ways depending on your needs:
Quick and dirty way which might actually be useful/good enough/good performance:
String jsonString = ...
jsonString.contains("\"response\": null");
Yes, it's error prone if the server changes anything, even line breaks etc. But it will be using a lot less resources.
Variations with higher tolerance include regexp that simply allow zero or multiple whitespace between field name and value. Another variant is to find the index of the field and look for the value after that manually:
int fieldIndex = jsonString.indexOf("\"response\":");
//left as an exercise...
Json parsing with a library, such as Gson (Google's json library):
Simple minimum Results class:
public static class Result {
public static class Results {
public String response;
}
public Results results;
}
Parse and check (ignoring null and length check of array):
Gson gson = new Gson();
Result[] results = gson.fromJson(jsonString, Result[].class);
System.out.println(results[0].results.response);
Gson can be found here:
https://github.com/google/gson