Hi @Metallkiller, welcome to the forum.
Following up on this thread, looks like Kuleuven might have updated their security settings, and I was able to come up with a python script, as an example, that will download each file:
"""demo to download files from a box web link"""
import os
from boxsdk import JWTAuth, Client
def main():
auth = JWTAuth.from_settings_file('.jwt.config.json')
auth.authenticate_instance()
client = Client(auth)
web_link_url = "https://kuleuven.app.box.com/s/dyo66et36l2lqvl19i9i7p66761sy0s6"
user = client.user().get()
print(f"User: {user.id}:{user.name}")
shared_folder = client.get_shared_item(web_link_url,'' )
print(f"Shared Folder: {shared_folder.id}:{shared_folder.name}")
print("#" * 80)
print("Type\tID\t\tName")
os.chdir('downloads')
items = shared_folder.get_items()
download_items(items)
os.chdir('..')
def download_items(items):
for item in items:
if item.type == 'folder':
os.mkdir(item.name)
os.chdir(item.name)
download_items(item.get_items())
os.chdir('..')
if item.type == 'file':
print(f"{item.type}\t{item.id}\t{item.name}",end='')
with open(item.name,'wb') as download_file:
item.download_to(download_file)
print("\tdone")
if __name__ == "__main__":
main()
print("Done")
Which resulted in:
User: 20344589936:UI-Elements-Sample
Shared Folder: 44028703597:Fall_Simulation_Data
Type ID Name
file 261422972029 ADL10_Cam1.avi done
file 261425259417 ADL10_Cam2.avi done
file 261426893160 ADL10_Cam3.avi done
file 261427013993 ADL10_Cam4.avi done
file 261428355921 ADL10_Cam5.avi done
file 261432107784 ADL11_Cam1.avi done
file 261432109936 ADL11_Cam2.avi
Due to the number of files, you’ll probably need to adapt the script to check if the file has already been completely downloaded, just in case it fails or you want to do this in chunks.
Let us know if this helps.
I was using the classic Python SDK and JWT authorization.
Cheers