Skip to main content
Question

Delete Collaboration_ID using API - is that per item (folder/file)

  • May 22, 2025
  • 2 replies
  • 30 views

Forum|alt.badge.img

Good day,

each Box User has a unique Collaboration_ID.

As per my understanding, Collaboration_ID parameter is the input parameter when using API to delete collaboration

                      client.collaboration(collaboration_id).delete()

Will deleted Collaboration_ID be removed from all Box objects (Folders and Files)?

Asking as Box file_id or folder_id is not an input parameter to the delete Collaboration_ID API call. Or perhaps I have to run another API command to "select file_id / folder_id" before deleting Collaboration_ID.

Kind regards,

Marin

2 replies

Forum|alt.badge.img

Marin, 

There is an individual collaboration ID for each piece of content. For example, if I am a collaborator on Folder A and Folder B, I will have two collaboration IDs. Therefore, to answer your original question, no deleting a collaboration_ID will not remove the user from all content they are collaborated on. 

Best,

Kourtney, Box Developer Advocate


Forum|alt.badge.img

Hi Kourtney,

thank you for your reply!

Could you please confirm which response field contains the collaboration_ID of the box_item (file/folder)?

It seems I'm retrieving the incorrect response field "collab.id":

----------------

collaborations = client.file(box_item_id).get_collaborations()

for collab in collaborations:
      user_name = str(collab.accessible_by)
      collaboration_id = collab.id

-------------

Kind regards,

Marin