I\'m using Retrofit2 and RxJava2CallAdapterFactory.
RxJava2CallAdapterFactory
The API I consume returns status code always as 200 and for success and response JSON string the JSON st
You can simply do that by doing this
try { String error = response.errorBody().string(); error = error.replace("\"", ""); Toast.makeText(getContext(), error, Toast.LENGTH_LONG).show(); } catch (IOException e) { e.printStackTrace(); }