digitalmars.D.learn - Is there websocket client implementation for D
- Ilya Korobitsyn (7/7) Mar 24 2015 Hello!
- Rikki Cattermole (2/9) Mar 24 2015 It appears you are on your own.
- thedeemon (5/7) Mar 25 2015 There's some WebSocket stuff here:
- Adam D. Ruppe (8/10) Mar 25 2015 Yeah, I've been meaning to write a client for a while but haven't
- aberba (2/12) May 21 2017 How about now?
- kerdemdemir (17/17) Jun 11 2018 Hi
- Heromyth (4/9) Sep 10 2018 We just implemented one in D.
- kerdem (10/22) Dec 19 2019 Hi
Hello! Is there any websocket client implementation in D? I know there is WS server as a part of vibe.d, but it does not seem to include client. Maybe there are some library bindings that I've missed? Thank you, Ilya
Mar 24 2015
On 25/03/2015 6:55 a.m., Ilya Korobitsyn wrote:Hello! Is there any websocket client implementation in D? I know there is WS server as a part of vibe.d, but it does not seem to include client. Maybe there are some library bindings that I've missed? Thank you, IlyaIt appears you are on your own.
Mar 24 2015
On Tuesday, 24 March 2015 at 17:55:38 UTC, Ilya Korobitsyn wrote:Hello! Is there any websocket client implementation in D?There's some WebSocket stuff here: https://github.com/adamdruppe/arsd/blob/master/cgi.d It's for server side, but probably contains stuff you need for client too.
Mar 25 2015
On Wednesday, 25 March 2015 at 07:12:56 UTC, thedeemon wrote:It's for server side, but probably contains stuff you need for client too.Yeah, I've been meaning to write a client for a while but haven't gotten around to it yet. What you do is make a HTTP request with a particular header, and if the server likes it, you're OK and can send messages. If not, the failure should be gracefully reported. Could probably write it up in a couple hours.... if I had a couple hours :(
Mar 25 2015
On Wednesday, 25 March 2015 at 15:46:31 UTC, Adam D. Ruppe wrote:On Wednesday, 25 March 2015 at 07:12:56 UTC, thedeemon wrote:How about now?It's for server side, but probably contains stuff you need for client too.Yeah, I've been meaning to write a client for a while but haven't gotten around to it yet. What you do is make a HTTP request with a particular header, and if the server likes it, you're OK and can send messages. If not, the failure should be gracefully reported. Could probably write it up in a couple hours.... if I had a couple hours :(
May 21 2017
Hi vibe.d has a client implementation. http://vibed.org/api/vibe.http.websockets/WebSocket It is as simple as : auto ws_url = URL("wss://stream.binance.com:9443/ws/ethbtc aggTrade"); auto ws = connectWebSocket(ws_url); if ( !ws.connected ) return; while ( true ) { if (ws && ws.dataAvailableForRead()) { writeln("Recieve", ws.receiveText()); } sleep(100.msecs); }
Jun 11 2018
On Tuesday, 24 March 2015 at 17:55:38 UTC, Ilya Korobitsyn wrote:Hello! Is there any websocket client implementation in D? I know there is WS server as a part of vibe.d, but it does not seem to include client. Maybe there are some library bindings that I've missed?We just implemented one in D. See https://github.com/huntlabs/hunt-http/tree/master/examples/WebSocketDemo
Sep 10 2018
On Monday, 10 September 2018 at 07:19:03 UTC, Heromyth wrote:On Tuesday, 24 March 2015 at 17:55:38 UTC, Ilya Korobitsyn wrote:Hi I wish it would compiled than I would really give it a try. It seems WebSockets moved from hunt-http to hunt-web. hunt-web dependency not yet in dub. When I cloned hunt-web I couldn't get it compiled. I have created bug : https://github.com/huntlabs/hunt-http/issues/13 I hope you have time to fix it soon. ErdemdemHello! Is there any websocket client implementation in D? I know there is WS server as a part of vibe.d, but it does not seem to include client. Maybe there are some library bindings that I've missed?We just implemented one in D. See https://github.com/huntlabs/hunt-http/tree/master/examples/WebSocketDemo
Dec 19 2019