Relationship Insights (GET, POST)

Generate or retrieve relationship insights for a Salesforce record. Use POST to start asynchronous relationship insight generation and GET to retrieve the latest available relationship insights for a Salesforce record or a specific relationship insight.

Resource 

1/connect/relationship-research/insights

Resource Example 

1https://{yourInstance}.salesforce.com/services/data/v68.0/connect/relationship-research/insights

{yourInstance} is the domain name of your Salesforce instance.

Available Version 

67.0

HTTP Methods 

GET, POST

Request Parameters for GET 

Parameter NameTypeDescriptionRequired or OptionalAvailable Version
graphFormatStringFormat of the returned relationship graph. Possible values are:
  • NODES_EDGES (default)
  • FLAT
Optional67.0
includeDiagnosticsBooleanIndicates whether the response includes diagnostic information intended for debugging or administrative use (true) or not (false). The default is false.Optional67.0
includeEvidenceBooleanIndicates whether the response includes evidence objects (true) or not (false). The default is true.Optional67.0
includeNotesBooleanIndicates whether the response includes relationship notes, if available (true) or not (false). The default is true.Optional67.0
includeSensitiveEvidenceBooleanIndicates whether the response includes evidence marked as sensitive when the current user has the required permission (true) or not (false). The default is false.Optional67.0
includeSourcesBooleanIndicates whether the response includes source information (true) or not (false). The default is true.Optional67.0
maxEvidencePerRelationshipIntegerMaximum number of evidence records to return for each relationship. The default limit is 3.Optional67.0
maxRelationshipsIntegerMaximum number of relationships to return after access filtering is applied. The default limit is 50.Optional67.0
targetObjectStringAPI name of the target object type. If provided, the system validates that the record ID matches the specified object type. If omitted, the object type is derived from the record ID prefix.Optional67.0
targetRecordIdStringSalesforce record ID to retrieve the latest available relationship insight for the record.Optional67.0

Response Body for GET 

Get Relationship Insights

Request Body for POST 

JSON Example 

1{
2  "targetRecordId": "006xx0000001234AAA",
3  "targetObject": "Opportunity",
4  "useCaseApiName": "RRA_Default",
5  "regenerationMode": "REFRESH_IF_EXPIRED",
6  "generationOptions": {
7    "useDeepWebSearch": true,
8    "useRecordContext": true,
9    "generateSyntheticData": false
10  },
11  "maxRelationships": 12,
12  "requestMetadata": {
13    "clientId": "RRA_LAB_Component",
14    "correlationId": "f5a5c8c4-1234-5678-9abc-001122334455"
15  }
16}

Properties 

NameTypeDescriptionRequired or OptionalAvailable Version
generationOptionsGeneration Options Input[]Optional settings that influence data sources and generation behavior, such as enabling deep web search, using record context, or generating synthetic data for demonstrations.Optional67.0
maxRelationshipsIntegerMaximum number of relationships to retain in the generated insight graph. If not specified, the value defaults to the Relationship Research Agent configuration, for example, MAX_REL_PER_INSIGHT.Optional67.0
regenerationModeStringRegeneration strategy for relationship insights. Possible values include ALWAYS_REGENERATE, REFRESH_IF_EXPIRED, and REUSE_IF_FRESH. This setting controls whether an existing insight is reused or regenerated.Optional67.0
requestMetadataMap<String, Object>Additional diagnostic or routing metadata, such as clientId or correlationId, used for observability, tracing, and debugging.Optional67.0
targetObjectStringAPI name of the target SObject type, such as Opportunity. If not provided, the value is derived from targetRecordId.Optional67.0
targetRecordIdStringSalesforce record ID for which relationship insights must be generated. For example, Opportunity, Account, Contact.Required67.0
useCaseApiIdStringID of the relationship research insight use case applied during insight generation.Optional67.0
useCaseApiNameStringAPI name of the Relationship Research Agent use case configuration to apply. This value maps to the Template Config Definition in SDB. If not provided, the default org-level or object-level Relationship Research Agent configuration is used.Optional67.0

Response Body for POST 

Generate Relationship Insights