편집

다음을 통해 공유


Update retentionLabel

Namespace: microsoft.graph.security

Update the properties of a retentionLabel object.

To update a disposition review stage, include the actionAfterRetentionPeriod property in the request body with one of the possible values specified.

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) RecordsManagement.ReadWrite.All Not available.
Delegated (personal Microsoft account) Not supported. Not supported.
Application Not supported. Not supported.

HTTP request

PATCH /security/labels/retentionLabels/{retentionLabelId}

Request headers

Name Description
Authorization Bearer {token}. Required. Learn more about authentication and authorization.
Content-Type application/json. Required.

Request body

In the request body, supply only the values for properties to update. Existing properties that aren't included in the request body maintain their previous values or are recalculated based on changes to other property values.

The following table specifies the properties that can be updated.

Property Type Description
descriptionForAdmins String This is an optional property that provides the label information for the admin.
descriptionForUsers String This is an optional property that provides the label information for the user.
dispositionReviewStages microsoft.graph.security.dispositionReviewStage collection Review stages during which reviewers are notified to determine whether a document must be deleted or retained.
retentionDuration microsoft.graph.security.retentionDuration Specifies the number of days to retain the content.
defaultRecordBehavior microsoft.graph.security.defaultRecordBehavior Specifies the locked or unlocked state of a record label when it is created. The possible values are: startLocked, startUnlocked, unknownFutureValue.
labelToBeApplied String Specifies the replacement label to be applied automatically after the retention period of the current label ends.

Response

If successful, this method returns a 204 No Content response code.

Examples

Request

Here's an example of a request.

PATCH https://graph.microsoft.com/beta/security/labels/retentionLabels/9563a605-e827-4324-a5a9-09efddff1e50
Content-Type: application/json
Content-length: 555

{
  "@odata.type": "#microsoft.graph.security.retentionLabel",
  "retentionDuration": {
    "@odata.type": "microsoft.graph.security.retentionDurationInDays",
    "days": 2555
  },
}

Response

Here's an example of the response.

HTTP/1.1 204 No Content