{"id":18339490,"url":"https://github.com/antelcat/websocket","last_synced_at":"2026-02-07T18:34:22.045Z","repository":{"id":257815876,"uuid":"869512711","full_name":"Antelcat/WebSocket","owner":"Antelcat","description":".NET wrap for WebSocket","archived":false,"fork":false,"pushed_at":"2024-12-08T15:34:34.000Z","size":55,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-22T19:53:49.470Z","etag":null,"topics":["websocket","websocket-server","wrapper"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Antelcat.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-08T12:25:52.000Z","updated_at":"2024-12-08T15:34:38.000Z","dependencies_parsed_at":"2024-12-08T16:22:47.370Z","dependency_job_id":null,"html_url":"https://github.com/Antelcat/WebSocket","commit_stats":null,"previous_names":["antelcat/websocket"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Antelcat/WebSocket","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Antelcat%2FWebSocket","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Antelcat%2FWebSocket/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Antelcat%2FWebSocket/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Antelcat%2FWebSocket/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Antelcat","download_url":"https://codeload.github.com/Antelcat/WebSocket/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Antelcat%2FWebSocket/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29203782,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-07T17:44:10.191Z","status":"ssl_error","status_checked_at":"2026-02-07T17:44:07.936Z","response_time":63,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["websocket","websocket-server","wrapper"],"created_at":"2024-11-05T20:18:00.944Z","updated_at":"2026-02-07T18:34:22.029Z","avatar_url":"https://github.com/Antelcat.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# WebSocket\n .NET wrap for WebSocket\n\n# Example\n\nin `Program.cs`\n\n```csharp\nvar builder = WebApplication.CreateBuilder(args);\n\n...\nbuilder.Services.AddWebSockets();\n...\n    \nvar app = builder.Build();\n...\n// remember to call UseWebSockets() before MapWebSocket()\napp.UseWebSockets(); \napp.MapWebSocket\u003cSampleWebSocketClient\u003e(\"/WebSocket\");\n...\n```\n\nfor `SampleWebSocketClient`\n\nwhich lifetime is `Transient` or `Scoped`, each WebSocket connection will create corresponding instance\n\n```csharp\n// define your client model to receive message from WebSocket client \npublic class SampleWebSocketClient : Antelcat.AspNetCore.Client\n{\n    protected override async Task OnConnectedAsync()\n    {\n        Console.WriteLine($\"{Context.ConnectionId} connected\");\n    }\n\n    protected override async Task OnDisconnectedAsync(Exception? exception)\n    {\n        Console.WriteLine($\"{Context.ConnectionId} disconnected due to {exception}\");\n    }\n\n    protected override async Task OnReceivedTextAsync(string text, CancellationToken token)\n    {\n        await this.SendAsync(text, token);\n    }\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fantelcat%2Fwebsocket","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fantelcat%2Fwebsocket","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fantelcat%2Fwebsocket/lists"}