I want to pass the runtime of several parameters in the post-cleanup method for my Android project. Below is my url
http://myservice.com/home/MobileAPI/MobAPI.svc/LoginCriteria/26/address/1/permenant
Here I use the base URL as: http://myservice.com/home/MobileAPI/MobAPI.svc
I want to pass 'address' and 'permenant' at runtime in my GET method using Retrofit.
I am trying to do it like:
@GET("LoginCriteria/26/{address}/1/{permenant}") void getDetails(@Path("address") String address,@Path("permenant") String permenant, Callback<AddressParser> parserCallback);
Here is my JSON answer:
{ "response": { "type": "success", "data": { "datalist": { "total": "20", "user": [ { "empcode": "", "companycode": "", "companyname": "" }, { "empcode": "", "companycode": "", "companyname": "" } ] } } } }
I get the following execution:
Internal error com.fasterxml.jackson.databind.JsonMappingException: Unable to deserialize java.util.ArrayList instance from START_OBJECT.
If I execute only one parameter at runtime, it works. It does not work for several @Path parameters. Any suggestion would be greatly appreciated.
source share