Start a new topic

Issue resolving KinveyRef of Users collection

I have a collection for which each document includes a reference to documents from the (default) users collection, i.e. my documents look like:



{ _id : XXXX, ..., user : { "_type": "KinveyRef", "_id": YYYY, "_collection": "users" }, ...}





Now when I query this collection and try to resolve user data with a GET like:



GET /appdata/:appKey/:collectionName/:id?resolve=user HTTP/1.1

Host: baas.kinvey.com

Authorization: [user credentials]





I do get expected results (and I am able to resolve other collections without any issue), but the user related data does not get resolved, i.e. I get _obj:null even though corresponding ids do exist in my Users collection:



{ _id : XXXX, ..., user : { "_type": "KinveyRef", "_id": YYYY, "_collection": "users", "_obj": null }, ...}





Is there any special rule that forbids resolving data from the Users collection ? (like because it could contain sensitive data like email, social identity etc if not hidden with some collection hook).



1 Comment

Hi Nicolas, the Users collection is actually named "user" behind the scenes. If you change your reference to refer to this collection instead of "users", it should be properly resolved.
Login or Signup to post a comment