0

I have a list of users in parse.com

I need to retrieve some of these users, I had all of the necessary ids. For example I had 50 users stored in parse, but I only need 10.

With these 10 Ids I need to get the users.

I postman I do the next:

https://parseapi.back4app.com/users?where={"objectId":{"$in":["id01","id02","id03".."id10"]}}

And I get the data correctly.

How can I translate into a retrofit call? How I can do a "where" sentence in Retrofit?

Thanks for all.

Pablo Garcia
  • 361
  • 6
  • 23

1 Answers1

1

Try defining where as a URL parameter and setting {"objectId":{"$in":["id01","id02","id03".."id10"]}} as the value textInCurlyBrackets when using the retrofit call:

public interface FooService {

    @GET("https://parseapi.back4app.com/users")
    void getUsersByIDs(@Query("where") String textInCurlyBrackets, Callback<String> callback);
}

If you need further information this post may help you: Retrofit and GET using parameters

0xFEFFEFE
  • 120
  • 10