0

I have 5 subsites (Sub1,Sub2,Sub3,Sub4,Sub5) and all subsites is having Document library name (PublishedDocuments)

Sub1 - PublishedDocuments
Sub2 - PublishedDocuments
Sub3 - PublishedDocuments
Sub4 - PublishedDocuments
Sub5 - PublishedDocuments

how to fetch documents from PublishedDocuments library from all Subsite using rest-api , i have to create UI to show all documents in SPFX ,unable to write api to get all subsites and inside library

https://<siteurl>/<subsite>/_api/web/lists/getbytitle('PublishedDocuments')/items

1 Answer 1

1

There is no such rest api to get all items from all subsites. You have to loop through the 5 subsites in SPFX, then get all items in each subsite.

1
  • Thanks , i am able to loop in my code and get items .
    – kumar
    Jul 29, 2020 at 7:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.