Newer Version Available

This content describes an older version of this product. View Latest

EmailMessageRelation

Represents the relationship between an email and leads, contacts, users, and a single opportunity, campaign, case, account, or person account. This object is available in API version 37.0 and later

EmailMessageRelation is available only if you have Enhanced Email enabled in your organization.

EmailMessageRelation allows the following relationships:

  • An email can be related to leads, contacts, and users.
  • An email can also be related to one opportunity, campaign, case, account, or person account.

Supported Calls

create()delete()describeSObjects()getDeleted()getUpdated()query()retrieve()update()upsert()

Fields

Field Name Details
EmailMessageId
Type
reference
Properties
Create, Filter, Group, Sort
Description
The ID of the EmailMessage record.
RelationAddress
Type
string
Properties
Create, Filter, Group, Nillable, Sort
Description
The email address of the sender or recipient.
RelationId
Type
reference
Properties
Create, Filter, Group, Nillable, Sort, Update
Description
The RecordId of the sender or recipient.
RelationObjectType
Type
string
Properties
Filter, Group, Nillable, Sort
Description
The API name of the object type of the RecordId in the RelationId field. It can be a contact, lead, or user.
RelationType
Type
picklist
Properties
Create, Filter, Group, Restricted picklist, Sort
Description
The type of relationship the contact, lead, or user has with the email message. Possible values are: “Like”, “ToAddress”, “CcAddress”, “BccAddress”, and “FromAddress”.