Muokkaa

Jaa


Unfollow drive item

Namespace: microsoft.graph

Unfollow a driveItem.

Note: To follow an item, see Follow Item.

This API is available in the following national cloud deployments.

Global service US Government L4 US Government L5 (DOD) China operated by 21Vianet

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.

Permission type Least privileged permissions Higher privileged permissions
Delegated (work or school account) Files.Read Files.Read.All, Files.ReadWrite, Files.ReadWrite.All, Sites.Read.All, Sites.ReadWrite.All
Delegated (personal Microsoft account) Not supported. Not supported.
Application Files.Read.All Files.ReadWrite.All, Sites.Read.All, Sites.ReadWrite.All

HTTP request

DELETE /me/drive/following/{item-id}
DELETE /users/{user-id}/drive/following/{item-id}
POST /me/drive/items/{item-id}/unfollow
POST /users/{user-id}/drive/items/{item-id}/unfollow

Request headers

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

Request body

No request body is required.

Response

If successful, the API call returns a 204 No Content. It doesn't return anything in the response body.

Example

Request

The following example shows a request. This example unfollows an item identified by {item-id}.

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

Response

HTTP/1.1 204 No Content