I am new using python library shareplum. I have a sharepoint site with list named "Events". Inside that list there is a list item which is a folder with list items inside (EventsXXXX). I manage to update the Events list with a new item but I do not know how to move this item to EventsXXXX.
This is a snippet of my code:
user, password = 'xxxxx', 'xxxxxx'
auth = HttpNtlmAuth('yyyyyyy\\'+user, password)
site = Site('https://yyyyyyy/lib/zzzzz', version=Version.v2016, auth=auth)
folder = 'https://yyyyyyy/lib/zzzzz/Lists/Events/EventsXXXX'
sp_list = site.List('Events')
task_list = [{'Content Type': ......}]
sp_list.UpdateListItems(task_list, 'New', False)
The result is for Events list:
ID Title Project Fields
9928 XXXXXX1 YYYYY ZZZZZ
1525 EventsXXXX YYYYY KKKKK --> this is an list item but it is a folder containing list items
as ID 9928
Errors produced:
- I cannot access EventsXXXX using
sp_folder = site.Folder(folder)
Shareplum HTTP Post Failed : 401 Client Error: Unauthorized for url: https://xxxx/lib/xxxxx/_api/web/folders
- EventsXXXX is not recognised when doing
sp_list2 = site.List(folder)
Shareplum HTTP Post Failed : 500 Server Error: Internal Server Error for url: https://xxxx/lib/xxxx/_vti_bin/lists.asmx
I would appreciate any help to explain how to move item ID 9928 into the folder 1525 or how to save item ID 9928 into folder 1525, considering the above errors.