Is it possible to insert an actionable message in an existing email message?

Copper Contributor
I want to insert an actionable message in an existing email using Microsoft Graph API.

The message to be rewritten does not contain an actionable message. Is it possible to insert an existing actionable message in an existing email message?

When I update the message with the API, the body of the message is modified but the actionable message does not appear.

I have the impression that Outlook checks the presence and interprets the actionable message when it receives the email. But when I edit an existing message, it will not check the existence of an actionable message.

I tested the following cases:

  • Send a new message containing the same body -> it works
  • Modify an existing actionable message -> it works with documentation
  • Modify an existing emailMessage with random body without actionable message-> It works

The debugger's diagnostics show me this :


{"CardEnabledForMessage": false,
"ClientName": "OutlookWebApp",
"ClientVersion": "20221111004.15",
"InternetMessageId": "<email address removed for privacy reasons>",
"EntityExtractionSuccess": true,
-"AdaptiveCardPayload": {
"found": true,
"type": "AdaptiveCard"
-"MessageCardPayload": {
"found": false,
"type": null
-"AuthHeader": {
"results": "dkim=none (message not signed) header.d=none;dmarc=none action=none;",
"authAs": "Internal"



Code for path message :


def update_message(
    self, data: DataEvent, office_message_body: OfficeMessageBody
) -> int:
    url = f"/users/{data.id_user}/messages/{data.id_message}"
    response = self.microsoft_api.patch(
        json={"body": office_message_body.dict()},
            "CARD-UPDATE-IN-BODY": "true",
    return response.status_code


Content of body : 


  <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  <script type="application/adaptivecard+json">{
    "type": "AdaptiveCard",
    "version": "1.0",
    "body": [
        "type": "TextBlock",
        "text": "Visit the Outlook Portal",
        "size": "large"
        "type": "TextBlock",
        "text": "Click **Learn More** to learn more about Actionable Messages!"
        "type": "Input.Text",
        "id": "feedbackText",
        "placeholder": "Let us know what you think about Actionable Messages"
test Modify message


Thank you :)

0 Replies