Forum Discussion
rohanw24
Feb 16, 2021Brass Contributor
Project Online ReST API fetch recently updated tasks, assignments
Hello Everyone, I want to fetch recently updated tasks, assignments from Project Online. Currently I've included a filter to fetch projects and related tasks, assignments by published date time. ...
Paul_Mather
Feb 17, 2021MVP
Hello rohanw24,
Can you used the created date to filter out newly created projects / tasks / assignments?
Paul
rohanw24
Feb 27, 2021Brass Contributor
Hi Paul Mather,
While filtering projects I'm using this API uri:
https://example.sharepoint.com/sites/pwa/_api/ProjectServer/Projects?$filter=lastSavedDate gt $DateCriteria&isCheckedOut=true
$DateCriteria will contain timestamp when the application was successfully executed. So that it will consider only those projects that were saved after provided $DateCriteria and which are checked out. Could you please let me know your thoughts on this logic?
Thanks & Regards,
Rohan
- Paul_MatherFeb 27, 2021MVP
Hi rohanw24 ,
I think you will still get newly created data but the best way to see if the logic is correct is to test every single scenario in Project Online and executing your application.
Paul
- rohanw24Mar 04, 2021Brass Contributor
Hi Paul_Mather ,
I've changed my filter criteria to:
https://example.sharepoint.com/sites/pwa/_api/ProjectServer/Projects?$filter=CreatedDate lt datetime'$dateCriteria'&LastPublishedDate gt datetime'$dateCriteria'