An API that connects multiple Microsoft services, enabling data access and automation across platforms
Hi Babetecno SAT, Thank you for reaching out.
Please note that endsWith parameters does not always work with certain OData query parameters https://github.com/microsoftgraph/microsoft-graph-docs/issues/4331
However upon some testing we were able to get the query working as such: https://graph.microsoft.com/v1.0/users/<User-GUID>/messages?$count=true&$filter= (contains(from/emailAddress/address,'.com') and contains(to/emailAddress/address,'.com')) Note that a user guid is to be provided to the messages resource type so that the object is filterable. Further an item oData.count value will have the count value of the returned item.