How can we add pagination in To-Do Task List(MS Graph REST APIs), as $skip isn't working?

Sonal Mehta 21 Reputation points
2020-12-21T14:19:04.257+00:00

Hello ,

I am using MS Graph API for todo task lists. (/me/todo/lists). In this case, query parameters like $skip, $count and $search aren't working. Can you please help me out, how can we get pagination done for todo task listing?

For more details:
REST (GET): https://graph.microsoft.com/v1.0/me/todo/lists?$skip=2

In response, getting all the records!
{
"@odata.context": "https://graph.microsoft.com/v1.0/$metadata#users('info@keyman .com')/todo/lists",
value[<<all the values>>]
}

Microsoft Security Microsoft Graph
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Sunitha Gowda 6 Reputation points Microsoft Employee
    2020-12-22T06:45:59.613+00:00

    Hi Sonal,
    If your goal is to apply filters/pagination on tasks in a list this should help -

    https://graph.microsoft.com/v1.0/me/todo/lists/[ListID]/tasks?$skip=2.

    if you are filtering tasklist since the $skip is not yet available for to do List api you can try - https://graph.microsoft.com/v1.0/me/todo/lists?$filter=startsWith(displayName,'M')

    in general for pagination please refer doc here - https://learn.microsoft.com/en-us/graph/query-parameters#filter-parameter

    Also, to enable $skip query param on to do lists please create a new ask here on user voice - https://microsoftgraph.uservoice.com/forums/920506-microsoft-graph-feature-requests?category_id=373861


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.