How to create a private system entity from cloud code?
-
I want to create a private system entity. I can do it using the portal with "ACL: Private".
However, from Cloud Code (S2S) I cannot manage to do it:
This creates a public system entity:
createSystemEntity(entityType, timeToLive, null, data)This raises an error:
createSystemEntity(entityType, timeToLive, { "other": 0 }, data){ "reason_code": 40564, "status_message": "Processing exception: ACL must be readable", "status": 400 }This workaround does the job in two API calls:
createSystemEntity(entityType, timeToLive, { "other": 1 }, data) -> creates a public system entity
updateSystemEntityAcl(createResult.data.entityId, -1, { other: 0 }) -> makes the entity privateIf I can update the entity to make it private I should be able to create it as private.
Is there a way to do do it in the creation call?
Tnx
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login