Share via

Does Graph API return all Internet Message Headers associate with Item Attachment?

Piyumi Perera 131 Reputation points
2022-01-03T11:52:20.283+00:00

I have a requirement to get all internet message headers of an item attachment. Is it possible to do it?

https://learn.microsoft.com/en-us/graph/api/attachment-get?view=graph-rest-1.0&tabs=http#example-3-expand-and-get-the-properties-of-the-item-attached-to-a-message

var itemAttachment = await graphServiceClient.Users["id"]  
                    .Messages[messageId]  
                    .Attachments[messageWithItemAttachment[0].Id]  
                    .Request()  
                    .Expand($"microsoft.graph.itemAttachment/item")  
                    .GetAsync();  

This returns some set of message header. But not all.

I found following resource which trying to read headers of an item using expand query. How to use such expand query within another expand query?

https://stackoverflow.com/questions/60947499/get-message-using-graph-missing-some-internetmessageheaders

Microsoft Security | Microsoft Graph
0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.