Skip to content

Latest commit

 

History

History
124 lines (88 loc) · 3.78 KB

File metadata and controls

124 lines (88 loc) · 3.78 KB
author learafa
description Follow a driveItem.
title Follow drive item
ms.localizationpriority medium
ms.subservice sharepoint
doc_type apiPageType
ms.date 04/04/2024

Follow drive item

Namespace: microsoft.graph

Follow a driveItem.

Note: To unfollow an item, see Unfollow item.

[!INCLUDE national-cloud-support]

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

POST /drives/{drive-id}/items/{item-id}/follow
POST /groups/{group-id}/drive/items/{item-id}/follow
POST /me/drive/items/{item-id}/follow
POST /sites/{site-id}/drive/items/{item-id}/follow
POST /users/{user-id}/drive/items/{item-id}/follow

Request headers

Name Description
Authorization Bearer {token}. Required. Learn more about authentication and authorization.

Request body

No request body is required.

Response

This method returns a DriveItem for the item being followed.

Example

Request

This example follows an item identified by {item-id}.

POST https://graph.microsoft.com/v1.0/me/drive/items/{item-id}/follow

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

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

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

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

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

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

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


Response

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

{
  "id": "1312abc!1231",
  "name": "March Proposal.docx",
  "size": 19121,
  "lastModifiedDateTime": "2017-12-12T10:40:59Z"
}