You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The data model IFile exposes the property ListId which is very useful but the data model IFolder doesn't.
I would like the IFolder data model to also expose the same property.
@BitRevenant had a quick check on that and is harder than it looks.
Under the hood we use _api/Web/GetFolderById(guid'...') endpoint which lets you retrieve a folder object by its unique folder GUID.
However, the folder object itself does not directly contain the List ID and you need to query its ParentList property to get that.
I think that is one of the reasons the Β Folder.GetLibraryIdFromFolderAsync() method exists. Are you by any chance already using it?
Hello @Adam-it, thanks for replying me.
I tried the method what you wrote in your message called GetLibraryIdFromFolderAsync, however, this does not exist in the interface IFolder. Where can I access it? Thank you.
@BitRevenant sorry for that, just noticed it is an internal, not exposed as public π€¦ββοΈπ€¦ββοΈπ€¦ββοΈ.
In this case there is currently now easy workaround for that π«€. Will research this more in coming days and bring this up with the rest of the maintainers. Definitely a 'pain' that is worth fixing up
Activity
Adam-it commentedon Sep 23, 2026
@BitRevenant had a quick check on that and is harder than it looks.
Under the hood we use
_api/Web/GetFolderById(guid'...')endpoint which lets you retrieve a folder object by its unique folder GUID.However, the folder object itself does not directly contain the List ID and you need to query its ParentList property to get that.
I think that is one of the reasons the
Β Folder.GetLibraryIdFromFolderAsync()method exists. Are you by any chance already using it?BitRevenant commentedon Sep 25, 2026
Hello @Adam-it, thanks for replying me.
I tried the method what you wrote in your message called
GetLibraryIdFromFolderAsync, however, this does not exist in the interfaceIFolder. Where can I access it? Thank you.Adam-it commentedon Sep 25, 2026
@BitRevenant sorry for that, just noticed it is an internal, not exposed as public π€¦ββοΈπ€¦ββοΈπ€¦ββοΈ.
In this case there is currently now easy workaround for that π«€. Will research this more in coming days and bring this up with the rest of the maintainers. Definitely a 'pain' that is worth fixing up
mgwojciech commentedon Oct 10, 2026
Added the work-around. I don't think we would risk anything with that change ;)