Forum Discussion

KRife730's avatar
KRife730
Copper Contributor
Jul 09, 2020
Solved

Microsoft Teams apps

Hello, I have an issue I am hoping can be resolved but not sure if Microsoft teams has the capability.   For my place of work, it is required that staff complete or are in compliance with training...
  • YannickReekmans's avatar
    Jul 12, 2020

    KRife730 I don't see this much as a Teams capability, but more as a combination of multiple technologies. There are multiple approaches possible depending on your specific setup, I'll give some options with my own assumptions.

     

    Option 1

    Assumption: Shifts are linked to a Teams team, users can only be part of this team when they completed the form

    • You create the Microsoft Forms (or Pro) form
    • You create a Power Automate flow/Logic App with trigger "Forms -> When a new response is received".
    • Populate the flow to extract the user from the response, and add it to the Teams team
    • The user can start scheduling shifts.

    Option 2

    Assumption: Shifts are linked to a Teams team, and users are already in the team. Users ALWAYS need to complete the Form first, there is no difference for shifts in one team vs shifts in another team.

    • You create the Microsoft Forms (or Pro) form
    • You create two App Permission Policies in Teams Admin Center. One containing the Shifts app and another one that doesn't contain it.
    • You assign the "no Shifts app" policy to all your users
    • You create a Power Automate flow/Logic App with trigger "Forms -> When a new response is received".
    • Populate the flow to extract the user from the response, and trigger an Azure Automation runbook (maybe Azure Function?)
    • You create this Azure Automation runbook/Azure Function that runs the Teams Powershell module to assign the "with Shifts app" policy to this specific user.

    I hope this sets you an your way to find a solution.

Resources