SvRooij.TeamsMonitor.Core 0.3.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package SvRooij.TeamsMonitor.Core --version 0.3.0
NuGet\Install-Package SvRooij.TeamsMonitor.Core -Version 0.3.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SvRooij.TeamsMonitor.Core" Version="0.3.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add SvRooij.TeamsMonitor.Core --version 0.3.0
#r "nuget: SvRooij.TeamsMonitor.Core, 0.3.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install SvRooij.TeamsMonitor.Core as a Cake Addin
#addin nuget:?package=SvRooij.TeamsMonitor.Core&version=0.3.0

// Install SvRooij.TeamsMonitor.Core as a Cake Tool
#tool nuget:?package=SvRooij.TeamsMonitor.Core&version=0.3.0

SvRooij.TeamsMonitor.Core

Nuget badge Number of github stars Number of github issues Source on github

GitHub Sponsors Check my blog

A simple library you can use to connect to your local Teams Client. This library manages the required websocket connection so you can get instant updates from your Teams client.

You can also control various settings using this library. Just explore all the methods on the TeamsSocket.

Sample code

using var socket = new TeamsSocket(new TeamsSocketOptions("{token-from-teams-client}"));
socket.Update += (object sender, MeetingUpdate update) => { ... }
await socket.ConnectAsync(true, cancellationToken);

dotnet tool available

There also is an application available, if you just want to forward your Teams status to any webserver (like home assistant).

Teams has a local api?

Yes, it does! If you never heard of it, that might be right because it was released February 1st 2023. Once you enable it, you get a local api token.

I'm not explaining what the api looks like, as Martijn Smit already did that. For now you just need to know, if you enable the local api your Teams client will open a websocket server at localhost post 8124.

You can just use any client that supports websockets and connect to the following url.

ws://localhost:8124?token=API-TOKEN-FROM-PRIVACY&protocol-version=1.0.0&manufacturer=MuteDeck&device=MuteDeck&app=MuteDeck&app-version=1.4

If something changes to your meeting status (or any of the other values), you'll get a JSON encoded message on the open websocket connection that looks like:

{
    "apiVersion": "1.0.0",
    "meetingUpdate": {
        "meetingState": {
            "isMuted": false,
            "isCameraOn": true,
            "isHandRaised": false,
            "isInMeeting": false,
            "isRecordingOn": false,
            "isBackgroundBlurred": false
        },
        "meetingPermissions": {
            "canToggleMute": false,
            "canToggleVideo": true,
            "canToggleHand": false,
            "canToggleBlur": false,
            "canToggleRecord": false,
            "canLeave": false,
            "canReact": false
        }
    }
}

Socials

LinkedIn Profile Link Mastodon Follow on Twitter Check my blog Number of github stars

If you like my Teams Monitor, please give me a shout out on any of these platforms.

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net6.0

    • No dependencies.
  • net7.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
0.4.1 152 11/27/2023
0.3.0 163 3/17/2023