3

I want to build a real-time data API using SignalR on the server. I will be building a web client that will connect with the API the "usual way".

However, I would like 3rd parties to also be able to connect to this API. These clients may be web clients or other platforms such as Windows, Mac, iOS, etc. Ideally, they'd just be able to connect via plain websockets and be totally agnostic of whether SignalR is in use on the server or not.

It seems that there are a lot of libraries out there for clients on different platforms (Swift, Objective-C, Java/Android, c++, etc) that would allow them to connect to my API. Another approach (that some of these libraries use) is to embed a hidden web view. Either way it's quite a bit to impose on the 3rd parties. It needs to be simpler.

Is there a way to write a web application (for example) that only uses standard websocket calls and talks directly to my SignalR server without needing to include any SignalR specific scripts as dependencies? Can a non-web client do the same (i.e. make standard websocket calls, with no embedded web view)?

Basically, I would like the effort 3rd parties need to go through to be no greater than if I decide to make a vanilla websocket API and avoid signalR entirely.

jtheis
  • 916
  • 3
  • 12
  • 28

1 Answers1

0

No. You can´t do that currently. But that will be possible in the next version of SignalR (Asp.NET Core Sockets) according to this video. The first beta release is planned for mid 2017.

UPDATE

It seams that it´s indeed possible with some workarounds. Take a look at this link.

xleon
  • 6,201
  • 3
  • 36
  • 52