Voxa.AspNetCore 0.4.0-alpha

This is a prerelease version of Voxa.AspNetCore.
There is a newer prerelease version of this package available.
See the version list below for details.
dotnet add package Voxa.AspNetCore --version 0.4.0-alpha
                    
NuGet\Install-Package Voxa.AspNetCore -Version 0.4.0-alpha
                    
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="Voxa.AspNetCore" Version="0.4.0-alpha" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Voxa.AspNetCore" Version="0.4.0-alpha" />
                    
Directory.Packages.props
<PackageReference Include="Voxa.AspNetCore" />
                    
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 Voxa.AspNetCore --version 0.4.0-alpha
                    
#r "nuget: Voxa.AspNetCore, 0.4.0-alpha"
                    
#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 Voxa.AspNetCore@0.4.0-alpha
                    
#: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=Voxa.AspNetCore&version=0.4.0-alpha&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Voxa.AspNetCore&version=0.4.0-alpha&prerelease
                    
Install as a Cake Tool

Voxa.AspNetCore

Fluent ASP.NET Core integration for Voxa. Drop a real-time voice pipeline into a MAF-using app with one fluent expression — no manual Pipeline.Build() / PipelineRunner plumbing, no per-connection boilerplate.

app.MapVoxaVoice("/voice", voice => voice
    .UseSpeechToText(() => OpenAISpeech.StreamingTranscription(opts))
    .UseTranscriptionFilter()
    .UseMicrosoftAgent(agent)
    .UseSentenceAggregator()
    .UseTextToSpeech(() => OpenAISpeech.Synthesis(opts)));

That's the whole endpoint. WebSocket lifecycle, source/sink wiring, deadlock-safe agent loop, frontend-tool round-trips, and turn-boundary frames are all wired for you.

What MapVoxaVoice does

  • Maps a GET route that upgrades to a WebSocket on request.
  • Accepts the socket and (if configured) reads a typed hello envelope before the pipeline starts.
  • Builds a per-connection pipeline by invoking each registered processor factory: WebSocketAudioSource → registered processors (in order) → WebSocketAudioSink.
  • Runs a PipelineRunner for the connection's lifetime; tears down cleanly when the client disconnects or EndFrame is observed.

Builder surface

voice.UseProcessor(ctx => new MyProcessor(ctx.RequestServices.GetRequiredService<...>()))
voice.UseProcessor(() => new MyStatelessProcessor())

// Speech vendor convenience
voice.UseSpeechToText(() => OpenAISpeech.StreamingTranscription(opts))
voice.UseTextToSpeech(() => OpenAISpeech.Synthesis(opts))
voice.UseSentenceAggregator()
voice.UseTranscriptionFilter()
voice.UseSilenceGate()

// Microsoft Agent Framework
voice.UseMicrosoftAgent(agent)
voice.UseMicrosoftAgent(agent, options => { /* configure */ })
voice.UseMicrosoftAgent(ctx => agentFactory(ctx), (ctx, options) => { /* configure */ })

// Endpoint metadata
voice.RequireAuthorization("MyPolicy")
voice.RequireCors("MyCorsPolicy")

// Hello envelope (typed; lands in HttpContext.Items[VoiceHello.HelloMetadataKey])
voice.UseWebSocketHello<MyHello>((ws, ct) => ParseAsync(ws, ct))

// Custom frame types — emit your own JSON envelope without subclassing the sink
voice.UseCustomFrameSerializer(frame =>
    frame is MyFrame f ? JsonSerializer.Serialize(new { type = "myFrame", ... }) : null)

Advanced MAF integration

UseMicrosoftAgent(agent, options => {...}) exposes the full MicrosoftAgentVoiceOptions surface for hosts that need persisted history, frontend tools, post-turn audit, sanitized backend-tool progress, etc.:

voice.UseMicrosoftAgent(agent, options =>
{
    options.BuildMessages = (turn, ct) => LoadHistoryAsync(turn.UserText, ct);
    options.IsFrontendTool = name => myFrontendCatalog.Contains(name);
    options.BuildBackendToolStatus = name => name switch
    {
        "pf_get_spending_summary" => "Checking your spending...",
        _ => null,
    };
    options.OnTurnCompleted = (turn, summary, ct) => RecordAuditAsync(turn, summary, ct);
});

See the main repo for the full options reference and the underlying AgentLoopProcessor design.

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 Voxa.AspNetCore:

Package Downloads
Voxa

Batteries-included Voxa package. One package reference: AddVoxa(cfg) + MapVoxaVoice("/voice").UseDefaults() gives a working voice bot with STT, TTS, VAD, and an OpenAI chat agent — no knowledge of frames required.

Voxa.Transports.Twilio

Twilio Media Streams transport for the Voxa pipeline (VTL-001). MapVoxaTwilioVoice("/twilio") serves the TwiML webhook and accepts the media WebSocket, running a phone call through the SAME composed VAD→STT→agent→TTS pipeline as the native route — with barge-in. The wire is hand-rolled JSON over the shared Voxa.Transports.Telephony base (μ-law 8 kHz); no Twilio SDK, no WebRTC. Includes X-Twilio-Signature validation.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.7.2-alpha 131 7/10/2026
0.7.1-alpha 100 7/10/2026
0.7.0-alpha 97 7/10/2026
0.6.0-alpha 103 6/22/2026
0.5.0-alpha 95 6/13/2026
0.4.0-alpha 1,723 5/10/2026