MentorAgent Docs
Menu

ReferencePackage: Novior.MentorAgent.Server

ServerServiceExtensions class

The ServerServiceExtensions class of Novior.MentorAgent.Server.Extensions: Extension methods for registering Novior.MentorAgent.Server services.

View as Markdown
On this page

Extension methods for registering Novior.MentorAgent.Server services.

Namespace: Novior.MentorAgent.Server.Extensions. Package: Novior.MentorAgent.Server.

public static class ServerServiceExtensions

Terminal
dotnet add package Novior.MentorAgent.Server

public static IServiceCollection AddMentorAgentServer(this IServiceCollection services)

Adds the MentorAgent SignalR hub and server-side infrastructure. Call this after AddMentorAgent() in Program.cs. Then call app.MapMentorAgentServer() to expose the endpoints.

Example
builder.Services.AddMentorAgent(options => { ... });
builder.Services.AddMentorAgentServer();

It also calls AddMentorAgentMcp() and AddMentorAgentA2A(), which register the MCP server and the A2A agent when McpServerEnabled / A2AServerEnabled are set, for app.MapMentorAgentMcp() and app.MapMentorAgentA2A().