Process Data Using Generative AI Action

Using Einstein Generative AI, perform Natural Language Processing (NLP) to summarize text, extract key phrases, analyze sentiment, and unlock valuable insights.

This action is available in API version 61.0 and later.

To access the Process Data Using Generative AI action, you must have the Salesforce Feedback Management Starter or Growth License and the Salesforce org enabled with Surveys along with Generative AI Surveys feature.

Supported REST HTTP Methods 

URI: /services/data/vXX.X/actions/standard/processDataUsingGenAi

Where XX.X is the latest API version.

Formats: JSON, XML

HTTP Methods: POST

Authentication: Authorization: Bearer TOKEN

Where TOKEN is a variable.

Inputs 

InputTypeDescription
additionalParameterIdsStringCollection of additional record IDs on which NLP is performed.
featureString (Picklist)Required. Purpose of applying NLP to the target record: SurveyLongSummarization or SurveyShortSummarization.
targetRecordIdStringRequired. ID of the record on which NLP is performed.

Outputs 

OutputTypeDescription
nlpRecordIdstringID of the created NLP record.

Example 

POST

This example shows a sample request for the Process Data Using Generative AI action.

1{
2   "inputs":[{
3      "targetRecordId": "0MySM00000007eD0xx",
4      "additionalParameterIds": [
5 "0KuSM0000000JM10xx","0KuSM0000000JM20xx","0KuSM0000000JM30xx","0KuSM0000000JM40xx"
6      ],
7      "feature": "SurveyLongSummarization"   }]
8}

This example shows a sample response for the Process Data Using Generative AI action.

1[
2   {
3      "nlpRecordId" : "7NPSM0000000K5B4xx"
4   }
5]