MacroDeck.Plugin.Hosting 3.0.0-preview.10

This is a prerelease version of MacroDeck.Plugin.Hosting.
dotnet add package MacroDeck.Plugin.Hosting --version 3.0.0-preview.10
                    
NuGet\Install-Package MacroDeck.Plugin.Hosting -Version 3.0.0-preview.10
                    
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="MacroDeck.Plugin.Hosting" Version="3.0.0-preview.10" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="MacroDeck.Plugin.Hosting" Version="3.0.0-preview.10" />
                    
Directory.Packages.props
<PackageReference Include="MacroDeck.Plugin.Hosting" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add MacroDeck.Plugin.Hosting --version 3.0.0-preview.10
                    
#r "nuget: MacroDeck.Plugin.Hosting, 3.0.0-preview.10"
                    
#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.
#:package MacroDeck.Plugin.Hosting@3.0.0-preview.10
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=MacroDeck.Plugin.Hosting&version=3.0.0-preview.10&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=MacroDeck.Plugin.Hosting&version=3.0.0-preview.10&prerelease
                    
Install as a Cake Tool

MacroDeck.Plugin.Hosting

Write a Macro Deck plugin the way you would write an ASP.NET Core application. Registration, protocol framing, heartbeats, backpressure and reconnection are handled for you; you write integrations and let dependency injection build them.

A plugin declares what it is in a manifest.json, copied to the output directory so it sits at the plugin's content root:

{
  "manifestVersion": 1,
  "id": "com.example.my-plugin",
  "name": "My Plugin",
  "version": "1.0.0",
  "icon": "assets/icon.svg",
  "entrypoints": { "win-x64": { "executable": "MyPlugin.exe" } }
}
var plugin = MacroDeckPlugin.CreatePlugin(args)
    .RegisterIntegration<MyIntegration>()
    .Build();

await plugin.RunAsync();

You get the full generic host: IServiceCollection, IConfiguration, options binding, IHttpClientFactory, IHostedService and BackgroundService, middleware through IApplicationBuilder, an optional IPluginStartup class, and graceful shutdown.

Your plugin project needs the ASP.NET Core shared framework - either <Project Sdk="Microsoft.NET.Sdk.Web"> or a console project with <FrameworkReference Include="Microsoft.AspNetCore.App" />.

Routes under /_macrodeck/* are reserved by the SDK for health, readiness and diagnostics; mapping one yourself fails at startup rather than silently at request time.

Every capability kind an in-process integration can implement - actions, events, variables, icons, config flow, music players, weather, virtual profiles and issues - has a working remote adapter, and IIntegrationContext is a real, working call back into the host. Status: the host endpoints a plugin connects to are not in a released Macro Deck yet (#411).

Three behaviors changed recently, worth knowing if you built against an earlier version:

  • Capability invocations now dispatch concurrently, up to ProtocolLimits.MaxConcurrentInvocations at a time, rather than one at a time. A handler that shares mutable state without its own synchronization can now genuinely run concurrently with itself.
  • Integration initialization no longer runs at process start. It is gated on the connection actually being established: a resumed session is a no-op, and a non-resume reconnect shuts every integration down and re-initializes them, since cached host-side state from the old session cannot be trusted. The host telling a plugin its config changed now triggers the same re-initialize cycle, so a config flow's result reaches a running plugin without waiting for a reconnect.
  • A plugin can now invalidate the host's cached snapshot itself. Inject IPluginCatalogNotifier and call CatalogChanged(kind) after anything that changes what a later describe would answer - a config value your own InitializeAsync just read, a device that came or went. Fire-and-forget, like IEventPublisher.Publish: never throws, and a no-op with no open session.

See the plugin hosting guide for the full detail on both, and the capability parity matrix for every documented difference from an in-process integration.

Licensed under Apache-2.0.

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

NuGet packages (2)

Showing the top 2 NuGet packages that depend on MacroDeck.Plugin.Hosting:

Package Downloads
MacroDeck.Plugin.Serilog

Serilog sink for Macro Deck plugins. Forwards a plugin's own logs to the host over log.publish, so plugin authors write normal Serilog code and the entries show up in the host's log viewer.

MacroDeck.Plugin.Testing

Test host, fakes and assertions for a Macro Deck plugin built on MacroDeck.Plugin.Hosting - launch it in-process or as a real process, drive its capabilities, and inspect what it logged and published, without running Macro Deck itself.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
3.0.0-preview.10 235 9/4/2026
3.0.0-preview.8 65 9/1/2026
3.0.0-preview.7 77 8/28/2026
3.0.0-preview.6 153 8/24/2026
3.0.0-preview.5 85 8/22/2026
3.0.0-preview.4 92 8/20/2026
3.0.0-preview.3 107 8/14/2026
3.0.0-preview.2 82 8/14/2026
3.0.0-preview.1 95 8/13/2026
3.0.0-beta.12 0 9/23/2026
3.0.0-beta.11 227 9/17/2026
3.0.0-beta.7 87 9/16/2026
3.0.0-beta.6 64 9/15/2026
3.0.0-beta.5 97 9/14/2026
3.0.0-beta.4 194 9/11/2026
3.0.0-beta.3 73 9/9/2026
3.0.0-beta.2 91 9/6/2026
3.0.0-beta.1 78 9/6/2026