Skip to main content
Question

Download items from shared url with view tag in C# Not found error

  • May 23, 2025
  • 1 reply
  • 13 views

Forum|alt.badge.img

I received a link that I want to programmatically download the contents of, but for some reason, when I want to access the contents of the folder, I get this error:
BoxAPIException: The API returned an error [NotFound | xg49mhaymb3cmd9.0803f2ebec24b4ce18be5c7bca9f342e1] not_found - Not Found

The link I received is also strange:
https://samchully.app.box.com/v/Europe000000

What could be causing this?

The example code is as follows:

                IBoxConfig config = null;
                using (FileStream fs = new FileStream("980952769_tidv16ck_config.json", FileMode.Open))
                {
                    config = BoxConfig.CreateFromJsonFile(fs);
                }

                var sdk = new BoxJWTAuth(config);
                //USER Token auth //
                //var userToken = await sdk.UserTokenAsync(userId); //valid for 60 minutes so should be cached and re-used
                //BoxClient appUserClient = sdk.UserClient(userToken, userId);


                //ADMIN Token auth//
                string adminToken = await sdk.AdminTokenAsync();
                BoxClient appUserClient = sdk.AdminClient(adminToken);

 


                string webLinkUrl = "https://samchully.app.box.com/v/Europe000000";
                var user = appUserClient.UsersManager.GetCurrentUserInformationAsync().Result;
                Console.WriteLine($"User: {user.Id}:{user.Name}");

                var items = appUserClient.SharedItemsManager.SharedItemsAsync(webLinkUrl,null).Result;
                Console.WriteLine($"Shared Folder: {items.Id}:{items.Name}");
                Console.WriteLine("#".PadLeft(80, '#'));
                var folderitems = appUserClient.FoldersManager.GetFolderItemsAsync(items.Id, 5000).Result;

1 reply

Forum|alt.badge.img

Hi there, 

Welcome to the Box Community!

For API related concern, please refer to this article: https://developer.box.com/reference/

Thanks!