Skip to main content
Question

Transfer all contents to another user

  • May 22, 2025
  • 3 replies
  • 144 views

Forum|alt.badge.img

Hi,

We want to transfer all content to another user in box, then delete the user.

i read the API can transfer only root folder.

 

Thanks,

Amay

3 replies

Forum|alt.badge.img

Hello Amay, 

Having to pass folder ID 0 just means that the endpoint is going to transfer any owned content of the user to another user, but you will want to use this endpoint: https://developer.box.com/reference/put-users-id-folders-0/. This is necessary before deleting a user because otherwise any owned content is deleted with the user.

Best,

Kourtney, Box Developer Advocate


Forum|alt.badge.img

Thanks, i want to get userid to transfer the data using : how can i get it?

BoxFolder movedFolder = await client.UsersManager.MoveUserFolderAsync(sourceUserId, destinationUserId);

Forum|alt.badge.img

Please check out this guide on locating common values