문제

The goal is to use REST to pull content into a homegrown mobile app. I'm able to run simple API calls like this and get results:

https://xxx.sharepoint.com/sites/xxx/_api/web/lists/getbytitle('Site Pages')/items?$select=Title

But I can't figure out how to get the full content of news posts, which I believe is in a container named "CanvasContent" i.e title, author byline, first published date, body content, banner image thumbnail, etc.

도움이 되었습니까?

해결책 2

I had already tried @ganesh sanap's suggestion but it doesn't get the body content. Figured it out though - needed to add CanvasContent1 in the query so this works:

/_api/web/lists/getbytitle('Site%20Pages')/items?$select=Title,CanvasContent1,FileLeafRef

다른 팁

You can call the rest with this end point:

https://xxx.sharepoint.com/sites/xxx/_api/web/lists/getbytitle('Site Pages')/items

This will provide you with results of all information.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 sharepoint.stackexchange
scroll top