page_type | description | products | languages | extensions | urlFragment | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
sample |
Sample app which demonstrates how to use live share SDK inside meeting side panel. |
|
|
|
officedev-microsoft-teams-samples-meetings-sidepanel-csharp |
This sample illustrates how to implement Side Panel In-Meeting Experience and uses Live Share SDK to share data in realtime.
- Meeting Stage
- Meeting SidePanel
- Live Share SDK
- Adaptive Cards
- RSC Permissions
- App Theme
-
.NET Core SDK version 6.0
# determine dotnet version dotnet --version
-
Teams Microsoft Teams is installed and you have an account
-
dev tunnel or Ngrok (For local environment testing) latest version (any other tunneling software can also be used)
-
Run ngrok - point to port 3978
ngrok http 3978 --host-header="localhost:3978"
Alternatively, you can also use the
dev tunnels
. Please follow Create and host a dev tunnel and host the tunnel with anonymous user access command as shown below:devtunnel host -p 3978 --allow-anonymous
-
Create Microsoft Entra ID app registration in Azure portal and also register a bot with Azure Bot Service, following the instructions here.
- Ensure that you've enabled the Teams Channel
- While registering the bot, use
https://<your_tunnel_domain>/api/messages
as the messaging endpoint.NOTE: When you create your bot you will create an App ID and App password - make sure you keep these for later.
-
Clone the repository
git clone https://github.com/OfficeDev/Microsoft-Teams-Samples.git
-
If you are using Visual Studio
- Launch Visual Studio
- File -> Open -> Project/Solution
- Navigate to
samples\meetings-sidepanel\csharp
folder - Select
SidePanel.sln
file and open the solution
-
Setup and run the bot from Visual Studio: Modify the
appsettings.json
and fill in the following details:<<Microsoft-App-ID>>
- Generated from Step 2 (Application (client) ID) is the application app id<<Microsoft-App-Secret>>
- Generated from Step 2, also referred to as Client secret<<Your_Domain_URL>>
- Your application's base url. E.g. https://12345.ngrok-free.app if you are using ngrok and if you are using dev tunnels, your URL will be like: https://12345.devtunnels.ms.
-
Modify the
manifest.json
in the/AppManifest
folder and replace the following details:- <> with any random GUID or your MicrosoftAppId from Microsoft Entra ID app registration.
<<YOUR-MICROSOFT-APP-ID>>
with Application id generated from Step 2{{Base_URL}}
with base Url domain. E.g. if you are using ngrok it would behttps://1234.ngrok-free.app
then your domain-name will be1234.ngrok-free.app
and if you are using dev tunnels then your domain will be like:12345.devtunnels.ms
.{{domain-name}}
with base Url domain. E.g. if you are using ngrok it would behttps://1234.ngrok-free.app
then your domain-name will be1234.ngrok-free.app
and if you are using dev tunnels then your domain will be like:12345.devtunnels.ms
.
-
Run your app, either from Visual Studio with
F5
or usingdotnet run
in the appropriate folder. -
Navigate to
samples\meetings-sidepanel\csharp\ClientApp
folder and execute the below command.# npx @fluidframework/azure-local-service@latest
Note: Please Check the nodemodules
in ClientApp folder, Navigate to samples\meetings-sidepanel\csharp\ClientApp
if not exists, please install nodemodules using this command npm install
.
- Upload the manifest.zip to Teams (in the Apps view click "Upload a custom app")
- Go to Microsoft Teams. From the lower left corner, select Apps
- From the lower left corner, choose Upload a custom App
- Go to your project directory, the ./AppManifest folder, select the zip folder, and choose Open.
Note: If you are facing any issue in your app, please uncomment this line and put your debugger for local debug.
User interactions(Meeting Organizer)
- Add New Agenda Item - Gives provision to add new Agenda point.
- Add - Adds the agenda from Textinput to the SidePanel agenda list.
- Publish Agenda - Sends the agenda list to the meeting chat.
-
On click of "Add" button, agenda point will be added to the agenda list.
-
On click of "Publish Agenda", the agenda list will be sent to the meeting chat.
- To learn more about deploying a bot to Azure, see Deploy your bot to Azure for a complete list of deployment instructions.