aspnet-signalrlisted
Install: claude install-skill claude-dev-suite/claude-dev-suite
# ASP.NET Core SignalR - Quick Reference
> **Deep Knowledge**: Use `mcp__documentation__fetch_docs` with technology: `signalr` for comprehensive documentation.
## Hub Setup
```csharp
// Program.cs
builder.Services.AddSignalR();
app.MapHub<ChatHub>("/hubs/chat");
```
## Strongly-Typed Hub
```csharp
public interface IChatClient
{
Task ReceiveMessage(string user, string message);
Task UserJoined(string user);
Task UserLeft(string user);
}
public class ChatHub : Hub<IChatClient>
{
public async Task SendMessage(string user, string message)
{
await Clients.All.ReceiveMessage(user, message);
}
public async Task JoinRoom(string room)
{
await Groups.AddToGroupAsync(Context.ConnectionId, room);
await Clients.Group(room).UserJoined(Context.User?.Identity?.Name ?? "Anonymous");
}
public async Task LeaveRoom(string room)
{
await Groups.RemoveFromGroupAsync(Context.ConnectionId, room);
await Clients.Group(room).UserLeft(Context.User?.Identity?.Name ?? "Anonymous");
}
public override async Task OnConnectedAsync()
{
await base.OnConnectedAsync();
}
public override async Task OnDisconnectedAsync(Exception? exception)
{
await base.OnDisconnectedAsync(exception);
}
}
```
## Sending from Outside Hub
```csharp
public class NotificationService
{
private readonly IHubContext<ChatHub, IChatClient> _hubContext;
public NotificationService(IHubContext<Chat