APIs under the /beta version in Microsoft Graph are subject to change. Use of these APIs in production applications is not supported. To determine whether an API is available in v1.0, use the Version selector.
Forward a message, add a comment or modify any updateable properties
all in one forward call. The message is saved in the Sent Items folder.
Alternatively, you can first create a draft forward message to include a comment or update any message properties,
and then send the draft message.
Note
You can specify either a comment or the body property of the message parameter. Specifying both will return an HTTP 400 Bad Request error.
You must specify either the toRecipients parameter or the toRecipients property of the message parameter. Specifying both or specifying
neither will return an HTTP 400 Bad Request error.
Permissions
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)
Mail.Send
Delegated (personal Microsoft account)
Mail.Send
Application
Mail.Send
HTTP request
POST /me/messages/{id}/forward
POST /users/{id | userPrincipalName}/messages/{id}/forward
POST /me/mailFolders/{id}/messages/{id}/forward
POST /users/{id | userPrincipalName}/mailFolders/{id}/messages/{id}/forward
Request headers
Name
Type
Description
Authorization
string
Bearer {token}. Required.
Content-Type
string
Nature of the data in the body of an entity. Required.
Request body
In the request body, provide a JSON object with the following parameters.
POST https://graph.microsoft.com/beta/me/messages/AAMkADA1MTAAAH5JaLAAA=/forward
Content-Type: application/json
{
"message":{
"isDeliveryReceiptRequested": true,
"toRecipients":[
{
"emailAddress": {
"address":"danas@contoso.onmicrosoft.com",
"name":"Dana Swope"
}
}
]
},
"comment": "Dana, just want to make sure you get this."
}
GraphServiceClient graphClient = new GraphServiceClient( authProvider );
var message = new Message
{
IsDeliveryReceiptRequested = true,
ToRecipients = new List<Recipient>()
{
new Recipient
{
EmailAddress = new EmailAddress
{
Address = "danas@contoso.onmicrosoft.com",
Name = "Dana Swope"
}
}
}
};
var comment = "Dana, just want to make sure you get this.";
await graphClient.Me.Messages["AAMkADA1MTAAAH5JaLAAA="]
.Forward(null,message,comment)
.Request()
.PostAsync();
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
const options = {
authProvider,
};
const client = Client.init(options);
const forward = {
message:{
isDeliveryReceiptRequested: true,
toRecipients:[
{
emailAddress: {
address:"danas@contoso.onmicrosoft.com",
name:"Dana Swope"
}
}
]
},
comment: "Dana, just want to make sure you get this."
};
let res = await client.api('/me/messages/AAMkADA1MTAAAH5JaLAAA=/forward')
.version('beta')
.post(forward);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
IGraphServiceClient graphClient = GraphServiceClient.builder().authenticationProvider( authProvider ).buildClient();
Message message = new Message();
message.isDeliveryReceiptRequested = true;
LinkedList<Recipient> toRecipientsList = new LinkedList<Recipient>();
Recipient toRecipients = new Recipient();
EmailAddress emailAddress = new EmailAddress();
emailAddress.address = "danas@contoso.onmicrosoft.com";
emailAddress.name = "Dana Swope";
toRecipients.emailAddress = emailAddress;
toRecipientsList.add(toRecipients);
message.toRecipients = toRecipientsList;
String comment = "Dana, just want to make sure you get this.";
graphClient.me().messages("AAMkADA1MTAAAH5JaLAAA=")
.forward(null,message,comment)
.buildRequest()
.post();
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.