SignalWire.Sdk 1.1.2

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

<div align="center"> <a href="https://signalwire.com" target="_blank"> <img src="https://github.com/user-attachments/assets/0c8ed3b9-8c50-4dc6-9cc4-cc6cd137fd50" width="500" /> </a>

SignalWire SDK for .NET

Build AI voice agents, control live calls over WebSocket, and manage every SignalWire resource over REST -- all from one package.

<p align="center"> <a href="https://developer.signalwire.com/sdks/agents-sdk" target="_blank">Documentation</a> · <a href="https://github.com/signalwire/signalwire-docs/issues/new/choose" target="_blank">Report an Issue</a> · <a href="https://www.nuget.org/packages/SignalWire.Sdk" target="_blank">NuGet</a> </p>

<a href="https://discord.com/invite/F2WNYTNjuF" target="_blank"><img src="https://img.shields.io/badge/Discord%20Community-5865F2" alt="Discord" /></a> <a href="LICENSE"><img src="https://img.shields.io/badge/MIT-License-blue" alt="MIT License" /></a> <a href="https://github.com/signalwire/signalwire-dotnet" target="_blank"><img src="https://img.shields.io/github/stars/signalwire/signalwire-dotnet" alt="GitHub Stars" /></a>

<a href="https://codespaces.new/signalwire/signalwire-dotnet" target="_blank"><img src="https://github.com/codespaces/badge.svg" alt="Open in GitHub Codespaces" /></a> <a href="https://replit.com/new/github/signalwire/signalwire-dotnet" target="_blank"><img src="https://replit.com/badge/github/signalwire/signalwire-dotnet" alt="Run on Replit" /></a>

</div>


What's in this SDK

Capability What it does Quick link
AI Agents Build voice agents that handle calls autonomously -- the platform runs the AI pipeline, your code defines the persona, tools, and call flow Agent Guide
RELAY Client Control live calls and SMS/MMS in real time over WebSocket -- answer, play, record, collect DTMF, conference, transfer, and more RELAY docs
REST Client Manage SignalWire resources over HTTP -- phone numbers, SIP endpoints, Fabric AI agents, video rooms, messaging, and 18+ API namespaces REST docs
dotnet add package SignalWire.Sdk

AI Agents

Each agent is a self-contained microservice that generates SWML (SignalWire Markup Language) and handles SWAIG (SignalWire AI Gateway) tool calls. The SignalWire platform runs the entire AI pipeline (STT, LLM, TTS) -- your agent just defines the behavior.

using SignalWire.Agent;
using SignalWire.SWAIG;

var agent = new AgentBase(new AgentOptions { Name = "my-agent", Route = "/agent" });

agent.AddLanguage("English", "en-US", "inworld.Mark");
agent.PromptAddSection("Role", "You are a helpful assistant.");

agent.DefineTool("get_time", "Get the current time", new { },
    (args, rawData) => new FunctionResult($"The time is {DateTime.Now:HH:mm:ss}"));

agent.Run();

Agent Features

  • Prompt Object Model (POM) -- structured prompt composition via PromptAddSection()
  • SWAIG tools -- define functions with DefineTool() that the AI calls mid-conversation
  • Skills system -- add capabilities with one-liners: agent.AddSkill("datetime")
  • Contexts and steps -- structured multi-step workflows with navigation control
  • DataMap tools -- tools that execute on SignalWire's servers without your own webhook
  • Dynamic configuration -- per-request agent customization for multi-tenant deployments
  • Call flow control -- pre-answer, post-answer, and post-AI verb insertion
  • Prefab agents -- ready-to-use archetypes (InfoGatherer, Survey, FAQ, Receptionist, Concierge)
  • Multi-agent hosting -- serve multiple agents on a single server with AgentServer
  • SIP routing -- route SIP calls to agents based on usernames
  • Session state -- persistent conversation state with global data and post-prompt summaries
  • Security -- auto-generated basic auth, function-specific HMAC tokens
  • Serverless -- Azure Functions, AWS Lambda, and auto-detection adapters

RELAY Client

Real-time call control and messaging over WebSocket. The RELAY client connects to SignalWire via the Blade protocol and gives you async control over live phone calls and SMS/MMS.

using SignalWire.Relay;

var client = new RelayClient(new RelayOptions
{
    Project = "your-project-id",
    Token = "your-token",
    Host = "example.signalwire.com",
    Contexts = ["default"],
});

client.OnCall(async call =>
{
    await call.Answer();
    var action = await call.Play(new[] { new TtsMedia("Welcome to SignalWire!") });
    await action.Wait();
    await call.Hangup();
});

await client.Run();
  • 57+ calling methods (play, record, collect, detect, tap, stream, AI, conferencing, and more)
  • SMS/MMS messaging with delivery tracking
  • Action objects with Wait(), Stop(), Pause(), Resume()
  • Auto-reconnect with exponential backoff

See the RELAY documentation for the full guide, API reference, and examples.


REST Client

Synchronous REST client for managing SignalWire resources and controlling calls over HTTP.

using SignalWire.REST;

var client = new RestClient("project-id", "token", "example.signalwire.com");

client.Fabric.AiAgents.Create(new { name = "Support Bot" });
client.Calling.Play(callId, new { play = new[] { new { type = "tts", text = "Hello!" } } });
client.PhoneNumbers.List(new { area_code = "512" });
client.Datasphere.Documents.Search(new { query_string = "billing policy" });
  • 21 namespaced API surfaces: Fabric, Calling, Video, Datasphere, Compat, and more
  • HttpClient with connection pooling
  • Dictionary returns -- raw data, no wrapper objects

See the REST documentation for the full guide, API reference, and examples.


Installation

dotnet add package SignalWire.Sdk

Requires .NET 8.0+. Works with C#, F#, VB.NET, and any CLR language.

Environment Variables

Variable Used by Description
SIGNALWIRE_PROJECT_ID RELAY, REST Project identifier
SIGNALWIRE_API_TOKEN RELAY, REST API token
SIGNALWIRE_SPACE RELAY, REST Space hostname
SWML_BASIC_AUTH_USER Agents Basic auth username (default: auto-generated)
SWML_BASIC_AUTH_PASSWORD Agents Basic auth password (default: auto-generated)
SWML_PROXY_URL_BASE Agents Base URL when behind a reverse proxy
SIGNALWIRE_LOG_LEVEL All Logging level (debug, info, warn, error)
SIGNALWIRE_LOG_MODE All Set to off to suppress all logging

Testing

dotnet test

License

MIT -- see LICENSE for details.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  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.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  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

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
1.1.2 102 6/1/2026
1.1.1 95 6/1/2026