I am using the following to create a new email in Dynamics 365:
export const createEmail = (
subject: string,
description: string,
trackingToken: string | undefined,
caseId: string,
emailId: string,
partyData: any[],
): JQuery.jqXHR => $.ajax({
url: `${apiBaseUrl}/emails?$select=activityid,_ownerid_value,createdon,subject,statuscode,directioncode,sender,attachmentcount,
trackingtoken`,
type: 'POST',
global: true,
headers: {
'Prefer': 'return=representation'
},
dataType: 'json',
contentType: 'application/json',
data: JSON.stringify({
subject,
description,
trackingtoken: trackingToken,
'regardingobjectid_incident@odata.bind': `/incidents(${caseId})`,
'parentactivityid@odata.bind': `/emails(${emailId})`,
email_activity_parties: partyData,
}),
});
The new email is meant to be a reply to customer's incoming email. In the description parameter I'm passing the user's signature, because I need to add a separator between our response and the original email thread. However, the resulting email in Dynamics 365 has the signature I provided in the description, and another automatically-added signature. Is there a way to prevent Dynamics 365 from adding signatures to emails?