Set Query Parameters to Filter the Return of Messages

You use query parameters to filter the content of email messages returned by the Microsoft Office 365 Outlook Adapter.

This section provides a high-level overview of designing and running an integration that uses query parameters to filter the content of email messages returned by the Microsoft Office 365 Outlook Adapter.
  1. Create a REST Adapter trigger connection and Microsoft Office 365 Outlook Adapter invoke connection.
  2. Create an application integration.
  3. Drag the REST Adapter into the integration canvas and create the following query parameters:

    The Edit Request Parameters page shows fields for Operation Name, Resource URI, and HTTP Methods. Below this is the Specify Query Parameters section, which includes Add and Remove buttons. Below this is a table with columns for Name and Data Type. Six query parameters are listed.

  4. Drag the Microsoft Office 365 Outlook Adapter into the integration canvas and configure it as follows.
    1. On the Basic Info page, enter the name.
    2. On the Operations page, select Get messages to return a collection of emails from your mail box.
    3. On the Request Parameters page, select the query parameters to use to filter the content of email messages returned by the Microsoft Office 365 Outlook Adapter.

      The Edit Request Parameters page shows the Query Parameters field, which includes the label Enter name to filter. Below this is the Available Query Parameters section and the Selected Query Parameters section. Six parameters are selected.

  5. Open the mapper and map the source REST Adapter query parameters to the target Microsoft Office 365 Outlook Adapter query parameters.

    The mapper shows the Sources, Mapping canvas, and Target sections. Six query parameters are mapped from the source section to the target section.

  6. Drag a data stitch action below the Microsoft Office 365 Outlook Adapter to save the results of the Microsoft Office 365 Outlook Adapter operation in a variable.

    The Configure stitch section shows the stitch name and the value set. The edit icon appears in the upper right.

  7. Activate the integration.
  8. Click the Actions Actions icon menu, and select Run.
  9. Specify values for the following parameters and deselect any unused parameters, then click Run.
    URI Parameter Value Result of Setting
    trigger_query_param_for_top 2 Returns two emails.
    trigger_query_param_for_search Enterprise Returns emails that include the word Enterprise somewhere in the object properties.
    trigger_query_param_for_select subject, isRead, createdDateTime Returns emails that include these object properties.
    When processing completes, the Response section shows two emails returned with the following content:
    • The word Enterprise
    • The subject, isRead, and createdDateTime object properties


    The Response section is shown. The Status field and Instance ID field are shown. Below this is the Body column and the Headers column. The contents of the header are described above this image.

    Rerun the integration again with slightly different query parameters.

  10. Deselect trigger_query_param_for_search and select trigger_query_param_for_filter this time.
  11. Specify values for the following parameters, then click Run.
    URI Parameter Value Result of Setting
    trigger_query_param_for_top 2 Returns two emails.
    trigger_query_param_for_filter isRead eq true Returns emails in which the isRead object property is set to true, meaning the email has been read.
    trigger_query_param_for_select subject, isRead, createdDateTime Returns emails that include these object properties.
    When processing completes, the Response section shows two emails returned with the following content:
    • The subject, isRead, and createdDateTime object properties
    • The isRead object property set to true


    The Body column and the Headers column are shown. The contents of the header are described above this image.