Hi Venkatesh, Good morning and thank you for your question! I was able to collect an email using the InternetMessageID in Graph by using the GET method:
GET https://graph.microsoft.com/v1.0/me/messages?$filter=internetMessageId eq '<internet_message_id>'
Under the Graph Explorer, I go to Code Snippets and click on Java tab and it presented this code:
GraphServiceClient graphClient = GraphServiceClient.builder().authenticationProvider( authProvider ).buildClient();
Message message = graphClient.me().messages()
.buildRequest()
.filter("internetMessageID eq '<******@xxxxxxxxxxxx.INDPRD01.PROD.OUTLOOK.COM'">
.get();
I hope I was able to answer your question! If I have, please do not forget to Upvote and click Accept as answer if this reply is helpful.