Retrofit 2.0 java.lang.IllegalStateException: Expected BEGIN_ARRAY but was STRING Retrofit 2.0 java.lang.IllegalStateException: Expected BEGIN_ARRAY but was STRING json json

Retrofit 2.0 java.lang.IllegalStateException: Expected BEGIN_ARRAY but was STRING


EDIT: this answer is not valid for Retrofit 2+.
See what's new in Retrofit 2: http://inthecheesefactory.com/blog/retrofit-2.0/.


It may not help you in this case, but I've encountered the very same problem in one of my projects and the solution was to set the JSON converter to a custom instance of Gson.

Add this to your Retrofit.Builder:

.setConverter(new GsonConverter(new Gson()))


EDIT: it may conflict with addConverterFactory(). Unless you need it and know why, I'd take it out.


As Pankaj Kumar supposed - char[] iso is the problem. Changing type to String solved it!