Scxp.Sdk 0.1.6

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

Scxp.Sdk

.NET SDK for the Symmetric Context Exchange Protocol (SCXP) — a protocol for exchanging tool catalogs and tool calls between a consumer (which discovers and invokes tools) and a provider (which registers and serves them).

The SDK is transport-agnostic: you bring the transport (WebSocket, TCP, stdio, ...) by implementing a small IChannel, and the SDK handles the protocol — handshake, id correlation, batching, and Gen A tool-schema generation.

Install

dotnet add package Scxp.Sdk

Provider — expose tools

using Scxp.Sdk;

public class Tools
{
    [Tool(Name = "add", Domain = "com.example.math", Description = "Add two integers.")]
    public int Add(int a, int b) => a + b;
}

var catalog = ProviderCatalog.FromObject(new Tools(), new Info { Name = "my-provider", Version = "1.0.0" });

// `channel` is your IChannel implementation, already connected.
var provider = await Provider.CreateAsync(channel, catalog);
// The provider now serves tools/list and tools/call.

Consumer — discover and invoke tools

using Scxp.Sdk;
using System.Text.Json.Nodes;

// `channel` is your IChannel implementation, already connected.
var consumer = await Consumer.CreateAsync(channel, new ConsumerConfig
{
    Info = new Info { Name = "my-app", Version = "1.0.0" },
});

var manifest = await consumer.ListToolsAsync();                                  // discover
var result = await consumer.CallToolAsync("add", new JsonObject { ["a"] = 2, ["b"] = 3 });
// result.Content[0] -> "5"

Bring your own transport

Implement IChannel (send bytes, receive bytes, observe close). A runnable WebSocket example lives in the repository under examples/.

License

MIT.

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.
  • net10.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.1.6 1,247 9/7/2026
0.1.4 784 7/24/2026
0.1.2 120 7/23/2026
0.1.1 106 7/23/2026
0.1.0 114 7/15/2026

0.1.6: Adds [ToolDomain] — domain-level description/when_to_use/when_not_to_use are now emitted in the tools/list manifest, so a consumer can choose between domains by prose instead of by role name. Declared on the class owning the domain's tools; omitting it emits the same manifest as before. In sync with scxp (Python) 0.1.6. Supports SCXP protocol version 1.