Share via

message: createForward cannot trigger ccRecipients?

Alicia Quah Wei Ling 0 Reputation points
2024-11-26T12:03:04.85+00:00

my body input contains ccRecipients, but why output does not have?
i am using message:createForward

My input

{
  "receivedDateTime": "datetime-value",
  "sentDateTime": "datetime-value",
  "hasAttachments": true,
  "subject": "subject-value",
  "body": {
    "contentType": "",
    "content": "content-value"
  },
    "toRecipients":[
        {
            "emailAddress":{
                "address":"******@email.com"
            }
        }
    ],
    "ccRecipients":[
        {
            "emailAddress":{
                "address":"******@email.com"
            }
        },
        {
            "emailAddress":{
                "address":"******@email.com"
            }
        },
        {
            "emailAddress":{
                "address":"******@email.com"
            }
        }
    ],
  "comment": "<p>Hi aaa, </p></br><p>Approved, please help to attend this request.</p>",
  "bodyPreview": "bodyPreview-value"
}

This is my output:

{
  [my body content]
 
  },
  "sender": {
    "emailAddress": {
      "name": "Alicia Quah Wei Ling",
      "address": "******@email.com"
    }
  },
  "from": {
    "emailAddress": {
      "name": "Alicia Quah Wei Ling",
      "address": "******@email.com"
    }
  },
  "toRecipients": [
    {
      "emailAddress": {
        "name": "aaaaa",
        "address": "******@email.com"
      }
    }
  ],
  "ccRecipients": [],
  "bccRecipients": [],
  "replyTo": [],
  "flag": {
    "flagStatus": "notFlagged"
  }
}
Microsoft Security | Microsoft Graph
0 comments No comments

1 answer

Sort by: Most helpful
  1. Anonymous
    2024-11-27T01:55:16.9366667+00:00

    Hello Alicia Quah Wei Ling,

    Thank you for reaching out to Microsoft Support!

    According to the documentation, when calling the createForward endpoint, this method does not need to provide the request body (except in MIME format), so the request body provided when we use JSON format will not work.

    User's image

    To work around this, you can call the Update message endpoint to modify the value of the ccRecipients property after creating the draft.

    Hope this helps.

    If the answer is helpful, please click Accept Answer and kindly upvote it. If you have any further questions about this answer, please click Comment.

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.