Embedding Model-Driven Apps in Teams

Model-driven apps provide a no-code or low-code component approach to app development.  Typically, Model-driven apps run with the Unified Interface client, which provides a responsive, accessible design running in browsers and mobile devices. Now, model-driven apps can be embedded into Teams directly. Thus, it will help users save time and will allow them to access the required apps from Teams directly. 

The following are the steps to embed a model-driven app: 

  • Enable Model-driven integration with Teams 

These settings can be accessed from the admin portal. 

Under settings for the environment, select Integration and then choose Microsoft Teams Integration.  Set Allow model-driven apps to be embedded within Microsoft Teams to On. 

Microsoft Teams Integration

Select Additional Microsoft Teams settings > System Settings > General tab and choose the following options (if not set already) 

Microsoft Teams settings

  • Create an app in Dynamics CRM (Customer Relationship Management) 

         Create a new app with an existing or default solution inside CRM. Define the Sitemap using site map designer and add components (entities and related items, such as forms, charts, views, and dashboards) or edit existing components if needed. 

  • Publish the App 

        Save and publish the app 

publish the app

  • Assign security roles to the App 

        The App must be given some security role(s) to access it. The user can perform operations accordingly to the security role. 

  • Embed the App with Teams 

        In Microsoft Teams, select a team and a channel under that team. For example, in this blog, the General channel under the Contoso team is selected. 

The model-driven application embedded in Teams has a similar experience to the one used from Dynamics. User can perform all the operations (Create, Update, Delete, Assign, etc.). Thus, it feels exactly like using Dynamics CRM from the browser.

The following Demo App is created for this blog: 

The App called Demo App contains Out of the Box, Contact entity only. As our user is a System Administrator, it can perform all CRUD (Create, Read, Update, Delete) operations on this entity. Any user who does not have permission on this entity or specific permissions/ security roles can access this App accordingly. The permissions and security roles will be set from CRM. Anytime the App is modified, it can be refreshed inside Teams to reflect the recent changes immediately after published. 

Demo App contains

Some of the use cases for embedding the model-driven App into Teams can be  

  1. To directly access the timesheet and expenses app, which are commonly used apps, from Teams. 
  2. Showing Leads and Opportunities directly under a Sales or Marketing channel can be timesaving.  
  3. Availability of various charts and dashboards for users for a quick look. 

Conclusion 

The model-driven apps can be tailored according to the needs in Dynamics and can be shared across multiple channels, chats, or group chats easily.