Faactory.Canonical 0.1.0

dotnet add package Faactory.Canonical --version 0.1.0
                    
NuGet\Install-Package Faactory.Canonical -Version 0.1.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="Faactory.Canonical" Version="0.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Faactory.Canonical" Version="0.1.0" />
                    
Directory.Packages.props
<PackageReference Include="Faactory.Canonical" />
                    
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 Faactory.Canonical --version 0.1.0
                    
#r "nuget: Faactory.Canonical, 0.1.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.
#:package Faactory.Canonical@0.1.0
                    
#: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=Faactory.Canonical&version=0.1.0
                    
Install as a Cake Addin
#tool nuget:?package=Faactory.Canonical&version=0.1.0
                    
Install as a Cake Tool

Canonical API

A small, transport-neutral API runtime for .NET.

Registration

services.AddCanonicalApi();

ICanonicalApiBuilder registers named endpoints:

var apiBuilder = serviceProvider.GetRequiredService<ICanonicalApiBuilder>();

apiBuilder.Map(
    "apps.deploy",
    async (
        DeployRequest request,
        DeploymentService service,
        CancellationToken cancellationToken ) =>
    {
        return await service.DeployAsync( request, cancellationToken );
    }
);

Handlers can receive one payload, dependency-injection services, ApiContext, IServiceProvider, and CancellationToken.

Handlers may return synchronous values, void, Task, Task<T>, ValueTask, or ValueTask<T>.

Execution

Transports create an ApiContext with an ICanonicalApiWriter and execute it through ICanonicalApi:

var context = new ApiContext(
    "apps.deploy",
    requestId,
    payload,
    serviceProvider,
    writer,
    cancellationToken
);

var api = serviceProvider.GetRequiredService<ICanonicalApi>();

await api.ExecuteAsync( context );

Events and streams are request-scoped. Each request ends with one response or error.

Architecture

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 Faactory.Canonical:

Package Downloads
Faactory.Canonical.AspNetCore

ASP.NET Core HTTP and WebSocket integration for Canonical API.

Faactory.Canonical.Client

Client for the Canonical WebSocket protocol.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.0 121 8/27/2026