1

I'm using retrofit in my project, and I've made a GSON object for the response. But the object only contains nulls.

UserRespomse.java

package model;

import com.google.gson.annotations.SerializedName;

public class UserResponse {
    @SerializedName("status") private int mStatus;
    @SerializedName("details") private User mUser;
    @SerializedName("reason") private String mReason;

    public int getStatus() {
        return mStatus;
    }

    public User getUser() {
        return mUser;
    }

    public String getReason() {
        return mReason;
    }
}

UsersService.java

@GET("/users/{email}/auth/{password}")
void login(@Path(value="email", encode = false) String email, @Path("password") String password,
        Callback<UserResponse> callback);

The JSON returned

{"status":200,"details":{"id":1,"email":"orelzion@gmail.com","first_name":"Orel","last_name":"Zion","password":"$2a$10$eHAs0nh0XPsle3ZntjpMYucboMBGcwWpC0mrsNUuBClWXWTUR41w2","created_at":"2014-11-10T08:56:34-05:00","updated_at":"2014-11-10T08:58:01-05:00","facebook_token":null,"facebook_token_updated_at":null,"user_key":"9e38432ec505e1461efe3277ee57bc9025d50270","apps":[],"url":"/users/1"},"reason":""}

What could be the reason, or how can I see the GSON logs?

Thanks

orelzion
  • 2,452
  • 4
  • 30
  • 46

0 Answers0