-
Hello, My goal is to obtain the size metadata of all files within a Sharepoint site. I am using the SDK and here is my code so far:
The above code prints the drive id but it never enters the loop as records.value is empty (no Exceptions either). I am not actually interested in filtering but the API mandates a filter so I added something that looks benign. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Update: it seems that I need to generate a request similar to
However it is unclear how to do this in the SDK... |
Beta Was this translation helpful? Give feedback.
-
Answering my own question :-)) It seems that the RootRequestBuilder does not have the children property, but ItemRequestBuilder does.
where rootid is given by the following request builder:
P.S |
Beta Was this translation helpful? Give feedback.
Answering my own question :-))
It seems that the RootRequestBuilder does not have the children property, but ItemRequestBuilder does.
So the idea is to interact with the root via the the items resource:
records = await (client .drives .by_drive_id(driveid) .items .by_drive_item_id(rootid) .children .get() )
where rootid is given by the following request builder:
client.drives.by_drive_id(driveid).root
.P.S
Please let me know if there is a straightforward way to do it that I simply missed.