Outlook sent item internet header missing - outlook

I have written a C++ app that sync's Outlook emails with our central server DB. Incoming messages contain MessageID info in the internet header - I use this for key generation when placing the messages in the central DB. However, Sent Items in Outlook do not seem to have Internet Headers, so I am stuck for a static id I can use to generate a unique, static GUID for placing the message in the central DB. Multiple Outlook stores are being scanned for multiple users, each user running a copy of the sync program. To be clear, if Pete sends an email to Joe, the email in Pete's Sent Items folder needs the same id to be generated as the id generated for the email when it arrives in Joes Inbox folder - Pete & Joe are both running the sync software.
Does anyone know whether:
1. You can grab a static MessageID from a Sent Items email item
2. If not, is there another value within the Sent Items email that will be available to the sync app scanning the Sent Items folder, and available to the sync app scanning the Inbox that the email eventually arrives in.
Users could be running Outlook 2002 upwards.
Thanks very much.

The MAPI property PR_INTERNET_MESSAGE_ID is set for outgoing and incoming items.

Related

I want to use Image tracker in my Emails to track recipients who opened the mail or not. I use mail merge on outlook, so how can I put tracking image?

We do multiple email marketing activities to numerous recipients every day. Thus, I was looking forward to track how many recipients have opened my email. My development team has given me an API, through which I can generate unique image links for all the recipients and send them through mail merge field. Currently, when I am sending emails to recipients with unique image links, the image is rendering in the email content but I don't get any insight in my backend API.
Usually, I use Mail Merge on Word to run the campaigns. And I use Microsoft Outlook as email operator.
CAN ANYONE PLEASE HELP ME ON HOW TO INSERT A TRACKING IMAGE IN MY MAIL CONTENT ON WORD, SO THAT IF ANYONE OPENS THE MAIL, I GET HIS/HER DETAILS IN MY BACKEND DATABASE.
I tried to add the image in my mail content through the "IncludeImage" command on word and in the file URL I called the merge field from the connected datasheet. But when I am running the campaigns the image is appearing but I am not getting any tracking in my backend database.

Outlook API, Message Moved to "Sent Items" still beign marked as "[Draft]"

I'm working on an Outlook Add-in, using office.js, where users can send secure emails using backend service.
In compose mode, when the user sends the email, using the add-in of course, the add-in will then move the message to "Sent Items" folder using the Outlook API /message/{id}/move and everything goes OK with the exception that the message in question still being marked as "Draft" by Outlook which is really annoying and does confuse the user who just sent the email by telling him that "this message hasn't been sent"
I searched through the API to see if there is a way to mark an email as "SENT" in order to prevent Outlook from showing this RED hint but with no luck so far!
So, My Question Is: Is there any way to overcome this misleading msg by marking the email as it was sent by Outlook?
Thanks in advance.
Finally, I was able to achieve a perfect solution for this challenge.
Based on:
#BrianClink's comment
This answer (Which uses Graph API but Outlook REST API): Microsoft Graph API mail office 365: Is any option create inbox message NOT as Draft?
The approach/steps I followed to mark a mailItem as "SENT" (and not shown as 'draft') and put it in "SentItems" Folder are as follow:
First, Save the mailItem as "draft" using Office.context.mailbox.item.currentMail.saveAsync then retrieve its ID
Clone this draft mailItem properties eg: 'Sender', 'Subject', 'Body', 'ToRecipients'..etc so you get an exact copy of it.
With the newly cloned mailItem, add '[SingleValueExtendedProperties]' property with this value :
[
{
PropertyId: 'Integer 0x0E07',
Value: '1'
}
];
Serialize the new item as JSON and POST it to "sentitems" folder as follows:
xhr.open('POST', restHost + '/v2.0/me/MailFolders/sentitems/messages/');
xhr.send(clonedEmailJson);
On success, with xhr.status=201 [created], Remove the draft mailitem using a [DELETE] request
And you will end up having a new mail item created in your "sentItems" folder which appears as it was sent by Outlook :)
This was a very helpful solution to me because my users are using my add-in to send secure emails (using 3rd party API) and NOT Outlook, So, I wanted them to have the same UX/feeling as when they use Outlook.
Note:
Although the solution worked for me perfectly, it came with a price!
On slow internet connections or in case emails containing large attachments, the process can be remarkably slow, because the addin will first save the draft to the remote Exchange Server, get its ID, then duplicate it and send it again to the server, then remove the draft-ed one.

How to get conversation id if we only have send-only permission of user outlook account?

Is it possible to get conversation id and message id of the messages sent by our app on behalf of the user who only given send only permission?
We want to send follow-up mails in the same conversation and there is no way we can do that without message id.
I'm afraid not. You need to have mail.read in order to find the message id and add to the conversation.
Also, it's important to note that the id is mutable and can change for any number of reasons (most commonly the mail item being moved to another folder). It is possible to get immutable identifiers for Outlook resources but this functionality is still in Preview so, for the time being, it really shouldn't be used in a production environment.

Can messages on an Exchange Server be tampered with by a client user?

Is ist possible for a user connected to Exchange Server via a client (Outlook Web App) to tamper with the e-mails in his mailbox (inbox, drafts, sent items ect.)?
Like modifying e-mail content (text, subject...) or properties (date, time, recipient...).
The core of the question is: If there is an e-mail in the user's sent items folder and this user did not have access to the Exchange Server (neither physically nor remotely, except for his standard user access), how sure (or probable) ist it, that this e-mail has really been sent on that date and time with exactly that text to exactly those recipients and that it had not been planted there at a later date?
Does it make a difference if that user only has access to his account via Outlook Web App or if he also has access via MS Outlook?
Outlook Web App is just a client so it won't allow you to modify a sent email or fake/import one as that is not a valid task for that client. You could do this at the API level using something like EWS or MAPI but that would require knowledge that most users won't have (but most likly they would have access to do it though). The Mitigation to this is if you have Litigation hold enabled https://technet.microsoft.com/en-us/library/ee861123%28v=exchg.141%29.aspx on the mailbox then any changes they did make to a message would be tracked and you would always be able to see the original version. Also if you looked at the message with a MAPI editor like MFCMapi or OutlookSpy there would be tell tails of somebody trying to fake a message like the Creation time not matching the sent time etc and other properties would most likly give it away.
One thing i would suggest is look at your Message Tracking log as they will tell you exactly what was sent and who is was sent to and the time https://technet.microsoft.com/en-us/library/bb124375%28v=exchg.160%29.aspx while these also aren't immutable it would take an administrative access to the server to modify.

Dynamics 2016 email tracking ignoring outgoing replies

We have server-side synchronisation set up for our Dynamics 2016 on-premise instance, and it is correctly sending emails from a Case, and tracking replies from the customer. However, when an internal user replies using Outlook (without the CRM add in), their responses aren't being tracked. This means that the email conversation consists of an initial "outgoing" email, followed by only incoming responses.
The full scenario is:
Internal user sends an email from a CRM Case. Email tracked in CRM
Customer replies to email. Reply tracked in CRM and goes to internal user's Outlook
Internal user sends a reply from their Outlook. Reply is not tracked in CRM
Customer replies to email. Reply tracked in CRM and goes to internal user's Outlook
Is it possible to allow the Internal user's replies (point 3) to be tracked in CRM without installing the Outlook add in (i.e. so it also works from the Web/mobile versions of Outlook)?
I believe you cannot do this without Outlook client as per Jukka.
Without the CRM Outlook client you can’t get the information into CRM without copy-pasting it from one window to another in the aforementioned scenarios. No synchronization technology will help you here, since CRM is unaware of the item until it has been brought into its world. The “Track” button is a client-side feature that you can’t utilize with any server-side solution, which means there’s no way for a user to select an email, appointment, task or contact from the Exchange server that he or she would like to promote into a record in CRM. Since the the record wasn’t “born in CRM”, it just can’t find its way there.
Last resort would be Smart matching with Tracking token, which may help you in this scenario.
Update:
Customer reply is going to reach CRM through a monitored queue. You can read a lot & get clarity from the above link.
Deploying a solution like the CRM 2013 the server-side synchronization will take care of moving items like calendar appointments and contacts back and forth between the end-user client device and the central CRM database, but it only applies to items that already exist in the realm of CRM. What I mean by this is that the item was either originally created directly in the CRM application or it was received via a monitored location like an email queue.
Your expectation is right, it should be tracked. I would open a ticket with MS & solve this.
Once the item is in CRM, server-side sync can take care of tracking the subsequent updates to it. A re-scheduled tracked appointment will get updated with the new date, regardless of whether you change the date via CRM or your mobile phone calendar that’s linked to Exchange. An email thread with a tracked message and a tracking token ID injected into the email subject line will have the next replies automatically synchronized into CRM
I have heard back from our Microsoft Partner, and they say that this scenario isn't possible. By design, it'll only track incoming emails to CRM, or outgoing if sent from within CRM itself.

Resources