Hi I have Exchange Server 2007 setup with some users with their own inbox. Since this is all related to office conversations I want to move all the incoming and outgoing mails belonging to same conversation thread to disk folder (any folder on his machine say D:\Conversation1).
I am able to let user create separate disk folder for each conversation and let him move first mail in conversation to this folder. So that is not the problem now.
Also I have written a web app which when provided the conversation ID returns the corresponding disk folder path.
However now what I want is to process all incoming & outgoing mails and auto move them to the disk folder corresponding to their conversation thread. I found two possible ways:
Write Outlook plugin which when user logs in will intercept all incoming mails and outgoing mails find their conversation id, send it to web app I written and move them to the disk folder path returned by my web app.
Using EWS: I could write a service for client machines which will ask for user login and based on that login cred it will connect to Exchange server using Exchange Server Webservices (EWS) and will then do the same thing as above. However here it will require to periodically poll / ask Exchange Server to check if their are any new mails sent / received through by the user who provided the login credentials. In outlook plugin I need not do such periodic requests - I could just write code on new incoming / outgoing mail handlers.
Q. Is there any better approach to achieve this through EWS than as explained above.
Main Q. What I find wrong with both above approaches is that - my functionality is same for all mails accounts / users. So why need user to log in just for movement of mails. Can I write something like Exchange Server Tasks ( - a server side code instead of client side code as it was the case with both above approaches) which will continuously process all mails (from all mail accounts configured on Exchange Server) find their conversation IDs and with the help of my web app move them to the corresponding disk folder.
Details that you may ignore
I have Outlook 2010 configured for users.
I have a repository setup that will manage storage of mails in folder. Yes this repository will be own its own machine - not on the exchange server. But eventually it will be on hard disk, so referring them as "disk folder" is still no wrong.
Also you can think of that web app as a part of repository handling. So it runs on repository machine. Just didn't mentioned above to reduce details and focus on which approaches available and preferable - simple and clean.
Related
My goal is to develop an Exchange listener that will intercept the organization mail box for new mails and for each mail it would do some logic.
After i've researched the subject online - i saw that there are two primary ways to do that:
Configure a new MTA (Mail Transfer Agent) that will be situated before the exchange server and will intercept the SMTP messages.
Use EWS API to subscribe to a new mail event and run the login on the listener
in this way i have 2 basic problems:
Is there a way to subscribe to all mailboxes on the exchange server? without looping all the users ?
How i can block a client to read his email before my listener handled it ? (can i move the whole incoming mail to a special default folder that the users wouldn't have an access to it - some king of hidden folder ?
Is there other way besides the two that i mentioned to fulfill the demand ?
Thanks!
You can use a Transport Agent on Exchange https://technet.microsoft.com/en-us/library/bb125012(v=exchg.150).aspx which allows you to capture/proces messages while they are in the Transport pipeline. The advantage of this over what you have described in 1. is that you capture every message sent/received on the server including internal messages.
Is there a way to subscribe to all mailboxes on the exchange server? without looping all the users ?
No you need to managed your subscriptions per mailbox folder
How i can block a client to read his email before my listener handled it ? (can i move the whole incoming mail to a special default folder that the users wouldn't have an access to it - some king of hidden folder ?
All clients are equal on Exchange so you cant prioritise a client or block access to a new messages (you can block the client entirely) , in theory you could move all messages that arrive to NON_IPM_Root folder with an Inbox rule which means the user couldn't see them but you might want to consider the implications of what happens when your process fails, this could also be disabled by the user at any time when they create a Inbox rule themselves.
I need a little help understanding a task I have been given.
I started work on a 'SharePoint focused' team and we are trying to create a SharePoint portal that would house/manage all incoming mail to a specific company email address.
We have had a couple of issues setting up SharePoint to accept incoming mail, so have begun looking at other possible options.
1 option that was suggested was to 'write a job' that would read our mailbox server (on Office 365), and then find, pull and migrate/copy selected emails onto the sharepoint site.
(something else we are also interested in doing is seeing what info we can grab from these emails at this stage which we can use to create various mail objects in sharepoint with the mail metadata. Not sure what limitations there are to what can be accessed, if anything)
Is somebody able to explain a little more the type of process or work that is required to do this (access Office 365 mail via some API which we can create a timed job for), and any experience or advice around it? Where would I start looking or how would I start implementing it, etc.
Thanks!
You combine couple of things together. SP can read incoming emails through locally installed and configured SMTP server. You can then setup document library or list to store them or create event listener to handle incoming emails completely by your own.
But both cases (OOTB functionality or event receiver) rely on local SMTP. If you want process emails from other server like Exchange Online you must either forward these emails to local SMTP server installed beside SP or you must create your own code. It can be SP job or any other type like windows service or console application executed by windows schedule, ... calling Exchange online API (designed specially for Exchange online) or MAPI or POP3 (generic using libraries) to get emails and calling SP API (CSOM, REST API) to store emails.
Here is the reason for my peculiar question:
I am working on a mortgage application for a mortgage broker where each mortgage application is a record. Now this broker will take each of the applications he has received and enter this application (in an up line lender's system) and during the life of this mortgage application, he receives notification emails about updates from the up line lender.
It is required that in this application, all emails pertaining to a particular mortgage application are visible under that record.
My plan is to have all emails collect in a single inbox, and give that inbox an alias corresponding to the record id of the mortgage record. The alias remains active as long as the mortgage application is active and the broker cares for receiving these updates. Once the mortgage application record is dead, that alias is removed.
When displaying the particular mortgage record, I can query the mail server for the emails where the to address is the alias of that particular record.
My key requirements are:
The email server or email service should allow for about 400-500 aliases at a time.
Should have an API interface for creating and deleting an alias.
As far as the creating/deleting API is concerned, Google Apps (https://developers.google.com/admin-sdk/directory/v1/guides/manage-user-aliases) really fits the requirement, but has a 30 alias limit.
Does Microsoft Outlook online mail support this kind of API and ability to create mailbox alias?
If we went in the direction of having a Microsoft Exchange Server 2010/2013, would it allow programmatic access to create aliases? What would be the license cost?
Thanks in advance for looking this up.
With update from #mti2935, I am considering a catch-all solution rather then deal with creating aliases.
So, now I think all I need is to be able to process the emails. What's the best means of processing emails (in my case, I will simply have to look at the "to" field and put the emails in different buckets).
I have found a third party service that can help me parse emails. Definitely going to try that out and provide an update here.
Service: https://postmarkapp.com/inbound
Referenced by a post on: How to setup a mail server?
One option to consider is to setup a mail server using qmail, configured as a catch-all for your domain, such that all mail to *#yourdomain.tld forwards to a script which parses each incoming message, scrapes the to, from, subject, etc. logs the messages in your database, etc. It's easier than it sounds to setup. See How to setup a mail server?. This can be done fairly inexpensively on a Rackspace or AWS cloud server.
I have an application running on WebLogic Server with 6 instances. Many requests for the application come from Email. We already set up an email account that will be used by all clients to send email to. But the problem is that the email account inbox can only be opened for reading by a single connection, unlike a typical database.
Currently I can only deploy the email reading service on a single server instance, this will effectively create a single point of failure and unbalanced load. What's the best way to read from the same inbox from multiple servers? I am thinking developing something using a database table, sort of leasing, whoever locked the table own the lease and can connect to the email server, but this is pretty hard to implement correctly in all circumstances.
I am not sure why you say that only one client can access the inbox as POP certainly can handle multiple connections to the same inbox and this can be configured in the mail server. You might need to talk to your mail server admin.
I haven't worked with Weblogic to give you a specific answer, but you should also be able to have a service written that checks the incoming mail and process incoming mails into a database as you wanted. Once the information is in a database, you can use it via multiple hosts. This is a better approach as this can be setup to prevent multiple clients responding to the same email.
Ive been trying to figure out how this situation is handled easily.
I have a website that sends out some emails. I want to be able to somehow get the bounce backs and so I can store the information in a DB table.
The main confusion comes in how is this done? I assume I create a email address that will be the FROM:. But when the email doesnt go through I assume Exchange Server would get that bounce back... does it log it somewhere? in a file? In a database? How can I read this info ?
I have built a couple of applications that process Exchange bounce backs. Generally the bounce back messages will get returned to the inbox of the FROM address on the message that you send out. So, in order to store that information in a database table, I built a windows service that would periodically read that bounce back inbox, and then log that information into a database.
I assume your using exchange; So, in order to read the bounce back information from exchange I used the Exchange Web Services, that allow you to connect to exchange and read the message contents within an inbox (in addition to a bunch of other exchange functions). From there I could process the messages and insert data into my application's database.
One thing to note, is that Exchange Web Services are only available for Exchange 2007 or later. If you're using an earlier version, then you would have to investigate other options.