Banner background image
Integration Service Activities
Last updated Feb 28, 2024

Retrieve all the messages of a private chat with another user

Applications Used: Microsoft Teams

Description: There might be cases where all the unread chats between you and another user must be retrieved, especially if the user is a bot. While retrieving all the messages from a group chat or channel is pretty straightforward, doing the same for one-on-one conversations requires an additional step which will be explained in this page

The workflow uses Microsoft Teams activities Get Individual Chat and List All Chat Messages.

Building the workflow

  1. Open Studio Web and create a new project.
  2. Add the Get Individual Chat activity to your workflow. Here, we pass the user email (UPN) as input for retrieving the Chat ID. Configure the Get Individual Chat activity as follows:
    1. Set up your Microsoft Teams connection.
    2. Configure the User email (UPN) iproperty field with the e-mail of the user whose chat needs to be retrieved.
    3. Select the appropriate role between Owner (for team or organization members) or Guest for an external user, that uses Azure AD or other Office services.

    docs image
  3. Add a List All Chat Messages activityto the canvas. At this step, we pass the Chat ID that was retrieved in the previous step as input:
    1. Use a variable for the Chat property field by navigating to See More > Use variable. Select Chat ID under Get Individual Chat
    2. You can filter the chat messages based on createdDateTime or modifiedDateTime
    3. Similarly, the chat messages can be sorted by createdDateTime or modifiedDateTime. Only descending order is supported.
    docs image
  4. You can now retrieve all the chat messages with that respective individual user.

  • Building the workflow

Was this page helpful?

Get The Help You Need
Learning RPA - Automation Courses
UiPath Community Forum
Uipath Logo White
Trust and Security
© 2005-2024 UiPath. All rights reserved.