Start a new topic

Business Logic - How to set _acl.creator value manually?

I'm creating an entity from a business logic custom endpoint. I create a JSON object, then call "modules.utils.kinveyEntity(object)" to set the metadata properties. I then overwrite the "_acl.creator" property with the desired user's "_id" property value.

When I look in the data store, the "_acl.creator" property appears to have been set correctly, however, when I query the data store (which is set to Private) as the target user, the new object is not returned.

Is this the wrong way to overwrite the creator value? Is there another way to do it from the business logic?
1 Comment


I had the same issue: \_id is stored as BSON while \_acl.creator is a string. You have to overwrite object.\_acl.creator with your user's \_acl.creator property value.
Login or Signup to post a comment