How can we help you today?

How to Filter Outlook Emails Using a Search Term in SharePoint

Anyone will most likely agree that one of the most used tools in their workplace is their Microsoft Outlook email account. And having those Outlook emails visible in your SharePoint intranet is extremely useful, groundbreaking even.


The ShortPoint Microsoft Graph API connection makes this possible! In this guide, we’ll walk you through how to filter Outlook emails using a search term in SharePoint.


TABLE OF CONTENTS


Prerequisites

  • You must have ShortPoint SPFx version 8.6.0.0 and up installed.
  • You also need to be a ShortPoint Designer with either a Pro or Enterprise license. For more details, check out Licensing Options.
  • You must have the Microsoft Graph API connection enabled. Go to How to Enable Microsoft Graph Integration for MS Graph API Connections to learn how.
  • You must authorize the necessary permissions (Mail.Read) in the API access page. To check, go to your SharePoint Admin Center > Advanced > API access.
  • You must have the Design Element you want to use to connect on your SharePoint page. For best results, we recommend using Design Elements that allow listing of multiple items (Icon List, Simple List, Tiles, etc.).

What is the “Filter My Emails for a Search Term” Use Case?


The Filter My Emails for a Search Term use case allows you to GET the emails in your Outlook mailbox storage and filter them using the search term you specified.


Filter My Emails for a Search Term


With this use case, you can display Outlook emails relevant to the specific task or project you want to accomplish. 

The typical structure of this use case is:

https://graph.microsoft.com/v1.0/users/[%Me('email')%]/messages?$search=#searchText


You must enable the following permissions in the SharePoint Admin Center to use it:

  • Mail.Read - gives permission to read emails in the signed-in user's mailbox.


NOTEIf you haven’t given access to the permissions above, go to your SharePoint Admin Center > Advanced > API access.


Step-by-step Tutorial


Follow the steps below to learn how to use the Filter My Emails for a Search Term use case to create a list of Outlook emails filtered according to a search term.


Step 1: Edit the ShortPoint Web Part

Go to the SharePoint page you want to use and click Edit:


Edit


Close the Toolbox:


close icon


Select the ShortPoint web part and click the Edit Properties icon:


Edit properties icon


Step 2: Edit the Design Element


NOTEYou can use any Design Element you want. For best results, we recommend using Design Elements that allow listing of multiple items (Icon List, Simple List, etc.)

Click the EasyPass tag of the Design Element you’ll use:


EasyPass tag


Select the cogwheel icon:


cogwheel icon


Step 3: Open the Connect Window

Go to the Connect tab:


Connect tab


Click Configure to open the connect window:


configure


Step 4: Connect to Microsoft Graph API

Select Microsoft Graph API:


NOTEYou need to enable the Microsoft Graph API connection before using it. Learn more about it in How to Enable Microsoft Graph Integration for MS Graph API Connections.

Microsoft Graph API


Step 5: Use the Filter My Emails for a Search Term Use Case

Search for Filter My Emails for a Search Term and select it:



Add the Search term you want to use to filter your emails. In our case, we want to filter all our 'Important' emails:


Search Text


Step 6: Connect

Click Run Query:


Run Query


Select Connect:


Connect


Step 7: Map Items

Go to the Tiles tab:


NOTEItems mapping is typically done in the Items tab. But since we're using the Tiles Design Element, items mapping is done in the Tiles tab.


Tiles tab


Delete default content and use the link icon to map the properties you want to be displayed:


link icon


You can map any property you want. In our case, we used the following properties:

  1. #subject - shows the subject of the email.
  2. #webLink - redirects page viewers to the actual email.


mapped items


NOTECheck out ShortPoint Connect: How Items Mapping Works to learn more about mapping properties.

Step 8: Save

Select Preview to see how the Design Element looks:


Preview


Click Update to apply your changes:


Update


Click the green checkmark:


Green checkmark


Once satisfied, click Save:


Save


And Publish your page:


Publish


Congratulations! Filtering Outlook emails in SharePoint is now easier with the Microsoft Graph API connection, enabling seamless integration between your Outlook inbox and SharePoint intranet for improved email management and collaboration.


Frequently Asked Questions


What is the benefit of filtering Outlook emails using a search term in SharePoint?


Filtering Outlook emails in SharePoint allows users to access relevant emails directly within their SharePoint intranet. This integration, powered by the Microsoft Graph API, improves email management and collaboration by displaying Outlook emails related to specific tasks or projects, enhancing productivity.


What permissions are required to filter Outlook emails in SharePoint?


To filter Outlook emails using the Microsoft Graph API, you must enable the Mail.Read permission in the SharePoint Admin Center under API access. This permission allows the app to read emails in the signed-in user's mailbox securely.


Do I need to have Outlook desktop apps or the Outlook mobile app download to use this feature?


No, this filtering feature works within SharePoint via the Microsoft Graph API and does not require the Outlook desktop apps or the Outlook mobile app. However, having access to Outlook desktop apps or the Outlook mobile app can complement your email management.


Is this feature available for both web and mobile versions of SharePoint?


Yes, the integration works across web and mobile versions of SharePoint, providing a seamless experience whether you use desktop or mobile apps.


How can I start using this filtering feature in my SharePoint intranet?


You need to have ShortPoint SPFx version 8.6.0.0 or higher installed, a Pro or Enterprise ShortPoint Designer license, and enable Microsoft Graph API integration with the necessary permissions. Then, you can add the Design Element you want to use for the connection to your SharePoint page and configure it to filter Outlook emails by your chosen search term.


Related articles:

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.

World's best intranet sites are designed using ShortPoint

Get started today! Learn more
See all 51 topics

Start a trial

Ignite your vision. Install ShortPoint directly on your site, or play in sandbox mode. No credit card required.

Get started today

World’s best intranet sites are designed using ShortPoint

Thousands of companies using ShortPoint everyday to design, brand and build award winning intranet sites.

Get started Learn more