Category Archives: MS Teams
Get Owners of a Teams Channel Using Power Automate Flow
With Power Automate it has become easier to post automated messages, and alert approvals in Microsoft Teams, in the following blog we will explore some Power Automate actions which will help us to send these alerts messages and approvals to Microsoft Teams Channel Owners only. So let’s begin…! Let’s say we have a Teams Channel with members, as shown in the snapshot below. We need to send approvals to the Owner of the channel only. Here is how it is done, Step 1: In power automate flow, search for Office 365 Group Action, and now select List all members action. Select the Teams name from the dropdown. (Comments: When a Team is created it forms an Office 365 group) Step 2: Here we will be using the Microsoft Graph API to get the owners of the group more about it in the doc – https://learn.microsoft.com/en-us/graph/api/group-list-owners?view=graph-rest-1.0&tabs=http API : GET /groups/{id}/owners To get the ID go to https://admin.microsoft.com/ and follow the snapshot below. (Comments: to get the id of the group you need to have admin privileges) Step 3: After we run the flow, we get the output for step 2 as shown in the snapshot below. So now we need to get the “mail” from the “value” from step 2, hence here we use a Select action in Power Automate to get the emails from the values from step 2. Step 4: At last, we use a join expression to club the mails separated by (;)so that we can use them in the outlook action. Power Automate Flow Screenshots: Output: Hope this helps 😉
Share Story :
Send a message/notification on Microsoft Teams as soon as an Opportunity is created in Dynamics 365 via Azure Logic Apps.
In this blog we will see the steps in order to send a automated message via Teams as soon as an Opportunity is created in Microsoft Dynamics 365. Step 1: Go to portal.azure.com and select the Azure Logic App Resource. Step 2: Enter all the details such as the Name, Resource Group, Subscription, Region, etc. required while creating a Logic App. Step 3: Select the Dynamics 365 trigger When a record is updated. Step 4: Select Opportunities entity after setting by the Dynamics 365 CRM connection Step 5: Set the data refresh time as required. Step 6: Select the IF action in the next step and the condition would be status_label=won for true. Step 7: Inside True Block select Post a message in a chat or channel option. You can also handle the condition for False block, but in this case we can leave it blank. Step 8: You can post this message in a Group, Channel or send it as a Personal chat. Step 10: Wait for the trigger successful notification. Step 11: Go to Dynamics 365 CRM and navigate to opportunities entity. Step 12: Open a test opportunity or create one if doesn’t exist and close the opportunity as won. Step 13: As soon as you closed this opportunity you may have received the following message. Hence in this blog we saw how we can send messages on MS Teams using Azure Logic Apps on triggering certain conditions. Hope this helped!
Share Story :
Integrate Teams with Dynamics 365 for Custom Entities
In this blog, we will see how to integrate Microsoft Teams with Dynamics 365 for custom entities using Postman. Step 1- Go to portal.azure.com and select Azure Active Directory Step 2- On App Registration, click on new registration Step 3- Register an application and follow the steps Name Select Multitenant Enter the required URL Click on register Step 4- Add API permissions and add a permission. The request API permission window will appear where you need to select Dynamics 365. Step 5- The permission window appears and select Dynamics 365. Step 6- As you select Dynamics CRM you will be presented the permission window. Select “Delegated permission” and Check the User Impersonation then click Add Permission button. Step 7- After permissions assigned, Grant admin consent confirmation: Click on yes. Step 8- Go to Manifest and change “allowPublicClient”: true Step 9- Go to Overview, save client ID Below table will help out to fill in the values in Postman: Variable Name URL url Dynamics URL Version 9.0 Webapiurl {{url}}/api/data/v{{version}}/ Clientid Client ID (Showed in above screenshot) callbackurl http://localhost authurl https://login.microsoftonline.com/common/oauth2/authorize?resource={{URL}} Step 10- Go to Postman, create a new environment and enter all the details in the table: Step 11- Now connect to the environment from top right most corner Step 12- Then create a new request Step 13- Include the following in body: Put status as: Enable: true and Logical Entity Name: Schema name of the entity. Step 14- Go to Authorization tab. From the Dropdown Select OAuth 2.0. Now we will provide the variable values to generate token. Give a name of token Choose Grant Type Implicit and provide corresponding variables for Callback URL, Authorization URL and Client ID. Then click Get new Access Token. Step 15- Now click on Get New Access Token Step 16 – It will prompt you to login Dynamics 365 after you provide your authentication the token will generate. Step 17- Now click on Use Token Step 18- Click on Send button Step 19- Now, collaborate button will be visible in ribbon for required custom entity Hope this helps!!
Share Story :
Integration of Teams with Dynamics 365 for Custom Entities using Postman
In this blog we will see how to integrate teams with Dynamics 365 for custom entities using Postman. Solution Step 1- Go to portal.azure.com and select Azure Active Directory. Step 2- On App Registration, click on new registration Step 3-Register an application and follow the steps: Name, Select Multitenant, Enter the required url. Then, click on register. Step 4- Add API permissions and add a permission. The request API permission window will appear where you need to select Dynamics 365. Step 5-The permission window appears and select Dynamics 365 Step 6- As you select Dynamics CRM you will be presented the permission window. Select “Delegated permission” and check the User Impersonation then click Add Permission button. Step 7- After permissions assigned, Grant admin consent confirmation: Click on yes. Step 8- Go to Manifest and change “allowPublicClient”: true Step 9- Go to Overview, save client ID Variable Name URL url https://Dynamicsurl.dynamics.com/ Version 9.0 Webapiurl {{url}}/api/data/v{{version}}/ Client ID Client ID from overview callbackurl http://localhost authurl https://login.microsoftonline.com/common/oauth2/authorize?resource={{url}} Step 10- Go to Postman, create a new environment and enter all the details in the table Step 11- Now connect to the environment from top right most corner. Step 12- Then create a new request Step 13-Include the following in body: Put status as Enable: true Logical Entity Name: Schema name of the entity. Step 14- Go to Authorization From the Dropdown Select OAuth 2.0.Now we will provide the variable values to generate token. Give a name of token Choose Grant Type Implicit and provide corresponding variables for Callback URL, Auth URL and Client ID. Then click Get new Access Token. Now click on Get New Access Token Step 15- Now click on Get New Access Token Step 16- It will prompt you to login Dynamics 365 after you provide your authentication the token will generate. Step 17- Now, click on use token. Step 18- Click on send button Step 19- Now, collaborate button will be visible in ribbon for required entity. Hope this helps!!
Share Story :
Post an MS Form response to MS Teams Channel using Cloud Flows
In this blog, we will learn how to quickly design a simple Cloud Flow to post a message in MS Teams Channel when a user submits a response using MS Form. Step 1: Create an MS Form to get the responses from the targeted user. Go to https://forms.office.com/ and click on New Form to create an MS Form. Now, We will create MS Form that will take the Name, Age, Gender, Service ratting and comment which is optional as feedback. Step 2: Create a Team and Channel to post the responses Here, I am creating an Admin Team (Type — Private Team) that will be used by Management Team for organization. Now, we will add the “Feedback Responses” channel to post responses in Admin Team. Step 3: Create an Org Level Team that will be used by all team member to submit the responses (Optional — You can share the form via email or posted it on the website) Now, we will add the MS Form tab in the newly created “Feedback Form” channel so that team members can submit responses directly from MS Teams. After the channel is created, click on the + button on the top ribbon button to add a new channel tab. Look for MS Form and click to select the type of channel tab. Select Add existing form and choose your created Feedback form. After clicking on the Save button, a new Form Tab will be added to the feedback from channel of your Org Level Teams Check if Team, Channel and Form tab is visible from other users Log in with another and open the Team. Here, I have another user who has access to the Project Name team and Org Team but doesn’t have access to Admin Team as it Private Team for Management. Below is a screenshot for the same: Step 4: Create a Cloud Flow to post the response to the Private Teams channel Login to the Power Automate portal and create an Automated Cloud Flow Look for MS Form Trigger “When a new response is submitted” and click on Create to create Cloud Flow Select the Form in Cloud Flow trigger Add new step Get Response Data from MS Form Connect and select Response Id from triggering body Now, add a new step from Teams Connector Post a message (v3) to post the response in Teams Channel Configure the Team, Channel and Message (According to your requirement) Testing I have submitted the response from the MS Teams using another user: After submitting the response we get the message in the Admin Teams: Hope this helps!!!