Using Ai To Summarize Records In Microsoft Dynamics Crm

🧠 What is AISummarizeRecord?

AISummarizeRecord is a custom API in Dynamics CRM that uses AI to generate a concise summary of a specific record. It returns:

It works across standard entities like Accounts, Contacts, and Cases, and even on custom entities such as Deal Workflows.

 

⚙️ How to Run AISummarizeRecord Using JavaScript

Developers can call the summarization API from form scripts, command bar buttons, or even dashboards. Here’s a simple JavaScript example for an Account record:

var execute_AISummarizeRecord_Request = {

    EntityLogicalName: "account", // Replace with your entity name

    Id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", // Replace with record GUID

 

    getMetadata: function () {

        return {

            boundParameter: null,

            parameterTypes: {

                EntityLogicalName: { typeName: "Edm.String", structuralProperty: 1 },

                Id: { typeName: "Edm.String", structuralProperty: 1 }

            },

            operationType: 0,

            operationName: "AISummarizeRecord"

        };

    }

};

 

Xrm.WebApi.execute(execute_AISummarizeRecord_Request).then(

    function success(response) {

        if (response.ok) {

            return response.json();

        }

    }

).then(function (responseBody) {

    var summary = responseBody["SummarizedText"];

    var details = responseBody["AdditionalInformation"];

 

    console.log("Summary:", summary);

    console.log("Additional Info:", details);

}).catch(function (error) {

    console.error("Error:", error.message);

});

 

🧪 Example: Summarizing an Account

Let’s take the Contoso Ltd. account, which has multiple opportunities and active support cases. Running the summarization might return something like:

{

  "SummarizedText": "Contoso Ltd. is a long-standing customer with high engagement. They have 3 active opportunities and 2 open cases. Recent interactions indicate interest in cloud migration services.",

  "AdditionalInformation": {

    "PrimaryContact": "John Doe",

    "OpenCases": 2,

    "ActiveOpportunities": 3

  }

}

With just one API call, the sales team gets a quick, AI-generated overview of the account—perfect for pre-meeting prep or call follow-ups.

 

💡 Tips for Making the Most of This Feature

 

using-ai-to-summarize-records-in-microsoft-dynamic

Discussion