Exchange Online API to retrieve info from emails

Hello guys,

My company is in the middle of a project and they've requested my help. They basically would like to obtain, from a given company, all email usage related data to then put it in a nice graph so they can analyze things like:

Number of emails sent overall
How many numbers of emails are sent inside the organisation or outside.

To be more precise, these are the questions I have been made:

1.      When is email sent? Date, time and weekday
2.      Who is the sender/receiver? Remember, don’t take it down to people, we have to talk about areas/departments/...
3.      Are there people in CC/CCO? Who are they?  In the TO, CC and CCO. # of people and # of emails
4.      Is the email part of a chain/conversation? A “response” Chain size, number of hopes, …
5.      Is the email a forward? What was the original chain? Forward and Reply
6.      Is the email an automated email from a system? Or from a person?

From my understanding - I am no programmer-, I can use powershell to pull up some reports that should give some insight but they're looking to integrate all this data into one application they're developing.

My boss just mentioned to me that the powershell report would give them part of the information but they also looking to see more specific data such as if the email is ccd, forwarded, etc etc.

He says that Microsoft Graph does obtain this information.

Does anyone know which API they need to use?

Thank you very much for your help!
DsenoransAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Hasin Ahmed ChoudharyExchange AdministratorCommented:
I think you will have to contact MS for that or wait till some expert on messaging programmer expert replies.
0
Vasil Michev (MVP)Commented:
What you can pull from PowerShell are the message trace details, they only cover basic routing/deliver information. Headers are not exposed. Unless you get the actual message, there is no way to determine whether it's a part of specific conversation, number of replies in the conversation and so on. So in general, to get some of this information you will need to grant impersonation or full access permissions to all mailboxes in the company, which is not something you should be doing lightly. But if you are OK with this, yes, the EWS API or the newer REST based Outlook API (part of Graph) can give you message-level access.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
DsenoransAuthor Commented:
Thank you very much. I suspected it would be that way but had to ask!

Have a good day
0
Hasin Ahmed ChoudharyExchange AdministratorCommented:
NO further response from Author
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Programming

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.