One of the following permissions is required to call this API. To learn more, including how to choose permissions, see Permissions.
Permission type
Permissions (from least to most privileged)
Delegated (work or school account)
ServiceMessageViewpoint.Write
Delegated (personal Microsoft account)
Not supported.
Application
Not supported
HTTP request
POST /admin/serviceAnnouncement/messages/markRead
Request headers
Name
Description
Authorization
Bearer {token}. Required.
Content-Type
application/json. Required.
Request body
In the request body, supply a JSON representation of the parameters.
The following table shows the parameters that can be used with this action.
Parameter
Type
Description
messageIds
String collection
List of message IDs to mark as read.
Response
If successful, this action returns a 200 OK response code and a Boolean value true in the response body. Otherwise, will return false in the response body.
POST https://graph.microsoft.com/v1.0/admin/serviceAnnouncement/messages/markRead
Content-Type: application/json
{
"messageIds": ["MC172851", "MC167983"]
}
var graphClient = new GraphServiceClient(requestAdapter);
var requestBody = new Microsoft.Graph.Admin.ServiceAnnouncement.Messages.MarkRead.MarkReadPostRequestBody
{
MessageIds = new List<string>
{
"MC172851",
"MC167983",
},
};
var result = await graphClient.Admin.ServiceAnnouncement.Messages.MarkRead.PostAsync(requestBody);
<?php
// THIS SNIPPET IS A PREVIEW FOR THE KIOTA BASED SDK. NON-PRODUCTION USE ONLY
$graphServiceClient = new GraphServiceClient($requestAdapter);
$requestBody = new MarkReadPostRequestBody();
$requestBody->setMessageIds(['MC172851', 'MC167983', ]);
$requestResult = $graphServiceClient->admin()->serviceAnnouncement()->messages()->markRead()->post($requestBody);