Skip to content

Latest commit

 

History

History
144 lines (118 loc) · 6.79 KB

File metadata and controls

144 lines (118 loc) · 6.79 KB
title baseTask: delta
description Get a set of baseTask resources that have been added, deleted, or updated in a specific baseTaskList.
author devindrajit
ms.localizationpriority medium
ms.subservice outlook
doc_type apiPageType
ms.date 06/22/2024

baseTask: delta (deprecated)

Namespace: microsoft.graph

[!INCLUDE beta-disclaimer]

[!INCLUDE todo-deprecate-basetaskapi]

Get a set of baseTask resources that have been added, deleted, or updated in a specific baseTaskList.

A delta function call for baseTask resources in a baseTaskList is similar to a GET request, except that by appropriately applying state tokens in one or more of these calls, you can query for incremental changes in the baseTask in that baseTaskList. This allows you to maintain and synchronize a local store of a user's baseTask resources without having to fetch the entire set from the server every time.

Permissions

Choose the permission or permissions marked as least privileged for this API. Use a higher privileged permission or permissions only if your app requires it. For details about delegated and application permissions, see Permission types. To learn more about these permissions, see the permissions reference.

[!INCLUDE permissions-table]

HTTP request

GET /me/tasks/lists/{baseTaskListId}/tasks/delta
GET /users/{userId|userPrincipalName}/tasks/lists/{baseTaskListId}/tasks/delta

Query parameters

Tracking changes in a baseTask collection incurs a round of one or more delta function calls. If you use any query parameter (other than $deltatoken and $skiptoken), you must specify it in the initial delta request. Microsoft Graph automatically encodes any specified parameters into the token portion of the @odata.nextLink or @odata.deltaLink URL provided in the response. You only need to specify any desired query parameters once upfront. In subsequent requests, simply copy and apply the @odata.nextLink or @odata.deltaLink URL from the previous response, as that URL already includes the encoded, desired parameters.

Query parameter Type Description
$deltatoken string A state token returned in the @odata.deltaLink URL of the previous delta function call for the same baseTask collection, indicating the completion of that round of change tracking. Save and apply the entire @odata.deltaLink URL including this token in the first request of the next round of change tracking for that collection.
$skiptoken string A state token returned in the @odata.nextLink URL of the previous delta function call, indicating there are further changes to be tracked in the same baseTask collection.

OData query parameters

  • Delta query support $filter $top, and $expand query parameters for baseTask.
  • There is no support for $search.

Request headers

Name Type Description
Authorization string Bearer {token}. Required. Learn more about authentication and authorization.
Prefer string odata.maxpagesize={x}. Optional.

Request body

Don't supply a request body for this method.

Response

If successful, this function returns a 200 OK response code and a baseTask collection in the response body.

Examples

Request

GET https://graph.microsoft.com/beta/me/tasks/lists/AAMkAGVjMzJmMWZjLTgyYjgtNGIyNi1hOGQ0LWRjMjNmMGRmOWNiYQAuAAAAAAAboFsPFj7gQpLAt-6oC2JgAQCQ47jE5P--SoVECqTdM17RAAAB4mDIAAA=/tasks/delta

[!INCLUDE sample-code] [!INCLUDE sdk-documentation]


Response

Note: The response object shown here might be shortened for readability.

HTTP/1.1 200 OK
Content-Type: application/json

{
    "@odata.context": "https://graph.microsoft.com/beta/$metadata#Collection(baseTask)",
    "@odata.deltaLink": "https://graph.microsoft.com/beta/me/tasks/lists/AAMkAGVjMzJmMWZjLTgyYjgtNGIyNi1hOGQ0LWRjMjNmMGRmOWNiYQAuAAAAAAAboFsPFj7gQpLAt-6oC2JgAQCQ47jE5P--SoVECqTdM17RAAAB4mDIAAA=/tasks/delta?$deltatoken=AVCnFFj2r7PtnjtkD-g_6dgDSPbEboZhaMYEytpd57pcJMrR9oGkCIjK_dyVkhNB1EQn1zcQt7YZTwCS0V5MNQo6Iy0-T0csAkLZTMlbiII.lVEHqD5xdDrH30csYKP6tEvoYa3WtFhmYLtKBSxCPpQ",
    "value": [
        {
            "@odata.type": "#microsoft.graph.task",
            "@odata.etag": "W/\"kOO4xOT//0qFRAqk3TNe0QAAAymRBQ==\"",
            "importance": "normal",
            "status": "notStarted",
            "displayName": "Read documentation",
            "createdDateTime": "2021-11-15T13:16:53.0831814Z",
            "lastModifiedDateTime": "2021-11-15T13:17:08.8273666Z",
            "id": "AAkALgAAAAAAHYQDEapmEc2byACqAC-EWg0AkOO4xOT--0qFRAqk3TNe0QAAAy35RwAA",
            "body": {
                "content": "",
                "contentType": "text"
            },
            "parentList": {
                "id": "AAMkAGVjMzJmMWZjLTgyYjgtNGIyNi1hOGQ0LWRjMjNmMGRmOWNiYQAuAAAAAAAboFsPFj7gQpLAt-6oC2JgAQCQ47jE5P--SoVECqTdM17RAAAB4mDIAAA="
            }
        }
    ]
}