Add group to space

  • 26 January 2019
  • 2 replies

I see there are some conversations around Add a group to access a Space via API. I have read the article: Manage Space Access with the API. But unfortunately it doesn’t help me.

I create a space “Joe Test” with a parent of Shared. I have a group “Joe Test Group” which is the only group that should have access to “Joe Test”. I try using the API create_content_metadata_access but I receive this error:

“Can’t add access when inheriting”

How do I create my space initially so my “Joe Test Group” has sole access (Yes, I understand Admins will see all). How do I stop inheritance and add my 1 group.


2 replies

Sorry to answer my own question… but I found the answer to be that I needed to remove inheritance from the content_metadata. By calling update_content_metadata(:id, {inherits: false}), i was then able to call create_content_metadata_access( . . ) and it was able to update access to just my group.

Here’s where Joe found and gave his solution, for everyone else!